Strict-PPT closure of UC linking #
Library infrastructure toward #6043 (no cited result): proves that linking a strict-PPT UC
environment with a strict-PPT machine family preserves Environment.IsPPT when a polynomial-time
computable cap covers every reply on their interaction. A machine-wide reply bound
(Machine.IsReplyBounded) gives such a cap for every caller.
Modelling decisions and restrictions #
- Reply-length bound (
Machine.IsReplyBounded). Unlike [Can20a]'s cumulative import-based runtime budgets (Section 3.2),PPTCertificatetruncates imported replies per activation atPPTParam.replyBoundwhile leaving internal typed messages untruncated.Machine.IsReplyBoundedrequires every encoded reply exported byMto fit within a polynomial in the encoded activation parameterPPTParamalone (not in the request word or state). This gives a state-independent internal truncation capL(e)at which the outer environment'sPPTcertificate is instantiated viaEnvironment.IsPPT.isOraclePPTOn_run_wordHandle, ensuring no internal reply is truncated. Protocols that export payloads of unbounded environment-chosen length back to an outer caller are excluded from this global hypothesis. The tests inCslibFrontierTests.Crypto.UCPPTLinkinclude a strict-PPT lifted adversary whose linked environment failsEnvironment.IsPPT.
The caller-relative theorem below also admits machine families with unbounded exports when the specified caller reaches only replies covered by an efficiently computable cap.
Main definitions #
Cslib.Crypto.Protocols.UC.Machine.IsReplyBounded: every supported exported reply word fits in a polynomial of(encPPTParam n p).length.Cslib.Crypto.Protocols.UC.RepliesFitOn: a cap on the replies along the supported continuations of one caller linked to one machine.Cslib.Crypto.Protocols.UC.Computational.ReplyCap: one computable cap covers the reachable replies for a given tester, machine family and corruption set.
Main results #
Cslib.Crypto.Protocols.UC.Environment.IsPPT.isOraclePPTOn_lowerWith_link_of_reachable: a caller-specific cap on supported replies suffices for strict oracle-PPT linking.Cslib.Crypto.Protocols.UC.Environment.IsPPT.link_of_reachable: the linked UC environment is strict PPT under the same caller-specific cap.Cslib.Crypto.Protocols.UC.WordInterface.exists_polyBounded_reply_take,Cslib.Crypto.Protocols.UC.Machine.isReplyBounded_id: polynomial reply-length bound for truncated replies and for the forwarding machineMachine.id.Cslib.Crypto.Protocols.UC.Machine.IsReplyBounded.routeCorrupt,Cslib.Crypto.Protocols.UC.Machine.IsReplyBounded.liftRight,Cslib.Crypto.Protocols.UC.Machine.IsReplyBounded.hybridWrap: structural transfer lemmas for static-corruption routing, right-side interface lifting, and hybrid protocol wrapping.Cslib.Crypto.Protocols.UC.Environment.IsPPT.isOraclePPTOn_lowerWith_link: linking a strict-PPT environment with any reply-bounded strict-PPT machine family yields a uniform strict oracle-PPT program over the machine's lowered imported interface.Cslib.Crypto.Protocols.UC.Environment.IsPPT.link: linking a strict-PPT environment with a reply-bounded strict-PPT machine family preservesEnvironment.IsPPT.
Message-bound predicates #
Library construction (no cited definition): every encoded reply that the machine family M
exports, in any activation from any state with imported replies read up to p.replyBound bits,
has length at most a polynomial in (encPPTParam n p).length alone.
Transfer lemmas #
Library infrastructure (no cited result): static-corruption routing preserves
Machine.IsReplyBounded; every routed reply is either a party/network reply from M (possibly
tagged with one sum bit) or a constant none reply.
Library infrastructure (no cited result): a reply word truncated at p.replyBound, decoded and
re-encoded through a WordInterface, has length at most a polynomial in
(encPPTParam n p).length.
Library infrastructure (no cited result): the forwarding machine Machine.id is
Machine.IsReplyBounded: each exported reply is an imported reply truncated at p.replyBound
and re-encoded.
Library infrastructure (no cited result): lifting a reply-bounded machine family past a left
pass-through interface preserves Machine.IsReplyBounded; forwarded left-channel replies are
normalized from at most p.replyBound bits in polynomial time, and right-channel replies are
bounded by M's bound.
Library infrastructure (no cited result), toward #6043: hybridWrap preserves
Machine.IsReplyBounded; network replies gain one sum bit, and forwarded subroutine-network replies
are bounded as for Machine.id.
Linking #
Every actually returned exported word fits the cap along this typed execution. The imported oracle and its state are shared by the handler and the continuation.
- pure {ιI ιE α : Type} {I : ιI → Type} {E : ιE → Type} {m : Machine I E} {iI : WordInterface I} {iE : WordInterface E} {b L : ℕ} {State : Type} {oracle : iI.Channel × List Bool → StateT State PMF (List Bool)} (a : α) (s0 : m.State) (s : State) : RepliesFitOn m iI iE b L oracle (PFunctor.FreeM.pure a) s0 s
- coin {ιI ιE α : Type} {I : ιI → Type} {E : ιE → Type} {m : Machine I E} {iI : WordInterface I} {iE : WordInterface E} {b L : ℕ} {State : Type} {oracle : iI.Channel × List Bool → StateT State PMF (List Bool)} {k : ℕ} {cont : Fin (k + 1) → ProbOracleComp E α} {s0 : m.State} {s : State} (next : ∀ (a : Fin (k + 1)), RepliesFitOn m iI iE b L oracle (cont a) s0 s) : RepliesFitOn m iI iE b L oracle (PFunctor.FreeM.liftBind (Sum.inl k) cont) s0 s
- query {ιI ιE α : Type} {I : ιI → Type} {E : ιE → Type} {m : Machine I E} {iI : WordInterface I} {iE : WordInterface E} {b L : ℕ} {State : Type} {oracle : iI.Channel × List Bool → StateT State PMF (List Bool)} {q : ιE} {cont : E q → ProbOracleComp E α} {s0 : m.State} {s : State} (fits : ∀ x ∈ (ProbOracleComp.runWith oracle (ProbOracleComp.lowerWith iI b ((m.handle q).run s0)) s).support, match x.1 with | (reply, snd) => ((iE.reply q) reply).length ≤ L) (next : ∀ x ∈ (ProbOracleComp.runWith oracle (ProbOracleComp.lowerWith iI b ((m.handle q).run s0)) s).support, match x with | ((reply, nextMachine), nextOracle) => RepliesFitOn m iI iE b L oracle (cont reply) nextMachine nextOracle) : RepliesFitOn m iI iE b L oracle (PFunctor.FreeM.liftBind (Sum.inr q) cont) s0 s
The typed execution visits the same continuations when its proof uses a larger cap.
The global reply-length premise from Frontier's existing linking theorem suffices on every supported continuation, for every imported stateful oracle.
Truncating exported replies preserves the full joint distribution of result, encoded machine state and imported-oracle state on a supported execution.
A caller-specific cap suffices for strict-PPT linking. Its unary value must be efficiently computable from the original environment parameters. For each imported oracle and supported initial machine state, the caller must respect the cap along every supported continuation.
A uniform caller-specific cap on encoded machine replies for a fixed static corruption set. The same polynomial-time computable cap covers all external stateful oracles and each supported initial machine state. It can depend on the security parameter, auxiliary word and reply bound.
A polynomial majorant of a machine-wide reply bound gives a computable cap for each caller.
Library infrastructure (no cited result): linking a strict-PPT environment against any reply-bounded strict-PPT machine family yields a uniform strict oracle-PPT program over the machine's lowered imported interface.
Library infrastructure (no cited result), toward #6043 (not Proposition 7 of [Can20a]): linking a strict-PPT environment against a certified machine family with polynomially bounded replies gives a strict-PPT environment for the machine's imported ports.
Linking on an execution interface preserves strict PPT under a caller-specific reply cap.