In recent years, the confidentiality of smart contracts has become a fundamental requirement for practical applications. While many efforts have been made to develop architectural capabilities for enforcing confidential smart contracts, a few works arise to extend confidential smart contracts to Multi-Party Computation (MPC), i.e., multiple parties jointly evaluate a transaction off-chain and commit the outputs on-chain without revealing their secret inputs/outputs to each other. However, existing solutions lack public verifiability and require O(n) transactions to enable negotiation or resist adversaries, thus suffering from inefficiency and compromised security. In this paper, we propose Cloak, a framework for enabling Multi-Party Transaction (MPT) on existing blockchains. An MPT refers to transitioning blockchain states by an publicly verifiable off-chain MPC. We identify and handle the challenges of securing MPT by harmonizing TEE and blockchain. Consequently, Cloak secures the off-chain nondeterministic negotiation process (a party joins an MPT without knowing identities or the total number of parties until the MPT proposal settles), achieves public verifiability (the public can validate that the MPT correctly handles the secret inputs/outputs from multiple parties and reads/writes states on-chain), and resists Byzantine adversaries. According to our proof, Cloak achieves better security with only 2 transactions, superior to previous works that achieve compromised security at O(n) transactions cost. By evaluating examples and real-world MPTs, the gas cost of Cloak reduces by 32.4% on average.
翻译:近年来,智能合约的保密性已成为实际应用的基本需求。尽管已有许多工作致力于开发支持保密智能合约的架构能力,但少数研究尝试将保密智能合约扩展至多方计算(MPC),即多方共同在链下评估交易并在链上提交输出,同时不向彼此透露各自的秘密输入/输出。然而,现有解决方案缺乏公开可验证性,且需要O(n)笔交易才能实现协商或抵御敌手,因此存在效率低下和安全折衷的问题。本文提出Cloak框架,旨在现有区块链上实现多方交易(MPT)。MPT是指通过公开可验证的链下MPC实现区块链状态转换。我们通过协调TEE与区块链,识别并应对了保障MPT安全性的挑战。因此,Cloak能够保障链下非确定性协商过程的安全性(一方加入MPT时,在MPT提案最终确定前无需知晓其他参与方身份或总参与方数量),实现公开可验证性(公众可验证MPT是否正确处理来自多方的秘密输入/输出,并正确读写链上状态),同时抵抗拜占庭敌手。根据我们的证明,Cloak仅需2笔交易即可实现更高安全性,优于此前需O(n)笔交易成本却仅能实现折衷安全性的工作。通过示例及真实MPT的评估,Cloak的Gas成本平均降低了32.4%。