Decentralized electronic medical record sharing method and system supporting dynamic access

By combining blockchain storage and zero-knowledge proof verification with attribute encryption and revocation mechanisms, the problems of data tampering and access control in cloud storage systems are solved, enabling secure sharing and efficient access to electronic medical records.

CN117457133BActive Publication Date: 2026-11-24UNIV OF JINAN
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311361551.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-10-19
Publication Date
2026-11-24
Estimated Expiration
2043-10-19

AI Technical Summary

Technical Problem

Existing cloud storage systems suffer from semi-honesty issues when processing medical data, which may lead to data tampering or leakage, and lack effective access control management and data authenticity verification mechanisms.

Method used

Electronic medical records are stored using blockchain, data authenticity is verified through zero-knowledge proofs, and data is distributed to nodes through hash rings. Access permissions are dynamically managed using attribute encryption and revocation mechanisms, and decryption keys are tracked and updated using a key generation center.

Benefits of technology

It ensures data security and authenticity, reduces the storage pressure on the blockchain, dynamically manages access permissions, prevents data tampering and leakage, and improves the efficiency and security of data sharing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117457133B_ABST
    Figure CN117457133B_ABST
Patent Text Reader

Abstract

This invention relates to a decentralized electronic medical record sharing method and system supporting dynamic access, comprising the following steps: A data owner generates a proof based on zero-knowledge proof and sends it to the blockchain; after verifying the proof, the blockchain allows the data owner to upload medical record data; the blockchain allocates nodes for the stored data; the data owner, based on a key, creates encrypted data containing their identity identifier and the medical record data to be uploaded, and uploads the data to the corresponding node according to the obtained node address; within a set time period, the data user obtains a decryption key by proving their identity, which is used to decrypt the corresponding encrypted data to obtain the data uploaded by the data owner; the revocation list is updated based on a set revocation period, and the data user whose data has been revoked is added to the updated list, preventing them from decrypting data exceeding the revocation period.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of medical data system technology, specifically to a decentralized electronic medical record sharing method and system that supports dynamic access. Background Technology

[0002] The statements in this section are merely background information related to the present invention and do not necessarily constitute prior art.

[0003] Digitizing medical records can reduce patients' healthcare costs and facilitate access to and analysis of medical data by hospitals, research institutions, and laboratories. Electronic medical records involve patients' private data. To ensure the secure sharing of this sensitive medical data among patients, doctors, and laboratories, encryption is the most direct means of addressing privacy and security. Cloud storage can also reduce the pressure on local servers storing large amounts of medical record data. However, cloud servers, which rely on cloud storage, are semi-honest. They process data according to pre-defined protocols and attempt to learn sensitive data through any possible passive attacks. "Semi-honest" means that cloud servers, in order to save computing resources and transmission bandwidth, or due to software or hardware malfunctions, may not execute the complete search protocol or return all search results, or may even maliciously delete or tamper with files, leading to data loss or errors. Furthermore, cloud storage servers may dishonestly store data from users to reduce resource costs. Summary of the Invention

[0004] To address the technical problems mentioned above, this invention provides a decentralized electronic medical record sharing method and system that supports dynamic access. It uses blockchain to store electronic medical records to avoid the semi-honesty problem of cloud services, ensures the authenticity of uploaded data and alleviates the storage pressure on the blockchain by designing a verification process, and also designs a revocation mechanism to dynamically change the access permissions of data users.

[0005] To achieve the above objectives, the present invention adopts the following technical solution:

[0006] The first aspect of the present invention provides a decentralized electronic medical record sharing method supporting dynamic access, comprising the following steps:

[0007] The data owner generates a proof based on zero-knowledge proof and sends it to the blockchain. After verifying the proof, the blockchain allows the data owner to upload the medical record data.

[0008] Blockchain allocates nodes for stored data. Data owners use keys to create encrypted data containing their identity identifier and the medical records to be uploaded, and then upload the data to the corresponding node based on the obtained node address.

[0009] Data users can obtain a decryption key by verifying their identity within a set time period, which is used to decrypt the corresponding ciphertext and obtain the data uploaded by the data owner;

[0010] The revocation list is updated based on the set revocation period. Users whose data has been revoked are added to the updated list, and their access to the data is revoked, preventing them from decrypting data that has exceeded the revocation period.

[0011] Furthermore, after verifying the proof, the blockchain allows the data owner to upload medical records. Specifically, after receiving the proof, the blockchain verifies the validity of the submitted proof according to a set algorithm. If the algorithm returns a value of 1, the data owner is allowed to upload the data; otherwise, the upload is not allowed.

[0012] Furthermore, the blockchain allocates nodes for stored data, specifically: nodes are allocated based on hash rings, and data owners upload ciphertext to the corresponding nodes for storage according to the allocation results.

[0013] Furthermore, the data owner uses a key to encrypt the identity identifier and the medical record data to be uploaded into ciphertext, which is then used as the data to be uploaded. Specifically:

[0014] The key is obtained based on the first encryption algorithm, and the medical record data and identity information to be uploaded are used as input to obtain symmetric encrypted ciphertext.

[0015] The symmetric encryption ciphertext and the symmetric encryption key are used to obtain the attribute-encrypted ciphertext through a second encryption algorithm;

[0016] The attribute-encrypted ciphertext and the symmetric-encrypted ciphertext are used together as ciphertext c, and ciphertext c is the data to be uploaded.

[0017] Furthermore, blocks in the blockchain store datasets and data-to-node mappings, and uploaded data is stored on the nodes;

[0018] Alternatively, a payoff function can be used to reduce data storage on nodes with more than a certain amount of stored data, while increasing data storage on nodes with less than a certain amount of stored data, thus achieving a balanced state of data storage across all nodes.

[0019] Furthermore, within a set time period, data users obtain a decryption key by verifying their identity, which is used to decrypt the corresponding ciphertext and obtain the data uploaded by the data owner; specifically:

[0020] Data users obtain key update materials through public channels, and use public parameters, the data user's corresponding private key, and key update materials as inputs to the decryption algorithm;

[0021] If the data user is not added to the revocation list within the corresponding revocation period, the decryption algorithm outputs a decryption key within the revocation period;

[0022] If the data user has been added to the revocation list within the corresponding revocation period, the decryption algorithm will output a decryption failure symbol.

[0023] If the decryption key is lost or enters the market, the decryption key can be decrypted to obtain the corresponding ID, and the corresponding user can be tracked based on the ID.

[0024] Furthermore, during each revocation period, the updated attribute encrypted ciphertext is obtained based on the ciphertext update algorithm, using the public parameters, attribute encrypted ciphertext, and timestamp as inputs.

[0025] A second aspect of the present invention provides a system for implementing the above-described method, comprising:

[0026] The first data terminal communicates with the blockchain network. The data owner generates a proof based on the zero-knowledge proof in the first data terminal and sends it to the blockchain network. The data is then uploaded to the corresponding node based on the obtained node address. The data owner also uses the key in the first data terminal to create encrypted data of the identity identifier and the medical record data to be uploaded.

[0027] The blockchain network is configured to: allow data owners to upload medical record data after verifying proof from the first data terminal; allocate nodes for the stored data and receive medical record data uploaded from the first data terminal;

[0028] The second data terminal communicates with the blockchain network. Data users obtain a decryption key by proving their identity within a set time period based on the second data terminal. This key is used to decrypt the corresponding ciphertext and obtain the data uploaded by the data owner.

[0029] The permission update module is configured to communicate with the blockchain network, update the revocation list based on the set revocation period, and add the data users whose data has been revoked to the updated list so that they cannot decrypt data that has exceeded the revocation period.

[0030] A third aspect of the present invention provides a computer-readable storage medium.

[0031] A computer-readable storage medium having a computer program stored thereon that, when executed by a processor, implements the steps of the decentralized electronic medical record sharing method supporting dynamic access as described above.

[0032] A fourth aspect of the present invention provides a computer device.

[0033] A computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the steps of the decentralized electronic medical record sharing method supporting dynamic access as described above.

[0034] Compared with existing technologies, one or more of the above technical solutions have the following beneficial effects:

[0035] 1. Because cloud services are semi-honest, they will execute according to the set protocol while also being curious about the data stored by users. Therefore, there may be issues where cloud service providers communicate privately with designated users to modify the uploaded data. Using blockchain to store electronic medical records can prevent these situations from happening.

[0036] 2. A revocation mechanism is introduced. Over time, some data users will lose access to the data by adding their identities to the revocation list. When they execute the decryption key algorithm, it will fail, thus canceling their access to the data. This achieves dynamic management of access permissions.

[0037] 3. When data owners upload private data, the authenticity of the data is guaranteed through a zero-knowledge proof verification process. Upload is allowed after verification, thereby reducing the pressure on blockchain storage.

[0038] 4. The data source organization needs to generate the privacy data. This solves the blockchain storage capacity problem and ensures the authenticity of the data. It also allows the data owner to pay relevant fees and deposits for storing data on the blockchain, which are returned after verification.

[0039] 5. When the decryption key enters the market, it can be decrypted to obtain the private key sent after the ID is certified by the key generation center, thus enabling the tracking of the decryption key. Attached Figure Description

[0040] The accompanying drawings, which form part of this invention, are used to provide a further understanding of the invention. The illustrative embodiments of the invention and their descriptions are used to explain the invention and do not constitute an improper limitation of the invention.

[0041] Figure 1 A schematic diagram of a cloud-based electronic medical record system provided for one or more embodiments of the present invention;

[0042] Figure 2 An extended zero-knowledge circuit diagram provided for one or more embodiments of the present invention;

[0043] Figure 3 A schematic diagram of a blockchain network architecture provided for one or more embodiments of the present invention;

[0044] Figure 4 This is a schematic diagram of a system architecture provided for one or more embodiments of the present invention. Detailed Implementation

[0045] The present invention will be further described below with reference to the accompanying drawings and embodiments.

[0046] It should be noted that the following detailed descriptions are exemplary and intended to provide further illustration of the invention. Unless otherwise specified, 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 invention pertains.

[0047] As described in the background section, electrical medical records can be stored in cloud storage (e.g., Amazon EMR, DrChrono HER), such as... Figure 1 The diagram illustrates a cloud-based electronic medical record system architecture. Because cloud servers are semi-honest, they process data according to pre-defined protocols, attempting to learn sensitive data through any possible passive attacks. Blockchain technology can effectively address the issue of passive data learning in cloud storage. Patients can encrypt and upload data they need to share to the blockchain for storage. The blockchain's data integrity guarantees that uploaded data cannot be altered, reducing the risk of untrusted cloud service providers controlling uploaded data compared to cloud storage. This solution is more efficient than using cloud storage.

[0048] For users accessing uploaded data, as they age and their permissions change, they may become ineligible to access certain private data. Attribute encryption can effectively address this issue. Using a dual-policy approach (DP-RABE) combining Ciphertext Access Policy (CP-ABE) and Key Access Policy (KP-ABE) prevents unauthorized users from decrypting ciphertext. This enables dynamic access to data.

[0049] To prevent users from uploading false data to fraudulently obtain compensation or for other purposes, they are required to use extended zero-knowledge proofs to verify the data before uploading, thus ensuring the authenticity of the data and alleviating the pressure on blockchain storage.

[0050] Users authorized to decrypt private data possess the key to decrypt the encrypted data. If the private data is extremely important or has been purchased at a high price, the decryption key may enter the market, causing serious harm to patients. To address this issue, when distributing valid decryption keys, it is necessary to authenticate the user and encapsulate their ID within the decryption key. Once a decryption key is discovered on the market, its ID can be recovered through effective means, allowing for appropriate penalties to be imposed on the individual involved.

[0051] Therefore, the following embodiments provide a decentralized electronic medical record sharing method and system supporting dynamic access, comprising four entities: a Key Generation Center (KGC), a Data Owner (DO), a Data User (DU), and a Blockchain Network. To facilitate close collaboration among patients, doctors, insurance companies, and laboratories, the Data Owner generates a proof using extended zero-knowledge proofs and sends it to the blockchain. The blockchain verifies the proof; if verification is successful, uploading is allowed; otherwise, it is not, thus reducing the storage pressure on the blockchain. The Data Owner needs to upload their data to the blockchain network for storage in an encrypted manner. The Data Owner needs to pay related fees for storing data on the blockchain, and also needs to pay an additional deposit, which is refunded after the Data User verifies the data. The Blockchain Network allocates data to nodes storing data using a hash ring. Users upload data to the corresponding node based on the corresponding node address. Data Users need to prove their identity to the Key Generation Center to obtain a decryption key, used to decrypt the corresponding ciphertext. The Key Generation Center needs to update the revocation list within a specified period and include revoked users in it, preventing them from decrypting previous and subsequent data. This method achieves forward and backward confidentiality of data, enabling secure data sharing among patients, doctors, research institutions, and laboratories, and greatly improving efficiency.

[0052] Terminology Explanation:

[0053] Blockchain technology, a distributed database technology, is a decentralized data storage and transmission system built on cryptography and consensus algorithms. Its core concept is to divide data into a series of immutable blocks and link these blocks together using encryption and timestamps to form an irreversible chain.

[0054] Attribute-based encryption (ABE) is a cryptographic technique designed to enable fine-grained access control over data.

[0055] Example 1:

[0056] A decentralized electronic health record sharing method that supports dynamic access includes the following steps:

[0057] 1. The data owner uses extended zero-knowledge proofs to generate a valid proof and sends it to the blockchain. They then encrypt their private data and identity into ciphertext.

[0058] 2. After receiving the proof uploaded by the data owner, the blockchain verifies the proof. If the result is 1, the upload is allowed; if the result is 0, the upload is rejected.

[0059] 3. The data owner encrypts the ciphertext and symmetric key using attributes to form ciphertext, which is then used as the original data. Storage space is leased through blockchain Rent transactions, and a deposit is required to ensure the data owner provides the actual data.

[0060] 4. After receiving a Rent transaction initiated by a user, the blockchain allocates data to nodes through a hash ring. The allocation results will be published by the reseller, and the user will upload the original data according to the allocation results.

[0061] 5. After receiving the raw data uploaded by the user, the node needs to continuously provide Proof of Local Storage (POR) to the blockchain network through blockchain Join transactions to prove the validity and security of the storage.

[0062] 6. The blockchain network of this scheme also incorporates a Quit transaction to allow nodes to relinquish their current data in order to maximize their benefits.

[0063] 7. The key generation center runs the key generation algorithm and sends the generated parameters and selected hash function to the data owner and the blockchain network. It also sends the private key corresponding to the data user's identity to the data user.

[0064] 8. The key generation center runs the key update algorithm to generate key update material. This update material is then publicly sent to all data users during the revocation period.

[0065] 9. When a data user obtains publicly available key update materials, if the data has not been added to the revocation list, the user will receive the decryption key for that period when executing the decryption key algorithm; otherwise, the user will receive a failure symbol.

[0066] 10. If the decryption key enters the market, the key generation center can execute the key decryption algorithm to obtain the corresponding ID, and the corresponding user can be traced based on this key.

[0067] 11. Ciphertext Update Algorithm: During each revocation period, the blockchain network updates the ciphertext by writing a smart contract, resulting in the new ciphertext.

[0068] 12. The data owner decrypts the symmetric encryption key from the ciphertext using a decryption algorithm, and then uses the key to decrypt the ciphertext to obtain the plaintext. A hash algorithm is then applied to the plaintext to verify if it is the plaintext used in the zero-knowledge proof. If they match, the deposit is returned; otherwise, it is not refunded.

[0069] 13. The key generation center executes the revocation list update algorithm to add data users who have lost their decryption privileges to the revocation list, forming a new revocation list.

[0070] Specifically:

[0071] In step 1, to alleviate the pressure on blockchain storage, extended zero-knowledge proofs are introduced. First, the algorithm Setup(1) is executed. λ The algorithm (C) = (crs, pka) takes the security parameter and circuit C as input and outputs the public reference string crs and the public key pka. The data owner, the hospital where the data is located, executes the algorithm Sign(ska, x, name) → σ to ensure the correctness of the data. This algorithm also includes a hash algorithm H(x, name) → h. Then, the data owner executes the algorithm Prove(crs, c, a, y, h, x) → π. This algorithm takes the public reference string crs, the public input c, the metadata a (identity information, etc.), the output y, the hash value h, and the private data x as input and outputs a proof π, which is then sent to the blockchain. The data user executes the symmetric encryption algorithm Enc(x, name) → C. SE The key is K. This algorithm takes a private input x and the identity information name as input, and outputs a symmetric encrypted ciphertext C. SE

[0072] In step 2, the blockchain executes the algorithm after receiving the proof:

[0073] Verify(crs,pka,π,c,a,y,h,σ)→{0,1};

[0074] This algorithm verifies the validity of submitted proofs. If the algorithm returns 1, the data owner is allowed to upload their private data; otherwise, uploading is not allowed. This ensures data integrity while reducing the pressure on blockchain storage.

[0075] In step 3, the data owner encrypts the symmetric ciphertext C. SE The symmetric encryption key K is encrypted using the algorithm Enc(pp,t,K(S,ω))→C ABE Obtain the attribute encrypted ciphertext C ABE , will C SE C ABE Together, they form the ciphertext c. To store data in a blockchain network, users first need to pay for storage through the transaction txRent = (did, drt, tts, fee), where did represents the data's identity, drt represents the root of the Merkle tree, tts represents the rental period, and fee represents the storage cost. In addition, the data owner must deposit a certain amount of security deposit.

[0076] In step 4, the hash ring in the blockchain network allocates data to nodes for storage. The allocation results are obtained and published by the dealer. The data owner uploads the ciphertext c to the corresponding node for storage based on the publicly disclosed node.

[0077] In step 5, within the node network, nodes store data and submit storage proofs through the transaction txjoin = (bid, idx, proof). Here, bid represents the hash block bid, idx represents the index, and proof is a valid storage proof. Transactions form a chain, and within the chain's span, data is stored in the nodes. In the penalty-based blockchain, blocks only store the dataset and the mapping set from data to nodes. The data itself is stored on the nodes.

[0078] In step 6, due to limited node storage space, this scheme employs a blockchain load balancing approach to ensure all nodes can store data. A reward function gradually reduces data storage for nodes with excessive data, while increasing storage for nodes with insufficient data, thus achieving a balanced state across all nodes. Furthermore, nodes are allowed to relinquish stored data through the transaction txquit = (bid, idx, pk, σ) to maximize their profit. Here, bid is the hash block bid, idx is the index, pk is the node's public key with its signature σ.

[0079] In step 7, the key generation center runs Setup(λ,N,T)→(pp,msk,rl,st), where pp is the public parameter, msk is the master key, rl is the revocation list, and st is the input state. It then sends the public parameter pp and the selected hash function h to the DO and the blockchain network. The key generation center executes the algorithm KeyGen(pp,msk,st,id,(Ψ,O))→(SKid,st). This algorithm takes the public parameter pp, state st, master key msk, identity id, subjective attribute Ψ, and objective access policy as input, and outputs the private key SKid corresponding to the id and the corresponding state st. The key generation center then sends this private key SKid to the corresponding DU.

[0080] In step 8, the key generation center executes the key update algorithm KeyUpdate(pp,rl,st,t)→Kut during the current revocation period. This algorithm takes the public parameter pp, the revocation list rl, the input state st, and the timestamp t as input and outputs a key update material Kut, which is sent to all Dus in a public form.

[0081] In step 9, the data user obtains the key update material through a public channel and executes the algorithm DKGen(pp,SKid,Kut)→dkid,t / ⊥. This algorithm takes the public parameter pp, the user's corresponding private key SKid, and the key update material Kut as input. If the data user is not added to the revocation list within the revocation period, DU executes the algorithm and outputs a decryption key dkid,t that has been revoked. Conversely, if the data user is added to the revocation list within the revocation period, the algorithm outputs a decryption failure symbol: ⊥, indicating that the user no longer has decryption rights.

[0082] In step 10, there exists a situation where a legitimate data user sells their decryption key dkid,t because the user's privacy data is of significant value. If the decryption key is found to have entered the market, the key generation center can run the algorithm DKGen(pp,dk) idt )→sk id The algorithm uses pp as the common parameter and dk as the common parameter. idt The decryption key is taken as input, and the output is the corresponding user's private key sk. id Since this private key is issued by the key generation center to authenticate the user's identity, the corresponding malicious user can be found based on this ID.

[0083] In step 11, to achieve forward confidentiality of the ciphertext during each revocation period and prevent revoked data users from accessing previous ciphertext, the ciphertext update algorithm CTUpdate(pp,C) needs to be executed on the ciphertext during each revocation period. ABE ,t′)→C′ ABE The algorithm uses the common parameter pp and the attribute to encrypt the ciphertext C. ABE Given a binary timestamp t′ as input, output an updated attribute ciphertext C′. ABE At this point, the ciphertext in the blockchain node network is c = (C SE ,C′ ABE This algorithm is implemented by writing smart contracts in a blockchain network, and the algorithm is automatically executed when the conditions of the smart contracts are met.

[0084] In step 12, the data user downloads the corresponding C′ from a node in the blockchain network. ABE And execute the decryption algorithm Dec(pp,dkid,C′) ABE →K, this algorithm uses the common parameter pp, the decryption key dkid, and the attribute-encrypted ciphertext C′. ABE As input, the algorithm can encrypt the ciphertext C′ from the attributes. ABE The symmetric key K is decrypted from the input, and the algorithm Dec(K,C) is executed. SE The algorithm uses a symmetric encryption key K to symmetrically encrypt ciphertext C. SEAs input, the output consists of the user's private data x. After receiving the data, the algorithm H`(x,name)→h` is executed. If h = h`, the data is valid, and the user's deposit is returned; otherwise, the data is invalid, and the deposit is withheld. When the data is valid, plaintext data can be used, greatly improving efficiency between patients, doctors, and laboratories.

[0085] In step 13, as time goes on, some data users will lose access to the data. At this time, the key generation center needs to run the algorithm Rev(rl,id,t)→rl during the revocation period. This algorithm takes the revocation list rl, the revoked user ID, and the timestamp t as input and outputs a new revocation list rl. This revocation list allows the key update material Kut output by the key update algorithm in step 7 to output the failure symbol ⊥ when the data user whose access has been revoked during the revocation period runs the decryption algorithm, so as to protect the security of user privacy data.

[0086] By utilizing the decentralization and data integrity of blockchain technology in this embodiment, problems such as single points of attack and data tampering caused by servers are eliminated.

[0087] Attribute-based encryption (ABE) is a cryptographic technique designed to achieve fine-grained access control over data. Unlike traditional encryption methods, ABE allows users to control access to encrypted data based on their owned attributes. This technique, combined with a tree-based revocation mechanism, enables restrictions on users accessing ciphertext and the deletion of data for users who have lost access.

[0088] Tree-based undo mechanism: This is a data structure used to record and manage operation history. It uses a tree structure to represent the dependencies and undo order of operations. In this mechanism, each operation is represented as a node in the tree, and the dependencies between operations are represented by pointers to their parent nodes. This embodiment uses this scheme to manage the undo list. If a user's administrator access is revoked, they are added to the undo list. This scheme includes a subset covering algorithm KUN(st,rl,t), which obtains the minimum set associated with users whose data has not been undone. The specific algorithm is shown in Table 1.

[0089] Table 1: Subset Covering Algorithm

[0090]

[0091] Because the above process uses blockchain for storage, and cloud services are semi-honest—executing the set protocol while also being curious about the user's stored data—there is a possibility that cloud service providers could privately communicate with designated users to modify uploaded data, thereby covering up medical malpractice. Using blockchain can prevent these situations from occurring.

[0092] A tree-based revocation mechanism is employed. As time progresses, some data users will lose access to the data. Their identities can be added to a revocation list, and when they execute the decryption key algorithm, they will receive a failure symbol ⊥, thus revoking their access to the data. This achieves dynamic management of access permissions.

[0093] The requirement that data owners request the data source institution to generate a zero-knowledge proof for the privacy data when uploading it solves both the storage capacity problem of blockchain and ensures the authenticity of the data.

[0094] A key decryption algorithm was designed. When the decryption key enters the market, it can be used to decrypt the private key sent after the key generation center authenticates the ID. This enables the tracking of the decryption key.

[0095] Example 2:

[0096] A system for implementing the above method includes:

[0097] The first data module is configured such that: the data owner generates a proof based on zero-knowledge proof and sends it to the blockchain; after verifying the proof, the blockchain allows the data owner to upload medical record data.

[0098] The blockchain module is configured as follows: the blockchain allocates nodes for stored data, and the data owner uses a key to create encrypted data of their identity and the medical records to be uploaded as the data to be uploaded, and uploads the data to the corresponding node according to the obtained node address;

[0099] The second data module is configured so that data users can obtain a decryption key by proving their identity within a set time period, which is used to decrypt the corresponding ciphertext and obtain the data uploaded by the data owner.

[0100] The permission update module is configured to update the revocation list based on the set revocation period, adding the data user whose data has been revoked to the updated list so that they cannot decrypt data that has exceeded the revocation period.

[0101] Example 3:

[0102] This embodiment provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the decentralized electronic medical record sharing method supporting dynamic access as described in Embodiment 1 above.

[0103] Example 4:

[0104] This embodiment provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the steps in the decentralized electronic medical record sharing method supporting dynamic access as described in Embodiment 1 above.

[0105] The steps or networks involved in Embodiments 2 to 4 above correspond to those in Embodiment 1. For specific implementation details, please refer to the relevant description section of Embodiment 1. The term "computer-readable storage medium" should be understood as a single medium or multiple media including one or more instruction sets; it should also be understood as including any medium capable of storing, encoding, or carrying an instruction set for execution by a processor and enabling the processor to perform any of the methods in this invention.

Claims

1. A decentralized electronic medical record sharing method supporting dynamic access, characterized in that, Includes the following steps: The data owner generates a proof based on zero-knowledge proof and sends it to the blockchain. After verifying the proof, the blockchain allows the data owner to upload the medical record data. Blockchain allocates nodes for stored data. Data owners use keys to create encrypted data containing their identity identifier and the medical records to be uploaded, and then upload the data to the corresponding node based on the obtained node address. Data users can obtain a decryption key by verifying their identity within a set time period, which is used to decrypt the corresponding ciphertext and obtain the data uploaded by the data owner; The revocation list is updated based on the set revocation period. Users whose data has been revoked are added to the updated list, and their access to the data is revoked, preventing them from decrypting data that has exceeded the revocation period. The data user obtains key update material through a public channel, and uses public parameters, the data user's private key, and key update material as inputs to the decryption algorithm. If the data user is not added to the revocation list within the corresponding revocation period, the decryption algorithm outputs a decryption key within the revocation period; If the data user has been added to the revocation list within the corresponding revocation period, the decryption algorithm will output a decryption failure symbol. During each revocation period, the updated attribute encrypted ciphertext is obtained based on the ciphertext update algorithm, using the public parameters, attribute encrypted ciphertext, and timestamp as inputs.

2. The decentralized electronic medical record sharing method supporting dynamic access as described in claim 1, characterized in that, After verifying the proof, the blockchain allows the data owner to upload medical records. Specifically, after receiving the proof, the blockchain verifies the validity of the submitted proof according to a set algorithm. If the algorithm returns a value of 1, the data owner is allowed to upload the data; otherwise, the upload is not allowed.

3. The decentralized electronic medical record sharing method supporting dynamic access as described in claim 1, characterized in that, Blockchain allocates nodes for stored data, specifically: nodes are allocated based on hash rings, and data owners upload ciphertext to the corresponding nodes for storage according to the allocation results.

4. The decentralized electronic medical record sharing method supporting dynamic access as described in claim 1, characterized in that, The data owner uses a key to create encrypted data containing the identity identifier and the medical record data to be uploaded, specifically: The key is obtained based on the first encryption algorithm, and the medical record data and identity information to be uploaded are used as input to obtain symmetric encrypted ciphertext. The symmetric encryption ciphertext and the symmetric encryption key are used to obtain the attribute-encrypted ciphertext through a second encryption algorithm; The attribute-encrypted ciphertext and the symmetric-encrypted ciphertext are combined to form ciphertext c, which is the data to be uploaded.

5. The decentralized electronic medical record sharing method supporting dynamic access as described in claim 1, characterized in that, Blocks in a blockchain store datasets and mappings from data to nodes; uploaded data is stored on the nodes. Alternatively, a payoff function can be used to reduce the amount of data stored on nodes that exceed a certain value. Nodes with data storage below a certain value increase their data storage to achieve a balanced state of data storage across all nodes.

6. The decentralized electronic medical record sharing method supporting dynamic access as described in claim 1, characterized in that, If the decryption key enters the market, it can be decrypted to obtain the corresponding ID, and the corresponding user can be tracked based on the ID.

7. A decentralized electronic medical record sharing system supporting dynamic access, characterized in that: include: The first data terminal communicates with the blockchain network. The data owner generates a proof based on the zero-knowledge proof in the first data terminal and sends it to the blockchain network. The data is then uploaded to the corresponding node based on the obtained node address. The data owner also uses the key in the first data terminal to create encrypted data of the identity identifier and the medical record data to be uploaded. The blockchain network is configured to: allow data owners to upload medical record data after verifying proof from the first data terminal; allocate nodes for the stored data and receive medical record data uploaded from the first data terminal; During each revocation period, the updated attribute encrypted ciphertext is obtained based on the ciphertext update algorithm, using common parameters, attribute encrypted ciphertext, and timestamp as input. The second data terminal communicates with the blockchain network. Data users obtain a decryption key by proving their identity within a set time period based on the second data terminal. This key is used to decrypt the corresponding ciphertext and obtain the data uploaded by the data owner. The data user obtains key update materials through a public channel. The public parameters, the data user's private key, and the key update materials are used as inputs to the decryption algorithm. If the data user is not added to the revocation list within the corresponding revocation period, the decryption algorithm outputs a decryption key within the revocation period; If the data user has been added to the revocation list within the corresponding revocation period, the decryption algorithm will output a decryption failure symbol. The permission update module is configured to communicate with the blockchain network, update the revocation list based on the set revocation period, and add the data users whose data has been revoked to the updated list so that they cannot decrypt data that has exceeded the revocation period.

8. A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the decentralized electronic medical record sharing method supporting dynamic access as described in any one of claims 1-6.

9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the steps of the decentralized electronic medical record sharing method supporting dynamic access as described in any one of claims 1-6.

Citation Information

Patent Citations

  • Zero-knowledge proof method and system for medical document and storage medium

    CN110334175A

  • Electronic medical record sharing method, system and equipment based on block chain and storage medium

    CN116469501A