2023-02-27
Cait-Sith Security (1): Echo Broadcast
One sub-component used a couple of times is a combined broadcast commitment
functionality, implemented via echo broadcast.
In a nutshell, the idea behind echo broadcast is to ensure that a party
sends the same message to all others.
We accomplish this by sending a hash of all the messages we've received
to everyone else, thus enabling us to realize if a different message
was sent in the first round.
Definition (Echo Broadcast Protocol):
The broadcast protocol P [ EchoBroadcast ] \mathscr{P}[\text{EchoBroadcast}] P [ E c h o B r o a d c a s t ] is defined
as follows:
P [ EchoBroadcast ] P i ( 1 ) StartBroadcast i ( x ) : ‾ ↱ i ( ⋆ , x , 0 ) WaitBroadcast i ( x ) : ‾ x ^ _ ∙ ↰ i ( ⋆ , 0 ) con i ← Hash ( x ^ _ ∙ ) ↱ i ( ⋆ , con i , 1 ) return x _ ∙ EndBroadcast i ( ) : ‾ con ^ _ ∙ ↰ i ( ⋆ , 1 ) if ∃ j . con ^ j ≠ con i : stop ( ⋆ , 1 ) F [ SyncComm ] ⊗ F [ Hash ] Leakage : = { Hash , stop } \boxed{
\begin{matrix}
\colorbox{FBCFE8}{\large
$\mathscr{P}[\text{EchoBroadcast}]$
}\cr
\cr
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$P_i$
}\cr
\cr
&\underline{
(1)\text{StartBroadcast}_i(x):
}\cr
&\enspace
\Rsh_i(\star, x, 0)
\cr
\cr
&\underline{
\text{WaitBroadcast}_i(x):
}\cr
&\enspace
\hat{x}\_\bullet \Lsh_i(\star, 0)
\cr
&\enspace
\text{con}_i \gets \text{Hash}(\hat{x}\_\bullet)
\cr
&\enspace
\Rsh_i(\star, \text{con}_i, 1)
\cr
&\enspace
\texttt{return } x\_{\bullet}
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\hat{\text{con}}\_\bullet \Lsh_i(\star, 1)
\cr
&\enspace
\texttt{if } \exists j.\enspace
\hat{\text{con}}_j \neq \text{con}_i:
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\quad
\begin{matrix}
F[\text{SyncComm}]\cr
\otimes\cr
F[\text{Hash}]\cr
\end{matrix}\cr
\cr
\text{Leakage} := \{\text{Hash}, \texttt{stop}\}
\end{matrix}
} P [ E c h o B r o a d c a s t ] P i ( 1 ) S t a r t B r o a d c a s t i ( x ) : ↱ i ( ⋆ , x , 0 ) W a i t B r o a d c a s t i ( x ) : x ^ _ ∙ ↰ i ( ⋆ , 0 ) c o n i ← H a s h ( x ^ _ ∙ ) ↱ i ( ⋆ , c o n i , 1 ) return x _ ∙ E n d B r o a d c a s t i ( ) : c o n ^ _ ∙ ↰ i ( ⋆ , 1 ) if ∃ j . c o n ^ j = c o n i : stop ( ⋆ , 1 ) F [ S y n c C o m m ] ⊗ F [ H a s h ] L e a k a g e := { H a s h , stop }
□ \square □
We model this hash function as a random oracle here.
The functionality that this implements is basically what you'd
expect.
The parties have to set their broadcast value, and then the functionality
forces them to send it to all others.
However, there is a sort of catch, in that adversaries
can set a "trap" value, which will cause an abort later if the wrong
broadcast value is set after the trap.
This reflects the fact that adversaries can send their confirmation
message early , thus potentially causing an abort later.
In practice this won't matter for our purpose of using broadcasts
for commitments, because the commitment values will be random,
and thus not trappable.
Definition (Ideal Broadcast Protocol):
The protocol capturing the ideal behavior of broadcast
is defined as follows:
P [ IdealBroadcast ] P i ( 1 ) StartBroadcast i ( x ) : ‾ SetBroadcast i ( x ) SendBroadcast i ( ⋆ ) WaitBroadcast i ( ) : ‾ x _ ∙ ← GetBroadcast i ( ⋆ ) Sync i ( ⋆ ) return x _ ∙ EndBroadcast i ( ) : ‾ WaitSync i ( ⋆ ) if BadBroadcast i ( ) : stop ( ⋆ , 1 ) F [ Broadcast ] x i , sent _ i j , trap _ i j ← ⊥ ( 1 ) SetBroadcast i ( x ) : ‾ x i ← x SendBroadcast i ( S ) : ‾ assert x i ≠ ⊥ sent _ i j ← true ( ∀ j ∈ S ) GetBroadcast i ( S ) : ‾ wait _ ( i , 0 ) sent _ j i ( ∀ j ∈ S ) return [ x j ∣ j ∈ S ] Trap ( j , m _ ∙ ) : ‾ assert ∀ i . m i = ⊥ ∨ ( trap _ i j = ⊥ ∧ x i = ⊥ ) trap _ i j ← m i BadBroadcast i ( ) : ‾ return ∃ j . trap _ j i ≠ ⊥ ∧ trap _ j i ≠ x _ j ⊗ F [ Sync ( 1 ) ] ⊗ F [ Stop ] Leakage : = { Trap , stop } \boxed{
\begin{matrix}
\colorbox{FBCFE8}{\large
$\mathscr{P}[\text{IdealBroadcast}]$
}\cr
\cr
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$P_i$
}\cr
\cr
&\underline{
(1)\text{StartBroadcast}_i(x):
}\cr
&\enspace
\text{SetBroadcast}_i(x)
\cr
&\enspace
\text{SendBroadcast}_i(\star)
\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
x\_{\bullet} \gets \text{GetBroadcast}_i(\star)
\cr
&\enspace
\text{Sync}_i(\star)
\cr
&\enspace
\texttt{return } x\_{\bullet}
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\text{WaitSync}_i(\star)
\cr
&\enspace
\texttt{if } \text{BadBroadcast}_i():
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\quad
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$F[\text{Broadcast}]$
}\cr
\cr
&x_i, \text{sent}\_{ij}, \text{trap}\_{ij} \gets \bot\cr
\cr
&\underline{
(1)\text{SetBroadcast}_i(x):
}\cr
&\enspace
x_i \gets x
\cr
\cr
&\underline{
\text{SendBroadcast}_i(S):
}\cr
&\enspace
\texttt{assert } x_i \neq \bot
\cr
&\enspace
\text{sent}\_{ij} \gets \texttt{true}\ (\forall j \in S)
\cr
\cr
&\underline{
\text{GetBroadcast}_i(S):
}\cr
&\enspace
\texttt{wait}\_{(i, 0)}\ \text{sent}\_{ji}\ (\forall j \in S)
\cr
&\enspace
\texttt{return } [x_j \mid j \in S]
\cr
\cr
&\underline{
\textcolor{ef4444}{\text{Trap}(j, m\_\bullet)}:
}\cr
&\enspace
\texttt{assert } \forall i.\ m_i = \bot \lor (\text{trap}\_{i j} = \bot \land x_i = \bot)
\cr
&\enspace
\text{trap}\_{i j} \gets m_i
\cr
\cr
&\underline{
\text{BadBroadcast}_i():
}\cr
&\enspace
\texttt{return } \exists j.\ \text{trap}\_{j i} \neq \bot \land \text{trap}\_{j i} \neq x\_j
\cr
\end{aligned}
}
}\cr
\otimes\cr
F[\text{Sync}(1)]\cr
\otimes\cr
F[\text{Stop}]\cr
\end{matrix}\cr
\cr
\text{Leakage} := \{\text{Trap}, \texttt{stop}\}
\end{matrix}
} P [ I d e a l B r o a d c a s t ] P i ( 1 ) S t a r t B r o a d c a s t i ( x ) : S e t B r o a d c a s t i ( x ) S e n d B r o a d c a s t i ( ⋆ ) W a i t B r o a d c a s t i ( ) : x _ ∙ ← G e t B r o a d c a s t i ( ⋆ ) S y n c i ( ⋆ ) return x _ ∙ E n d B r o a d c a s t i ( ) : W a i t S y n c i ( ⋆ ) if B a d B r o a d c a s t i ( ) : stop ( ⋆ , 1 ) F [ B r o a d c a s t ] x i , s e n t _ ij , t r a p _ ij ← ⊥ ( 1 ) S e t B r o a d c a s t i ( x ) : x i ← x S e n d B r o a d c a s t i ( S ) : assert x i = ⊥ s e n t _ ij ← true ( ∀ j ∈ S ) G e t B r o a d c a s t i ( S ) : wait _ ( i , 0 ) s e n t _ ji ( ∀ j ∈ S ) return [ x j ∣ j ∈ S ] T r a p ( j , m _ ∙ ) : assert ∀ i . m i = ⊥ ∨ ( t r a p _ ij = ⊥ ∧ x i = ⊥ ) t r a p _ ij ← m i B a d B r o a d c a s t i ( ) : return ∃ j . t r a p _ ji = ⊥ ∧ t r a p _ ji = x _ j ⊗ F [ S y n c ( 1 )] ⊗ F [ S t o p ] L e a k a g e := { T r a p , stop }
□ \square □
Another little detail is that the ideal functionality reflects
the fact that the original broadcast had two rounds, via the synchronization
mechanism.
Lemma:
For a negligible ϵ \epsilon ϵ , and any combination of malicious parties:
P [ EchoBroadcast ] ⇝ ϵ P [ IdealBroadcast ] \mathscr{P}[\text{EchoBroadcast}] \overset{\epsilon}{\leadsto} \mathscr{P}[\text{IdealBroadcast}] P [ E c h o B r o a d c a s t ] ⇝ ϵ P [ I d e a l B r o a d c a s t ]
Proof:
As per usual, we unroll Inst ( P [ EchoBroadcast ] ) \text{Inst}(\mathscr{P}[\text{EchoBroadcast}]) I n s t ( P [ E c h o B r o a d c a s t ]) ,
to get:
Γ H 0 ( 1 ) StartBroadcast i ( x ) : ‾ … ⊗ Γ M 0 = 1 ( ↱ k , ↰ k , Hash ) ∘ F [ SyncComm ] ⊗ F [ Hash ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^0_H$
}\cr
\cr
&\underline{
(1)\text{StartBroadcast}_i(x):
}\cr
&\enspace
\ldots
\cr
\end{aligned}
}
}
\otimes
\boxed{\colorbox{FBCFE8}{\large
$\Gamma^0_M$
} = 1
\begin{pmatrix}
\Rsh_k
,\cr
\Lsh_k
,\cr
\text{Hash}
\end{pmatrix}
}
\cr
\circ
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix} Γ H 0 ( 1 ) S t a r t B r o a d c a s t i ( x ) : … ⊗ Γ M 0 = 1 ↱ k , ↰ k , H a s h ∘ F [ S y n c C o m m ] ⊗ F [ H a s h ]
having split the game into an honest part, and a malicious part,
long with the ideal functionalities.
The malicious part will slowly become our simulator.
Our next step will be to modify the honest part to send both
the hash of their messages, and an entire vector confirmation.
The malicious part will ignore this new information,
giving us an identical game.
Γ H 1 … WaitBroadcast i ( ) : ‾ x ^ _ ∙ ↰ i ( ⋆ , 0 ) h i ← Hash ( x ^ _ ∙ ) ↱ i ( ⋆ , ( h i , x ^ _ ∙ ) , 1 ) EndBroadcast i ( ) : ‾ ( h ^ _ ∙ , x ⃗ _ ∙ ) ↰ i ( ⋆ , 1 ) if ∃ j . h ^ j ≠ h i : stop ( ⋆ , 1 ) ⊗ Γ M 1 ↱ k ( S , h _ ∙ , 1 ) : ‾ ↱ k ( S , ( h _ ∙ , ⊥ ) , 1 ) ↰ k ( S , 1 ) : ‾ ( h ^ _ ∙ , … ) ↰ k ( S , 1 ) return [ h ^ j ∣ j ∈ S ] ⊗ 1 ( ↱ k , ↰ k , Hash ) ∘ F [ SyncComm ] ⊗ F [ Hash ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^1_H$
}\cr
&\ldots\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
\hat{x}\_\bullet \Lsh_i(\star, 0)
\cr
&\enspace
h_i \gets \text{Hash}(\hat{x}\_\bullet)
\cr
&\enspace
\colorbox{bae6fd}{$
\Rsh_i(\star, (h_i, \hat{x}\_\bullet), 1)
$}
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\colorbox{bae6fd}{$
(\hat{h}\_\bullet, \vec{x}\_\bullet) \Lsh_i(\star, 1)
$}
\cr
&\enspace
\texttt{if } \exists j.\enspace
\hat{h}_j \neq h_i:
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{bae6fd}{\large
$\Gamma^1_M$
}\cr
\cr
&\underline{
\Rsh_k(S, h\_\bullet, 1):
}\cr
&\enspace
\Rsh_k(S, (h\_\bullet, \bot), 1)
\cr
\cr
&\underline{
\Lsh_k(S, 1):
}\cr
&\enspace
(\hat{h}\_\bullet, \ldots)\Lsh_k(S, 1)
\cr
&\enspace
\texttt{return } [\hat{h}_j \mid j \in S]
\cr
\end{aligned}
}
}
\cr
\otimes
\cr
1(\Rsh_k, \Lsh_k, \text{Hash})
\end{matrix}
\cr
\circ
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix} Γ H 1 … W a i t B r o a d c a s t i ( ) : x ^ _ ∙ ↰ i ( ⋆ , 0 ) h i ← H a s h ( x ^ _ ∙ ) ↱ i ( ⋆ , ( h i , x ^ _ ∙ ) , 1 ) E n d B r o a d c a s t i ( ) : ( h ^ _ ∙ , x _ ∙ ) ↰ i ( ⋆ , 1 ) if ∃ j . h ^ j = h i : stop ( ⋆ , 1 ) ⊗ Γ M 1 ↱ k ( S , h _ ∙ , 1 ) : ↱ k ( S , ( h _ ∙ , ⊥ ) , 1 ) ↰ k ( S , 1 ) : ( h ^ _ ∙ , … ) ↰ k ( S , 1 ) return [ h ^ j ∣ j ∈ S ] ⊗ 1 ( ↱ k , ↰ k , H a s h ) ∘ F [ S y n c C o m m ] ⊗ F [ H a s h ]
Now, we can have the honest parties omit their hash completely,
only sending the vector.
This requires moving some of the hashing logic into the malicious part,
and the verification check at the end,
but otherwise gives us an identical game.
Γ H 2 … WaitBroadcast i ( ) : ‾ ↱ i ( ⋆ , x , 0 ) x ^ _ ∙ ↰ i ( ⋆ , 0 ) ↱ i ( ⋆ , ( ⊥ , x ^ _ ∙ ) , 1 ) EndBroadcast i ( ) : ‾ ( h ^ _ ∙ , x ⃗ _ ∙ ) ↰ i ( ⋆ , 1 ) if ∃ j . ( h ^ j ≠ ⊥ ∧ h ^ j ≠ Hash ( x ⃗ i ) ) ∨ ( x ⃗ j ≠ ⊥ ∧ Hash ( x ⃗ j ) ≠ Hash ( x ⃗ i ) ) : stop ( ⋆ , 1 ) ⊗ Γ M 2 ↱ k ( S , h _ ∙ , 1 ) : ‾ ↱ k ( S , ( h _ ∙ , ⊥ ) , 1 ) ↰ k ( S , 1 ) : ‾ ( h ^ _ ∙ , x ⃗ _ ∙ ) ↰ k ( S , 1 ) if h ^ j = ⊥ : assert x ⃗ j ≠ ⊥ h ^ j ← Hash ( x ⃗ j ) return [ h ^ j ∣ j ∈ S ] ⊗ 1 ( ↱ k , ↰ k , Hash ) ∘ F [ SyncComm ] ⊗ F [ Hash ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^2_H$
}\cr
&\ldots\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
\Rsh_i(\star, x, 0)
\cr
&\enspace
\hat{x}\_\bullet \Lsh_i(\star, 0)
\cr
&\enspace
\colorbox{bae6fd}{$
\Rsh_i(\star, (\bot, \hat{x}\_\bullet), 1)
$}
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
(\hat{h}\_\bullet, \vec{x}\_\bullet) \Lsh_i(\star, 1)
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{if } \exists j.\enspace
\begin{matrix}
(\hat{h}_j \neq \bot \land \hat{h}_j \neq \text{Hash}(\vec{x}_i))\ \lor\cr
(\vec{x}_j \neq \bot \land \text{Hash}(\vec{x}_j) \neq \text{Hash}(\vec{x}_i))
\end{matrix}
:
$}
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^2_M$
}\cr
\cr
&\underline{
\Rsh_k(S, h\_\bullet, 1):
}\cr
&\enspace
\Rsh_k(S, (h\_\bullet, \bot), 1)
\cr
\cr
&\colorbox{bae6fd}{$\underline{
\Lsh_k(S, 1):
}$}\cr
&\enspace
(\hat{h}\_\bullet, \vec{x}\_\bullet)\Lsh_k(S, 1)
\cr
&\enspace
\texttt{if } \hat{h}_j = \bot:
\cr
&\enspace\enspace
\texttt{assert } \vec{x}_j \neq \bot
\cr
&\enspace\enspace
\hat{h}_j \gets \text{Hash}(\vec{x}_j)
\cr
&\enspace
\texttt{return } [\hat{h}_j \mid j \in S]
\cr
\end{aligned}
}
}
\cr
\otimes
\cr
1(\Rsh_k, \Lsh_k, \text{Hash})
\end{matrix}
\cr
\circ
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix} Γ H 2 … W a i t B r o a d c a s t i ( ) : ↱ i ( ⋆ , x , 0 ) x ^ _ ∙ ↰ i ( ⋆ , 0 ) ↱ i ( ⋆ , ( ⊥ , x ^ _ ∙ ) , 1 ) E n d B r o a d c a s t i ( ) : ( h ^ _ ∙ , x _ ∙ ) ↰ i ( ⋆ , 1 ) if ∃ j . ( h ^ j = ⊥ ∧ h ^ j = H a s h ( x i )) ∨ ( x j = ⊥ ∧ H a s h ( x j ) = H a s h ( x i )) : stop ( ⋆ , 1 ) ⊗ Γ M 2 ↱ k ( S , h _ ∙ , 1 ) : ↱ k ( S , ( h _ ∙ , ⊥ ) , 1 ) ↰ k ( S , 1 ) : ( h ^ _ ∙ , x _ ∙ ) ↰ k ( S , 1 ) if h ^ j = ⊥ : assert x j = ⊥ h ^ j ← H a s h ( x j ) return [ h ^ j ∣ j ∈ S ] ⊗ 1 ( ↱ k , ↰ k , H a s h ) ∘ F [ S y n c C o m m ] ⊗ F [ H a s h ]
Because we're using a random oracle.
Nowe, we can extract preimages by snopping on the hash queries
made by the adversary, and send those instead.
Γ H 3 … WaitBroadcast i ( ) : ‾ x ^ _ ∙ ↰ i ( ⋆ , 0 ) ↱ i ( ⋆ , ( ⊥ , x ^ _ ∙ ) , 1 ) EndBroadcast i ( ) : ‾ ( h ^ _ ∙ , x ⃗ _ ∙ ) ↰ i ( ⋆ , 1 ) if ∃ j . ( h ^ j ≠ ⊥ ∧ h ^ j ≠ Hash ( x ⃗ i ) ) ∨ ( x ⃗ j ≠ ⊥ ∧ Hash ( x ⃗ j ) ≠ Hash ( x ⃗ i ) ) : stop ( ⋆ , 1 ) ⊗ Γ M 3 μ [ … ] ← ⊥ Hash ( x _ ∙ ) : ‾ h ← Hash ( x _ ∙ ) μ [ h ] ← x _ ∙ return h h _ i j ← ⊥ ↱ k ( S , h _ ∙ , 1 ) : ‾ assert ∀ j ∈ S . h j ≠ ⊥ for j ∈ S ∩ M : h _ k j ← h j for j ∈ S ∩ H : if μ [ h j ] ≠ ⊥ : ↱ k ( { j } , ( ⊥ , μ [ h j ] ) , 1 ) else : ↱ k ( { j } , ( h j , ⊥ ) , 1 ) ↰ k ( S , 1 ) : ‾ ( … , x ⃗ _ ∙ ) ↰ k ( S ∩ H , 1 ) wait _ ( k , 1 ) ∀ j ∈ S ∩ M . h _ j k ≠ ⊥ return [ Hash ( x ⃗ _ j ) ∣ j ∈ S ∩ H h _ j k ∣ j ∈ S ∩ M ] ⊗ 1 ( ↱ k , ↰ k , Hash ) ∘ F [ SyncComm ] ⊗ F [ Hash ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^3_H$
}\cr
&\ldots\cr
\cr
&\colorbox{bae6fd}{$\underline{
\text{WaitBroadcast}_i():
}$}\cr
&\enspace
\hat{x}\_\bullet \Lsh_i(\star, 0)
\cr
&\enspace
\Rsh_i(\star, (\bot, \hat{x}\_\bullet), 1)
\cr
\cr
&\colorbox{bae6fd}{$\underline{
\text{EndBroadcast}_i():
}$}\cr
&\enspace
(\hat{h}\_\bullet, \vec{x}\_\bullet) \Lsh_i(\star, 1)
\cr
&\enspace
\texttt{if } \exists j.\enspace
\begin{matrix}
(\hat{h}_j \neq \bot \land \hat{h}_j \neq \text{Hash}(\vec{x}_i))\ \lor\cr
(\vec{x}_j \neq \bot \land \text{Hash}(\vec{x}_j) \neq \text{Hash}(\vec{x}_i))
\end{matrix}
:
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{bae6fd}{\large
$\Gamma^3_M$
}\cr
\cr
&\mu[\ldots] \gets \bot\cr
&\underline{
\text{Hash}(x\_\bullet):
}\cr
&\enspace
h \gets \text{Hash}(x\_\bullet)
\cr
&\enspace
\mu[h] \gets x\_\bullet
\cr
&\enspace
\texttt{return } h
\cr
\cr
&h\_{ij} \gets \bot\cr
&\underline{
\Rsh_k(S, h\_\bullet, 1):
}\cr
&\enspace
\texttt{assert } \forall j \in S.\ h_j \neq \bot
\cr
&\enspace
\texttt{for } j \in S \cap \mathcal{M}:
\cr
&\enspace\enspace
h\_{kj} \gets h_j
\cr
&\enspace
\texttt{for } j \in S \cap \mathcal{H}:
\cr
&\enspace\enspace
\texttt{if } \mu[h_j] \neq \bot:
\cr
&\enspace\enspace\enspace
\Rsh_k(\{j\}, (\bot, \mu[h_j]), 1)
\cr
&\enspace\enspace
\texttt{else}:
\cr
&\enspace\enspace\enspace
\Rsh_k(\{j\}, (h_j, \bot), 1)
\cr
&
\cr
&\underline{
\Lsh_k(S, 1):
}\cr
&\enspace
(\ldots, \vec{x}\_\bullet)\Lsh_k(S \cap \mathcal{H}, 1)
\cr
&\enspace
\texttt{wait}\_{(k, 1)}\ \forall j \in S \cap \mathcal{M}.\ h\_{jk} \neq \bot
\cr
&\enspace
\texttt{return }\begin{bmatrix}
\text{Hash}(\vec{x}\_j) &\mid& j \in S \cap \mathcal{H}\cr
h\_{jk} &\mid& j \in S \cap \mathcal{M}\cr
\end{bmatrix}
\cr
\cr
\end{aligned}
}
}
\cr
\otimes
\cr
1(\Rsh_k, \Lsh_k, \text{Hash})
\end{matrix}
\cr
\circ
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix} Γ H 3 … W a i t B r o a d c a s t i ( ) : x ^ _ ∙ ↰ i ( ⋆ , 0 ) ↱ i ( ⋆ , ( ⊥ , x ^ _ ∙ ) , 1 ) E n d B r o a d c a s t i ( ) : ( h ^ _ ∙ , x _ ∙ ) ↰ i ( ⋆ , 1 ) if ∃ j . ( h ^ j = ⊥ ∧ h ^ j = H a s h ( x i )) ∨ ( x j = ⊥ ∧ H a s h ( x j ) = H a s h ( x i )) : stop ( ⋆ , 1 ) ⊗ Γ M 3 μ [ … ] ← ⊥ H a s h ( x _ ∙ ) : h ← H a s h ( x _ ∙ ) μ [ h ] ← x _ ∙ return h h _ ij ← ⊥ ↱ k ( S , h _ ∙ , 1 ) : assert ∀ j ∈ S . h j = ⊥ for j ∈ S ∩ M : h _ kj ← h j for j ∈ S ∩ H : if μ [ h j ] = ⊥ : ↱ k ({ j } , ( ⊥ , μ [ h j ]) , 1 ) else : ↱ k ({ j } , ( h j , ⊥ ) , 1 ) ↰ k ( S , 1 ) : ( … , x _ ∙ ) ↰ k ( S ∩ H , 1 ) wait _ ( k , 1 ) ∀ j ∈ S ∩ M . h _ jk = ⊥ return [ H a s h ( x _ j ) h _ jk ∣ ∣ j ∈ S ∩ H j ∈ S ∩ M ] ⊗ 1 ( ↱ k , ↰ k , H a s h ) ∘ F [ S y n c C o m m ] ⊗ F [ H a s h ]
Now, except with negligible probability, a hash with no pre-image
will cause the final verification check made by honest parties
to fail, so we can instead cause an abort when the adversary
tries to send such a hash,
allowing us to always extract a pre-image, or to abort:
Γ H 4 … WaitBroadcast i ( ) : ‾ x ^ _ ∙ ↰ i ( ⋆ , 0 ) ↱ i ( ⋆ , x ^ _ ∙ , 1 ) EndBroadcast i ( ) : ‾ x ⃗ _ ∙ ↰ i ( ⋆ , 1 ) if ∃ j . Hash ( x ⃗ j ) ≠ Hash ( x ⃗ i ) : stop ( ⋆ , 1 ) ⊗ Γ M 4 … ↱ k ( S , h _ ∙ , 1 ) : ‾ … for j ∈ S ∩ H : if μ [ h j ] ≠ ⊥ : ↱ k ( { j } , μ [ h j ] , 1 ) else : stop ( ⋆ , 1 ) ↰ k ( S , 1 ) : ‾ x ⃗ _ ∙ ↰ k ( S ∩ H , 1 ) … ⊗ 1 ( ↱ k , ↰ k , Hash ) ∘ F [ SyncComm ] ⊗ F [ Hash ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^4_H$
}\cr
&\ldots\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
\hat{x}\_\bullet \Lsh_i(\star, 0)
\cr
&\enspace
\colorbox{bae6fd}{$
\Rsh_i(\star, \hat{x}\_\bullet, 1)
$}
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\colorbox{bae6fd}{$
\vec{x}\_\bullet \Lsh_i(\star, 1)
$}
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{if } \exists j.\enspace
\text{Hash}(\vec{x}_j) \neq \text{Hash}(\vec{x}_i)
:
$}
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^4_M$
}\cr
\cr
&\ldots\cr
\cr
&\underline{
\Rsh_k(S, h\_\bullet, 1):
}\cr
&\enspace
\ldots
\cr
&\enspace
\texttt{for } j \in S \cap \mathcal{H}:
\cr
&\enspace\enspace
\texttt{if } \mu[h_j] \neq \bot:
\cr
&\enspace\enspace\enspace
\colorbox{bae6fd}{$
\Rsh_k(\{j\}, \mu[h_j], 1)
$}
\cr
&\enspace\enspace
\texttt{else}:
\cr
&\enspace\enspace\enspace
\colorbox{bae6fd}{$
\texttt{stop}(\star, 1)
$}
\cr
&
\cr
&\underline{
\Lsh_k(S, 1):
}\cr
&\enspace
\colorbox{bae6fd}{$
\vec{x}\_\bullet\Lsh_k(S \cap \mathcal{H}, 1)
$}
\cr
&\enspace
\ldots
\cr
\cr
\end{aligned}
}
}
\cr
\otimes
\cr
1(\Rsh_k, \Lsh_k, \text{Hash})
\end{matrix}
\cr
\circ
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix} Γ H 4 … W a i t B r o a d c a s t i ( ) : x ^ _ ∙ ↰ i ( ⋆ , 0 ) ↱ i ( ⋆ , x ^ _ ∙ , 1 ) E n d B r o a d c a s t i ( ) : x _ ∙ ↰ i ( ⋆ , 1 ) if ∃ j . H a s h ( x j ) = H a s h ( x i ) : stop ( ⋆ , 1 ) ⊗ Γ M 4 … ↱ k ( S , h _ ∙ , 1 ) : … for j ∈ S ∩ H : if μ [ h j ] = ⊥ : ↱ k ({ j } , μ [ h j ] , 1 ) else : stop ( ⋆ , 1 ) ↰ k ( S , 1 ) : x _ ∙ ↰ k ( S ∩ H , 1 ) … ⊗ 1 ( ↱ k , ↰ k , H a s h ) ∘ F [ S y n c C o m m ] ⊗ F [ H a s h ]
At this point, we've actually written a simulator
for a protocol P 0 \mathscr{P}^0 P 0 , which is like our initial
protocol, except that the parties send their entire vector,
rather than their hash.
This shows that P [ EchoBroadcast ] ⇝ P 0 \mathscr{P}[\text{EchoBroadcast}] \leadsto \mathscr{P}^0 P [ E c h o B r o a d c a s t ] ⇝ P 0 .
We can unroll Inst ( P 0 ) \text{Inst}(\mathscr{P}^0) I n s t ( P 0 ) to get:
Γ H 5 … WaitBroadcast i ( ) : ‾ ↱ i ( ⋆ , x , 0 ) x ^ _ ∙ ↰ i ( ⋆ , 0 ) ↱ i ( ⋆ , x ^ _ ∙ , 1 ) EndBroadcast i ( ) : ‾ x ⃗ _ ∙ ↰ i ( ⋆ , 1 ) if ∃ j . Hash ( x ⃗ j ) ≠ Hash ( x ⃗ i ) : stop ( ⋆ , 1 ) ⊗ Γ M 5 = 1 ( ↱ k , ↰ k , Hash ) ∘ F [ SyncComm ] ⊗ F [ Hash ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^5_H$
}\cr
&\ldots\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
\Rsh_i(\star, x, 0)
\cr
&\enspace
\hat{x}\_\bullet \Lsh_i(\star, 0)
\cr
&\enspace
\Rsh_i(\star, \hat{x}\_\bullet, 1)
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\vec{x}\_\bullet \Lsh_i(\star, 1)
\cr
&\enspace
\texttt{if } \exists j.\enspace
\text{Hash}(\vec{x}_j) \neq \text{Hash}(\vec{x}_i)
:
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\boxed{\colorbox{FBCFE8}{\large
$\Gamma^5_M$
} = 1
\begin{pmatrix}
\Rsh_k
,\cr
\Lsh_k
,\cr
\text{Hash}
\end{pmatrix}
}
\cr
\circ
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix} Γ H 5 … W a i t B r o a d c a s t i ( ) : ↱ i ( ⋆ , x , 0 ) x ^ _ ∙ ↰ i ( ⋆ , 0 ) ↱ i ( ⋆ , x ^ _ ∙ , 1 ) E n d B r o a d c a s t i ( ) : x _ ∙ ↰ i ( ⋆ , 1 ) if ∃ j . H a s h ( x j ) = H a s h ( x i ) : stop ( ⋆ , 1 ) ⊗ Γ M 5 = 1 ↱ k , ↰ k , H a s h ∘ F [ S y n c C o m m ] ⊗ F [ H a s h ]
Except with negligible probability, the hashes won't collide,
so we can replace the hash based check with an actual check
of equality.
Γ H 6 … EndBroadcast i ( ) : ‾ … if ∃ j . x ⃗ j ≠ x ⃗ i : stop ( ⋆ , 1 ) ⊗ Γ M 6 = Γ M 5 ∘ F [ SyncComm ] ⊗ F [ Hash ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^6_H$
}\cr
&\ldots\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\ldots
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{if } \exists j.\enspace
\vec{x}_j \neq \vec{x}_i
:
$}
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\boxed{\colorbox{FBCFE8}{\large
$\Gamma^6_M$
} = \Gamma^5_M}
\cr
\circ
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix} Γ H 6 … E n d B r o a d c a s t i ( ) : … if ∃ j . x j = x i : stop ( ⋆ , 1 ) ⊗ Γ M 6 = Γ M 5 ∘ F [ S y n c C o m m ] ⊗ F [ H a s h ]
Now, we employ a classic trick, and are trying to get
rid of F [ SyncComm ] F[\text{SyncComm}] F [ S y n c C o m m ] .
Our strategy to do this will be to inline all of the variables
in a common mutable functionality:
Γ H 7 ( 1 ) StartBroadcast i ( x ) : ‾ x ^ _ i j ← x WaitBroadcast i ( ) : ‾ wait _ ( i , 0 ) ∀ j . x ^ _ j i ≠ ⊥ x ⃗ _ i j ← x ^ _ ∙ i sync _ i j ← true EndBroadcast i ( ) : ‾ wait _ ( i , 1 ) ∀ j . sync _ j i ≠ ⊥ if ∃ j . x ⃗ _ j i ≠ x ^ _ ∙ i : stop ( ⋆ , 1 ) ⊗ Γ M 7 ↱ k ( S , m _ ∙ , 0 ) : ‾ assert ∀ j ∈ S . m j ≠ ⊥ ∧ x ^ _ k j = ⊥ x ^ _ k j ← m j ( ∀ j ∈ S ) ↱ k ( S , m _ ∙ , 1 ) : ‾ assert ∀ j ∈ S . m j ≠ ⊥ ∧ x ⃗ _ k j = ⊥ x ⃗ _ k j ← m j ( ∀ j ∈ S ) sync _ k j ← true ( ∀ j ∈ S ) ↰ k ( S , 0 ) : ‾ wait _ ( k , 0 ) ∀ j ∈ S . x ^ _ j k ≠ ⊥ return [ x ^ _ j k ∣ j ∈ S ] ↰ k ( S , 1 ) : ‾ wait _ ( k , 1 ) ∀ j ∈ S . sync _ j k ≠ ⊥ return [ x ⃗ _ j k ∣ j ∈ S ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ∘ pub x ^ _ i j , x ⃗ _ i j , sync _ i j ← ⊥ ⊗ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{bae6fd}{\large
$\Gamma^7_H$
}\cr
\cr
&\underline{
(1)\text{StartBroadcast}_i(x):
}\cr
&\enspace
\hat{x}\_{ij} \gets x
\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
\texttt{wait}\_{(i, 0)}\ \forall j.\ \hat{x}\_{ji} \neq \bot
\cr
&\enspace
\vec{x}\_{ij} \gets \hat{x}\_{\bullet i}
\cr
&\enspace
\text{sync}\_{ij} \gets \texttt{true}
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\texttt{wait}\_{(i, 1)}\ \forall j.\ \text{sync}\_{ji} \neq \bot
\cr
&\enspace
\texttt{if } \exists j.\enspace
\vec{x}\_{ji} \neq \hat{x}\_{\bullet i}
:
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{bae6fd}{\large
$\Gamma^7_M$
}\cr
\cr
&\underline{
\Rsh_k(S, m\_\bullet, 0):
}\cr
&\enspace
\texttt{assert } \forall j \in S.\ m_j \neq \bot \land \hat{x}\_{kj} = \bot
\cr
&\enspace
\hat{x}\_{kj} \gets m_j\ (\forall j \in S)
\cr
\cr
&\underline{
\Rsh_k(S, m\_\bullet, 1):
}\cr
&\enspace
\texttt{assert } \forall j \in S.\ m_j \neq \bot \land \vec{x}\_{kj} = \bot
\cr
&\enspace
\vec{x}\_{kj} \gets m_j\ (\forall j \in S)
\cr
&\enspace
\text{sync}\_{kj} \gets \texttt{true}\ (\forall j \in S)
\cr
\cr
&\underline{
\Lsh_k(S, 0):
}\cr
&\enspace
\texttt{wait}\_{(k, 0)}\ \forall j \in S.\ \hat{x}\_{jk} \neq \bot
\cr
&\enspace
\texttt{return } [\hat{x}\_{j k} \mid j \in S]
\cr
\cr
&\underline{
\Lsh_k(S, 1):
}\cr
&\enspace
\texttt{wait}\_{(k, 1)}\ \forall j \in S.\ \text{sync}\_{jk} \neq \bot
\cr
&\enspace
\texttt{return } [\vec{x}\_{jk} \mid j \in S]
\cr
\end{aligned}
}
}
\cr
\otimes
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix}
\cr
\circ
\cr
\boxed{
\small{
\begin{aligned}
\texttt{pub } \hat{x}\_{ij}, \vec{x}\_{ij}, \text{sync}\_{ij} \gets \bot
\end{aligned}
}
}
\otimes
F[\text{Stop}]
\end{matrix} Γ H 7 ( 1 ) S t a r t B r o a d c a s t i ( x ) : x ^ _ ij ← x W a i t B r o a d c a s t i ( ) : wait _ ( i , 0 ) ∀ j . x ^ _ ji = ⊥ x _ ij ← x ^ _ ∙ i s y n c _ ij ← true E n d B r o a d c a s t i ( ) : wait _ ( i , 1 ) ∀ j . s y n c _ ji = ⊥ if ∃ j . x _ ji = x ^ _ ∙ i : stop ( ⋆ , 1 ) ⊗ Γ M 7 ↱ k ( S , m _ ∙ , 0 ) : assert ∀ j ∈ S . m j = ⊥ ∧ x ^ _ kj = ⊥ x ^ _ kj ← m j ( ∀ j ∈ S ) ↱ k ( S , m _ ∙ , 1 ) : assert ∀ j ∈ S . m j = ⊥ ∧ x _ kj = ⊥ x _ kj ← m j ( ∀ j ∈ S ) s y n c _ kj ← true ( ∀ j ∈ S ) ↰ k ( S , 0 ) : wait _ ( k , 0 ) ∀ j ∈ S . x ^ _ jk = ⊥ return [ x ^ _ jk ∣ j ∈ S ] ↰ k ( S , 1 ) : wait _ ( k , 1 ) ∀ j ∈ S . s y n c _ jk = ⊥ return [ x _ jk ∣ j ∈ S ] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ∘ pub x ^ _ ij , x _ ij , s y n c _ ij ← ⊥ ⊗ F [ S t o p ]
Next, we can split the verification check into an honest check, and a malicious check.
Γ H 8 … EndBroadcast i ( ) : ‾ … if ∃ j ∈ H . x ^ _ ∙ j ≠ x ^ _ ∙ i : stop ( ⋆ , 1 ) if ∃ j ∈ M . x ⃗ _ j i ≠ x ^ _ ∙ i : stop ( ⋆ , 1 ) ⊗ Γ M 8 = Γ M 7 ⊗ F [ SyncComm ] ⊗ F [ Hash ] ∘ pub x ^ _ i j , x ⃗ _ i j , sync _ i j ← ⊥ ⊗ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^8_H$
}\cr
&\ldots\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\ldots
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{if } \exists j \in \mathcal{H}.\enspace
\hat{x}\_{\bullet j} \neq \hat{x}\_{\bullet i}
:
$}
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{if } \exists j \in \mathcal{M}.\enspace
\vec{x}\_{ji} \neq \hat{x}\_{\bullet i}
:
$}
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^8_M$
} = \Gamma^7_M\cr
\end{aligned}
}
}
\cr
\otimes
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix}
\cr
\circ
\cr
\boxed{
\small{
\begin{aligned}
\texttt{pub } \hat{x}\_{ij}, \vec{x}\_{ij}, \text{sync}\_{ij} \gets \bot
\end{aligned}
}
}
\otimes
F[\text{Stop}]
\end{matrix} Γ H 8 … E n d B r o a d c a s t i ( ) : … if ∃ j ∈ H . x ^ _ ∙ j = x ^ _ ∙ i : stop ( ⋆ , 1 ) if ∃ j ∈ M . x _ ji = x ^ _ ∙ i : stop ( ⋆ , 1 ) ⊗ Γ M 8 = Γ M 7 ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ∘ pub x ^ _ ij , x _ ij , s y n c _ ij ← ⊥ ⊗ F [ S t o p ]
The only reason the honest check will fail is if the adversary
sends to different messages to honest parties,
causing their confirmations to differ.
We can
detect that in Γ M \Gamma_M Γ M instead, replacing the honest check.
Γ H 9 ( 1 ) StartBroadcast i ( x ) : ‾ x ^ _ i j ← x sent _ i j ← true WaitBroadcast i ( ) : ‾ wait _ ( i , 0 ) ∀ j . x ^ _ i j ≠ ⊥ x ⃗ _ i j ← x ^ _ ∙ i sync _ i j ← true EndBroadcast i ( ) : ‾ wait _ ( i , 1 ) ∀ j . sync _ j i ≠ ⊥ if ∃ j ∈ M . x ⃗ _ j i ≠ x ^ _ ∙ i : stop ( ⋆ , 1 ) ⊗ Γ M 9 x k ← ⊥ ↱ k ( S , m _ ∙ , 0 ) : ‾ assert ∀ j ∈ S . m j ≠ ⊥ ∧ x ^ _ k j = ⊥ for j ∈ S ∩ H : if x k = ⊥ : x k ← m j elif x k ≠ m j : stop ( { j } , 1 ) x ^ _ k j ← m j ( ∀ j ∈ S ) … ⊗ F [ SyncComm ] ⊗ F [ Hash ] ∘ pub x ^ _ i j , x ⃗ _ i j , sent _ i j , sync _ i j ← ⊥ ⊗ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^9_H$
}\cr
\cr
&\underline{
(1)\text{StartBroadcast}_i(x):
}\cr
&\enspace
\hat{x}\_{ij} \gets x
\cr
&\enspace
\text{sent}\_{ij} \gets \texttt{true}
\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
\texttt{wait}\_{(i, 0)}\ \forall j.\ \hat{x}\_{ij} \neq \bot
\cr
&\enspace
\vec{x}\_{ij} \gets \hat{x}\_{\bullet i}
\cr
&\enspace
\text{sync}\_{ij} \gets \texttt{true}
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\texttt{wait}\_{(i, 1)}\ \forall j.\ \text{sync}\_{ji} \neq \bot
\cr
&\enspace
\texttt{if } \exists j \in \mathcal{M}.\enspace
\vec{x}\_{ji} \neq \hat{x}\_{\bullet i}
:
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^9_M$
}\cr
\cr
&\colorbox{bae6fd}{$
x_k \gets \bot
$}\cr
&\underline{
\Rsh_k(S, m\_\bullet, 0):
}\cr
&\enspace
\texttt{assert } \forall j \in S.\ m_j \neq \bot \land \hat{x}\_{kj} = \bot
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{for } j \in S \cap \mathcal{H}:
$}
\cr
&\enspace\enspace
\colorbox{bae6fd}{$
\texttt{if } x_k = \bot:\enspace x_k \gets m_j
$}
\cr
&\enspace\enspace
\colorbox{bae6fd}{$
\texttt{elif } x_k \neq m_j:\enspace \texttt{stop}(\{j\}, 1)
$}
\cr
&\enspace
\hat{x}\_{kj} \gets m_j\ (\forall j \in S)
\cr
\cr
&
\ldots
\cr
\end{aligned}
}
}
\cr
\otimes
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix}
\cr
\circ
\cr
\boxed{
\small{
\begin{aligned}
\texttt{pub } \hat{x}\_{ij}, \vec{x}\_{ij}, \text{sent}\_{ij}, \text{sync}\_{ij} \gets \bot
\end{aligned}
}
}
\otimes
F[\text{Stop}]
\end{matrix} Γ H 9 ( 1 ) S t a r t B r o a d c a s t i ( x ) : x ^ _ ij ← x s e n t _ ij ← true W a i t B r o a d c a s t i ( ) : wait _ ( i , 0 ) ∀ j . x ^ _ ij = ⊥ x _ ij ← x ^ _ ∙ i s y n c _ ij ← true E n d B r o a d c a s t i ( ) : wait _ ( i , 1 ) ∀ j . s y n c _ ji = ⊥ if ∃ j ∈ M . x _ ji = x ^ _ ∙ i : stop ( ⋆ , 1 ) ⊗ Γ M 9 x k ← ⊥ ↱ k ( S , m _ ∙ , 0 ) : assert ∀ j ∈ S . m j = ⊥ ∧ x ^ _ kj = ⊥ for j ∈ S ∩ H : if x k = ⊥ : x k ← m j elif x k = m j : stop ({ j } , 1 ) x ^ _ kj ← m j ( ∀ j ∈ S ) … ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ∘ pub x ^ _ ij , x _ ij , s e n t _ ij , s y n c _ ij ← ⊥ ⊗ F [ S t o p ]
Now, the only thing that can cause a malicious failure is if
a bad x ⃗ _ i j \vec{x}\_{ij} x _ ij value is set.
We can capture this with a trap value.
Γ H 10 ( 1 ) Broadcast i ( x ) : ‾ x ^ _ i j ← x sent _ i j ← true WaitBroadcast i ( ) : ‾ wait _ ( i , 0 ) ∀ j . x ^ _ i j ≠ ⊥ x ⃗ _ i j ← x ^ _ ∙ i sync _ i j ← true EndBroadcast i ( ) : ‾ wait _ ( i , 1 ) ∀ j . sync _ j i ≠ ⊥ if trap _ ∙ i ≠ ⊥ ∧ trap _ ∙ i ≠ x ^ _ ∙ i : stop ( ⋆ , 1 ) ⊗ Γ M 10 … ↱ k ( S , m _ ∙ , 1 ) : ‾ assert ∀ j ∈ S . m j ≠ ⊥ ∧ x ⃗ _ k j = ⊥ for j ∈ S ∩ H : if trap _ ∙ j = ⊥ : trap _ ∙ j ← m j elif trap _ ∙ j ≠ m j : stop ( { j } , 1 ) x ⃗ _ k j ← m j ( ∀ j ∈ S ) sync _ k j ← true ( ∀ j ∈ S ) ⊗ F [ SyncComm ] ⊗ F [ Hash ] ∘ pub x ^ _ i j , trap _ i j , x ⃗ _ i j , sent _ i j , sync _ i j ← ⊥ ⊗ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^{10}_H$
}\cr
\cr
&\underline{
(1)\text{Broadcast}_i(x):
}\cr
&\enspace
\hat{x}\_{ij} \gets x
\cr
&\enspace
\text{sent}\_{ij} \gets \texttt{true}
\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
\texttt{wait}\_{(i, 0)}\ \forall j.\ \hat{x}\_{ij} \neq \bot
\cr
&\enspace
\vec{x}\_{ij} \gets \hat{x}\_{\bullet i}
\cr
&\enspace
\text{sync}\_{ij} \gets \texttt{true}
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\texttt{wait}\_{(i, 1)}\ \forall j.\ \text{sync}\_{ji} \neq \bot
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{if }
\text{trap}\_{\bullet i} \neq \bot \land
\text{trap}\_{\bullet i} \neq \hat{x}\_{\bullet i}
:
$}
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^{10}_M$
}\cr
\cr
&\ldots\cr
\cr
&\underline{
\Rsh_k(S, m\_\bullet, 1):
}\cr
&\enspace
\texttt{assert } \forall j \in S.\ m_j \neq \bot \land \vec{x}\_{kj} = \bot
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{for } j \in S \cap \mathcal{H}:
$}
\cr
&\enspace\enspace
\colorbox{bae6fd}{$
\texttt{if } \text{trap}\_{\bullet j} = \bot:\enspace \text{trap}\_{\bullet j} \gets m_j
$}
\cr
&\enspace\enspace
\colorbox{bae6fd}{$
\texttt{elif } \text{trap}\_{\bullet j} \neq m_j:\enspace \texttt{stop}(\{j\}, 1)
$}
\cr
&\enspace
\vec{x}\_{kj} \gets m_j\ (\forall j \in S)
\cr
&\enspace
\text{sync}\_{kj} \gets \texttt{true}\ (\forall j \in S)
\cr
\end{aligned}
}
}
\cr
\otimes
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix}
\cr
\circ
\cr
\boxed{
\small{
\begin{aligned}
\texttt{pub } \hat{x}\_{ij}, \text{trap}\_{ij}, \vec{x}\_{ij}, \text{sent}\_{ij}, \text{sync}\_{ij} \gets \bot
\end{aligned}
}
}
\otimes
F[\text{Stop}]
\end{matrix} Γ H 10 ( 1 ) B r o a d c a s t i ( x ) : x ^ _ ij ← x s e n t _ ij ← true W a i t B r o a d c a s t i ( ) : wait _ ( i , 0 ) ∀ j . x ^ _ ij = ⊥ x _ ij ← x ^ _ ∙ i s y n c _ ij ← true E n d B r o a d c a s t i ( ) : wait _ ( i , 1 ) ∀ j . s y n c _ ji = ⊥ if t r a p _ ∙ i = ⊥ ∧ t r a p _ ∙ i = x ^ _ ∙ i : stop ( ⋆ , 1 ) ⊗ Γ M 10 … ↱ k ( S , m _ ∙ , 1 ) : assert ∀ j ∈ S . m j = ⊥ ∧ x _ kj = ⊥ for j ∈ S ∩ H : if t r a p _ ∙ j = ⊥ : t r a p _ ∙ j ← m j elif t r a p _ ∙ j = m j : stop ({ j } , 1 ) x _ kj ← m j ( ∀ j ∈ S ) s y n c _ kj ← true ( ∀ j ∈ S ) ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ∘ pub x ^ _ ij , t r a p _ ij , x _ ij , s e n t _ ij , s y n c _ ij ← ⊥ ⊗ F [ S t o p ]
Since we can't equivocate, simplify variables.
Γ H 11 ( 1 ) Broadcast i ( x ) : ‾ SetBroadcast i ( x ) SendBroadcast i ( ⋆ ) WaitBroadcast i ( ) : ‾ x _ ∙ ← GetBroadcast i ( ⋆ ) Sync i ( ⋆ ) EndBroadcast i ( ) : ‾ WaitSync i ( ⋆ ) if BadBroadcast i ( ) : stop ( ⋆ , 1 ) ⊗ Γ M 11 x k , x ^ _ i j , x ⃗ _ i j ← ⊥ ↱ k ( S , m _ ∙ , 0 ) : ‾ assert ∀ j ∈ S . m j ≠ ⊥ ∧ x ^ _ k j = ⊥ for j ∈ S ∩ H : if x k = ⊥ : x k ← m j SetBroadcast k ( x k ) elif x k ≠ m j : stop ( { j } , 1 ) x ^ _ k j ← m j ( ∀ j ∈ S ∩ M ) SendBroadcast k ( S ∩ H ) ↱ k ( S , m _ ∙ , 1 ) : ‾ assert ∀ j ∈ S . m j ≠ ⊥ ∧ x ⃗ _ k j = ⊥ for j ∈ S ∩ H : if trap _ ∙ j = ⊥ : Trap ( j , m j ) elif trap _ ∙ j ≠ m j : stop ( { j } , 1 ) x ⃗ _ k j ← m j ( ∀ j ∈ S ) Sync k ( S ) ↰ k ( S , 0 ) : ‾ wait _ ( k , 0 ) ∀ j ∈ S ∩ M . x ^ _ j k ≠ ⊥ x ^ _ j k ← GetBroadcast k ( { j } ) ( ∀ j ∈ S ∩ H ) return [ x ^ _ j k ∣ j ∈ S ] ↰ k ( S , 1 ) : ‾ WaitSync k ( ) x ⃗ _ j k ← GetBroadcast k ( ⋆ ) ( ∀ j ∈ S ∩ H ) return [ x ⃗ _ j k ∣ j ∈ S ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ∘ F [ Broadcast ] ′ x i , sent _ i j , trap _ i j ← ⊥ ( 1 ) SetBroadcast i ( x ) : ‾ x i ← x GetBroadcast i ( S ) : ‾ wait _ ( i , 0 ) sent _ j i ( ∀ j ∈ S ) return [ x j ∣ j ∈ S ] Trap ( j , m _ ∙ ) : ‾ assert trap _ ∙ j = ⊥ trap _ i j ← m i BadBroadcast ( j , m _ ∙ ) : ‾ return ∃ i . trap _ i j ≠ ⊥ ∧ trap _ i j ≠ x _ i ⊗ F [ Sync ( 1 ) ] ⊗ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{bae6fd}{\large
$\Gamma^{11}_H$
}\cr
\cr
&\underline{
(1)\text{Broadcast}_i(x):
}\cr
&\enspace
\text{SetBroadcast}_i(x)
\cr
&\enspace
\text{SendBroadcast}_i(\star)
\cr
\cr
&\underline{
\text{WaitBroadcast}_i():
}\cr
&\enspace
x\_{\bullet} \gets \text{GetBroadcast}_i(\star)
\cr
&\enspace
\text{Sync}_i(\star)
\cr
\cr
&\underline{
\text{EndBroadcast}_i():
}\cr
&\enspace
\text{WaitSync}_i(\star)
\cr
&\enspace
\texttt{if } \text{BadBroadcast}_i():
\cr
&\enspace\enspace
\texttt{stop}(\star, 1)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^{11}_M$
}\cr
\cr
&\colorbox{bae6fd}{$
x_k, \hat{x}\_{ij}, \vec{x}\_{ij} \gets \bot
$}\cr
&\underline{
\Rsh_k(S, m\_\bullet, 0):
}\cr
&\enspace
\texttt{assert } \forall j \in S.\ m_j \neq \bot \land \hat{x}\_{kj} = \bot
\cr
&\enspace
\texttt{for } j \in S \cap \mathcal{H}:
\cr
&\enspace\enspace
\texttt{if } x_k = \bot:
\cr
&\enspace\enspace\enspace
x_k \gets m_j
\cr
&\enspace\enspace\enspace
\colorbox{bae6fd}{$
\text{SetBroadcast}_k(x_k)
$}
\cr
&\enspace\enspace
\texttt{elif } x_k \neq m_j:\enspace \texttt{stop}(\{j\}, 1)
\cr
&\enspace
\hat{x}\_{kj} \gets m_j\ (\forall j \in S \cap \mathcal{M})
\cr
&\enspace
\colorbox{bae6fd}{$
\text{SendBroadcast}_k(S \cap \mathcal{H})
$}
\cr
\cr
&\underline{
\Rsh_k(S, m\_\bullet, 1):
}\cr
&\enspace
\texttt{assert } \forall j \in S.\ m_j \neq \bot \land \vec{x}\_{kj} = \bot
\cr
&\enspace
\texttt{for } j \in S \cap \mathcal{H}:
\cr
&\enspace\enspace
\texttt{if } \text{trap}\_{\bullet j} = \bot:
\cr
&\enspace\enspace\enspace
\colorbox{bae6fd}{$
\text{Trap}(j, m_j)
$}
\cr
&\enspace\enspace
\texttt{elif } \text{trap}\_{\bullet j} \neq m_j:\enspace \texttt{stop}(\{j\}, 1)
\cr
&\enspace
\vec{x}\_{kj} \gets m_j\ (\forall j \in S)
\cr
&\enspace
\colorbox{bae6fd}{$
\text{Sync}_k(S)
$}
\cr
\cr
&\underline{
\Lsh_k(S, 0):
}\cr
&\enspace
\texttt{wait}\_{(k, 0)}\ \forall j \in S \cap M.\ \hat{x}\_{jk} \neq \bot
\cr
&\enspace
\colorbox{bae6fd}{$
\hat{x}\_{jk} \gets \text{GetBroadcast}_k(\{j\})\ (\forall j \in S \cap \mathcal{H})
$}
\cr
&\enspace
\texttt{return } [\hat{x}\_{j k} \mid j \in S]
\cr
\cr
&\underline{
\Lsh_k(S, 1):
}\cr
&\enspace
\colorbox{bae6fd}{$
\text{WaitSync}_k()
$}
\cr
&\enspace
\colorbox{bae6fd}{$
\vec{x}\_{jk} \gets \text{GetBroadcast}_k(\star)\ (\forall j \in S \cap \mathcal{H})
$}
\cr
&\enspace
\texttt{return } [\vec{x}\_{jk} \mid j \in S]
\cr
\end{aligned}
}
}
\cr
\otimes
\cr
F[\text{SyncComm}] \otimes F[\text{Hash}]
\end{matrix}
\cr
\circ
\cr
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$F[\text{Broadcast}]'$
}\cr
\cr
&x_i, \text{sent}\_{ij}, \text{trap}\_{ij} \gets \bot\cr
\cr
&\underline{
(1)\text{SetBroadcast}_i(x):
}\cr
&\enspace
x_i \gets x
\cr
\cr
&\underline{
\text{GetBroadcast}_i(S):
}\cr
&\enspace
\texttt{wait}\_{(i, 0)}\ \text{sent}\_{ji}\ (\forall j \in S)
\cr
&\enspace
\texttt{return } [x_j \mid j \in S]
\cr
\cr
&\underline{
\text{Trap}(j, m\_\bullet):
}\cr
&\enspace
\texttt{assert } \text{trap}\_{\bullet j} = \bot
\cr
&\enspace
\text{trap}\_{i j} \gets m_i
\cr
\cr
&\underline{
\text{BadBroadcast}(j, m\_\bullet):
}\cr
&\enspace
\texttt{return } \exists i.\ \text{trap}\_{i j} \neq \bot \land \text{trap}\_{i j} \neq x\_i
\cr
\end{aligned}
}
}
\otimes
F[\text{Sync}(1)]
\otimes
F[\text{Stop}]
\end{matrix} Γ H 11 ( 1 ) B r o a d c a s t i ( x ) : S e t B r o a d c a s t i ( x ) S e n d B r o a d c a s t i ( ⋆ ) W a i t B r o a d c a s t i ( ) : x _ ∙ ← G e t B r o a d c a s t i ( ⋆ ) S y n c i ( ⋆ ) E n d B r o a d c a s t i ( ) : W a i t S y n c i ( ⋆ ) if B a d B r o a d c a s t i ( ) : stop ( ⋆ , 1 ) ⊗ Γ M 11 x k , x ^ _ ij , x _ ij ← ⊥ ↱ k ( S , m _ ∙ , 0 ) : assert ∀ j ∈ S . m j = ⊥ ∧ x ^ _ kj = ⊥ for j ∈ S ∩ H : if x k = ⊥ : x k ← m j S e t B r o a d c a s t k ( x k ) elif x k = m j : stop ({ j } , 1 ) x ^ _ kj ← m j ( ∀ j ∈ S ∩ M ) S e n d B r o a d c a s t k ( S ∩ H ) ↱ k ( S , m _ ∙ , 1 ) : assert ∀ j ∈ S . m j = ⊥ ∧ x _ kj = ⊥ for j ∈ S ∩ H : if t r a p _ ∙ j = ⊥ : T r a p ( j , m j ) elif t r a p _ ∙ j = m j : stop ({ j } , 1 ) x _ kj ← m j ( ∀ j ∈ S ) S y n c k ( S ) ↰ k ( S , 0 ) : wait _ ( k , 0 ) ∀ j ∈ S ∩ M . x ^ _ jk = ⊥ x ^ _ jk ← G e t B r o a d c a s t k ({ j }) ( ∀ j ∈ S ∩ H ) return [ x ^ _ jk ∣ j ∈ S ] ↰ k ( S , 1 ) : W a i t S y n c k ( ) x _ jk ← G e t B r o a d c a s t k ( ⋆ ) ( ∀ j ∈ S ∩ H ) return [ x _ jk ∣ j ∈ S ] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ∘ F [ B r o a d c a s t ] ′ x i , s e n t _ ij , t r a p _ ij ← ⊥ ( 1 ) S e t B r o a d c a s t i ( x ) : x i ← x G e t B r o a d c a s t i ( S ) : wait _ ( i , 0 ) s e n t _ ji ( ∀ j ∈ S ) return [ x j ∣ j ∈ S ] T r a p ( j , m _ ∙ ) : assert t r a p _ ∙ j = ⊥ t r a p _ ij ← m i B a d B r o a d c a s t ( j , m _ ∙ ) : return ∃ i . t r a p _ ij = ⊥ ∧ t r a p _ ij = x _ i ⊗ F [ S y n c ( 1 )] ⊗ F [ S t o p ]
As suggested by the introduction of this broadcast functionality,
we now have a new protocol P 1 \mathscr{P}^1 P 1 ,
and have shown that P 0 ⇝ P 1 \mathscr{P}^0 \leadsto \mathscr{P}^1 P 0 ⇝ P 1
by our game hopping.
We're not quite done yet, because the trapping here is a bit too strong,
in that the adversary can trap even after a broadcast value has been
set.
We can simulate this freedom away.
Next, unroll again.
Γ H 12 ( 1 ) StartBroadcast i ( x ) : ‾ … ⊗ Γ M 12 = 1 ( SetBroadcast k , GetBroadcast k , BadBroadcast k , Sync k , Trap ) ∘ F [ Broadcast ] ′ ⊗ F [ Sync ( 1 ) ] ⊗ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^{12}_H$
}\cr
\cr
&\underline{
(1)\text{StartBroadcast}_i(x):
}\cr
&\enspace
\ldots
\cr
\end{aligned}
}
}
\otimes
\boxed{\colorbox{FBCFE8}{\large
$\Gamma^{12}_M$
} = 1
\begin{pmatrix}
\text{SetBroadcast}_k
,\cr
\text{GetBroadcast}_k
,\cr
\text{BadBroadcast}_k
,\cr
\text{Sync}_k
,\cr
\text{Trap}
\end{pmatrix}
}
\cr
\circ
\cr
F[\text{Broadcast}]' \otimes F[\text{Sync}(1)] \otimes F[\text{Stop}]
\end{matrix} Γ H 12 ( 1 ) S t a r t B r o a d c a s t i ( x ) : … ⊗ Γ M 12 = 1 S e t B r o a d c a s t k , G e t B r o a d c a s t k , B a d B r o a d c a s t k , S y n c k , T r a p ∘ F [ B r o a d c a s t ] ′ ⊗ F [ S y n c ( 1 )] ⊗ F [ S t o p ]
Traps that happen after a broadcast can be simulated by triggering an abort
ourselves in the simulator.
Γ H 13 = Γ H 12 ⊗ Γ M 13 Trap ( j , m _ ∙ ) : ‾ for i ∈ H : if ∃ k . x ← nowait GetBroadcast k ( { i } ) : if m i ≠ x : stop ( { j } , 1 ) return Trap ( j , m _ ∙ ) ∘ F [ Broadcast ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^{13}_H$
} = \Gamma^{12}_H\cr
\end{aligned}
}
}
\otimes
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^{13}_M$
}\cr
\cr
&\colorbox{bae6fd}{$
\underline{
\text{Trap}(j, m\_{\bullet}):
}$}\cr
&\enspace
\texttt{for } i \in \mathcal{H}:
\cr
&\enspace\enspace
\texttt{if } \exists k.\ x \gets \texttt{nowait } \text{GetBroadcast}_k(\{i\}):
\cr
&\enspace\enspace\enspace
\texttt{if } m_i \neq x:
\cr
&\enspace\enspace\enspace\enspace
\texttt{stop}(\{j\}, 1)
\cr
&\enspace\enspace\enspace\enspace
\texttt{return}
\cr
&\enspace
\text{Trap}(j, m\_\bullet)
\cr
\end{aligned}
}
}
\cr
\circ
\cr
F[\text{Broadcast}] \otimes F[\text{Sync}(1)] \otimes F[\text{Stop}]
\end{matrix} Γ H 13 = Γ H 12 ⊗ Γ M 13 T r a p ( j , m _ ∙ ) : for i ∈ H : if ∃ k . x ← nowait G e t B r o a d c a s t k ({ i }) : if m i = x : stop ({ j } , 1 ) return T r a p ( j , m _ ∙ ) ∘ F [ B r o a d c a s t ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S t o p ]
This is a simulator for P [ IdealBroadcast ] \mathscr{P}[\text{IdealBroadcast}] P [ I d e a l B r o a d c a s t ] ,
which concludes our proof, via the logic:
P [ EchoBroadcast ] ⇝ P 0 ⇝ P 1 ⇝ P [ IdealBroadcast ] \mathscr{P}[\text{EchoBroadcast}] \leadsto \mathscr{P}^0 \leadsto \mathscr{P}^1
\leadsto \mathscr{P}[\text{IdealBroadcast}] P [ E c h o B r o a d c a s t ] ⇝ P 0 ⇝ P 1 ⇝ P [ I d e a l B r o a d c a s t ]
■ \blacksquare ■
Commitments
Our main application of broadcast will be to define a commitment protocol.
The basic idea is that you commit to a value by hashing it,
along with a random salt,
and then broadcast that commitment.
Later, you can open the value by sending it along with the salt.
Definition (Commitment Protocol):
P [ Commit ] P i x i , r i ← ⊥ ( 1 ) SetCommit i ( x ) : ‾ x i ← x , r i ← $ 01 2 λ SetBroadcast i ( Hash ( x i , r i ) ) Commit i ( ) : ‾ SendBroadcast i ( ⋆ ) WaitCommit i ( ) : ‾ return WaitBroadcast i ( ) Open i ( ) : ‾ assert x i ≠ ⊥ ↱ i ( ⋆ , ( x i , r i ) , 2 ) WaitOpen i ( ) : ‾ c _ ∙ ← WaitCommit i ( ) EndBroadcast i ( ) ( x ^ _ ∙ , r ^ _ ∙ ) ↰ i ( ⋆ , 2 ) if ∃ j . Hash ( x ^ j , r ^ j ) ≠ c j : stop ( ⋆ , 2 ) return x ^ _ ∙ F [ Stop ] ⊚ F [ SyncComm ] ⊗ F [ Hash ] Leakage : = { Hash , stop } ⊲ P [ EchoBroadcast ] \boxed{
\begin{matrix}
\colorbox{FBCFE8}{\large
$\mathscr{P}[\text{Commit}]$
}\cr
\cr
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$P_i$
}\cr
\cr
&x_i, r_i \gets \bot\cr
\cr
&\underline{
(1)\text{SetCommit}_i(x):
}\cr
&\enspace
x_i \gets x, \quad r_i \xleftarrow{\$} \texttt{01}^{2 \lambda}
\cr
&\enspace
\text{SetBroadcast}_i(\text{Hash}(x_i, r_i))
\cr
\cr
&\underline{
\text{Commit}_i():
}\cr
&\enspace
\text{SendBroadcast}_i(\star)
\cr
\cr
&\underline{
\text{WaitCommit}_i():
}\cr
&\enspace
\texttt{return } \text{WaitBroadcast}_i()
\cr
\cr
&\underline{
\text{Open}_i():
}\cr
&\enspace
\texttt{assert } x_i \neq \bot
\cr
&\enspace
\Rsh_i(\star, (x_i, r_i), 2)
\cr
\cr
&\underline{
\text{WaitOpen}_i():
}\cr
&\enspace
c\_\bullet \gets \text{WaitCommit}_i()
\cr
&\enspace
\text{EndBroadcast}_i()
\cr
&\enspace
(\hat{x}\_{\bullet}, \hat{r}\_{\bullet}) \Lsh_i(\star, 2)
\cr
&\enspace
\texttt{if } \exists j.\ \text{Hash}(\hat{x}_j, \hat{r}_j) \neq c_j:
\cr
&\enspace\enspace
\texttt{stop}(\star, 2)
\cr
&\enspace
\texttt{return } \hat{x}\_{\bullet}
\cr
\cr
\end{aligned}
}
}
\quad
\begin{matrix}
F[\text{Stop}]\cr
\circledcirc\cr
F[\text{SyncComm}]\cr
\otimes\cr
F[\text{Hash}]\cr
\end{matrix}\cr
\cr
\text{Leakage} := \{\text{Hash}, \texttt{stop}\}
\end{matrix}
}
\lhd \mathscr{P}[\text{EchoBroadcast}] P [ C o m m i t ] P i x i , r i ← ⊥ ( 1 ) S e t C o m m i t i ( x ) : x i ← x , r i $ 01 2 λ S e t B r o a d c a s t i ( H a s h ( x i , r i )) C o m m i t i ( ) : S e n d B r o a d c a s t i ( ⋆ ) W a i t C o m m i t i ( ) : return W a i t B r o a d c a s t i ( ) O p e n i ( ) : assert x i = ⊥ ↱ i ( ⋆ , ( x i , r i ) , 2 ) W a i t O p e n i ( ) : c _ ∙ ← W a i t C o m m i t i ( ) E n d B r o a d c a s t i ( ) ( x ^ _ ∙ , r ^ _ ∙ ) ↰ i ( ⋆ , 2 ) if ∃ j . H a s h ( x ^ j , r ^ j ) = c j : stop ( ⋆ , 2 ) return x ^ _ ∙ F [ S t o p ] ⊚ F [ S y n c C o m m ] ⊗ F [ H a s h ] L e a k a g e := { H a s h , stop } ⊲ P [ E c h o B r o a d c a s t ]
□ \square □
The ideal functionality this is supposed
to implement is relatively straightforward.
You set a commit value,
and can wait for others to commit as well.
Finally, you can open, which doesn't allow you to actually
change the value you've committed to, it just makes it now visible to others.
We also have the usual abort points remaining in the protocol.
Definition (Ideal Commitment):
P [ IdealCommit ] P i ( 1 ) SetCommit i ( x ) : ‾ SetCommit i ( x ) Commit i ( ) : ‾ Commit i ( ⋆ ) WaitCommit i ( ) : ‾ WaitCommit i ( ⋆ ) Sync i ( ⋆ ) Open i ( ) : ‾ Open i ( ⋆ ) WaitOpen i ( ) : ‾ WaitCommit i ( ) WaitSync i ( ⋆ ) return WaitOpen i ( ⋆ ) F [ Commit ] x i , com _ i j , open _ i j ← ⊥ ( 1 ) SetCommit i ( x ) : ‾ x i ← x Commit i ( S ) : ‾ com _ i j ← true ( ∀ j ∈ S ) WaitCommit i ( S ) : ‾ wait _ ( i , 0 ) ∀ j ∈ S . com _ j i Open i ( S ) : ‾ assert x i ≠ ⊥ open _ i j ← true ( ∀ j ∈ S ) WaitOpen i ( S ) : ‾ wait _ ( i , 2 ) ∀ j ∈ S . open _ j i return x _ ∙ ⊗ F [ Sync ( 1 ) ] ⊚ F [ Stop ] Leakage : = { Hash , stop } \boxed{
\begin{matrix}
\colorbox{FBCFE8}{\large
$\mathscr{P}[\text{IdealCommit}]$
}\cr
\cr
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$P_i$
}\cr
\cr
&\underline{
(1)\text{SetCommit}_i(x):
}\cr
&\enspace
\text{SetCommit}_i(x)
\cr
\cr
&\underline{
\text{Commit}_i():
}\cr
&\enspace
\text{Commit}_i(\star)
\cr
\cr
&\underline{
\text{WaitCommit}_i():
}\cr
&\enspace
\text{WaitCommit}_i(\star)
\cr
&\enspace
\text{Sync}_i(\star)
\cr
\cr
&\underline{
\text{Open}_i():
}\cr
&\enspace
\text{Open}_i(\star)
\cr
\cr
&\underline{
\text{WaitOpen}_i():
}\cr
&\enspace
\text{WaitCommit}_i()
\cr
&\enspace
\text{WaitSync}_i(\star)
\cr
&\enspace
\texttt{return } \text{WaitOpen}_i(\star)
\cr
\end{aligned}
}
}
\quad
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$F[\text{Commit}]$
}\cr
\cr
&x_i, \text{com}\_{ij}, \text{open}\_{ij} \gets \bot\cr
\cr
&\underline{
(1)\text{SetCommit}_i(x):
}\cr
&\enspace
x_i \gets x
\cr
\cr
&\underline{
\text{Commit}_i(S):
}\cr
&\enspace
\text{com}\_{ij} \gets \texttt{true}\ (\forall j \in S)
\cr
\cr
&\underline{
\text{WaitCommit}_i(S):
}\cr
&\enspace
\texttt{wait}\_{(i, 0)} \forall j \in S.\ \text{com}\_{ji}
\cr
\cr
&\underline{
\text{Open}_i(S):
}\cr
&\enspace
\texttt{assert } x_i \neq \bot
\cr
&\enspace
\text{open}\_{ij} \gets \texttt{true} (\forall j \in S)
\cr
\cr
&\underline{
\text{WaitOpen}_i(S):
}\cr
&\enspace
\text{wait}\_{(i, 2)} \forall j \in S.\ \text{open}\_{ji}
\cr
&\enspace
\texttt{return } x\_\bullet
\cr
\end{aligned}
}
}\cr
\otimes\cr
F[\text{Sync}(1)]\cr
\circledcirc\cr
F[\text{Stop}]
\end{matrix}\cr
\cr
\text{Leakage} := \{\text{Hash}, \texttt{stop}\}
\end{matrix}
} P [ I d e a l C o m m i t ] P i ( 1 ) S e t C o m m i t i ( x ) : S e t C o m m i t i ( x ) C o m m i t i ( ) : C o m m i t i ( ⋆ ) W a i t C o m m i t i ( ) : W a i t C o m m i t i ( ⋆ ) S y n c i ( ⋆ ) O p e n i ( ) : O p e n i ( ⋆ ) W a i t O p e n i ( ) : W a i t C o m m i t i ( ) W a i t S y n c i ( ⋆ ) return W a i t O p e n i ( ⋆ ) F [ C o m m i t ] x i , c o m _ ij , o p e n _ ij ← ⊥ ( 1 ) S e t C o m m i t i ( x ) : x i ← x C o m m i t i ( S ) : c o m _ ij ← true ( ∀ j ∈ S ) W a i t C o m m i t i ( S ) : wait _ ( i , 0 ) ∀ j ∈ S . c o m _ ji O p e n i ( S ) : assert x i = ⊥ o p e n _ ij ← true ( ∀ j ∈ S ) W a i t O p e n i ( S ) : w a i t _ ( i , 2 ) ∀ j ∈ S . o p e n _ ji return x _ ∙ ⊗ F [ S y n c ( 1 )] ⊚ F [ S t o p ] L e a k a g e := { H a s h , stop }
□ \square □
Lemma:
For some negligible ϵ \epsilon ϵ , and any combination of malicious parties,
we have:
P [ Commit ⇝ ϵ P [ IdealCommit ] \begin{matrix}
\mathscr{P}[\text{Commit}
\overset{\epsilon}{\leadsto}
\mathscr{P}[\text{IdealCommit}]
\end{matrix} P [ C o m m i t ⇝ ϵ P [ I d e a l C o m m i t ]
Proof:
First, we have P [ Commit ] ⇝ P 0 \mathscr{P}[\text{Commit}] \leadsto \mathscr{P}^0 P [ C o m m i t ] ⇝ P 0 ,
where P 0 \mathscr{P}^0 P 0 replaces P [ EchoBroadcast ] \mathscr{P}[\text{EchoBroadcast}] P [ E c h o B r o a d c a s t ]
with P [ IdealBroadcast ] \mathscr{P}[\text{IdealBroadcast}] P [ I d e a l B r o a d c a s t ] ,
and we start from there.
We unroll Inst ( P 0 ) \text{Inst}(\mathscr{P}^0) I n s t ( P 0 ) to get:
Γ H 0 ( 1 ) SetCommit i ( x ) : ‾ … ⊗ Γ M 0 = 1 ( SetBroadcast k , SendBroadcast k , GetBroadcast k , BadBroadcast k , Trap , Sync k , WaitSync k , ↱ k , ↰ k , Hash , stop ) ∘ F [ Broadcast ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^0_H$
}\cr
\cr
&\underline{
(1)\text{SetCommit}_i(x):
}\cr
&\enspace
\ldots
\cr
\end{aligned}
}
}
\otimes
\boxed{\colorbox{FBCFE8}{\large
$\Gamma^0_M$
} = 1
\begin{pmatrix}
\text{SetBroadcast}_k
,\cr
\text{SendBroadcast}_k
,\cr
\text{GetBroadcast}_k
,\cr
\text{BadBroadcast}_k
,\cr
\text{Trap}
,\cr
\text{Sync}_k
,\cr
\text{WaitSync}_k
,\cr
\Rsh_k
,\cr
\Lsh_k
,\cr
\text{Hash}
,\cr
\texttt{stop}
\end{pmatrix}
}
\cr
\circ
\cr
F[\text{Broadcast}] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 0 ( 1 ) S e t C o m m i t i ( x ) : … ⊗ Γ M 0 = 1 S e t B r o a d c a s t k , S e n d B r o a d c a s t k , G e t B r o a d c a s t k , B a d B r o a d c a s t k , T r a p , S y n c k , W a i t S y n c k , ↱ k , ↰ k , H a s h , stop ∘ F [ B r o a d c a s t ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
Now, a trap value needs to be provided before the commitment
value is known.
However, for honest parties, these commitment values
are in all likelihood freshly sampled, because of the entropy
in r r r .
This means that trapping honest values is useless,
since except with negligible probability, it has no effect.
Γ H 1 = Γ H 0 ⊗ Γ M 1 … Trap ( j , m _ ∙ ) : ‾ com i ← x i ≠ ⊥ ( ∀ i ∈ M ) com i ← nowait GetBroadcast k ( { i } ) ≠ ⊥ ( ∀ i ∈ H ) assert ∀ i . m i = ⊥ ∨ ( trap _ i j = ⊥ ∧ ¬ com i ) ∀ i ∈ H . m i ← ⊥ Trap ( j , m _ ∙ ) ∘ F [ Broadcast ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^1_H$
} = \Gamma^0_H
\end{aligned}
}
\otimes
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^1_M$
}\cr
&\ldots\cr
&\colorbox{bae6fd}{$
\underline{
\text{Trap}(j, m\_\bullet):
}$}\cr
&\enspace
\text{com}_i \gets x_i \neq \bot (\forall i \in \mathcal{M})
\cr
&\enspace
\text{com}_i \gets \texttt{nowait } \text{GetBroadcast}_k(\{i\})\neq \bot (\forall i \in \mathcal{H})
\cr
&\enspace
\texttt{assert } \forall i.\ m_i = \bot \lor (\text{trap}\_{i j} = \bot \land \neg \text{com}_i)
\cr
&\enspace
\forall i \in \mathcal{H}.\ m_i \gets \bot
\cr
&\enspace
\text{Trap}(j, m\_{\bullet})
\cr
\end{aligned}
}
}
\cr
\circ
\cr
F[\text{Broadcast}] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 1 = Γ H 0 ⊗ Γ M 1 … T r a p ( j , m _ ∙ ) : c o m i ← x i = ⊥ ( ∀ i ∈ M ) c o m i ← nowait G e t B r o a d c a s t k ({ i }) = ⊥ ( ∀ i ∈ H ) assert ∀ i . m i = ⊥ ∨ ( t r a p _ ij = ⊥ ∧ ¬ c o m i ) ∀ i ∈ H . m i ← ⊥ T r a p ( j , m _ ∙ ) ∘ F [ B r o a d c a s t ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
We can now replace F [ Broadcast ] F[\text{Broadcast}] F [ B r o a d c a s t ] with
a function F [ Broadcast ′ ] F[\text{Broadcast}'] F [ B r o a d c a s t ′ ] , in which trapping isn't
possible, because we can simulate the effects ourself.
Γ H 2 = Γ H 1 ⊗ Γ M 2 … c k , trap _ i j , bad k ← ⊥ Trap ( j , m _ ∙ ) : ‾ com i ← c i ≠ ⊥ ( ∀ i ∈ M ) com i ← nowait GetBroadcast k ( { i } ) ≠ ⊥ ( ∀ i ∈ H ) assert ∀ i . m i = ⊥ ∨ ( trap _ i j = ⊥ ∧ ¬ com i ) ∀ i ∈ H . m i ← ⊥ trap _ i j ← m i SetBroadcast k ( c ) : ‾ c k ← c if ∃ j . trap _ j k ≠ ⊥ ∧ trap _ j k ≠ c : bad j ← true if j ∈ H : stop ( { j } , 1 ) BadBroadcast k ( ) : ‾ return bad k ∘ F [ Broadcast ′ ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^2_H$
} = \Gamma^1_H
\end{aligned}
}
\otimes
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^2_M$
}\cr
&\ldots\cr
&\colorbox{bae6fd}{$
c_k, \text{trap}\_{ij}, \text{bad}_k \gets \bot$}
\cr
\cr
&\underline{
\text{Trap}(j, m\_\bullet):
}\cr
&\enspace
\text{com}_i \gets c_i \neq \bot (\forall i \in \mathcal{M})
\cr
&\enspace
\text{com}_i \gets \texttt{nowait } \text{GetBroadcast}_k(\{i\})\neq \bot (\forall i \in \mathcal{H})
\cr
&\enspace
\texttt{assert } \forall i.\ m_i = \bot \lor (\text{trap}\_{i j} = \bot \land \neg \text{com}_i)
\cr
&\enspace
\forall i \in \mathcal{H}.\ m_i \gets \bot
\cr
&\enspace
\colorbox{bae6fd}{$
\text{trap}\_{ij} \gets m_i
$}
\cr
\cr
&\colorbox{bae6fd}{$
\underline{
\text{SetBroadcast}_k(c):
}$}\cr
&\enspace
c_k \gets c
\cr
&\enspace
\texttt{if } \exists j.\ \text{trap}\_{jk} \neq \bot \land \text{trap}\_{jk} \neq c:
\cr
&\enspace\enspace
\text{bad}_j \gets \texttt{true}
\cr
&\enspace\enspace
\texttt{if } j \in \mathcal{H}:\ \texttt{stop}(\{j\}, 1)
\cr
\cr
&\colorbox{bae6fd}{$
\underline{
\text{BadBroadcast}_k():
}$}\cr
&\enspace
\texttt{return } \text{bad}_k
\cr
\end{aligned}
}
}
\cr
\circ
\cr
F[\text{Broadcast}'] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 2 = Γ H 1 ⊗ Γ M 2 … c k , t r a p _ ij , b a d k ← ⊥ T r a p ( j , m _ ∙ ) : c o m i ← c i = ⊥ ( ∀ i ∈ M ) c o m i ← nowait G e t B r o a d c a s t k ({ i }) = ⊥ ( ∀ i ∈ H ) assert ∀ i . m i = ⊥ ∨ ( t r a p _ ij = ⊥ ∧ ¬ c o m i ) ∀ i ∈ H . m i ← ⊥ t r a p _ ij ← m i S e t B r o a d c a s t k ( c ) : c k ← c if ∃ j . t r a p _ jk = ⊥ ∧ t r a p _ jk = c : b a d j ← true if j ∈ H : stop ({ j } , 1 ) B a d B r o a d c a s t k ( ) : return b a d k ∘ F [ B r o a d c a s t ′ ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
From this we see that we're in fact simulating a protocol P 1 \mathscr{P}^1 P 1 ,
which is like P [ IdealBroadcast ] \mathscr{P}[\text{IdealBroadcast}] P [ I d e a l B r o a d c a s t ] ,
except that trapping is not possible.
Let's unroll that protocol, to get:
Γ H 3 ( 1 ) SetCommit i ( x ) : ‾ … ⊗ Γ M 3 = 1 ( SetBroadcast k , SendBroadcast k , GetBroadcast k , , Sync k , WaitSync k , ↱ k , ↰ k , Hash , stop ) ∘ F [ Broadcast ′ ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^3_H$
}\cr
\cr
&\underline{
(1)\text{SetCommit}_i(x):
}\cr
&\enspace
\ldots
\cr
\end{aligned}
}
}
\otimes
\boxed{\colorbox{FBCFE8}{\large
$\Gamma^3_M$
} = 1
\begin{pmatrix}
\text{SetBroadcast}_k
,\cr
\text{SendBroadcast}_k
,\cr
\text{GetBroadcast}_k
,\cr
,\cr
\text{Sync}_k
,\cr
\text{WaitSync}_k
,\cr
\Rsh_k
,\cr
\Lsh_k
,\cr
\text{Hash}
,\cr
\texttt{stop}
\end{pmatrix}
}
\cr
\circ
\cr
F[\text{Broadcast}'] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 3 ( 1 ) S e t C o m m i t i ( x ) : … ⊗ Γ M 3 = 1 S e t B r o a d c a s t k , S e n d B r o a d c a s t k , G e t B r o a d c a s t k , , S y n c k , W a i t S y n c k , ↱ k , ↰ k , H a s h , stop ∘ F [ B r o a d c a s t ′ ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
At the end of WaitOpen i \text{WaitOpen}_i W a i t O p e n i , we check that the opened
values match the commitments.
Because honest parties will always open the right values,
we can instead limit the check to malicious parties.
Γ H 4 WaitOpen i ( x ) : ‾ c _ ∙ ← WaitCommit i ( ) EndBroadcast i ( ) ( x ^ _ ∙ , r ^ _ ∙ ) ↰ i ( ⋆ , 2 ) if ∃ j ∈ M . Hash ( x ^ j , r ^ j ) ≠ c j : stop ( ⋆ , 2 ) return x ^ _ ∙ ⊗ Γ M 4 = Γ M 3 ∘ F [ Broadcast ′ ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^4_H$
}\cr
\cr
&\underline{
\text{WaitOpen}_i(x):
}\cr
&\enspace
c\_\bullet \gets \text{WaitCommit}_i()
\cr
&\enspace
\text{EndBroadcast}_i()
\cr
&\enspace
(\hat{x}\_{\bullet}, \hat{r}\_{\bullet}) \Lsh_i(\star, 2)
\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{if } \exists j \in \mathcal{M}.\ \text{Hash}(\hat{x}_j, \hat{r}_j) \neq c_j:
$}
\cr
&\enspace\enspace
\texttt{stop}(\star, 2)
\cr
&\enspace
\texttt{return } \hat{x}\_{\bullet}
\cr
\end{aligned}
}
}
\otimes
\boxed{\colorbox{FBCFE8}{\large
$\Gamma^4_M$
} = \Gamma^3_M
}
\cr
\circ
\cr
F[\text{Broadcast}'] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 4 W a i t O p e n i ( x ) : c _ ∙ ← W a i t C o m m i t i ( ) E n d B r o a d c a s t i ( ) ( x ^ _ ∙ , r ^ _ ∙ ) ↰ i ( ⋆ , 2 ) if ∃ j ∈ M . H a s h ( x ^ j , r ^ j ) = c j : stop ( ⋆ , 2 ) return x ^ _ ∙ ⊗ Γ M 4 = Γ M 3 ∘ F [ B r o a d c a s t ′ ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
Now, because of the entropy of the r r r values, in all likelihood
the random oracle will not have been queried
at that value before, and so we can instead assume that the value
is random, and then backfill it later.
Thus, we have honest parties broadcast completely random commitments,
and then program the random oracle after they open the commitment.
Γ H 5 x i , c i ← ⊥ … ( 1 ) SetCommit i ( x ) : ‾ x i ← x c i ← $ 01 2 λ SetBroadcast i ( c i ) Open i ( ) : ‾ assert x i ≠ ⊥ r i ← $ 01 2 λ ↱ i ( ⋆ , ( x i , r i ) , 2 ) WaitOpen i ( x ) : ‾ c _ ∙ ← WaitCommit i ( ) EndBroadcast i ( ) ( x ^ _ ∙ , r ^ _ ∙ ) ↰ i ( ⋆ , 2 ) if ∃ j ∈ M . Hash ( x ^ j , r ^ j ) ≠ c j : stop ( ⋆ , 2 ) return x ^ _ ∙ ⊗ Γ H 5 … Hash ( x , r ) : ‾ if ∃ k ∈ M , j ∈ H . nowait ↰ k ( { j } , 2 ) = ( x , r ) : if ∃ k ∈ M , j ∈ H . nowait GetBroadcast ( { j } ) → c j : return c j return Hash ( x , r ) ∘ F [ Broadcast ′ ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^5_H$
}\cr
\cr
&\colorbox{bae6fd}{$
x_i, c_i \gets \bot
$}\cr
&\ldots\cr
\cr
&\colorbox{bae6fd}{$
\underline{
(1)\text{SetCommit}_i(x):
}$}\cr
&\enspace
x_i \gets x
\cr
&\enspace
c_i \xleftarrow{\$} \texttt{01}^{2 \lambda}
\cr
&\enspace
\text{SetBroadcast}_i(c_i)
\cr
\cr
&\underline{
\text{Open}_i():
}\cr
&\enspace
\texttt{assert } x_i \neq \bot
\cr
&\enspace
\colorbox{bae6fd}{$
r_i \xleftarrow{\$} \texttt{01}^{2\lambda}
$}
\cr
&\enspace
\Rsh_i(\star, (x_i, r_i), 2)
\cr
\cr
&\underline{
\text{WaitOpen}_i(x):
}\cr
&\enspace
c\_\bullet \gets \text{WaitCommit}_i()
\cr
&\enspace
\text{EndBroadcast}_i()
\cr
&\enspace
(\hat{x}\_{\bullet}, \hat{r}\_{\bullet}) \Lsh_i(\star, 2)
\cr
&\enspace
\texttt{if } \exists j \in \mathcal{M}.\ \text{Hash}(\hat{x}_j, \hat{r}_j) \neq c_j:
\cr
&\enspace\enspace
\texttt{stop}(\star, 2)
\cr
&\enspace
\texttt{return } \hat{x}\_{\bullet}
\cr
\end{aligned}
}
}
\otimes
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^5_H$
}\cr
&\ldots\cr
\cr
&\colorbox{bae6fd}{$
\underline{
\text{Hash}(x, r):
}$}\cr
&\enspace
\texttt{if } \exists k \in \mathcal{M}, j \in \mathcal{H}.\ \texttt{nowait}\Lsh_k(\{j\}, 2) = (x, r):
\cr
&\enspace\enspace
\texttt{if } \exists k \in \mathcal{M}, j \in \mathcal{H}.\ \texttt{nowait } \text{GetBroadcast}(\{j\}) \to c_j:
\cr
&\enspace\enspace\enspace
\texttt{return } c_j
\cr
&\enspace
\texttt{return } \text{Hash}(x, r)
\cr
\end{aligned}
}
}
\cr
\circ
\cr
F[\text{Broadcast}'] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 5 x i , c i ← ⊥ … ( 1 ) S e t C o m m i t i ( x ) : x i ← x c i $ 01 2 λ S e t B r o a d c a s t i ( c i ) O p e n i ( ) : assert x i = ⊥ r i $ 01 2 λ ↱ i ( ⋆ , ( x i , r i ) , 2 ) W a i t O p e n i ( x ) : c _ ∙ ← W a i t C o m m i t i ( ) E n d B r o a d c a s t i ( ) ( x ^ _ ∙ , r ^ _ ∙ ) ↰ i ( ⋆ , 2 ) if ∃ j ∈ M . H a s h ( x ^ j , r ^ j ) = c j : stop ( ⋆ , 2 ) return x ^ _ ∙ ⊗ Γ H 5 … H a s h ( x , r ) : if ∃ k ∈ M , j ∈ H . nowait ↰ k ({ j } , 2 ) = ( x , r ) : if ∃ k ∈ M , j ∈ H . nowait G e t B r o a d c a s t ({ j }) → c j : return c j return H a s h ( x , r ) ∘ F [ B r o a d c a s t ′ ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
Next, except with negligible probability we can extract preimages
of commitments, since a commitment that hasn't come from the hash
function will fail with probability ≤ 2 − 2 λ \leq 2^{-2\lambda} ≤ 2 − 2 λ .
Γ H 6 = Γ H 5 ⊗ Γ H 6 μ [ ∙ ] , x k , r k ← ⊥ … SetBroadcast k ( h ) : ‾ assert h ∈ μ ( x k , r k ) ← μ [ h ] SetBroadcast k ( h ) Hash ( x , r ) : ‾ h ← Hash ′ ( x , r ) μ [ h ] ← ( x , r ) return h Hash ′ ( x , r ) : ‾ … ∘ F [ Broadcast ′ ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^6_H$
} = \Gamma^5_H\cr
\end{aligned}
}
}
\otimes
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^6_H$
}\cr
&\mu[\bullet], x_k, r_k \gets \bot\cr
&\ldots\cr
\cr
&\colorbox{bae6fd}{$
\underline{
\text{SetBroadcast}_k(h):
}$}\cr
&\enspace
\texttt{assert } h \in \mu
\cr
&\enspace
(x_k, r_k) \gets \mu[h]
\cr
&\enspace
\text{SetBroadcast}_k(h)
\cr
\cr
&\colorbox{bae6fd}{$
\underline{
\text{Hash}(x, r):
}$}\cr
&\enspace
h \gets \text{Hash}'(x, r)
\cr
&\enspace
\mu[h] \gets (x, r)
\cr
&\enspace
\texttt{return } h
\cr
&\underline{
\text{Hash}'(x, r):
}\cr
&\enspace
\ldots
\cr
\end{aligned}
}
}
\cr
\circ
\cr
F[\text{Broadcast}'] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 6 = Γ H 5 ⊗ Γ H 6 μ [ ∙ ] , x k , r k ← ⊥ … S e t B r o a d c a s t k ( h ) : assert h ∈ μ ( x k , r k ) ← μ [ h ] S e t B r o a d c a s t k ( h ) H a s h ( x , r ) : h ← H a s h ′ ( x , r ) μ [ h ] ← ( x , r ) return h H a s h ′ ( x , r ) : … ∘ F [ B r o a d c a s t ′ ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
Next, instead of checking for bad openings inside honest parties,
we can instead have malicious parties directly cause
a stop once they send a bad value.
Γ H 7 … WaitOpen i ( ) : ‾ c _ ∙ ← WaitCommit i ( ) EndBroadcast i ( ) ( x ^ _ ∙ , r ^ _ ∙ ) ↰ i ( ⋆ , 2 ) if ∃ j . Hash ( x ^ j , r ^ j ) ≠ c j : stop ( ⋆ , 2 ) return x ^ _ ∙ ⊗ Γ H 7 μ [ ∙ ] , x k , r k ← ⊥ … ↱ k ( S , ( x ^ _ ∙ , r ^ _ ∙ ) ) : ‾ for j ∈ S ∩ H . Hash ( x ^ j , r ^ j ) ≠ Hash ( x k , r k ) : stop ( { j } , 2 ) ↱ k ( S , ( x ^ _ ∙ , r ^ _ ∙ ) ) ∘ F [ Broadcast ′ ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^7_H$
}\cr
&\ldots\cr
\cr
&\underline{
\text{WaitOpen}_i():
}\cr
&\enspace
c\_\bullet \gets \text{WaitCommit}_i()
\cr
&\enspace
\text{EndBroadcast}_i()
\cr
&\enspace
(\hat{x}\_{\bullet}, \hat{r}\_{\bullet}) \Lsh_i(\star, 2)
\cr
&\enspace
\colorbox{#fca5a5}{$
\texttt{if } \exists j.\ \text{Hash}(\hat{x}_j, \hat{r}_j) \neq c_j:
$}
\cr
&\enspace\enspace
\colorbox{#fca5a5}{$
\texttt{stop}(\star, 2)
$}
\cr
&\enspace
\texttt{return } \hat{x}\_{\bullet}
\cr
\end{aligned}
}
}
\otimes
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^7_H$
}\cr
&\mu[\bullet], x_k, r_k \gets \bot\cr
&\ldots\cr
\cr
&\colorbox{bae6fd}{$
\underline{
\Rsh_k(S, (\hat{x}\_\bullet, \hat{r}\_\bullet)):
}$}\cr
&\enspace
\texttt{for } j \in S \cap \mathcal{H}.\ \text{Hash}(\hat{x}_j, \hat{r}_j) \neq \text{Hash}(x_k, r_k):
\cr
&\enspace\enspace
\texttt{stop}(\{j\}, 2)
\cr
&\enspace
\Rsh_k(S, (\hat{x}\_\bullet, \hat{r}\_\bullet))
\cr
\end{aligned}
}
}
\cr
\circ
\cr
F[\text{Broadcast}'] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 7 … W a i t O p e n i ( ) : c _ ∙ ← W a i t C o m m i t i ( ) E n d B r o a d c a s t i ( ) ( x ^ _ ∙ , r ^ _ ∙ ) ↰ i ( ⋆ , 2 ) if ∃ j . H a s h ( x ^ j , r ^ j ) = c j : stop ( ⋆ , 2 ) return x ^ _ ∙ ⊗ Γ H 7 μ [ ∙ ] , x k , r k ← ⊥ … ↱ k ( S , ( x ^ _ ∙ , r ^ _ ∙ )) : for j ∈ S ∩ H . H a s h ( x ^ j , r ^ j ) = H a s h ( x k , r k ) : stop ({ j } , 2 ) ↱ k ( S , ( x ^ _ ∙ , r ^ _ ∙ )) ∘ F [ B r o a d c a s t ′ ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
(red parts deleted).
Now, because random oracles are collision resistant, we get the same
result to check full equality rather than hash equality.
Γ H 8 = Γ H 7 ⊗ Γ H 8 … ↱ k ( S , ( x ^ _ ∙ , r ^ _ ∙ ) , 2 ) : ‾ for j ∈ S ∩ H . ( x ^ j , r ^ j ) ≠ ( x k , r k ) : stop ( { j } , 2 ) ↱ k ( S , ( x ^ _ ∙ , r ^ _ ∙ ) ) ∘ F [ Broadcast ′ ] ⊗ F [ Sync ( 1 ) ] ⊗ F [ SyncComm ] ⊗ F [ Hash ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^8_H$
} = \Gamma^7_H\cr
\end{aligned}
}
}
\otimes
\boxed{
\small{
\begin{aligned}
&\colorbox{FBCFE8}{\large
$\Gamma^8_H$
}\cr
&\ldots\cr
\cr
&\underline{
\Rsh_k(S, (\hat{x}\_\bullet, \hat{r}\_\bullet), 2):
}\cr
&\enspace
\colorbox{bae6fd}{$
\texttt{for } j \in S \cap \mathcal{H}.\ (\hat{x}_j, \hat{r}_j) \neq (x_k, r_k):
$}
\cr
&\enspace\enspace
\texttt{stop}(\{j\}, 2)
\cr
&\enspace
\Rsh_k(S, (\hat{x}\_\bullet, \hat{r}\_\bullet))
\cr
\end{aligned}
}
}
\cr
\circ
\cr
F[\text{Broadcast}'] \otimes F[\text{Sync}(1)] \otimes F[\text{SyncComm}] \otimes F[\text{Hash}]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 8 = Γ H 7 ⊗ Γ H 8 … ↱ k ( S , ( x ^ _ ∙ , r ^ _ ∙ ) , 2 ) : for j ∈ S ∩ H . ( x ^ j , r ^ j ) = ( x k , r k ) : stop ({ j } , 2 ) ↱ k ( S , ( x ^ _ ∙ , r ^ _ ∙ )) ∘ F [ B r o a d c a s t ′ ] ⊗ F [ S y n c ( 1 )] ⊗ F [ S y n c C o m m ] ⊗ F [ H a s h ] ⊚ F [ S t o p ]
At this point, the malicious party can't actually send honest
parties an opened value that's any different than the one they
used to generate their initial broadcast hash.
We can now rewrite the adversary to use the ideal commitment
functionality instead.
Γ H 9 ( 1 ) SetCommit i ( x ) : ‾ SetCommit i ( x ) Commit i ( ) : ‾ Commit i ( ⋆ ) WaitCommit i ( ) : ‾ WaitCommit i ( ⋆ ) Sync i ( ⋆ ) Open i ( ) : ‾ Open i ( ⋆ ) WaitOpen i ( ) : ‾ WaitCommit i ( ) WaitSync i ( ⋆ ) return WaitOpen i ( ⋆ ) ⊗ Γ H 9 … SetBroadcast k ( h ) : ‾ assert h ∈ μ h k ← h SetCommit k ( μ [ h ] ) SendBroadcast k ( S ) : ‾ h ^ _ k j ← h k ( ∀ j ∈ S ∩ m ) Commit k ( S ) GetBroadcast k ( S ) : ‾ WaitCommit k ( S ) for j ∈ S ∩ H . c j = ⊥ : c j ← $ 01 2 λ return [ c j ∣ j ∈ S ∩ H h ^ _ j k ∣ j ∈ S ∩ M ] ↱ k ( S , m ^ _ ∙ , 2 ) : ‾ ( x ^ _ ∙ , r ^ _ ∙ ) ← m ^ _ ∙ for j ∈ S ∩ H . ( x ^ j , r ^ j ) ≠ ( x k , r k ) : stop ( { j } , 2 ) S ← S / { j } m _ k j ← ( ∀ j ∈ S ∩ M ) Open k ( S ) ↰ k ( S , 2 ) : ‾ xr _ ∙ ← WaitOpen k ( S ) return [ xr j ∣ j ∈ S ∩ H m _ k j ∣ j ∈ S ∩ M ] Hash ( x , r ) : ‾ h ← Hash ′ ( x , r ) μ [ h ] ← ( x , r ) return h Hash ′ ( x , r ) : ‾ if ∃ k ∈ M , j ∈ H . nowait ↰ k ( { j } , 2 ) = ( x , r ) : if ∃ k ∈ M , j ∈ H . nowait GetBroadcast ( { j } ) → c j : return c j return Hash ( x , r ) ⊗ 1 ( Sync k , WaitSync k , stop ) ⊗ F [ Hash ] ∘ F [ IdealCommit ] ⊗ F [ Sync ( 1 ) ] ⊚ F [ Stop ] \begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{bae6fd}{\large
$\Gamma^9_H$
}\cr
\cr
&\underline{
(1)\text{SetCommit}_i(x):
}\cr
&\enspace
\text{SetCommit}_i(x)
\cr
\cr
&\underline{
\text{Commit}_i():
}\cr
&\enspace
\text{Commit}_i(\star)
\cr
\cr
&\underline{
\text{WaitCommit}_i():
}\cr
&\enspace
\text{WaitCommit}_i(\star)
\cr
&\enspace
\text{Sync}_i(\star)
\cr
\cr
&\underline{
\text{Open}_i():
}\cr
&\enspace
\text{Open}_i(\star)
\cr
\cr
&\underline{
\text{WaitOpen}_i():
}\cr
&\enspace
\text{WaitCommit}_i()
\cr
&\enspace
\text{WaitSync}_i(\star)
\cr
&\enspace
\texttt{return } \text{WaitOpen}_i(\star)
\cr
\end{aligned}
}
}
\otimes
\begin{matrix}
\boxed{
\small{
\begin{aligned}
&\colorbox{bae6fd}{\large
$\Gamma^9_H$
}\cr
&\ldots\cr
\cr
&\underline{
\text{SetBroadcast}_k(h):
}\cr
&\enspace
\texttt{assert } h \in \mu
\cr
&\enspace
h_k \gets h
\cr
&\enspace
\text{SetCommit}_k(\mu[h])
\cr
\cr
&\underline{
\text{SendBroadcast}_k(S):
}\cr
&\enspace
\hat{h}\_{kj} \gets h_k \ (\forall j \in S \cap \mathcal{m})
\cr
&\enspace
\text{Commit}_k(S)
\cr
\cr
&\underline{
\text{GetBroadcast}_k(S):
}\cr
&\enspace
\text{WaitCommit}_k(S)
\cr
&\enspace
\texttt{for } j \in S \cap \mathcal{H}.\ c_j = \bot:
\cr
&\enspace\enspace
c_j \xleftarrow{\$} \texttt{01}^{2\lambda}
\cr
&\enspace
\texttt{return } \begin{bmatrix}
c_j &\mid j \in S \cap \mathcal{H} \cr
\hat{h}\_{jk} &\mid j \in S \cap \mathcal{M}
\end{bmatrix}
\cr
\cr
&\underline{
\Rsh_k(S, \hat{m}\_\bullet, 2):
}\cr
&\enspace
(\hat{x}\_\bullet, \hat{r}\_\bullet) \gets \hat{m}\_\bullet
\cr
&\enspace
\texttt{for } j \in S \cap \mathcal{H}.\ (\hat{x}_j, \hat{r}_j) \neq (x_k, r_k):
\cr
&\enspace\enspace
\texttt{stop}(\{j\}, 2)
\cr
&\enspace\enspace
S \gets S / \{j\}
\cr
&\enspace
m\_{kj} \gets (\forall j \in S \cap \mathcal{M})
\cr
&\enspace
\text{Open}_k(S)
\cr
\cr
&\underline{
\Lsh_k(S, 2):
}\cr
&\enspace
\text{xr}\_\bullet \gets \text{WaitOpen}_k(S)
\cr
&\enspace
\texttt{return } \begin{bmatrix}
\text{xr}_j &\mid j \in S \cap \mathcal{H}\cr
m\_{kj} &\mid j \in S \cap \mathcal{M}
\end{bmatrix}
\cr
\cr
&\underline{
\text{Hash}(x, r):
}\cr
&\enspace
h \gets \text{Hash}'(x, r)
\cr
&\enspace
\mu[h] \gets (x, r)
\cr
&\enspace
\texttt{return } h
\cr
\cr
&\underline{
\text{Hash}'(x, r):
}\cr
&\enspace
\texttt{if } \exists k \in \mathcal{M}, j \in \mathcal{H}.\ \texttt{nowait}\Lsh_k(\{j\}, 2) = (x, r):
\cr
&\enspace\enspace
\texttt{if } \exists k \in \mathcal{M}, j \in \mathcal{H}.\ \texttt{nowait } \text{GetBroadcast}(\{j\}) \to c_j:
\cr
&\enspace\enspace\enspace
\texttt{return } c_j
\cr
&\enspace
\texttt{return } \text{Hash}(x, r)
\cr
\end{aligned}
}
}\cr
\otimes\cr
1(\text{Sync}_k, \text{WaitSync}_k, \texttt{stop}) \otimes F[\text{Hash}]
\end{matrix}
\cr
\circ
\cr
F[\text{IdealCommit}] \otimes F[\text{Sync}(1)]
\circledcirc F[\text{Stop}]
\end{matrix} Γ H 9 ( 1 ) S e t C o m m i t i ( x ) : S e t C o m m i t i ( x ) C o m m i t i ( ) : C o m m i t i ( ⋆ ) W a i t C o m m i t i ( ) : W a i t C o m m i t i ( ⋆ ) S y n c i ( ⋆ ) O p e n i ( ) : O p e n i ( ⋆ ) W a i t O p e n i ( ) : W a i t C o m m i t i ( ) W a i t S y n c i ( ⋆ ) return W a i t O p e n i ( ⋆ ) ⊗ Γ H 9 … S e t B r o a d c a s t k ( h ) : assert h ∈ μ h k ← h S e t C o m m i t k ( μ [ h ]) S e n d B r o a d c a s t k ( S ) : h ^ _ kj ← h k ( ∀ j ∈ S ∩ m ) C o m m i t k ( S ) G e t B r o a d c a s t k ( S ) : W a i t C o m m i t k ( S ) for j ∈ S ∩ H . c j = ⊥ : c j $ 01 2 λ return [ c j h ^ _ jk ∣ j ∈ S ∩ H ∣ j ∈ S ∩ M ] ↱ k ( S , m ^ _ ∙ , 2 ) : ( x ^ _ ∙ , r ^ _ ∙ ) ← m ^ _ ∙ for j ∈ S ∩ H . ( x ^ j , r ^ j ) = ( x k , r k ) : stop ({ j } , 2 ) S ← S / { j } m _ kj ← ( ∀ j ∈ S ∩ M ) O p e n k ( S ) ↰ k ( S , 2 ) : x r _ ∙ ← W a i t O p e n k ( S ) return [ x r j m _ kj ∣ j ∈ S ∩ H ∣ j ∈ S ∩ M ] H a s h ( x , r ) : h ← H a s h ′ ( x , r ) μ [ h ] ← ( x , r ) return h H a s h ′ ( x , r ) : if ∃ k ∈ M , j ∈ H . nowait ↰ k ({ j } , 2 ) = ( x , r ) : if ∃ k ∈ M , j ∈ H . nowait G e t B r o a d c a s t ({ j }) → c j : return c j return H a s h ( x , r ) ⊗ 1 ( S y n c k , W a i t S y n c k , stop ) ⊗ F [ H a s h ] ∘ F [ I d e a l C o m m i t ] ⊗ F [ S y n c ( 1 )] ⊚ F [ S t o p ]
This is fact a simulator over P [ IdealCommit ] \mathscr{P}[\text{IdealCommit}] P [ I d e a l C o m m i t ] ,
concluding our proof.
■ \blacksquare ■