An IPFS Privacy Storage Sharing Scheme Based on SM4 Algorithm

Jiazhen Song, Yutong Li, Haori Lu, Jingrong Wang, Peng NieProceedings of the 2022 2nd International Conference on Education, Information Management and Service Science (EIMSS 2022) 2022 · OpenAlex

Abstract

Nowadays, based on the characteristics of immutability and decentralization, IPFS as a distributed file system is applied in more and more scenarios. However, the storage mode of IPFS is designed for all Internet users and is open. Therefore, the protection of personal privacy data stored on IPFS and the sharing of privacy information within a specific range have become the problems that need to be solved in the current application of IPFS. Based on the above requirements, this paper proposes a scheme based on SM4 domestic commercial security algorithm, which realizes the storage of private information in the form of ciphertext on IPFS, ensures its privacy and realizes the sharing of plaintext content only within the specified range. After analysis, our proposed scheme has reached a high level in algorithm performance and process security. And the scheme has been applied to the self-realized rumour management platform, which shows that it has a wide application prospect.

Introduction

The InterPlanetary File System (IPFS) represents a significant advancement in decentralized storage, offering immutability and content-addressing. However, its "public-by-default" nature presents a major challenge for sensitive data: once a file is uploaded, anyone with the file's hash can access it. This lack of inherent privacy is a dealbreaker for blockchain-integrated systems or personal data storage. This paper addresses the critical gap of leveraging IPFS's efficiency while ensuring private information remains accessible only to authorized circles.

Proposed System Architecture

The researchers propose a three-tier architecture designed to secure data before it reaches the IPFS network. This architecture involves three primary entities: an Information Generator, a Trusted Agent, and an Information Requester.

System architecture of the proposed IPFS privacy storage sharing scheme.

In this workflow, the Information Generator produces the data, which is then passed to the Trusted Agent. The Agent performs the encryption using the SM4 algorithm before uploading the resulting ciphertext to the local IPFS warehouse. This ensures that the IPFS hash generated points only to encrypted data, rendering it useless to unauthorized parties. Because data is encrypted before upload, identical files from the same generator still result in the same ciphertext, preserving IPFS's natural deduplication efficiency.

The SM4 Encryption Methodology

The core of the solution is the SM4 algorithm, a Chinese national standard for commercial block ciphers. SM4 is a symmetric encryption algorithm utilizing a 128-bit key and a 128-bit block size, processing data through 32 rounds of nonlinear iterative structure.

A key advantage of SM4 in this context is its efficiency. By using symmetric encryption rather than asymmetric (public-key) cryptography, the system maintains high-speed processing, which is essential for the performance expectations of IPFS. Furthermore, SM4's decryption process uses the exact same algorithmic structure as encryption; the requester simply applies the round keys in reverse order, simplifying the implementation for the Trusted Agent and the Requester.

Comparative Analysis and Results

The proposed scheme was evaluated qualitatively and through a comparative analysis with the Data Encryption Standard (DES), as shown in the table below.

Comparison of algorithm characteristics between DES and SM4.

The analysis highlights that SM4 offers superior security due to its 128-bit key length compared to the 56-bit key of DES or the 112-bit effective key of 3DES. Additionally, SM4 achieves high performance in both software and hardware implementations, whereas DES is notably slower in software.

The scheme's practical utility was demonstrated through its deployment in a rumor management platform. In this application, social platforms act as generators, the management platform as the trusted agent, and regulators as requesters. This allows for the secure tracing of misinformation sources without exposing private publisher data to the public internet.

Conclusion and Future Work

While the SM4-based scheme provides a robust framework for IPFS privacy, several areas remain for future exploration. The current model relies on a centralized "Trusted Agent" for key management; future iterations could explore Decentralized Identifiers (DIDs) or Smart Contracts to automate trust. Additionally, while qualitative performance is high, further research could provide granular quantitative benchmarks against other modern standards like AES-128.

Summary updated

Abstract

Nowadays, based on the characteristics of immutability and decentralization, IPFS as a distributed file system is applied in more and more scenarios.However, the storage mode of IPFS is designed for all Internet users and is open.Therefore, the protection of personal privacy data stored on IPFS and the sharing of privacy information within a specific range have become the problems that need to be solved in the current application of IPFS.Based on the above requirements, this paper proposes a scheme based on SM4 domestic commercial security algorithm, which realizes the storage of private information in the form of ciphertext on IPFS, ensures its privacy and realizes the sharing of plaintext content only within the specified range.After analysis, our proposed scheme has reached a high level in algorithm performance and process security.And the scheme has been applied to the self-realized rumour management platform, which shows that it has a wide application prospect.
BibTeX
@inproceedings{song2022ipfs,
  author = {Jiazhen Song and Yutong Li and Haori Lu and Jingrong Wang and Peng Nie},
  title = {{An IPFS Privacy Storage Sharing Scheme Based on SM4 Algorithm}},
  booktitle = {Proceedings of the 2022 2nd International Conference on Education, Information Management and Service Science (EIMSS 2022)},
  year = {2022},
  doi = {10.2991/978-94-6463-024-4\_67},
}
Figure