An SGX-based key protection scheme for Hyperledger Fabric
摘要
Hyperledger Fabric (Fabric for short) is a typical consortium blockchain. Private keys play a pivotal role in the workflow of Fabric. However, in the current official implementation of Fabric, a user’s private key is directly stored in the local filesystem. There have been schemes to protect private keys of blockchain systems, while many of them do not provide runtime protection for private keys. Few of them are designed for Fabric and cannot work directly on Fabric. In this paper, we utilize the hardware security features provided by Intel SGX to design a key protection scheme for Fabric, which can provide both storage and runtime protection for private keys. Operations related to private keys are enforced in Enclaves. Private keys that are not in service are sealed and stored locally, ensuring that they can be used securely and continuously. The corresponding sealed private key will be loaded into an Enclave only when a proposal/transaction/commit is to be signed. By employing this approach, we can enhance the security of key generation, storage, and usage without disrupting the standard functionalities of Fabric. We implemented a prototype system and verified its functionalities and performances through rigorous testing in a simulated environment. The experimental results show that our scheme can work normally in Fabric with reasonable performance overheads, validating its feasibility.