bitpro가 원문에서 글자만 모은 내용이에요. 표·그림·수식은 빠지거나 깨질 수 있어요. 전체 6쪽 중 3쪽
imburse and ensure the Operator can only get a round’s reimbursements in the next round,
after having correctly concluded the previous one.
We observe that if the Operator posts a ReadyToReimburse transaction before all KickOff
transactions have been finalized, a Challenger can punish it by posting a KickoffNotFinalized
transaction that spends the finalizer connector and the output of theReadyToReimburse, taking the
Operator’s collateral and thus preventing the Operator from getting reimbursed. We further observe
that before moving to the next round, all unused kickoff connectors must be burned by the Operator
by posting the BurnUnusedKickOff transaction: this contributes to economic safety of the bridge
by preventing a malicious Operator from moving the collateral to a subsequent round while still
being able to post KickOff transactions spending from the previous, no longer collateralized round.
Similarly, should the Operator post a ReadyToReimburse before all the kickoff connectors of the
Roundi have been burnt, the Challenger can post a UnspentKickOff transaction and burn a kickoff
connector as well as the Operator’s collateral. 9
Figure 3 depicts the payoff round transactions and the transactions spending their outputs, in
the presence of a single KickOff transaction. Figure 4 depicts the case with multiple (in this case,
two) KickOff transactions processed in a single round, showing how Clementine can handle high
throughput.
5.4 Multiple Operators, Watchtowers, and Challengers
In the previous subsections, we have introduced all the key building blocks of the Clementine protocol,
and we have introduced all the key participants of the protocol: an Operator, a Watchtower, and a
Challenger. To fully enhance Clementine security and avoid single points of failure, we now consider
multiple Operators, Watchtowers, and Challengers taking part to the protocol. We assume that, at
least one Operator, one Watchtower, and one Challenger in the sets of Operators, Watchtowers, and
Challengers are honest (existential honesty assumption).
This new setting only requires minimal adjustments to the protocol described above. With multiple
Operators supporting the bridge, all KickOff transactions need to have an OP RETURN output
that includes an identifier for the Operator that posted it, and an identifier for the MoveToVault
transaction(s) the reimbursement takes the money from. We observe that for each peg out, only
one reimbursement (to one Operator) can be issued, thanks to the way the Payout transaction
is constructed. Recall that the Payout transaction is created by the user, Alice, and revealed in
Citrea when posting the Burn transaction; its first input and first output are signed by Alice under
the SIGHASH SINGLE|ANYONECANPAY, which allows anyone to attach new inputs or outputs to
the transaction without invalidating the signature. In this way, Operators compete to complete the
transaction, and only one of them will end up posting on Bitcoin.
The KickOff transaction needs to include two outputs for each Watchtower: one that is spent
by the Watchtower by revealing a commitment to the canonical chain that is different from the one
presented by the Operator, and that is spent by the Operator when acknowledging the challenge.
Introducing multiple Challengers does not have any effect on the way transactions are constructed,
nor on the way the protocol works: it only adds more people watching over the behavior of the Operator,
guaranteeing that, should the Operator try to cheat, someone will react.
Figure 5 depicts the complete transaction graph of Clementine.
9After this, if an Operator posts a malicious kickoff, a Challenger needs to be careful to not send unnecessary
challenges: without the collateral Operator cannot get reimbursed anyway.
11
In Out
KickOff i,j
WinCom(bhi,j ),σO Challenge Connector
Finalizer Connector
Reimburse Link Connector
Disprove Connector
Latest Blockhash Connector
Assert Connector
.
.
.
Assert Connector
Watchtower Challenge Connector
Acknowledge Connector
.
.
.
Watchtower Challenge Connector
Acknowledge Connector
OP RETURN
In Out
Disprovei,j,h
DisproveWitnessh
σO
dB
⋆
In Out
BlockHashTimeouti,j
Covenant
Covenant
σO
ϵB
⋆
In Out
AssertTimeouti,j,l
Covenant
Covenant
σO
dB
⋆
In Out
OperatorChallengeNACKi,j,k
Covenant
Covenant
σO
dB
⋆
In Out
KickoffNotFinalizedi,j
Covenant
σO
dB
⊥
In Out
Roundi
σO Burn Connector
dB
CheckSig(pkO )
First Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi,1 )
∨
CheckSig(pkO )∧
OP CSV(1 block )
.
.
.
Last Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi,k )
∨
CheckSig(pkO )∧
OP CSV(1 block )
First Reimburse Connector
ϵB
CheckSig(pkO )
.
.
.
Last Reimburse Connector
ϵB
CheckSig(pkO )
In Out
Roundi+1
σO Burn Connector
dB
CheckSig(pkO )
First Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi+1,1 )
∨
CheckSig(pkO )∧
OP CSV(1 block )
.
.
.
Last Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi+1,k )
∨
CheckSig(pkO )∧
OP CSV(1 block )
First Reimburse Connector
ϵB
CheckSig(pkO )
.
.
.
Last Reimburse Connector
ϵB
CheckSig(pkO )
In Out
ReadyToReimbursei
σO Burn Connector
dB
CheckSig(pkO )∧
OP CSV(t9 blocks)
In Out
UnspentKickOff i,j
σO
σO
dB
⊥
In Out
BurnUnusedKickOffi,j
σO ϵB
⋆
Fig. 3: Round transaction graph of Clementine in the case of a single KickOff transaction.
12
In Out
KickOff i,j
WinCom(bhi,j ),σO Challenge Connector
CheckCovenant
∨
CheckSig(pkO )∧ OP CSV(t5 blocks)
Finalizer Connector
CheckCovenant
Reimburse Link Connector
CheckCovenant
Disprove Connector
Latest Blockhash Connector
Assert Connector
.
.
.
Assert Connector
Watchtower Challenge Connector
Acknowledge Connector
.
.
.
Watchtower Challenge Connector
Acknowledge Connector
OP RETURN
In Out
KickOff i,j’
WinCom(bhi,j ),σO Challenge Connector
CheckCovenant
∨
CheckSig(pkO )∧ OP CSV(t5 blocks)
Finalizer Connector
CheckCovenant
Reimburse Link Connector
CheckCovenant
Disprove Connector
Latest Blockhash Connector
Assert Connector
.
.
.
Assert Connector
Watchtower Challenge Connector
Acknowledge Connector
.
.
.
Watchtower Challenge Connector
Acknowledge Connector
OP RETURN
In Out
MoveToVault
Covenant vB
CheckCovenant
In Out
NoChallengei,j
σO
Covenant
ϵB
⋆
In Out
KickoffNotFinalizedi,j
Covenant
σO
dB
⊥
In Out
MoveToVault
Covenant vB
CheckCovenant
In Out
NoChallengei,j
σO
Covenant
ϵB
⋆
In Out
KickoffNotFinalizedi,j
Covenant
σO
dB
⊥
In Out
Reimbursei,j
Covenant
Covenant
σO
vB
CheckSig(pkO )
In Out
Reimbursei,j
Covenant
Covenant
σO
vB
CheckSig(pkO )
In Out
Roundi
σO Burn Connector
dB
CheckSig(pkO )
First Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi,1 )
∨
CheckSig(pkO )∧
OP CSV(1 block )
.
.
.
Last Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi,k )
∨
CheckSig(pkO )∧
OP CSV(1 block )
First Reimburse Connector
ϵB
CheckSig(pkO )
.
.
.
Last Reimburse Connector
ϵB
CheckSig(pkO )
In Out
Roundi+1
σO Burn Connector
dB
CheckSig(pkO )
First Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi+1,1 )
∨
CheckSig(pkO )∧
OP CSV(1 block )
.
.
.
Last Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi+1,k )
∨
CheckSig(pkO )∧
OP CSV(1 block )
First Reimburse Connector
ϵB
CheckSig(pkO )
.
.
.
Last Reimburse Connector
ϵB
CheckSig(pkO )
In Out
ReadyToReimbursei
σO Burn Connector
dB
CheckSig(pkO )∧
OP CSV(t9 blocks)
In Out
UnspentKickOff i,j
σO
σO
dB
⊥
In Out
UnspentKickOff i,j
σO
σO
dB
⊥
In Out
BurnUnusedKickOffi,j
σO ϵB
⋆
In Out
BurnUnusedKickOffi,j
σO ϵB
⋆
Fig. 4: Round transaction graph in the presence of multiple (in this case, due to space constraints,
two) different KickOff transactions.
13
In Out
KickOff i,j
WinCom(bhi,j ),σO Challenge Connector
ϵB
CheckCovenant
∨
CheckSig(pkO )∧ OP CSV(t5 blocks)
Finalizer Connector
ϵB
CheckCovenant
Reimburse Link Connector
ϵB
CheckCovenant
Disprove Connector
ϵB
CheckCovenant∧ OP CSV(t8 blocks)
∨
BridgeDisproveScript0,..., BridgeDisproveScript100ns ,
ClementineDisproveScript0,..., ClementineDisproveScriptm
Latest Blockhash Connector
ϵB
CheckCovenant∧ OP CSV(t7 blocks)
∨
CheckWintSig(lbhi,j )
Assert Connector
ϵB
CheckCovenant∧ OP CSV(t6 blocks)
∨
CheckWintSig(zi,j,0,..., zi,j,100 )
.
.
.
Assert Connector
ϵB
CheckCovenant∧ OP CSV(t6 blocks)
∨
CheckWintSig(zi,j,100(ns−1)+1,..., zi,j,100ns )
Watchtower Challenge Connector
ϵB
CheckCovenant∧ OP CSV(t3 blocks)
∨
CheckSig(pkW1 )
Acknowledge Connector
ϵB
CheckCovenant∧ OP CSV(t4 blocks)
∨
CheckCovenant∧ OP CSV(t3 blocks)
∨
H(si,j,1 )
.
.
.
Watchtower Challenge Connector
ϵB
CheckCovenant∧ OP CSV(t3 blocks)
∨
CheckSig(pkWm )
Acknowledge Connector
ϵB
CheckCovenant∧ OP CSV(t4 blocks)
∨
CheckCovenant∧ OP CSV(t3 blocks)
∨
H(si,j,m )
0B
OP RETURN(move txid, operator idx)
In Out
NoChallengei,j
σO
Covenant
ϵB
⋆
In Out
Challengei,j
cBCovenant(SINGLE|ANYONE)
CheckSig(pkO )
σC 0B
OP RETURN(evm addr)
In Out
DisproveTimeouti,j
Covenant
Covenant
ϵB
⋆
In Out
Disprovei,j,h
DisproveWitnessh
σO
dB
⋆
In Out
BlockHashTimeouti,j
Covenant
Covenant
σO
ϵB
⋆
In Out
BlockHashi,j
WinCom(lbhi,j ) ϵB
⋆
In Out
AssertTimeouti,j,l
Covenant
Covenant
σO
dB
⋆
In Out
Asserti,j,l
WinCom(zi,j,l,..., zi,j,100·l ) ϵB
⋆
In Out
WatchtowerChallengei,j,k
σWk
σWk
ϵB
DATA(cp[: 32bytes])
ϵB
DATA(cp[32bytes : 64bytes])
0B
OP RETURN(cp[64bytes : 144bytes])
In Out
WatchtowerChallengeTimeouti,j,k
Covenant
Covenant
ϵB
⋆
In Out
OperatorChallengeACKi,j,k
si,j,k ϵB
⋆
In Out
OperatorChallengeNACKi,j,k
Covenant
Covenant
σO
dB
⋆
In Out
KickoffNotFinalizedi,j
Covenant
σO
dB
⊥
In Out
Reimbursei,j
Covenant
Covenant
σO
vB
CheckSig(pkO )
In Out
Roundi
σO Burn Connector
dB
CheckSig(pkO )
First Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi,1 )
∨
CheckSig(pkO )∧
OP CSV(1 block )
.
.
.
Last Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi,k )
∨
CheckSig(pkO )∧
OP CSV(1 block )
First Reimburse Connector
ϵB
CheckSig(pkO )
.
.
.
Last Reimburse Connector
ϵB
CheckSig(pkO )
In Out
Roundi+1
σO Burn Connector
dB
CheckSig(pkO )
First Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi+1,1 )
∨
CheckSig(pkO )∧
OP CSV(1 block )
.
.
.
Last Kickoff Connector
ϵB
CheckSig(pkO )∧
CheckWintSig(bhi+1,k )
∨
CheckSig(pkO )∧
OP CSV(1 block )
First Reimburse Connector
ϵB
CheckSig(pkO )
.
.
.
Last Reimburse Connector
ϵB
CheckSig(pkO )
In Out
ReadyToReimbursei
σO Burn Connector
dB
CheckSig(pkO )∧
OP CSV(t9 blocks)
In Out
UnspentKickOff i,j
σO
σO
dB
⊥
In Out
BurnUnusedKickOffi,j
σO ϵB
⋆
In Out
Deposit
σA vB
CheckCovenant∧
DATA(citrea addr)
∨
CheckSig(pkA )∧
OP CSV(t1 blocks)
In Out
MoveToVault
Covenant vB
CheckCovenant
In Out
Payout
(v−f )BσB
CheckSig(pkB )
σO 0B
OP RETURN(operator id)
Fig. 5: Complete transaction graph of Clementine.
14
6 Transactions and Disprove Scripts
6.1 Transaction Description
In this section, we formalize all the transactions encompassed by Clementine. We specify transactions
in the form of tables, color-coding the cells as follows: In orange we outline the inputs, in blue the
witness, and in green the information about the outputs. With ⋆ we denote a transaction input,
witness, or output that can be anything (valid according to Bitcoin consensus rules), but is irrelevant
to our protocol. With ⊥ we refer to a script that burns the funds.
In the transaction tables and in the pseudocodes, we will use various indexes: with i we denote the
index running through the number of rounds, with j the index running through number of outputs of
a Round transaction, with k the index running through the number of Watchtowers, and with l the
index running through the number of program splits.
The Deposit transaction is posted to Bitcoin by the user when pegging in. The output of this
transaction holds the the amount v the user wants to transfer from Bitcoin to Citrea, and it can be
spent either by the Operator in the MoveToVaulttransaction (enforced via covenants), or by the
user itself after a (relative) timeout of t1 blocks. This last condition allows the user to get back the
money in case malicious Operators do not move forward with the peg in request. After posting the
Deposit transaction, the user shares its own Citrea address with the Operators and Signers and,
finally, an Operator issues a Mint transaction in Citrea that gives v coins to the user.
The MoveToVault transaction is posted by an Operator and makes the v coins of the user
spendable by the Reimburse transaction. When posting MoveToVault, the Operator reveals the
Citrea address of the user: this is checked by the Bitcoin light client running on Citrea, ensuring no
cBTC are minted out of thin air.
Deposit
Input Tx Index Tapleaf Witness
0 ⋆ ⋆ N/A σA
Output Value Script
0 vB (CheckCovenant∧ DATA(citrea addr))∨(CheckSig(pkA)∧ OP CSV(t1 blocks))
MoveToVault
Input Tx Index Tapleaf Witness
0 Deposit 0 0 Covenant
Output Value Script
0 vB CheckCovenant
When a user pegs out, it creates a 0-value output and it posts a Burn transaction that calls
the withdraw function in Citrea. The Burn transaction is EVM-compatible and burns v coins; in its
data, this transaction includes an incomplete Payout transaction that has the 0-value as input. The
0-value input guarantees that only one Payout transaction goes on-chain and that the correct user
has been pegged out. Later, Payout is signed with v−f coins as output spendable by the user. The
0-value input is signed with SIGHASH SINGLE|ANYONECANPAY and the signature along with output
details is sent to the Operators off-chain. When Operators see an incomplete transaction on Citrea,
they compete to complete it, adding one input in which it fronts money to the user (or more than
one depending on the unspent outputs that the Operator has at his disposal) and one output that
holds the Operator identifier (more outputs if the operator needs to send back to itself some coins for
change). The complete Payout transaction is then posted on-chain by an Operator.
The Reimburse transaction is posted by an Operator to get reimbursed. We recall that an Op-
erator can be reimbursed of a payout, only in the next payoff round.
A Round transaction is posted by Operators at the beginning of an Operator’s new payoff round.
The first round transaction, Round1, created by an Operator is simpler than the following ones: it
has a burn connector holding the d coins of the Operator’s collateral and no kickoff connectors each
one holding ϵ of coins. 10 The burn connector allows to propagate the collateral to the next round
and it can be spent by the Operator after all the KickOff transactions of the round have been
finalized. The Operator can also spend the burn connector to exit from the Operators’ set. The kickoff
10Non-standard transactions [3, 5, 7], i.e., transactions s.t. ϵ = 0 coins can be included in a block by a miner but, by
default, these transactions are not propagated through the network.
15
Payout
Input Tx Index Tapleaf Witness
0 ⋆ ⋆ N/A σB
1 ⋆ ⋆ N/A σO
Output Value Script
0 (v−f)B CheckSig(pkB)
1 0 OP RETURN(operator id)
Reimbursei,j
Input Tx Index Tapleaf Witness
0 MoveToVault 0 0 Covenant
1 KickOff i,j 2 0 Covenant
2 Roundi+1 no+j 0 σO
Output Value Script
0 vB CheckSig(pkO)
connectors of a Round1 transaction can be spent by the Operator either by providing its signature
and a Winternitz commitment to the chain, or after a relative timelock enforced by OP CSV, aka.
OP CHECKSEQUENCEVERIFY. The opcode OP CSV requires the spending transaction to set the
nSequence number of a transaction field to a value that is equal or larger than the top stack value; we
observe that an Operator cannot spend a kickoff connector with aKickOff transaction because all the
transactions spending from the KickOff are bound by covenants to a KickOff with nSequence = 0.
We recall that an Operator, before moving to the next round, must spend all the kickoff connectors: if
there are not sufficient peg outs, it can issue a BurnUnusedKickOff transaction. Successive round
transactions, Roundi, spend from a ReadyToReimburse and they include no additional outputs
(reimburse connectors) that can be spent by the Reimburse transactions of previous round’s peg
outs.
Round1
Input Tx Index Tapleaf Witness
0 ⋆ ⋆ N/A σO
Output Value Script
0 dB “Burn Connector”CheckSig(pkO)
1 ϵB “First Kickoff Connector”CheckSig(pkO)∧ (CheckWintSig(bh1,1)∨ OP CSV(1 block ))
... ... ...
no ϵB “Last Kickoff Connector”CheckSig(pkO)∧ (CheckWintSig(bh1,no)∨ OP CSV(1 block ))
Roundi
Input Tx Index Tapleaf Witness
0 ReadyToReimbursei-1 0 0 σO
Output Value Script
0 dB “Burn Connector”CheckSig(pkO)
1 ϵB “First Kickoff Connector”CheckSig(pkO)∧ (CheckWintSig(bhi,1)∨ OP CSV(1 block ))
... ... ...
no ϵB “Last Kickoff Connector”CheckSig(pkO)∧ (CheckWintSig(bhi,no)∨ OP CSV(1 block ))
no+1 ϵB “First Reimburse Connector”CheckSig(pkO)
... ... ...
no+no ϵB “Last Reimburse Connector”CheckSig(pkO)
A ReadyToReimburse transaction spends a burn connector and creates a new burn connector
with the Operator’s collateral. The output can either be spent by the Operator after a timeout or by
a Challenger with the UnspentKickOff or the KickoffNotFinalized transactions. The former is
posted if the Operator posts a ReadyToReimburse before all the kickoff connectors of the round
16
have been burnt, the latter is posted if not every disprove process in the round was finished before the
Operator sends ReadyToReimburse. The ReadyToReimburse transaction is necessary to safely
move from one round to the next: if the Operator starts a new round before having burnt the kickoff
connectors and before the timeout, it loses its collateral.
ReadyToReimbursei
Input Tx Index Tapleaf Witness
0 Roundi 0 0 σO
Output Value Script
0 dB “Burn Connector”CheckSig(pkO)∧ OP CSV(t9 blocks)
BurnUnusedKickOffi,j
Input Tx Index Tapleaf Witness
0 Roundi j 1 σO
Output Value Script
0 ϵB ⋆
KickOffNotFinalizedi,j
Input Tx Index Tapleaf Witness
0 KickOff i,j 1 0 Covenant
1 ReadyToReimbursei 0 0 σO
Output Value Script
0 dB ⊥
UnspentKickOffi,j
Input Tx Index Tapleaf Witness
0 ReadyToReimbursei 0 0 σO
1 Roundi j 1 σO
Output Value Script
0 dB ⊥
A KickOff transaction is published by the Operator plays a pivotal role in Clementine. By posting
it, the Operator reveals a commitment to the chain. A KickOff transaction has the outputs that
Watchtowers, Challengers, and the Operator himself use to determine whether a reimbursement is
legit or not. The outputs of the KickOff transaction include:
– Challenge Connector : It can be spent by a Challenger, by posting the Challenge transaction. The
Challenge transaction allows to challenge the Operator’s commitment to the chain: an incomplete
version of it is created during peg in, and then any Challenger can complete it by adding one c-
value input that the Operator can spend to fund the (expensive)Assert transaction – this protects
the Operator from griefing. In the Challenge transaction, the Challenger also includes an output
with the its own address on Citrea: if the challenge was correct, the Challenger can have the c
coins back on Citrea (by proving the outcome of the challenge through a light client proof). If no
Challenge transactions is posted, then the challenge connector is spent by the Operator via the
NoChallenge transaction after a relative timelock t5 blocks.
– Finalizer Connector : When this connector is spent, the KickOff is finalized. Depending on how
this connector is spent, we have information on whether the Operator can post the Reimburse
transaction or if the Operator’s collateral has been taken. In particular, if the finalizer connector
is spent by the KickOffNotFinalized, OperatorChallengeNACK, BlockHashTimeout, or
AssertTimeout transactions, then the (malicious) Operator loses its collateral and the possi-
bility of acting as Operator again. On the other hand, if the finalizer connector is spent by the
NoChallenge and DisproveTimeout, the Operator can get reimbursed, as no challenge took
place or the challenge has been won by the Operator. We observe that, by design, if the Oper-
ator attempts to ask invalid reimbursement requests, it is sufficient for Challengers to contest a
single KickOff transaction. In fact, a single successful challenge is enough to seize the Operator’s
collateral a프로젝트로 돌아가기