Call-bounded UC execution with static corruptions #
This module defines an execution experiment for the universal-composability (UC) framework of
[Can20a], in this library's novel call-bounded port model: its budgets
(Protocol.PolyBounded, Adversary.PolyBounded, Environment.PolyBounded) bound oracle call
counts only, with unbounded local computation, and computational polynomial-time machine execution
is open in #6043. For n-party protocols with a fixed set of statically corrupted parties, in the
package style of CslibFrontier.Crypto.Protocols.UC.Machine:
- A protocol
π : UC.Protocol n In Out NetQ NetRis, for every security parameterκand set of corrupted partiesC, a closed machine with a party port (.inl (i, x)gives inputxto partyi, or polls it, and returns its pending output, if any) and a network port (.inr q). An ideal functionalityFis the protocolF.toProtocolwhose network port is the functionality's backdoor. - An adversary
A : UC.Adversary n AdvQ AdvR NetQ NetRis, for everyκandC, a machine that answers the environment's queries of typeAdvQby talking to a network port with queriesNetQ. - An environment
Z : UC.Environment n In Out AdvQ AdvRis, for everyκand auxiliary inputz, a program with private coins that activates honest parties and the adversary and finally outputs a bit.
In the execution UC.exec π A C Z κ z, the protocol π κ C is wrapped in UC.corruptRouter C: on
the party port, the environment reaches only honest parties (i ∉ C), while the adversary reaches
the party port of corrupted parties (i ∈ C) through .inl (i, x) on its network port, and every
other network query .inr q is forwarded to π κ C. Thus corruptRouter C itself only redirects
party-port inputs and outputs for C; stronger corruption behavior (such as Byzantine state
exposure or arbitrary message injection, as in [Can20a]) is determined by how π κ C depends
on C, and a protocol independent of C is tested only against party-port input/output
substitution. Messages are pulled: a machine's outgoing messages wait in its state until queried.
UC.advantage π φ A S C Z κ z is the distinguishing advantage of Z between (π, A) and
(φ, S). The budgets Protocol.PolyBounded, Adversary.PolyBounded and
Environment.PolyBounded bound the number of calls of every activation, and the calls of the whole
environment, by a polynomial in κ; the environment may read an auxiliary input of any length, but
its budget does not grow with it, as in the model of [Can20a] where the environment's run time
is bounded in terms of the security parameter. As always for call budgets, they bound interaction,
not running time. UC.SimPolyBound g pA pS bounds a simulator's budget by g
evaluated at κ plus the adversary's budget.
Main definitions #
Cslib.Crypto.Protocols.UC.partySpec,Cslib.Crypto.Protocols.UC.netSpec,Cslib.Crypto.Protocols.UC.protocolSpec,Cslib.Crypto.Protocols.UC.execSpec: the ports.Cslib.Crypto.Protocols.UC.queryParty,Cslib.Crypto.Protocols.UC.queryAdv,Cslib.Crypto.Protocols.UC.queryNet: named query helpers on the party, adversary, and network ports.Cslib.Crypto.Protocols.UC.Protocol,Cslib.Crypto.Protocols.UC.IdealFunctionality,Cslib.Crypto.Protocols.UC.IdealFunctionality.toProtocol,Cslib.Crypto.Protocols.UC.Adversary,Cslib.Crypto.Protocols.UC.Environment: the participants of the execution.Cslib.Crypto.Protocols.UC.RoutedNetQ,Cslib.Crypto.Protocols.UC.RoutedNetR,Cslib.Crypto.Protocols.UC.ExecAdversary: the network port of a protocol behind static-corruption routing, and the adversaries that talk to it.Cslib.Crypto.Protocols.UC.routeNet,Cslib.Crypto.Protocols.UC.corruptRouter,Cslib.Crypto.Protocols.UC.liftNet,Cslib.Crypto.Protocols.UC.liftAdversary: static-corruption routing and the adversary's place in front of the network port.Cslib.Crypto.Protocols.UC.execMachine,Cslib.Crypto.Protocols.UC.exec,Cslib.Crypto.Protocols.UC.advantage: the execution experiment and its distinguishing advantage.Cslib.Crypto.Protocols.UC.Protocol.PolyBounded,Cslib.Crypto.Protocols.UC.Adversary.PolyBounded,Cslib.Crypto.Protocols.UC.Environment.PolyBounded,Cslib.Crypto.Protocols.UC.SimPolyBound: polynomial budgets.
Main results #
Cslib.Crypto.Protocols.UC.handle_corruptRouter_map_state: state representations of protocol machines lift throughcorruptRouter.Cslib.Crypto.Protocols.UC.corruptRouter_invariant_of_mem_support_runFrom: reflexive, transitive per-activation state invariants lift throughcorruptRouterand multi-steprunFromruns.Cslib.Crypto.Protocols.UC.runFrom_liftNet_map_state: network-port state representations factorliftNetruns through a network-interface machine.Cslib.Crypto.Protocols.UC.advantage_self,Cslib.Crypto.Protocols.UC.advantage_comm,Cslib.Crypto.Protocols.UC.advantage_triangle: the advantage is a pseudometric on executions.Cslib.Crypto.Protocols.UC.SimPolyBound.refl,Cslib.Crypto.Protocols.UC.SimPolyBound.trans: simulator budgets compose.
References #
- R. Canetti, Universally Composable Security, Section 4: the model of execution
and UC emulation. This module covers static corruptions with a fixed number of parties per
session, and identifies a session with one closed machine per
(κ, C).
Ports #
A port answering every query of type Q with a reply of type R.
Library infrastructure (no cited result): query party i with input x on the party port of an
execution or protocol interface (execSpec / protocolSpec).
Library infrastructure (no cited result): send query q to the adversary (or network) port of
an execution or protocol interface (execSpec / protocolSpec).
Library infrastructure (no cited result): send query q on a standalone network port
(netSpec NetQ NetR).
Participants #
An n-party protocol: a closed machine with a party port and a network port for every security
parameter and set of corrupted parties.
An n-party ideal functionality: a trusted machine with private state, which answers party
inputs and the simulator's backdoor queries.
- State : Type
The private state.
The initial state, given the security parameter and the corrupted parties.
Party
igives inputx(or polls) and receives its pending output, if any.A backdoor query of the adversary.
The ideal protocol of a functionality: party inputs go to onInput, and the network port is the
backdoor.
An adversary (or simulator): a machine answering the environment's queries AdvQ with replies
AdvR, talking to a network port with queries NetQ and replies NetR.
An environment: for every security parameter and auxiliary input, a program with private coins that activates parties and the adversary and outputs a bit.
The network queries of an n-party protocol with party inputs In and network queries NetQ
behind static-corruption routing (corruptRouter): .inl (i, x) is an input to corrupted party
i, and .inr q is a network query of the protocol.
The network replies of a protocol with party outputs Out and network replies NetR behind
static-corruption routing: .inl o is the pending output of a corrupted party, if any, and .inr r
is a network reply of the protocol.
An adversary in the UC execution of an n-party protocol with party inputs In, outputs Out
and network port NetQ/NetR: it answers the environment's queries AdvQ with replies AdvR by
talking to the protocol's network port behind static-corruption routing.
Execution #
Network-side static-corruption routing over a monad m: an adversary-routed input
.inl (i, x) reaches onIn i x only when i ∈ C (returning .inl none otherwise), and a
network query .inr q is forwarded to onBack q.
Library infrastructure (no cited result): routeNet on an adversary-routed party input runs
onIn for corrupted parties and refuses honest parties.
Library infrastructure (no cited result): routeNet on a network query forwards to onBack
and wraps the reply in Sum.inr.
Static-corruption routing. The environment's input (i, x) reaches party i only when i is
honest; the adversary's .inl (i, x) reaches party i only when i is corrupted; every other
network query of the adversary is forwarded to the protocol.
Library infrastructure (no cited result): on an honest party query (i ∉ C), corruptRouter
forwards the activation to P.
Library infrastructure (no cited result): on a corrupted party query (i ∈ C),
corruptRouter returns none without changing P's state.
Library infrastructure (no cited result): on an adversary-routed query to a corrupted party
(i ∈ C), corruptRouter forwards to P's party port and wraps the reply in Sum.inl.
Library infrastructure (no cited result): on an adversary-routed query to an honest party
(i ∉ C), corruptRouter returns .inl none without changing P's state.
Library infrastructure (no cited result): on a network query .inr q, corruptRouter forwards
to P's network port and wraps the reply in Sum.inr.
Intertwining two protocol machines intertwines their corruptRouter wrappers for any static
corruption set C.
Lifts a reflexive, transitive per-activation relation R from single steps of P through
corruptRouter C P and any multi-step execution runFrom prog s.
A program calling only the network port, as a program calling the ports of a protocol.
Running a network-port program liftNet program against a protocol-interface machine M₁
from f s factors through a network-interface machine M₂ whenever f intertwines M₁'s
network-port handler (M₁.handle (.inr q)) with M₂.handle q.
The adversary in front of the network port: party queries pass through unchanged, and the adversary's activations call the network port.
The closed system the environment talks to: the adversary in front of the corruption-routed protocol.
Library infrastructure (no cited result): an honest party query (i ∉ C) to execMachine
bypasses the adversary, runs π κ C on party i, and leaves the adversary's state unchanged.
Library infrastructure (no cited result): a corrupted party query (i ∈ C) to execMachine
returns none without invoking the adversary or changing either state.
Library infrastructure (no cited result): an adversary query q to execMachine runs
(A κ C).handle q lifted onto the network port against corruptRouter C (π κ C) and reassociates
the resulting state pair.
The UC execution experiment: the environment's output bit when it interacts with protocol π
and adversary A, with corrupted parties C, security parameter κ and auxiliary input z.
The advantage of the environment Z in distinguishing protocol π with adversary A from
protocol φ with adversary S.
An execution cannot be distinguished from itself.
The advantage is symmetric.
The triangle inequality through an intermediate protocol and adversary.
Polynomial budgets #
Polynomial oracle-call-count bound on protocol activations (bounding oracle call counts only
and leaving local computation unbounded, in this library's novel call-bounded port model;
computational polynomial-time machine execution is open in #6043): every activation of the protocol
at security parameter κ makes at most p.eval κ calls.
Polynomial oracle-call-count bound on adversary activations (bounding oracle call counts only
and leaving local computation unbounded, in this library's novel call-bounded port model;
computational polynomial-time machine execution is open in #6043): every activation of the adversary
at security parameter κ makes at most p.eval κ calls.
Polynomial oracle-call-count bound on an environment (bounding oracle call counts only and
leaving local computation unbounded, in this library's novel call-bounded port model; computational
polynomial-time machine execution is open in #6043): at security parameter κ, the environment
makes at most p.eval κ calls in total, counting its private samples, whatever its auxiliary
input.
The simulator budget pS is at most g evaluated at the security parameter plus the adversary
budget pA. Since polynomials over ℕ are monotone, this is a bound by a polynomial in both the
security parameter and the adversary's budget.
An adversary's own budget is a simulator budget for it.
Simulator budgets compose: a simulator for a simulator.
The simulator's budget is dominated pointwise by g composed with X + pA.