Blockchain-based electronic certificate management method, device and equipment and storage medium

CN116226289BActive Publication Date: 2026-10-09YGSOFT INC
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310385782.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-04-11
Publication Date
2026-10-09
Estimated Expiration
2043-04-11

AI Technical Summary

Technical Problem

[0002]在企业进行生产经营管理过程中,在其企业会计核算系统、业务系统或者外部单位产生业务往来时,会产生大量的电子凭据相关数据,由于区块链网络的容量是有限的,如果大量的电子凭证数据被存储在区块链上,可能会导致网络拥堵和延迟,进而影响交易的速度和效率,因此电子凭据数据难以在区块链上实现原文存储

Benefits of technology

[0049]This application discloses a blockchain-based electronic certificate management method, apparatus, device, and storage medium, relating to the field of blockchain technology. The method involves acquiring electronic certificate data to be processed and a first key; encrypting the electronic certificate data using the first key to obtain first encrypted data; storing the first encrypted data in a distributed peer-to-peer network; receiving the hash path returned by the distributed peer-to-peer network; storing the hash path and the first key in the blockchain network; receiving a data request instruction from a data requester and verifying the data requester's identity; outputting the data requester's data access permissions when the data requester passes identity verification; determining a target hash path and target key matching the data requester in the blockchain network based on the data access permissions; searching for matching encrypted electronic certificate data in the distributed peer-to-peer network using the target hash path; and decrypting the encrypted electronic certificate data using the target key to obtain the original electronic certificate data. This application manages electronic certificate data by combining a blockchain network and a distributed peer-to-peer network to achieve on-chain and off-chain collaboration, ensuring data privacy and security, and achieving secure storage of electronic certificate data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116226289B_ABST
    Figure CN116226289B_ABST
Patent Text Reader

Abstract

The application discloses a blockchain-based electronic certificate management method and device, equipment and a storage medium, and relates to the technical field of blockchains. The electronic certificate data to be processed is encrypted by a first key to obtain encrypted data, the encrypted data is stored in a distributed peer-to-peer network, and a returned hash path is received. The hash path and the first key are stored in a blockchain network, a data request instruction is received, and a data demander is identity-verified. When the data demander passes the identity verification, a matching target hash path and a target key are determined in the blockchain network according to data access authority, the matching electronic certificate encrypted data is found through the target hash path, the electronic certificate encrypted data is decrypted through the target key, and the electronic certificate original data is obtained. The application realizes the management of electronic certificate data by combining the on-chain and off-chain manners of the blockchain, can guarantee the privacy and security of data, and realizes the secure storage of electronic certificate data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of blockchain technology, specifically to a blockchain-based electronic certificate management method, apparatus, device, and storage medium. Background Technology

[0002] During the production and operation management of enterprises, a large amount of electronic voucher data is generated when business transactions occur in their accounting systems, business systems, or with external entities. Since the capacity of blockchain networks is limited, storing a large amount of electronic voucher data on the blockchain may lead to network congestion and delays, thus affecting the speed and efficiency of transactions. Therefore, it is difficult to store electronic voucher data in its original form on the blockchain. Furthermore, storing electronic voucher data on the blockchain also presents privacy and security issues. First, while blockchain networks are designed for openness and transparency, some electronic voucher data may contain sensitive information, such as personal identification numbers and social security numbers. Storing this data on the blockchain could lead to privacy breaches. Second, although blockchain networks are secure, the storage and transmission of electronic voucher data may have vulnerabilities and risks, such as hacker attacks and malware, which could lead to the tampering or theft of electronic voucher data. Summary of the Invention

[0003] The purpose of this application is to propose a blockchain-based electronic certificate management method, apparatus, computer equipment, and storage medium to address the scalability, privacy, and security issues associated with storing electronic certificate data on the blockchain, and the difficulty in storing electronic certificate data in its original form on the blockchain. To solve the above technical problems, this application provides a blockchain-based electronic certificate management method, employing the following technical solution:

[0004] A blockchain-based electronic certificate management method includes:

[0005] Obtain the electronic credential data to be processed and the first key, and encrypt the electronic credential data to be processed using the first key to obtain the first encrypted data;

[0006] The first encrypted data is stored in a distributed peer-to-peer network, and the hash path returned by the distributed peer-to-peer network is received.

[0007] Store the hash path and the first key in the blockchain network;

[0008] Receive a data request instruction initiated by a data requester, and verify the identity of the data requester. When the data requester passes the identity verification, output the data access permissions of the data requester.

[0009] Based on the data access permissions, a target hash path and target key matching the data requester are determined in the blockchain network;

[0010] The target hash path is used to find the matching encrypted electronic credential data in the distributed peer-to-peer network, and the target key is used to decrypt the encrypted electronic credential data to obtain the original electronic credential data.

[0011] Furthermore, storing the hash path and the first key in the blockchain network specifically includes:

[0012] Obtain the second key, and encrypt the hash path and the first key using the second key to obtain the second encrypted data;

[0013] The second encrypted data is stored in the blockchain network.

[0014] Furthermore, storing the second encrypted data in the blockchain network specifically includes:

[0015] Invoke the smart contract of the blockchain network;

[0016] The second encrypted data is verified through a smart contract on the blockchain network;

[0017] Once the second encrypted data passes data verification, it is written into the blockchain network, and data consensus is achieved.

[0018] Furthermore, the step of receiving a data request instruction initiated by a data requester and verifying the identity of the data requester, and outputting the data access permissions of the data requester when the data requester passes the identity verification, specifically includes:

[0019] Receive a data request instruction initiated by a data requester, and parse the data request instruction to obtain the identity data of the data requester;

[0020] The identity of the data requester is verified using the identity data to obtain the identity verification result;

[0021] The data access permissions of the data requester are determined based on the identity verification results.

[0022] Output the data access permissions of the data requester.

[0023] Furthermore, the identity of the data requester is verified using the identity data to obtain the identity verification result, specifically including:

[0024] The identity data is compared with the identity registration data stored in the blockchain network to obtain the identity data comparison result;

[0025] The identity of the data requester is verified based on the identity data comparison results, and the identity verification result is obtained.

[0026] Furthermore, the step of searching for matching encrypted electronic credentials in the distributed peer-to-peer network through the target hash path, and decrypting the encrypted electronic credentials using the target key to obtain the original electronic credentials data, specifically includes:

[0027] In the distributed peer-to-peer network, path matching is performed on the target hash path to obtain the path matching result;

[0028] The storage address of the encrypted electronic credential data is determined based on the path matching result;

[0029] The encrypted data of the electronic credentials is read in the distributed peer-to-peer network according to the storage address;

[0030] The encrypted data of the electronic credential is decrypted using the target key to obtain the original electronic credential data.

[0031] Furthermore, after storing the first encrypted data in a distributed peer-to-peer network and receiving the hash path returned by the distributed peer-to-peer network, the method further includes:

[0032] Receive multi-party data collaborative operation instructions, and determine all participants involved in the multi-party data collaborative operation and the data storage path of each participant in the distributed peer-to-peer network based on the multi-party data collaborative operation instructions.

[0033] The target computation data stored by each participant is obtained according to the data storage path of each participant in the distributed peer-to-peer network.

[0034] Based on a preset multi-party computation protocol, the target computation data of each participating party is obtained through collaborative computation to obtain the multi-party data collaborative computation result.

[0035] The results of the multi-party data collaborative operation are sent to the clients of each participating party.

[0036] To address the aforementioned technical problems, this application also provides a blockchain-based electronic certificate management device, which employs the following technical solution:

[0037] A blockchain-based electronic certificate management device includes:

[0038] An initial encryption module is used to obtain the electronic credential data to be processed and a first key, and to encrypt the electronic credential data to be processed using the first key to obtain first encrypted data.

[0039] The first storage module is used to store the first encrypted data in a distributed peer-to-peer network and receive the hash path returned by the distributed peer-to-peer network.

[0040] The second storage module is used to store the hash path and the first key in the blockchain network;

[0041] The identity verification module is used to receive data request instructions initiated by the data requester and to verify the identity of the data requester. When the data requester passes the identity verification, the module outputs the data access permissions of the data requester.

[0042] The target matching module is used to determine the target hash path and target key that match the data requester in the blockchain network based on the data access permissions.

[0043] The data decryption module is used to search for matching encrypted electronic credentials in the distributed peer-to-peer network through the target hash path, and to decrypt the encrypted electronic credentials using the target key to obtain the original electronic credentials data.

[0044] To address the aforementioned technical problems, this application also provides a computer device that employs the following technical solution:

[0045] A computer device includes a memory and a processor, the memory storing computer-readable instructions, the processor executing the computer-readable instructions to implement the steps of the blockchain-based electronic credential management method as described in any of the preceding claims.

[0046] To address the aforementioned technical problems, this application also provides a computer-readable storage medium, employing the technical solution described below:

[0047] A computer-readable storage medium storing computer-readable instructions, which, when executed by a processor, implement the steps of the blockchain-based electronic credential management method as described in any one of the preceding descriptions.

[0048] Compared with the prior art, the embodiments of this application have the following main advantages:

[0049] This application discloses a blockchain-based electronic certificate management method, apparatus, device, and storage medium, relating to the field of blockchain technology. The method involves acquiring electronic certificate data to be processed and a first key; encrypting the electronic certificate data using the first key to obtain first encrypted data; storing the first encrypted data in a distributed peer-to-peer network; receiving the hash path returned by the distributed peer-to-peer network; storing the hash path and the first key in the blockchain network; receiving a data request instruction from a data requester and verifying the data requester's identity; outputting the data requester's data access permissions when the data requester passes identity verification; determining a target hash path and target key matching the data requester in the blockchain network based on the data access permissions; searching for matching encrypted electronic certificate data in the distributed peer-to-peer network using the target hash path; and decrypting the encrypted electronic certificate data using the target key to obtain the original electronic certificate data. This application manages electronic certificate data by combining a blockchain network and a distributed peer-to-peer network to achieve on-chain and off-chain collaboration, ensuring data privacy and security, and achieving secure storage of electronic certificate data. Attached Figure Description

[0050] To more clearly illustrate the solutions in this application, the accompanying drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0051] Figure 1 An exemplary system architecture diagram is shown, in which this application can be applied;

[0052] Figure 2 A flowchart illustrating an embodiment of the blockchain-based electronic credential management method according to this application is shown;

[0053] Figure 3 A schematic diagram of the structure of one embodiment of a blockchain-based electronic credential management device according to this application is shown;

[0054] Figure 4 A schematic diagram of the structure of one embodiment of a computer device according to this application is shown. Detailed Implementation

[0055] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein in the specification of the application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application; the terms "comprising" and "having," and any variations thereof, in the specification, claims, and foregoing drawings of this application, are intended to cover non-exclusive inclusion. The terms "first," "second," etc., in the specification, claims, or foregoing drawings of this application are used to distinguish different objects, not to describe a particular order.

[0056] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.

[0057] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.

[0058] like Figure 1 As shown, system architecture 100 may include terminal devices 101, 102, and 103, a network 104, and a server 105. Network 104 serves as the medium for providing communication links between terminal devices 101, 102, and 103 and server 105. Network 104 may include various connection types, such as wired or wireless communication links, or fiber optic cables, etc.

[0059] Users can use terminal devices 101, 102, and 103 to interact with server 105 via network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, and 103, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social media platform software, etc.

[0060] Terminal devices 101, 102, and 103 can be various electronic devices with displays and support web browsing, including but not limited to smartphones, tablets, e-book readers, MP3 players (Moving Picture Experts Group Audio Layer III), MP4 players (Moving Picture Experts Group Audio Layer IV), laptops, and desktop computers, etc.

[0061] Server 105 can be a server that provides various services, such as a backend server that supports the pages displayed on terminal devices 101, 102, and 103. The server can be a standalone server or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms.

[0062] It should be noted that the blockchain-based electronic certificate management method provided in this application embodiment is generally executed by a server, and correspondingly, the blockchain-based electronic certificate management device is generally set in the server.

[0063] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.

[0064] Continue to refer to Figure 2 The diagram illustrates a flowchart of an embodiment of the blockchain-based electronic credential management method according to this application. This embodiment can acquire and process relevant data based on artificial intelligence technology. Artificial intelligence (AI) refers to the theories, methods, technologies, and application systems that utilize digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results.

[0065] Foundational technologies for artificial intelligence generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interactive systems, and mechatronics. AI software technologies mainly encompass computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.

[0066] During the production and operation management of enterprises, a large amount of electronic voucher data is generated when business transactions occur in their accounting systems, business systems, or with external units. Since the capacity of the blockchain network is limited, if a large amount of electronic voucher data is stored on the blockchain, it may lead to network congestion and delays, thereby affecting the speed and efficiency of transactions. Therefore, it is difficult to store electronic voucher data in its original form on the blockchain. Furthermore, storing electronic voucher data on the blockchain also presents privacy and security issues.

[0067] To address the aforementioned technical issues, this application discloses a blockchain-based electronic voucher management method, apparatus, device, and storage medium, relating to the field of blockchain technology. By combining a blockchain network and a distributed peer-to-peer network to achieve on-chain and off-chain joint management of electronic voucher data, including operations such as uploading, storage, and sharing, it can ensure data privacy and security and achieve secure storage of electronic voucher data.

[0068] The aforementioned blockchain-based electronic certificate management method includes the following steps:

[0069] S201, Obtain the electronic credential data to be processed and the first key, and encrypt the electronic credential data to be processed using the first key to obtain the first encrypted data.

[0070] Electronic credentials refer to electronically generated certificates of identity, rights, and assets, which may include digital ID cards, electronic certificates, and electronic tickets. They are characterized by ease of transmission, storage, verification, and exchange. The primary key can be generated using a symmetric encryption algorithm, such as AES. Symmetric keys ensure the security of data during transmission and storage, while also facilitating subsequent decryption.

[0071] In this embodiment, when the server receives a data upload request, it obtains the electronic credential data to be processed uploaded by the data provider, and obtains the first key corresponding to the electronic credential data to be processed. The server then encrypts the electronic credential data to be processed using the first key to obtain the first encrypted data.

[0072] It should be noted that when data providers upload the electronic credential data to be processed, they can also upload a data access permission file at the same time. The data access permission file specifies the whitelist of participants who can view the electronic credential data, as well as the range of data that each participant can view.

[0073] In this embodiment, the blockchain-based electronic credential management method operates on electronic devices (e.g., Figure 1 The server shown can receive various requests or instructions via wired or wireless connections. It should be noted that the aforementioned wireless connection methods may include, but are not limited to, 3G / 4G connections, WiFi connections, Bluetooth connections, WiMAX connections, Zigbee connections, UWB (ultra-wideband) connections, and other currently known or future wireless connection methods.

[0074] S202, store the first encrypted data in a distributed peer-to-peer network and receive the hash path returned by the distributed peer-to-peer network.

[0075] IPFS is a distributed peer-to-peer network that enables efficient, secure, and reliable data storage and transmission. We can store electronic credentials on the IPFS network to ensure data reliability and accessibility. IPFS is a content-addressed distributed file system that enables efficient file storage and retrieval. Electronic credential data, after being symmetrically encrypted, is distributed and stored in IPFS, returning a storage hash path used for indexing the original electronic credential data.

[0076] In this embodiment, after the server obtains the first encrypted data corresponding to the electronic credential data to be processed, it stores the first encrypted data in the IPFS network and receives the hash path returned by the IPFS network.

[0077] In the above embodiments, the first encrypted data corresponding to the electronic credential data to be processed is then stored in a distributed peer-to-peer network. Compared with the blockchain network, the distributed peer-to-peer network has greater capacity and bandwidth, which can solve the problem that storing electronic credential data on the blockchain may lead to network congestion and delays, thereby affecting the speed and efficiency of transactions.

[0078] S203 stores the hash path and the first key into the blockchain network.

[0079] Blockchain technology is a decentralized distributed ledger technology that can achieve the characteristics of information security, immutability, decentralization and traceability, making it very suitable for the management and cross-domain sharing of electronic vouchers.

[0080] In this embodiment, the server stores the hash path generated by IPFS and the first key used to encrypt the electronic credential data to be processed into the blockchain network.

[0081] In the above embodiments, this application stores the electronic credential data to be processed through the IPFS network, stores the hash path generated by IPFS and the first key used to encrypt the electronic credential data to be processed through the blockchain network, and manages the electronic credential data in a combined on-chain and off-chain manner by combining the blockchain network and the distributed peer-to-peer network, which can ensure data privacy and security and achieve secure storage of electronic credential data.

[0082] Furthermore, the hash path and the first key are stored in the blockchain network, specifically including:

[0083] Obtain the second key, and use the second key to encrypt the hash path and the first key to obtain the second encrypted data;

[0084] The second encrypted data is stored in the blockchain network.

[0085] In this embodiment, to further ensure data security, a dual encryption scheme can be adopted to implement data storage. A second key is used to encrypt the hash path and the first key, resulting in second encrypted data, which is then stored in the blockchain network.

[0086] The second key can also be generated using symmetric encryption algorithms, such as AES and RSA.

[0087] Furthermore, storing the second encrypted data in the blockchain network specifically includes:

[0088] Invoking smart contracts on the blockchain network;

[0089] The second encrypted data is verified through smart contracts on the blockchain network;

[0090] Once the second encrypted data passes data verification, it is written into the blockchain network, and data consensus is achieved.

[0091] A smart contract is an automatically executing computer program that can execute code under specific conditions and interact with other smart contracts and participants on a blockchain network. Smart contracts are one of the core components of blockchain technology, enabling operations such as the issuance, storage, verification, and exchange of electronic credentials, as well as functions like user registration, login, querying, and operations. When constructing smart contracts, factors such as data privacy protection, cross-domain sharing, and user experience must be fully considered to ensure the security and stability of the system.

[0092] In this embodiment, the server generates a smart contract that calls the blockchain network, verifies the second encrypted data through the smart contract of the blockchain network, and writes the second encrypted data into the blockchain network after the data verification is passed, thus completing the data consensus.

[0093] When storing data on the blockchain, smart contracts can ensure data consistency and security. Smart contracts can verify data before it is written to the blockchain and determine whether the data is valid and legal according to predefined rules. If the data is invalid or illegal, the smart contract will refuse to write it to the blockchain, thereby ensuring that the data stored on the blockchain is accurate and reliable.

[0094] Furthermore, smart contracts can monitor and process data after it has been written to the blockchain. Smart contracts can automatically execute specific operations based on predefined conditions, such as performing an operation at a specific time or transferring data to other participants under specific conditions. These functions make data stored on the blockchain more flexible and intelligent, thereby meeting more business needs.

[0095] Specifically, the AES algorithm can be used to encrypt the hash path and key, and then the encrypted data can be used as the payload of a transaction and stored by calling a smart contract in the blockchain network.

[0096] In a smart contract, a data structure can be defined to store the encrypted hash path and key, as well as the corresponding account information. Methods can then be defined within the smart contract to access and update this data structure.

[0097] When the data needs to be accessed, the encrypted hash path and key can be obtained by calling the corresponding method in the smart contract. Then, the symmetric key for decrypting the electronic credential data can be obtained by using the decryption key, and the corresponding electronic credential data can be obtained from IPFS using the hash path.

[0098] It's important to note that authentication is required during storage and access to ensure that only authorized users can access the data. This can be achieved through access control within smart contracts. Furthermore, to protect data privacy, it's advisable to incorporate data privacy protection mechanisms into smart contracts, such as zero-knowledge proofs.

[0099] S204: Receive the data request instruction initiated by the data requester and verify the identity of the data requester. When the data requester passes the identity verification, output the data access permissions of the data requester.

[0100] In this embodiment, the server receives a data request instruction from a data requester and verifies the data requester's identity. When the data requester passes the identity verification, the server outputs the data access permissions for the data requester. Identity verification ensures the privacy and security of electronic credential data.

[0101] Furthermore, it receives data request instructions from data requesters and verifies their identities. When a data requester passes the identity verification, it outputs the data access permissions for that data requester, specifically including:

[0102] Receive data request instructions from data requesters and parse the data request instructions to obtain the identity data of the data requesters;

[0103] The identity of the data requester is verified using identity data, and the identity verification result is obtained.

[0104] Determine the data access permissions of the data requester based on the identity verification results;

[0105] Output the data access permissions of the data requester.

[0106] In this embodiment, after the server receives a data request instruction from a data requester, it parses the instruction to obtain the data requester's identity data. The server then verifies the data requester's identity using this data, obtains the verification result, determines the data access permissions based on the result, and outputs the data access permissions. Only data requesters who pass the identity verification are granted permission to view electronic credential data.

[0107] Furthermore, the identity of the data requester is verified using identity data to obtain the identity verification result, which specifically includes:

[0108] The identity data is compared with the identity registration data stored in the blockchain network to obtain the identity data comparison result;

[0109] The identity of the data requester is verified based on the identity data comparison results, and the identity verification result is obtained.

[0110] In this embodiment, the server compares the identity data with the identity registration data stored in the blockchain network to obtain the identity data comparison result, and verifies the identity of the data requester based on the identity data comparison result to obtain the identity verification result.

[0111] During the identity verification process, the data requester sends their identity information, such as an ID card number or digital identity, to the blockchain network for verification. The blockchain network checks if this identity information exists in the identity registration data and further determines if it is listed in the data access permission file, such as a record in an identity authentication contract. If the identity information query is successful, the blockchain network returns an encrypted access policy and permissions anchored to the identity. This access policy and permissions are specific to the current identity information to ensure the legitimacy and security of data access. Through this identity verification process, it is ensured that only legitimate users can obtain the corresponding electronic credential data, thereby protecting data privacy and security.

[0112] S205, determine the target hash path and target key matching the data requester in the blockchain network based on data access permissions.

[0113] In this embodiment, after the data request method passes identity verification, the server determines the target hash path and target key matching the data requester in the blockchain network according to data access permissions. This allows the server to search for the corresponding encrypted data in the IPFS network based on the target hash path and to decrypt the encrypted data using the target key to obtain the original data.

[0114] S206: Search for matching encrypted electronic credentials in a distributed peer-to-peer network using the target hash path, and decrypt the encrypted electronic credentials using the target key to obtain the original electronic credentials data.

[0115] In this embodiment, the server searches for matching encrypted electronic credential data in IPFS using the target hash path, and decrypts the encrypted electronic credential data using the target key to obtain the original electronic credential data. By combining the blockchain network and the distributed peer-to-peer network to achieve on-chain and off-chain joint management of electronic credential data, and by combining identity verification to determine the identity of the data requester, the privacy and security of electronic credential data can be guaranteed, and secure storage of electronic credential data can be achieved.

[0116] Furthermore, the process involves searching for matching encrypted electronic credentials in a distributed peer-to-peer network using the target hash path, and then decrypting the encrypted electronic credentials using the target key to obtain the original electronic credentials data. Specifically, this includes:

[0117] In a distributed peer-to-peer network, path matching is performed on the target hash path to obtain the path matching result;

[0118] The storage address of the encrypted electronic credential data is determined based on the path matching results;

[0119] Read encrypted data of electronic credentials in a distributed peer-to-peer network based on the storage address;

[0120] The encrypted data of the electronic credential is decrypted using the target key to obtain the original electronic credential data.

[0121] In this embodiment, the server performs path matching on the target hash path in a distributed peer-to-peer network to obtain the path matching result. Based on the path matching result, it determines the storage address of the encrypted electronic credential data. Based on the storage address, it reads the encrypted electronic credential data in the distributed peer-to-peer network and decrypts the encrypted electronic credential data using the target key to obtain the original electronic credential data.

[0122] Furthermore, after storing the first encrypted data in a distributed peer-to-peer network and receiving the hash path returned by the distributed peer-to-peer network, the process also includes:

[0123] Receive instructions for multi-party data collaborative computation, and determine all participants involved in the multi-party data collaborative computation, as well as the data storage path of each participant in the distributed peer-to-peer network, based on the instructions.

[0124] The target computational data stored by each participant is obtained based on the data storage path of each participant in the distributed peer-to-peer network.

[0125] Based on a preset multi-party computation protocol, the target computation data of each participating party is obtained through collaborative computation to obtain the multi-party data collaborative computation result.

[0126] The results of collaborative data processing from multiple parties are sent to the clients of each participating party.

[0127] In this embodiment, when there is a need for multi-party data collaborative computation, the server receives a multi-party data collaborative computation instruction, determines all participants involved in the multi-party data collaborative computation based on the instruction, as well as the data storage path of each participant in the distributed peer-to-peer network, obtains the target computation data stored by each participant according to the data storage path of each participant in the distributed peer-to-peer network, performs collaborative computation on the obtained target computation data of each participant based on a preset multi-party computation protocol, obtains the multi-party data collaborative computation result, and sends the multi-party data collaborative computation result to the client of each participant.

[0128] To ensure the security of multi-party data operations, each participant can be identified through a blockchain network before obtaining their data storage path in the distributed peer-to-peer network. Once the participant's identity is verified, the IPFS data storage path is returned through the blockchain network, and then the target operation data stored by each participant is obtained from IPFS, further improving data security.

[0129] Specifically, Secure Multiparty Computing (SMC) can be used for multiparty computation. Under this protocol, participating parties can perform specific calculations and analyses without compromising data privacy. For example, if it is necessary to calculate the average of multiple electronic credentials, the participating parties can perform the calculation through the multiparty computation protocol without directly sharing the electronic credential data.

[0130] Alternatively, homomorphic encryption can be used for multi-party computation. Homomorphic encryption allows multiple participants to perform computations on ciphertext without needing to decrypt it. This avoids exposing data to other participants while achieving the goals of computation and analysis.

[0131] In one specific embodiment of this application, assume there are two companies, A and B, that need to collaborate on a financial audit. However, because the data involved comes from different databases, they cannot directly share the data. Therefore, they decide to use the Secure Multi-Party Computation Protocol (SMC) for multi-party computation and analysis. The specific steps are as follows:

[0132] First, both companies A and B encrypt their data and upload the encrypted data to the Secure Multi-Party Computation (SMC) platform.

[0133] Then, the encrypted data is processed on the SMC platform;

[0134] Finally, the SMC platform distributes the encrypted data processing results to companies A and B that participated in the computation.

[0135] Through the above scheme, all parties can perform calculations, such as calculating the average of two datasets, using the SMC protocol without exposing their data. The SMC platform returns the calculation results to companies A and B, who then conduct appropriate financial audits based on the results. By using the Secure Multi-Party Computation (SMC) protocol, companies A and B do not need to disclose their sensitive data; they only need to upload encrypted data to the platform for calculation, thus ensuring data privacy and security.

[0136] In the above embodiments, this application discloses a blockchain-based electronic certificate management method, relating to the field of blockchain technology. The method involves acquiring electronic certificate data to be processed and a first key; encrypting the electronic certificate data using the first key to obtain first encrypted data; storing the first encrypted data in a distributed peer-to-peer network; receiving the hash path returned by the distributed peer-to-peer network; storing the hash path and the first key in the blockchain network; receiving a data request instruction from a data requester and verifying the data requester's identity; outputting the data requester's data access permissions when the data requester passes identity verification; determining a target hash path and target key matching the data requester in the blockchain network based on the data access permissions; searching for matching encrypted electronic certificate data in the distributed peer-to-peer network using the target hash path; and decrypting the encrypted electronic certificate data using the target key to obtain the original electronic certificate data. This application manages electronic certificate data by combining a blockchain network and a distributed peer-to-peer network to achieve on-chain and off-chain joint management, ensuring data privacy and security, and achieving secure storage of electronic certificate data.

[0137] The blockchain referred to in this application is a novel application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. Essentially, a blockchain is a decentralized database, a chain of data blocks linked together using cryptographic methods. Each data block contains information about a batch of network transactions, used to verify the validity of the information (anti-counterfeiting) and generate the next block. A blockchain can include an underlying blockchain platform, a platform product service layer, and an application service layer.

[0138] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by instructing related hardware through computer-readable instructions. These computer-readable instructions can be stored in a computer-readable storage medium. When executed, the computer-readable instructions can include the processes of the embodiments of the above methods. The aforementioned storage medium can be a non-volatile storage medium such as a magnetic disk, optical disk, or read-only memory (ROM), or random access memory (RAM).

[0139] It should be understood that although the steps in the flowcharts of the accompanying figures are shown sequentially as indicated by the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the accompanying figures may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the sub-steps or stages of other steps.

[0140] Further reference Figure 3 As a response to the above Figure 2 The implementation of the method shown in this application provides an embodiment of a blockchain-based electronic certificate management device, which is similar to... Figure 2 Corresponding to the method embodiments shown, this device can be specifically applied to various electronic devices.

[0141] like Figure 3 As shown, the blockchain-based electronic certificate management device 300 described in this embodiment includes:

[0142] The initial encryption module 301 is used to obtain the electronic credential data to be processed and the first key, and to encrypt the electronic credential data to be processed using the first key to obtain the first encrypted data.

[0143] The first storage module 302 is used to store the first encrypted data in a distributed peer-to-peer network and receive the hash path returned by the distributed peer-to-peer network.

[0144] The second storage module 303 is used to store the hash path and the first key into the blockchain network;

[0145] The identity verification module 304 is used to receive the data request instruction initiated by the data requester and verify the identity of the data requester. When the data requester passes the identity verification, the module outputs the data access permissions of the data requester.

[0146] The target matching module 305 is used to determine the target hash path and target key of the data requester in the blockchain network according to the data access permissions.

[0147] The data decryption module 306 is used to search for matching encrypted electronic credentials in a distributed peer-to-peer network through the target hash path, and to decrypt the encrypted electronic credentials using the target key to obtain the original electronic credentials data.

[0148] Furthermore, the second storage module 303 specifically includes:

[0149] A dual encryption unit is used to obtain a second key and encrypt the hash path and the first key using the second key to obtain the second encrypted data.

[0150] A data storage unit is used to store second encrypted data into a blockchain network.

[0151] Furthermore, the data storage unit specifically includes:

[0152] The contract invocation subunit is used to invoke smart contracts on the blockchain network;

[0153] The data verification subunit is used to verify the second encrypted data through smart contracts on the blockchain network;

[0154] The data consensus subunit is used to write the second encrypted data into the blockchain network and complete the data consensus after the second encrypted data passes the data verification.

[0155] Furthermore, the identity verification module 304 specifically includes:

[0156] The identity data acquisition unit is used to receive data request instructions initiated by the data requester and parse the data request instructions to obtain the identity data of the data requester.

[0157] The identity verification unit is used to verify the identity of the data requester using identity data and obtain the identity verification result.

[0158] The permission confirmation unit is used to determine the data access permissions of the data requester based on the identity verification results.

[0159] The permission output unit is used to output the data access permissions of the data requester.

[0160] Furthermore, the identity verification unit specifically includes:

[0161] The data comparison subunit is used to compare identity data with identity registration data stored in the blockchain network to obtain the identity data comparison result;

[0162] The identity verification subunit is used to verify the identity of the data requester based on the identity data comparison results and obtain the identity verification result.

[0163] Furthermore, the data decryption module 306 specifically includes:

[0164] The path matching unit is used to perform path matching on the target hash path in a distributed peer-to-peer network and obtain the path matching result.

[0165] The address confirmation unit is used to determine the storage address of the encrypted data of the electronic credential based on the path matching result.

[0166] The data reading unit is used to read encrypted data of electronic credentials in a distributed peer-to-peer network based on the storage address.

[0167] The data decryption unit is used to decrypt the encrypted data of the electronic credential using the target key to obtain the original electronic credential data.

[0168] Furthermore, the blockchain-based electronic credential management device 300 also includes:

[0169] The multi-party computation response module is used to receive multi-party data collaborative computation instructions and determine all participants involved in the multi-party data collaborative computation, as well as the data storage path of each participant in the distributed peer-to-peer network, based on the multi-party data collaborative computation instructions.

[0170] The computation data retrieval module is used to retrieve the target computation data stored by each participant based on the data storage path of each participant in the distributed peer-to-peer network.

[0171] The multi-party collaborative computing module is used to perform collaborative computing on the target computing data of each participating party based on a preset multi-party computing protocol, and obtain the multi-party data collaborative computing result.

[0172] The calculation result output module is used to send the results of collaborative data calculations from multiple parties to the clients of each participating party.

[0173] In the above embodiments, this application discloses a blockchain-based electronic certificate management device, relating to the field of blockchain technology. The device acquires electronic certificate data to be processed and a first key, encrypts the electronic certificate data using the first key to obtain first encrypted data, stores the first encrypted data in a distributed peer-to-peer network, receives the hash path returned by the distributed peer-to-peer network, stores the hash path and the first key in the blockchain network, receives a data request instruction from a data requester, verifies the identity of the data requester, outputs the data access permissions of the data requester when the identity verification is successful, determines a target hash path and target key matching the data requester in the blockchain network based on the data access permissions, searches for matching encrypted electronic certificate data in the distributed peer-to-peer network using the target hash path, and decrypts the encrypted electronic certificate data using the target key to obtain the original electronic certificate data. This application manages electronic certificate data by combining a blockchain network and a distributed peer-to-peer network to achieve on-chain and off-chain joint management, ensuring data privacy and security, and achieving secure storage of electronic certificate data.

[0174] To address the aforementioned technical problems, embodiments of this application also provide a computer device. Please refer to [link / reference needed]. Figure 4 , Figure 4 This is a basic structural block diagram of the computer device in this embodiment.

[0175] The computer device 4 includes a memory 41, a processor 42, and a network interface 43 that are interconnected via a system bus. It should be noted that only the computer device 4 with components 41-43 is shown in the figure; however, it should be understood that it is not required to implement all the shown components, and more or fewer components can be implemented alternatively. Those skilled in the art will understand that the computer device described here is a device capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes, but is not limited to, microprocessors, application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), digital signal processors (DSPs), embedded devices, etc.

[0176] The computer device can be a desktop computer, laptop, handheld computer, or cloud server, etc. The computer device can interact with the user via a keyboard, mouse, remote control, touchpad, or voice control.

[0177] The memory 41 includes at least one type of readable storage medium, including flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, disk, optical disk, etc. In some embodiments, the memory 41 may be an internal storage unit of the computer device 4, such as the hard disk or memory of the computer device 4. In other embodiments, the memory 41 may also be an external storage device of the computer device 4, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the computer device 4. Of course, the memory 41 may also include both the internal storage unit and its external storage device of the computer device 4. In this embodiment, the memory 41 is typically used to store the operating system and various application software installed on the computer device 4, such as computer-readable instructions for a blockchain-based electronic credential management method. In addition, the memory 41 can also be used to temporarily store various types of data that have been output or will be output.

[0178] In some embodiments, the processor 42 may be a central processing unit (CPU), controller, microcontroller, microprocessor, or other data processing chip. The processor 42 is typically used to control the overall operation of the computer device 4. In this embodiment, the processor 42 is used to execute computer-readable instructions stored in the memory 41 or to process data, for example, to execute computer-readable instructions for the blockchain-based electronic credential management method.

[0179] The network interface 43 may include a wireless network interface or a wired network interface, which is typically used to establish communication connections between the computer device 4 and other electronic devices.

[0180] In the above embodiments, this application discloses a computer device relating to the field of blockchain technology. It acquires electronic credential data to be processed and a first key, encrypts the electronic credential data using the first key to obtain first encrypted data, stores the first encrypted data in a distributed peer-to-peer network, receives the hash path returned by the distributed peer-to-peer network, stores the hash path and the first key in a blockchain network, receives a data request instruction from a data requester, verifies the identity of the data requester, outputs the data access permissions of the data requester when the identity verification is successful, determines a target hash path and target key matching the data requester in the blockchain network based on the data access permissions, searches for matching encrypted electronic credential data in the distributed peer-to-peer network using the target hash path, and decrypts the encrypted electronic credential data using the target key to obtain the original electronic credential data. This application manages electronic credential data by combining a blockchain network and a distributed peer-to-peer network to achieve on-chain and off-chain joint management, ensuring data privacy and security, and achieving secure storage of electronic credential data.

[0181] This application also provides another implementation, namely, providing a computer-readable storage medium storing computer-readable instructions that can be executed by at least one processor to cause the at least one processor to perform the steps of the blockchain-based electronic credential management method described above.

[0182] In the above embodiments, this application discloses a storage medium relating to the field of blockchain technology. It acquires electronic credential data to be processed and a first key, encrypts the electronic credential data using the first key to obtain first encrypted data, stores the first encrypted data in a distributed peer-to-peer network, receives the hash path returned by the distributed peer-to-peer network, stores the hash path and the first key in a blockchain network, receives a data request instruction from a data requester, verifies the identity of the data requester, outputs the data access permissions of the data requester when the identity verification is successful, determines a target hash path and target key matching the data requester in the blockchain network based on the data access permissions, searches for matching encrypted electronic credential data in the distributed peer-to-peer network using the target hash path, and decrypts the encrypted electronic credential data using the target key to obtain the original electronic credential data. This application manages electronic credential data by combining a blockchain network and a distributed peer-to-peer network to achieve on-chain and off-chain joint management, ensuring data privacy and security, and achieving secure storage of electronic credential data.

[0183] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.

[0184] This application can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This application can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.

[0185] Obviously, the embodiments described above are only some embodiments of this application, not all embodiments. The accompanying drawings show preferred embodiments of this application, but do not limit the patent scope of this application. This application can be implemented in many different forms; rather, the purpose of providing these embodiments is to provide a more thorough and comprehensive understanding of the disclosure of this application. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing specific embodiments, or make equivalent substitutions for some of the technical features. Any equivalent structures made using the content of this application's specification and drawings, directly or indirectly applied to other related technical fields, are similarly within the scope of patent protection of this application.

Claims

1. A blockchain-based electronic voucher management method, characterized in that, include: Obtain the electronic credential data to be processed and the first key, and encrypt the electronic credential data to be processed using the first key to obtain the first encrypted data; The first encrypted data is stored in a distributed peer-to-peer network, and a hash path returned by the distributed peer-to-peer network is received, wherein the hash path is used to index the first encrypted data in the peer-to-peer network. Store the hash path and the first key in the blockchain network; Receive a data request instruction initiated by a data requester, and verify the identity of the data requester. When the data requester passes the identity verification, output the data access permissions of the data requester. Based on the data access permissions, a target hash path and target key matching the data requester are determined in the blockchain network; The target hash path is used to find the matching encrypted electronic credential data in the distributed peer-to-peer network, and the target key is used to decrypt the encrypted electronic credential data to obtain the original electronic credential data. After storing the first encrypted data in a distributed peer-to-peer network and receiving the hash path returned by the distributed peer-to-peer network, the method further includes: Receive multi-party data collaborative operation instructions, and determine all participants involved in the multi-party data collaborative operation and the data storage path of each participant in the distributed peer-to-peer network based on the multi-party data collaborative operation instructions. The target computation data stored by each participant is obtained according to the data storage path of each participant in the distributed peer-to-peer network. Based on a preset multi-party computation protocol, the target computation data of each participating party is obtained through collaborative computation to obtain the multi-party data collaborative computation result. The results of the multi-party data collaborative operation are sent to the clients of each participating party; Specifically, before obtaining the data storage path of each participant in the distributed peer-to-peer network, the participants are authenticated through the blockchain network. After the participants are authenticated, the data storage path of the distributed peer-to-peer network is returned through the blockchain network, and then the target computation data stored by each participant is obtained from the distributed peer-to-peer network.

2. The blockchain-based electronic certificate management method as described in claim 1, characterized in that, The step of storing the hash path and the first key in the blockchain network specifically includes: Obtain the second key, and encrypt the hash path and the first key using the second key to obtain the second encrypted data; The second encrypted data is stored in the blockchain network.

3. The blockchain-based electronic certificate management method as described in claim 2, characterized in that, The step of storing the second encrypted data in the blockchain network specifically includes: Invoke the smart contract of the blockchain network; The second encrypted data is verified through a smart contract on the blockchain network; Once the second encrypted data passes data verification, it is written into the blockchain network, and data consensus is achieved.

4. The blockchain-based electronic certificate management method as described in claim 1, characterized in that, The process of receiving a data request instruction initiated by a data requester and verifying the identity of the data requester, and outputting the data access permissions of the data requester when the data requester passes the identity verification, specifically includes: Receive a data request instruction initiated by a data requester, and parse the data request instruction to obtain the identity data of the data requester; The identity of the data requester is verified using the identity data to obtain the identity verification result. The data access permissions of the data requester are determined based on the identity verification results. Output the data access permissions of the data requester.

5. The blockchain-based electronic certificate management method as described in claim 4, characterized in that, The identity of the data requester is verified using the identity data, and the verification result is obtained, specifically including: The identity data is compared with the identity registration data stored in the blockchain network to obtain the identity data comparison result; The identity of the data requester is verified based on the identity data comparison results, and the identity verification result is obtained.

6. The blockchain-based electronic certificate management method as described in any one of claims 1 to 5, characterized in that, The process of searching for matching encrypted electronic credentials in the distributed peer-to-peer network using the target hash path, and decrypting the encrypted electronic credentials using the target key to obtain the original electronic credentials data, specifically includes: In the distributed peer-to-peer network, path matching is performed on the target hash path to obtain the path matching result; The storage address of the encrypted electronic credential data is determined based on the path matching result; The encrypted data of the electronic credentials is read in the distributed peer-to-peer network according to the storage address; The encrypted data of the electronic credential is decrypted using the target key to obtain the original electronic credential data.

7. A blockchain-based electronic voucher management device, characterized in that, The electronic certificate management device implements the steps of the blockchain-based electronic certificate management method as described in any one of claims 1 to 6, wherein the electronic certificate management device comprises: An initial encryption module is used to obtain the electronic credential data to be processed and a first key, and to encrypt the electronic credential data to be processed using the first key to obtain first encrypted data. A first storage module is configured to store the first encrypted data in a distributed peer-to-peer network and receive a hash path returned by the distributed peer-to-peer network, wherein the hash path is used to index the first encrypted data in the peer-to-peer network. The second storage module is used to store the hash path and the first key in the blockchain network; The identity verification module is used to receive data request instructions initiated by the data requester and to verify the identity of the data requester. When the data requester passes the identity verification, the module outputs the data access permissions of the data requester. The target matching module is used to determine the target hash path and target key that match the data requester in the blockchain network based on the data access permissions. The data decryption module is used to search for matching encrypted electronic credentials in the distributed peer-to-peer network through the target hash path, and to decrypt the encrypted electronic credentials using the target key to obtain the original electronic credentials data.

8. A computer device, characterized in that, The method includes a memory and a processor, wherein the memory stores computer-readable instructions, and the processor executes the computer-readable instructions to implement the steps of the blockchain-based electronic credential management method as described in any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-readable instructions, which, when executed by a processor, implement the steps of the blockchain-based electronic credential management method as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Voucher transmission method and device based on block chain, electronic equipment and storage medium

    CN114679269A

  • Resource data processing method and device based on block chain, and server

    CN115796871A