[go: up one dir, main page]

CN117577248B - Medical data sharing method and system integrating blockchain and privacy protection technology - Google Patents

Medical data sharing method and system integrating blockchain and privacy protection technology Download PDF

Info

Publication number
CN117577248B
CN117577248B CN202410052287.6A CN202410052287A CN117577248B CN 117577248 B CN117577248 B CN 117577248B CN 202410052287 A CN202410052287 A CN 202410052287A CN 117577248 B CN117577248 B CN 117577248B
Authority
CN
China
Prior art keywords
medical
data
medical data
search
chain
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202410052287.6A
Other languages
Chinese (zh)
Other versions
CN117577248A (en
Inventor
李劲松
赵振淞
陆遥
田雨
周天舒
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang University ZJU
Original Assignee
Zhejiang University ZJU
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang University ZJU filed Critical Zhejiang University ZJU
Priority to CN202410052287.6A priority Critical patent/CN117577248B/en
Publication of CN117577248A publication Critical patent/CN117577248A/en
Application granted granted Critical
Publication of CN117577248B publication Critical patent/CN117577248B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16HHEALTHCARE INFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR THE HANDLING OR PROCESSING OF MEDICAL OR HEALTHCARE DATA
    • G16H10/00ICT specially adapted for the handling or processing of patient-related medical or healthcare data
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/62Protecting access to data via a platform, e.g. using keys or access control rules
    • G06F21/6218Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
    • G06F21/6245Protecting personal data, e.g. for financial or medical purposes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Bioethics (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • Medical Informatics (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Primary Health Care (AREA)
  • Epidemiology (AREA)
  • Computing Systems (AREA)
  • Public Health (AREA)
  • Medical Treatment And Welfare Office Work (AREA)

Abstract

The invention discloses a medical data sharing method and a system for fusing a blockchain and a privacy intersection technology. The invention realizes the unified searching and screening functions of multi-center data on the blockchain and the matching and aligning functions of the multi-center data by introducing the searchable encryption technology and the privacy set intersection technology, enriches the functionality of medical data sharing, and truly realizes the data communication and intercommunication among the multi-centers under the security privacy condition.

Description

融合区块链与隐私求交技术的医疗数据共享方法及系统Medical data sharing method and system integrating blockchain and privacy protection technology

技术领域Technical Field

本发明属于医疗信息技术领域,尤其涉及一种融合区块链与隐私求交技术的医疗数据共享方法及系统。The present invention belongs to the field of medical information technology, and in particular to a medical data sharing method and system that integrates blockchain and privacy protection technology.

背景技术Background technique

医疗数据是指所有与医疗卫生和生命健康活动相关的数据集合,涉及医疗服务、疾病防控、健康保障和养生保健等多个方面,具有数据量大、数据种类多、价值高、产生快等特点。然而在现实中,医疗数据往往得不到有效的利用,所以蕴含的价值也无法完全开发。其原因主要有以下两点:首先,关键的医疗数据往往由不同的医疗机构或部门创建和维护,分散在多个中心之中,导致医疗机构之间共享医疗数据不便,效率低下。除此之外,医疗数据本身高度敏感,包含了大量的患者隐私信息,其泄露可能导致严重后果,使得大多医疗机构往往不愿共享其数据,阻碍了医疗服务质量的提高与高精尖研究的开展。因此,对于医疗机构以及相关部门而言,如何在保证安全和隐私环境下实现多中心医疗数据的收集、共享和有效利用仍然是一个巨大的挑战。Medical data refers to all data sets related to medical and health activities, involving medical services, disease prevention and control, health protection, and health care. It has the characteristics of large data volume, multiple data types, high value, and fast generation. However, in reality, medical data is often not effectively utilized, so the value contained cannot be fully developed. The main reasons are as follows: First, key medical data is often created and maintained by different medical institutions or departments, and is scattered among multiple centers, which makes it inconvenient and inefficient to share medical data between medical institutions. In addition, medical data itself is highly sensitive and contains a large amount of patient privacy information. Its leakage may lead to serious consequences, making most medical institutions reluctant to share their data, hindering the improvement of medical service quality and the development of high-precision research. Therefore, for medical institutions and relevant departments, how to achieve the collection, sharing and effective use of multi-center medical data in a safe and private environment is still a huge challenge.

区块链技术作为一种安全的分布式账本与平台,逐步应用于医疗领域,为多中心医疗数据共享提供了一种潜在的解决方案。对于规模庞大的医疗数据,区块链可以与隐私计算等新兴安全技术结合,提供了一种全新的方式来储存和交换医疗数据要素,保证医疗数据的可信共享及安全利用,解决跨机构医疗数据不敢使用的难题。As a secure distributed ledger and platform, blockchain technology has been gradually applied to the medical field, providing a potential solution for multi-center medical data sharing. For large-scale medical data, blockchain can be combined with emerging security technologies such as privacy computing to provide a new way to store and exchange medical data elements, ensure the trusted sharing and safe use of medical data, and solve the problem of cross-institutional medical data not being able to be used.

目前,与本申请最相近的技术方案为:①基于数据传输的医疗区块链,这种类型的区块链将加密后的医疗数据密文储存在区块链上,只有拥有对应解密手段的用户才能接收到数据,区块链主要用作数据安全传输的媒介。Li Patrick等人设计了一种名为DMMS的去中心化药物管理系统用于患者用药史的管理。利用Hyperledger Fabric网络将处方开具者、接受处方的患者、药物的详细信息上传到区块链上,并采用非对称加密的方式实现隐私保护和权限控制,解决了传输医疗数据的困难性以及集中式网络的不安全性的问题。②基于权限验证的医疗区块链,这种类型的区块链将具体的医疗数据存储在本地,将医疗数据的哈希值储存在链上,利用区块链防篡改的特性实现数据的安全存储。Zhang J等人设计了一种针对电子康复病历的区块链共享方案,利用混合P2P网络、非对称加密算法、Raft共识算法等技术,在共享过程中实现分布式存储与隐私保护,并将摘要信息以区块链数据结构存储在联盟区块链上,实现不同医院之间医疗数据的点对点查询。At present, the technical solutions closest to this application are: ① Medical blockchain based on data transmission. This type of blockchain stores encrypted medical data ciphertext on the blockchain. Only users with corresponding decryption means can receive the data. The blockchain is mainly used as a medium for secure data transmission. Li Patrick et al. designed a decentralized drug management system called DMMS for the management of patient medication history. The Hyperledger Fabric network is used to upload detailed information about the prescriber, the patient receiving the prescription, and the drug to the blockchain, and asymmetric encryption is used to achieve privacy protection and permission control, which solves the difficulty of transmitting medical data and the insecurity of centralized networks. ② Medical blockchain based on permission verification. This type of blockchain stores specific medical data locally and stores the hash value of medical data on the chain, using the tamper-proof characteristics of the blockchain to achieve secure data storage. Zhang J et al. designed a blockchain sharing solution for electronic rehabilitation medical records, using hybrid P2P networks, asymmetric encryption algorithms, Raft consensus algorithms and other technologies to achieve distributed storage and privacy protection in the sharing process, and store summary information on the alliance blockchain in a blockchain data structure to achieve point-to-point query of medical data between different hospitals.

现有的医疗区块链模式都存在相应的不足之处。①传统的基于数据传输的医疗区块链中,医疗机构需要将所有数据上传到区块链,但实际上区块链的储存能力有限,同时对于不同的接收者,发送者需要对数据重新加密并再次上传。随着数据上传量的增多,区块链性能和效率会大幅度下降,因此区块链的储存能力是一个非常大的考验。②传统的基于权限验证的医疗区块链中,需要将医疗数据储存在本地,将数据哈希值存储在区块链上。这种方式虽然减少了链上的存储开销,但也导致了医疗区块链在医疗数据的共享过程中功能性不足的问题。单纯的数据哈希值仅能实现简单的数据交换,也有部分研究通过在区块链上存储摘要的形式来对数据进行简单的搜索功能。但在实际应用中,医疗数据本身情况复杂多变,因此如何打破单独一家医疗机构的信息孤岛,利用区块链实现真正意义上的多中心医疗数据的统一搜索、对齐与匹配至关重要。The existing medical blockchain models all have corresponding shortcomings. ① In the traditional medical blockchain based on data transmission, medical institutions need to upload all data to the blockchain, but in fact the storage capacity of the blockchain is limited. At the same time, for different recipients, the sender needs to re-encrypt the data and upload it again. With the increase in the amount of data uploaded, the performance and efficiency of the blockchain will drop significantly, so the storage capacity of the blockchain is a very big test. ② In the traditional medical blockchain based on permission verification, medical data needs to be stored locally and the data hash value is stored on the blockchain. Although this method reduces the storage overhead on the chain, it also leads to the problem of insufficient functionality of the medical blockchain in the process of sharing medical data. The simple data hash value can only realize simple data exchange, and some studies have also performed simple search functions on the data by storing summaries on the blockchain. However, in actual applications, the medical data itself is complex and changeable, so it is crucial to break the information island of a single medical institution and use the blockchain to achieve unified search, alignment and matching of multi-center medical data in a true sense.

发明内容Summary of the invention

本发明的目的在于针对现有技术的不足,提供一种融合区块链与隐私求交技术的医疗数据共享方法及系统。The purpose of the present invention is to address the deficiencies of the prior art and provide a medical data sharing method and system that integrates blockchain and privacy protection technology.

本发明的目的是通过以下技术方案实现的:The objective of the present invention is achieved through the following technical solutions:

根据本说明书的第一方面,提供一种融合区块链与隐私求交技术的医疗数据共享方法,该方法包括:According to a first aspect of this specification, a medical data sharing method integrating blockchain and privacy protection technology is provided, the method comprising:

建立医疗区块链系统,所述医疗区块链系统包括两条独立并行的区块链:摘要搜索链与数据传输链;Establishing a medical blockchain system, the medical blockchain system comprising two independent and parallel blockchains: a summary search chain and a data transmission chain;

将医疗机构储存在本地的医疗数据提取为摘要形式,并将医疗数据摘要通过共识机制上传到摘要搜索链;Extract the medical data stored locally by medical institutions into summary form, and upload the medical data summary to the summary search chain through a consensus mechanism;

对摘要搜索链中的医疗数据摘要进行搜索,根据搜索方提供的搜索条件对医疗数据摘要进行筛选,并将筛选结构返回给医疗数据所属的医疗机构;Search the medical data abstracts in the abstract search chain, filter the medical data abstracts according to the search conditions provided by the search party, and return the filter structure to the medical institution to which the medical data belongs;

对筛选出的医疗数据摘要基于隐私求交技术进行多家医疗机构的匹配与对齐,并将对齐结果返回给医疗数据所属的医疗机构;The screened medical data summaries are matched and aligned with multiple medical institutions based on privacy intersection technology, and the alignment results are returned to the medical institution to which the medical data belongs;

收到筛选或对齐结果的医疗机构若同意共享医疗数据,则通过基于密文策略的属性加密方法将待共享医疗数据上传到数据传输链,由满足属性条件的搜索方解密获取。If the medical institution that receives the screening or alignment results agrees to share the medical data, the medical data to be shared will be uploaded to the data transmission chain through an attribute encryption method based on a ciphertext strategy, and will be decrypted and obtained by the search party that meets the attribute conditions.

进一步地,所述摘要搜索链由医疗机构与监管机构节点组成,储存医疗机构上传的医疗数据摘要,并由监管平台作为搜索功能的外部客户端;Furthermore, the summary search chain is composed of nodes of medical institutions and regulatory agencies, storing medical data summaries uploaded by medical institutions, and the regulatory platform serves as an external client for the search function;

所述数据传输链由医疗机构、监管机构与第三方机构节点组成,储存医疗机构筛选、对齐后上传的医疗数据,由监管机构负责第三方机构的权限管理,完成医疗机构之间、医疗机构与第三方机构之间的数据共享。The data transmission chain is composed of nodes of medical institutions, regulatory agencies and third-party agencies, and stores medical data uploaded after screening and alignment by medical institutions. The regulatory agency is responsible for the authority management of third-party agencies and completes data sharing between medical institutions and between medical institutions and third-party agencies.

进一步地,所述医疗数据摘要的上传具体为:Furthermore, the upload of the medical data summary is specifically as follows:

将医疗机构储存在本地的医疗数据提取为约定好的摘要形式,由医疗机构定期创建区块并按时间顺序相连,创建的区块通过各医疗机构节点之间的共识完成医疗数据摘要的上链。The medical data stored locally by medical institutions are extracted into an agreed summary form. The medical institutions regularly create blocks and connect them in chronological order. The created blocks complete the upload of the medical data summary to the chain through consensus among the nodes of each medical institution.

进一步地,所述医疗数据摘要的搜索与筛选具体为:Furthermore, the search and screening of the medical data summary is specifically as follows:

医疗机构根据安全等级确定安全参数,生成自身的公钥和私钥;Medical institutions determine security parameters based on security levels and generate their own public and private keys;

医疗机构通过自身的公钥对待上链的医疗数据摘要进行加密生成密文,对所有医疗数据摘要的密文均进行上链;Medical institutions use their own public keys to encrypt the medical data summaries to be uploaded to the chain to generate ciphertext, and upload the ciphertext of all medical data summaries to the chain;

当搜索方通过监管机构提供的中间平台对医疗数据摘要进行搜索时,监管机构将搜索方的搜索条件发送给摘要搜索链上所有参与共识的医疗机构;When the searcher searches for medical data summaries through the intermediary platform provided by the regulatory agency, the regulatory agency sends the searcher's search conditions to all medical institutions participating in the consensus on the summary search chain;

各医疗机构根据搜索条件通过自身的私钥生成陷门;Each medical institution generates a trapdoor using its own private key based on the search criteria;

智能合约根据医疗机构上链的陷门,对储存在链上的医疗机构的所有加密摘要进行搜索,对比陷门和每个加密摘要,筛选出符合搜索条件的加密摘要;The smart contract searches all encrypted summaries of medical institutions stored on the chain according to the trapdoors uploaded by the medical institutions, compares the trapdoors with each encrypted summary, and selects the encrypted summaries that meet the search criteria;

智能合约将筛选出的加密摘要通知其所属的医疗机构,医疗机构对加密摘要通过自身的私钥进行解密,得到解密后的医疗数据摘要。The smart contract will notify the medical institution to which it belongs of the screened encrypted summary. The medical institution will decrypt the encrypted summary using its own private key to obtain the decrypted medical data summary.

进一步地,所述医疗数据摘要的匹配与对齐采用基于Diffie-Hellman密钥交换算法的隐私求交技术,通过可交换加密函数实现两次交换加密顺序的加密操作,使得参与双方对于交集数据得到完全相同的不可逆密文。Furthermore, the matching and alignment of the medical data summaries adopts the privacy intersection technology based on the Diffie-Hellman key exchange algorithm, and implements the encryption operation of exchanging the encryption order twice through the exchangeable encryption function, so that the participating parties obtain exactly the same irreversible ciphertext for the intersection data.

进一步地,对于待进行医疗数据摘要匹配与对齐的任意两家医疗机构,分别记为A和B,匹配与对齐流程如下:Furthermore, for any two medical institutions to be matched and aligned with medical data summaries, denoted as A and B, the matching and alignment process is as follows:

对于医疗机构A,选择随机数α作为私钥,对每个筛选出的医疗数据摘要进行哈希操作,使用私钥α对哈希值进行加密生成密文上链,将密文/>通过监管机构节点发送给医疗机构B;For medical institution A, a random number α is selected as the private key, a hash operation is performed on each screened medical data summary, and the hash value is encrypted using the private key α to generate a ciphertext. On the chain, the ciphertext/> Sent to medical institution B through the regulatory agency node;

对于医疗机构B,选择随机数β作为私钥,对每个筛选出的医疗数据摘要进行哈希操作,使用私钥β对哈希值进行加密生成密文上链,将密文/>通过监管机构节点发送给医疗机构A;For medical institution B, a random number β is selected as the private key, a hash operation is performed on each screened medical data summary, and the hash value is encrypted using the private key β to generate a ciphertext. On the chain, the ciphertext/> Sent to medical institution A through the regulatory agency node;

医疗机构B对于接收到的密文使用私钥β进行二次加密生成密文/>并再次上链;医疗机构A对于接收到的密文/>使用私钥α进行二次加密生成密文/>并再次上链;Medical institution B receives the ciphertext Use the private key β to perform secondary encryption to generate ciphertext/> And upload it to the chain again; Medical institution A receives the ciphertext/> Use private key α to perform secondary encryption to generate ciphertext/> And wind it up again;

通过部署在摘要搜索链上的智能合约比较密文和/>,/>和/>中一致的医疗数据摘要即为交集数据/>Compare ciphertexts through smart contracts deployed on the summary search chain and/> ,/> and/> The consistent medical data summary is the intersection data/> .

进一步地,所述医疗数据的共享具体为:Furthermore, the medical data is specifically shared as follows:

参与数据共享的医疗机构根据安全参数生成公钥和主密钥;Medical institutions participating in data sharing generate public keys and master keys based on security parameters;

对于待共享的医疗数据,医疗机构按照待共享的搜索方指定的要求生成访问结构,并结合公钥对待共享的医疗数据进行加密保护生成密文,医疗机构通过共识将生成的密文上传到数据传输链;For the medical data to be shared, the medical institution generates an access structure according to the requirements specified by the search party to be shared, and encrypts the medical data to be shared with the public key to generate ciphertext. The medical institution uploads the generated ciphertext to the data transmission chain through consensus;

各搜索方将自身拥有的属性和主密钥结合生成用于解密的私钥,对于满足属性条件的搜索方,使用生成的私钥对加密的医疗数据进行解密,获得满足搜索条件的医疗数据,完成医疗数据的安全共享。Each search party combines its own attributes and the master key to generate a private key for decryption. For search parties that meet the attribute conditions, the generated private key is used to decrypt the encrypted medical data to obtain medical data that meets the search conditions, thereby completing the secure sharing of medical data.

根据本说明书的第二方面,提供一种融合区块链与隐私求交技术的医疗数据共享系统,该系统包括:According to a second aspect of this specification, a medical data sharing system integrating blockchain and privacy protection technology is provided, the system comprising:

区块链框架模块:建立医疗区块链系统,所述医疗区块链系统包括两条独立并行的区块链:摘要搜索链与数据传输链;Blockchain framework module: establish a medical blockchain system, which includes two independent and parallel blockchains: a summary search chain and a data transmission chain;

数据摘要上传模块:将医疗机构储存在本地的医疗数据提取为摘要形式,并将医疗数据摘要通过共识机制上传到摘要搜索链;Data summary upload module: extracts the medical data stored locally by medical institutions into summary form, and uploads the medical data summary to the summary search chain through a consensus mechanism;

数据摘要搜索与筛选模块:对摘要搜索链中的医疗数据摘要进行搜索,根据搜索方提供的搜索条件对医疗数据摘要进行筛选,并将筛选结构返回给医疗数据所属的医疗机构;Data summary search and screening module: Search the medical data summaries in the summary search chain, screen the medical data summaries according to the search conditions provided by the searcher, and return the screening structure to the medical institution to which the medical data belongs;

数据摘要匹配与对齐模块:对筛选出的医疗数据摘要基于隐私求交技术进行多家医疗机构的匹配与对齐,并将对齐结果返回给医疗数据所属的医疗机构;Data summary matching and alignment module: matches and aligns the selected medical data summaries across multiple medical institutions based on privacy intersection technology, and returns the alignment results to the medical institution to which the medical data belongs;

数据传递与共享模块:收到筛选或对齐结果的医疗机构若同意共享医疗数据,则通过基于密文策略的属性加密方法将待共享医疗数据上传到数据传输链,由满足属性条件的搜索方解密获取。Data transmission and sharing module: If the medical institution that receives the screening or alignment results agrees to share the medical data, the medical data to be shared will be uploaded to the data transmission chain through an attribute encryption method based on the ciphertext strategy, and will be decrypted and obtained by the search party that meets the attribute conditions.

根据本说明书的第三方面,提供一种融合区块链与隐私求交技术的医疗数据共享设备,包括存储器和一个或多个处理器,所述存储器中存储有可执行代码,所述处理器执行所述可执行代码时,实现如第一方面所述的融合区块链与隐私求交技术的医疗数据共享方法。According to the third aspect of this specification, a medical data sharing device integrating blockchain and privacy intersection technology is provided, comprising a memory and one or more processors, wherein the memory stores executable code, and when the processor executes the executable code, the medical data sharing method integrating blockchain and privacy intersection technology as described in the first aspect is implemented.

根据本说明书的第四方面,提供一种计算机可读存储介质,其上存储有程序,所述程序被处理器执行时,实现如第一方面所述的融合区块链与隐私求交技术的医疗数据共享方法。According to a fourth aspect of this specification, a computer-readable storage medium is provided, on which a program is stored. When the program is executed by a processor, the medical data sharing method that integrates blockchain and privacy protection technology as described in the first aspect is implemented.

本发明的有益效果是:The beneficial effects of the present invention are:

1. 本发明通过设计双链并行的区块链系统结构,一是通过两条独立并行的医疗区块链,实现了医疗数据摘要的链上搜索以及对应医疗数据的链上共享,仅储存必要且关键数据,解决了基于数据传输的医疗区块链中存储空间不足、区块链体量臃肿的问题;二是将区块链与属性加密技术结合,并将摘要检索与数据传输独立开来,实现一次上传多次共享以及多对多的数据共享模式,避免了基于权限验证的医疗区块链中数据共享多次请求和重复共享的问题,解决了多中心数据共享效率低下的问题。1. The present invention designs a dual-chain parallel blockchain system structure. First, through two independent and parallel medical blockchains, on-chain search of medical data summaries and on-chain sharing of corresponding medical data are realized, and only necessary and key data are stored, which solves the problems of insufficient storage space and bloated blockchain volume in medical blockchains based on data transmission; second, blockchain is combined with attribute encryption technology, and summary retrieval is separated from data transmission, so as to realize one-time upload and multiple sharing and many-to-many data sharing modes, avoiding the problems of multiple requests and repeated sharing of data sharing in medical blockchains based on authority verification, and solving the problem of low efficiency of multi-center data sharing.

2. 本发明通过引入可搜索加密技术与隐私集合求交集技术,并将二者有机结合,实现了区块链上多中心数据的统一搜索与筛选功能以及多中心数据的匹配与对齐功能。解决了传统医疗区块链功能性不足,各中心在数据共享过程中存在一定的封闭性与割裂性的问题,真正意义上实现了保证安全隐私条件下多中心之间的数据交流互通。2. This invention introduces searchable encryption technology and privacy set intersection technology, and organically combines the two to achieve unified search and screening functions of multi-center data on the blockchain, as well as matching and alignment functions of multi-center data. It solves the problem of insufficient functionality of traditional medical blockchains and the certain closedness and fragmentation of each center in the data sharing process, and truly realizes data exchange and intercommunication between multiple centers under the condition of ensuring security and privacy.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

图1为一示例性实施例示出的融合区块链与隐私求交技术的医疗数据共享方法实现原理图;FIG1 is a schematic diagram showing a medical data sharing method integrating blockchain and privacy protection technology according to an exemplary embodiment;

图2为一示例性实施例示出的基于双链的医疗区块链系统架构图;FIG2 is a diagram showing the architecture of a medical blockchain system based on dual chains according to an exemplary embodiment;

图3为一示例性实施例示出的融合区块链与隐私求交技术的医疗数据共享系统结构图;FIG3 is a structural diagram of a medical data sharing system integrating blockchain and privacy protection technology, shown in an exemplary embodiment;

图4为一示例性实施例示出的融合区块链与隐私求交技术的医疗数据共享设备结构图。FIG4 is a structural diagram of a medical data sharing device that integrates blockchain and privacy-enforcing technologies, shown as an exemplary embodiment.

具体实施方式Detailed ways

为了更好的理解本申请的技术方案,下面结合附图对本申请实施例进行详细描述。In order to better understand the technical solution of the present application, the embodiments of the present application are described in detail below with reference to the accompanying drawings.

应当明确,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其它实施例,都属于本申请保护的范围。It should be clear that the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present application.

在本申请实施例中使用的术语是仅仅出于描述特定实施例的目的,而非旨在限制本申请。在本申请实施例和所附权利要求书中所使用的单数形式的“一种”、“所述”和“该”也旨在包括多数形式,除非上下文清楚地表示其他含义。The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the present application. The singular forms "a", "said" and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings.

本发明提供一种融合区块链与隐私求交技术的医疗数据共享方法,如图1所示,该方法包括建立基于双链的医疗区块链系统、数据摘要上传、数据摘要搜索与筛选、数据摘要匹配与对齐、数据传递与共享等部分,下面详细阐述每个部分的具体实现流程。The present invention provides a medical data sharing method that integrates blockchain and privacy-enhancing technology. As shown in FIG1 , the method includes establishing a medical blockchain system based on a dual chain, uploading data summaries, searching and screening data summaries, matching and aligning data summaries, and transmitting and sharing data. The specific implementation process of each part is described in detail below.

一、建立基于双链的医疗区块链系统1. Establish a dual-chain medical blockchain system

与传统的医疗区块链不同,如图2所示,本发明的医疗区块链系统由两条独立并行的区块链组成,且各自功能不同,参与其中的节点的功能、地位与数量也不尽相同。参与本发明医疗区块链系统的节点共有三类:Different from the traditional medical blockchain, as shown in Figure 2, the medical blockchain system of the present invention consists of two independent parallel blockchains, each with different functions, and the functions, status and number of nodes involved are also different. There are three types of nodes participating in the medical blockchain system of the present invention:

①医疗机构,如医院等。此类节点为全节点,具有数据上传和共识功能,主要负责医疗数据摘要和所需数据的上传下载,在系统中默认为完全可信;① Medical institutions, such as hospitals. This type of node is a full node with data upload and consensus functions. It is mainly responsible for uploading and downloading medical data summaries and required data. It is fully trusted by default in the system;

②第三方机构,如高校院所、科研中心、医药公司、保险公司、私人诊所等。在系统中的主要目的是获取需要的医疗数据,并在一定条件下参与部分的共识功能,此类节点默认为半可信节点;② Third-party institutions, such as universities, research centers, pharmaceutical companies, insurance companies, private clinics, etc. The main purpose of the system is to obtain the required medical data and participate in some consensus functions under certain conditions. Such nodes are semi-trusted nodes by default;

③监管机构,监管机构在区块链中负责第三方机构权限和准入的管理与审批,并作为数据搜索和对齐匹配的中间功能性平台,不参与共识机制。③ Regulatory agencies: Regulatory agencies are responsible for the management and approval of the authority and access of third-party agencies in the blockchain, and serve as an intermediate functional platform for data search and alignment matching, but do not participate in the consensus mechanism.

以上三类节点将共同构成两条区块链:摘要搜索链与数据传输链。The above three types of nodes will jointly constitute two blockchains: summary search chain and data transmission chain.

①摘要搜索链由医疗机构节点与监管机构节点组成,其将储存各个医疗机构上传的医疗数据摘要,并由监管平台作为搜索功能的外部客户端,第三方机构节点则不参与该链的工作。① The summary search chain is composed of medical institution nodes and regulatory agency nodes. It will store the medical data summaries uploaded by various medical institutions, and the regulatory platform will serve as the external client of the search function. Third-party agency nodes do not participate in the work of the chain.

②数据传输链由所有的三类节点组成,储存医疗机构按照对应要求筛选对齐后上传的数据,完成医疗机构之间、医疗机构与第三方机构之间的数据共享,第三方机构节点会在此部分参与共识。②The data transmission chain is composed of all three types of nodes, which store the data uploaded by medical institutions after screening and alignment according to corresponding requirements, and complete data sharing between medical institutions and between medical institutions and third-party institutions. The nodes of third-party institutions will participate in the consensus in this part.

二、数据摘要上传2. Data summary upload

为了保证区块链上数据的安全性,克服区块链的存储空间限制和性能瓶颈,本发明使用链上链下结合的储存模式,具体详细的医疗数据将储存在医疗机构本地服务器中,摘要搜索链上则将医疗数据以约定好的摘要形式储存在链上,由医疗机构定期创建区块并按时间顺序相连。每个区块由两部分组成:块头和块体。块头包含区块哈希、时间戳和默克尔根等必要信息;块体的默克尔树则是摘要的关键,主要包含医疗机构ID、患者ID、疾病种类、医疗数据格式以及就医时间等信息,以此实现医疗数据的精细化搜索与筛选,并能进一步实现患者样本或是疾病种类等不同条件的数据对齐。例如,可以按患者层面进行数据对齐,具体为,某患者在多家医疗机构有过就医记录,通过筛选与对齐机制可以一次性获取该患者在固定时间间隔内在多家医疗机构的所有就诊信息;或者按疾病种类层面进行数据对齐,具体为,某家科研院所需要研究疾病A和疾病B的潜在关系,通过筛选与对齐机制,可以找到各医疗机构中同时患有疾病A和疾病B的患者及其就诊信息。In order to ensure the security of data on the blockchain and overcome the storage space limitations and performance bottlenecks of the blockchain, the present invention uses a storage mode that combines on-chain and off-chain. Specific and detailed medical data will be stored in the local server of the medical institution, and the summary search chain will store the medical data in the form of an agreed summary on the chain. The medical institution will create blocks regularly and connect them in chronological order. Each block consists of two parts: a block header and a block body. The block header contains necessary information such as block hash, timestamp, and Merkle root; the Merkle tree of the block body is the key to the summary, mainly including information such as medical institution ID, patient ID, disease type, medical data format, and medical treatment time, so as to achieve refined search and screening of medical data, and can further achieve data alignment of different conditions such as patient samples or disease types. For example, data alignment can be performed at the patient level. Specifically, if a patient has medical records in multiple medical institutions, the screening and alignment mechanism can be used to obtain all the medical information of the patient in multiple medical institutions within a fixed time interval at one time; or data alignment can be performed at the disease type level. Specifically, if a scientific research institute needs to study the potential relationship between disease A and disease B, the screening and alignment mechanism can be used to find patients with both disease A and disease B in each medical institution and their medical information.

由医疗机构创建的区块通过各节点之间的共识完成摘要数据的上链,此步骤只有医疗机构节点参与共识,因为默认其完全可信,此处的共识将采用Raft共识算法以提高共识效率,其支持最大的容错故障节点数是(N-1)/2,其中N为集群中节点总数。Raft共识算法的大致流程如下:首先选举一个“领导者”,接着赋予“领导者”完全的权力管理区块的写入,“领导者”收到区块的写入请求后,完成写入操作,生成区块,并复制到其他节点。The blocks created by the medical institution complete the upload of summary data to the chain through the consensus between the nodes. In this step, only the nodes of the medical institution participate in the consensus because they are completely trustworthy by default. The consensus here will use the Raft consensus algorithm to improve the efficiency of the consensus. The maximum number of fault-tolerant nodes it supports is (N-1)/2, where N is the total number of nodes in the cluster. The general process of the Raft consensus algorithm is as follows: First, a "leader" is elected, and then the "leader" is given full power to manage the writing of the block. After receiving the write request of the block, the "leader" completes the write operation, generates the block, and copies it to other nodes.

三、数据摘要搜索与筛选3. Data summary search and screening

为了保证数据在搜索和筛选过程中的安全与隐私,本发明采用公钥可搜索加密(Public Key Encryption With Searching,PEKS)方法实现搜索功能。完整的数据摘要搜索与筛选流程如下:In order to ensure the security and privacy of data during the search and screening process, this paper adopts the Public Key Encryption With Searching (PEKS) method to implement the search function. The complete data summary search and screening process is as follows:

(1)医疗机构根据各自的安全等级确定安全参数,并生成属于自身的公钥/>和私钥/>(1) Medical institutions determine safety parameters based on their respective safety levels , and generate its own public key/> and private key/> ;

其中为密钥生成函数。in is the key generation function.

(2)对于待上链的数据摘要,医疗机构通过自身的公钥对其进行加密,生成密文(2) Summary of data to be uploaded to the chain , the medical institution encrypts it with its own public key to generate ciphertext ;

其中为加密函数;对所有数据摘要的密文均进行上链。in It is an encryption function; the ciphertext of all data summaries are uploaded to the chain.

(3)当搜索方通过监管机构的中间功能性平台对医疗数据摘要进行搜索时,监管机构将搜索方的搜索条件发送给摘要搜索链上所有参与共识的医疗机构,例如搜索条件/>为:某患者ID在固定时间间隔内的所有就诊信息;(3) When a searcher searches for medical data summaries through the regulator’s intermediate functional platform, the regulator will Sent to all medical institutions participating in the consensus on the summary search chain, such as search conditions/> For: all the medical information of a patient ID within a fixed time interval;

各医疗机构根据搜索条件通过自身的私钥/>生成相应的陷门/> Medical institutions according to search conditions Through your own private key /> Generate the corresponding trapdoor/> ;

其中为陷门函数。in is a trapdoor function.

(4)部署在摘要搜索链上的智能合约根据各医疗机构上链的陷门,对储存在链上的该医疗机构的所有加密摘要/>进行搜索,对比陷门/>和每个加密摘要/>,判断搜索条件/>和数据摘要/>是否匹配,返回每个加密摘要/>的比较结果/>,若不匹配则,若匹配则/>(4) The smart contract deployed on the summary search chain is based on the trapdoors on the chain of each medical institution. , all encrypted summaries of the medical institution stored on the chain/> Search and compare trapdoors/> and each encrypted digest/> , determine the search conditions/> and data summary/> Whether it matches, return each encrypted summary/> Comparison results of /> If it does not match, , if it matches then/> ;

其中为匹配函数。in is the matching function.

(5)搜索完成后,智能合约将符合筛选要求的加密摘要通知其所属的医疗机构和搜索方,医疗机构对该加密摘要/>通过自身的私钥进行解密,得到解密后的数据摘要,用于后续的匹配对齐;(5) After the search is completed, the smart contract will send an encrypted summary that meets the screening requirements Notify the medical institution and search party to which the medical institution belongs, and the medical institution will send the encrypted summary/> Decrypted with its own private key to obtain the decrypted data summary , used for subsequent matching and alignment;

其中为解密函数。in is the decryption function.

四、数据摘要匹配与对齐4. Data Summary Matching and Alignment

在完成了初步的数据筛选后,对筛选得到的数据做进一步的匹配与对齐,在多中心即多家医疗机构获取符合共同要求的医疗数据。本发明引入隐私集合求交集(PrivateSet Intersection,PSI)技术,获取多中心医疗数据的交集且不暴露交集外的数据。这一步将通过用于通讯的监管机构节点以及部署在摘要搜索链上的智能合约完成。为了方便与可搜索加密结合从而实现区块链上的隐私求交,本发明采用基于Diffie-Hellman密钥交换算法的PSI方案,该方案基于Diffie-Hellman密钥交换协议的思路,通过可交换加密函数实现两次交换加密顺序的加密操作,使得参与双方对于交集数据,得到完全相同的不可逆密文。对于本发明而言,以医疗机构A与医疗机构B之间的隐私求交为例,数据摘要匹配与对齐流程如下:After completing the preliminary data screening, the screened data is further matched and aligned to obtain medical data that meets common requirements from multiple centers, i.e. multiple medical institutions. The present invention introduces the Private Set Intersection (PSI) technology to obtain the intersection of multi-center medical data without exposing data outside the intersection. This step will be completed through the regulatory agency node used for communication and the smart contract deployed on the summary search chain. In order to facilitate the combination with searchable encryption to achieve privacy intersection on the blockchain, the present invention adopts the PSI scheme based on the Diffie-Hellman key exchange algorithm. The scheme is based on the idea of the Diffie-Hellman key exchange protocol and implements two encryption operations of exchanging encryption orders through an exchangeable encryption function, so that the participating parties can obtain exactly the same irreversible ciphertext for the intersection data. For the present invention, taking the privacy intersection between medical institution A and medical institution B as an example, the data summary matching and alignment process is as follows:

假设在完成数据摘要的初步搜索与筛选后医疗机构A中符合要求的数据摘要为,医疗机构B中符合要求的数据摘要为/>,其中可交换加密函数的定义如下:Assume that after the initial search and screening of data summaries, the data summaries that meet the requirements in medical institution A are as follows: , the summary of data that meets the requirements in medical institution B is/> , where the commutative encryption function is defined as follows:

其中,为需要加密的数据,/>为两次加密操作。in, For data that needs to be encrypted, /> This is two encryption operations.

对于医疗机构A,选择随机数作为私钥。对于每一个数据摘要/>,医疗机构A对其进行哈希操作/>,再基于其哈希值使用私钥对其加密,生成密文/>上链,并将此密文/>通过监管机构节点发送给医疗机构B。For medical institution A, select a random number As a private key. For each data digest/> , medical institution A performs hash operation on it/> , and then encrypt it with the private key based on its hash value to generate ciphertext/> On the chain, and this ciphertext/> Sent to medical institution B through the regulatory agency node.

对于医疗机构B,选择随机数作为私钥。对于每一个数据摘要/>,医疗机构B对其进行哈希操作/>,再基于其哈希值使用私钥对其加密,生成密文/>上链,并将此密文/>通过监管机构节点发送给医疗机构A。For medical institution B, select a random number As a private key. For each data digest/> , medical institution B performs hash operation on it/> , and then encrypt it with the private key based on its hash value to generate ciphertext/> On the chain, and this ciphertext/> Sent to medical institution A through the regulatory agency node.

医疗机构B对于接收到的医疗机构A的密文,使用其私钥/>对其进行二次加密生成密文/>并再次上链。Medical institution B receives the ciphertext from medical institution A. , using its private key/> It is encrypted twice to generate ciphertext/> And wind it up again.

医疗机构A对于接收到的医疗机构B的密文,使用其私钥/>对其进行二次加密生成密文/>并再次上链。Medical institution A receives the ciphertext from medical institution B , using its private key/> It is encrypted twice to generate ciphertext/> And wind it up again.

通过部署在摘要搜索链上的智能合约,比较医疗机构A与B二次加密后的密文和/>。医疗机构A与B中若拥有相同的数据摘要,则两次加密得到的密文一致,因此/>中一致的数据摘要即为二者交集数据U。Compare the encrypted ciphertexts of medical institutions A and B after double encryption through the smart contract deployed on the summary search chain and/> If medical institutions A and B have the same data summary, the ciphertexts obtained by the two encryptions are the same, so/> and The consistent data summary in is the intersection data U of the two.

其中表示集合求交集操作。in Represents a set intersection operation.

若需要多中心的数据摘要匹配与对齐,则按上述步骤多次实施两两医疗机构的数据摘要匹配与对齐。具体地,对于筛选出超过两家医疗机构的情况,例如筛选出医疗机构A、B、C,可以先对医疗机构A、B进行数据对齐,将对齐结果再与医疗机构C进行数据对齐,从而得到在三家医疗机构中均符合筛选要求的医疗数据摘要。If multi-center data summary matching and alignment is required, the data summary matching and alignment of two medical institutions shall be performed multiple times according to the above steps. Specifically, in the case where more than two medical institutions are screened out, for example, medical institutions A, B, and C are screened out, the data of medical institutions A and B can be aligned first, and the alignment results can be aligned with the data of medical institution C, so as to obtain medical data summaries that meet the screening requirements in all three medical institutions.

五、数据传递与共享模块5. Data transmission and sharing module

在完成对数据摘要搜索与筛选、数据摘要匹配与对齐之后,需要在医疗机构与第三方机构,医疗机构与医疗机构之间共享符合要求的具体数据。这一步通过与摘要搜索链并行且独立的第二条区块链-数据传输链实现。且为了保证数据共享过程中的效率以及隐私性,本发明引入了基于密文策略的属性加密(KP-ABE)方法,实现安全的多对多共享。共享的流程如下:After completing the search and screening of data summaries, matching and alignment of data summaries, it is necessary to share specific data that meets the requirements between medical institutions and third-party institutions, and between medical institutions. This step is achieved through a second blockchain-data transmission chain that is parallel and independent to the summary search chain. In order to ensure the efficiency and privacy of the data sharing process, the present invention introduces the attribute encryption (KP-ABE) method based on the ciphertext strategy to achieve secure many-to-many sharing. The sharing process is as follows:

(1)参与数据共享的医疗机构根据安全参数生成公钥/>和主密钥/>(1) Medical institutions participating in data sharing shall share data according to security parameters. Generate public key/> and the master key/> ;

其中为密钥生成函数。in is the key generation function.

(2)对于待共享的医疗数据,医疗机构将按待共享的搜索方指定的要求生成访问结构T,并结合公钥对待共享的医疗数据D进行加密保护,生成密文/>(2) For the medical data to be shared, the medical institution will generate the access structure T according to the requirements specified by the search party to be shared, and combine it with the public key Encrypt and protect the shared medical data D to generate ciphertext/> ;

其中为加密函数;医疗机构通过共识将生成的密文/>上传到数据传输链。in is an encryption function; the medical institution generates the ciphertext through consensus/> Upload to the data transfer chain.

(3)对于属性加密而言,不同的访问结构对应不同的属性,只有属性S满足访问结构T才能进行解密。对于由访问结构T生成的密文,各搜索方将自身拥有的属性S和主密钥/>结合生成用于解密的私钥/>(3) For attribute encryption, different access structures correspond to different attributes. Only when attribute S satisfies access structure T can decryption be performed. For the ciphertext generated by access structure T , each search party will own the attribute S and the master key/> Combined to generate a private key for decryption/> ;

其中为密钥生成函数。in is the key generation function.

(4)对于满足属性条件的搜索方,可以用生成的私钥对加密的医疗数据进行解密,获得满足搜索条件的医疗数据,完成医疗数据的安全共享。当存在多个搜索方时,只要拥有满足访问结构的属性即可解密密文,避免多次加密带来的空间占用和效率降低;(4) For search parties that meet the attribute conditions, the generated private key can be used to decrypt the encrypted medical data, obtain the medical data that meets the search conditions, and complete the secure sharing of medical data. When there are multiple search parties, as long as they have the attributes that meet the access structure, they can decrypt the ciphertext, avoiding the space occupation and efficiency reduction caused by multiple encryption;

其中为解密函数。in is the decryption function.

搜索方可以为第三方机构或者其他医疗机构。第三方机构在医疗区块链系统中属于半可信节点,考虑到其不稳定性,数据传输链的共识算法采用实用拜占庭容错算法(Practical Byzantine Fault Tolerance,PBFT)。PBFT算法在保证可用性和安全性的前提下,提供了(n-1)/3的容错性,即在含有n个节点的区块链系统中,可以容忍不超过(n-1)/3数量的节点为恶意节点,极大地提高了共识算法的容错率,抵挡恶意攻击,保护系统一致性。The search party can be a third-party organization or other medical institution. The third-party organization is a semi-trusted node in the medical blockchain system. Considering its instability, the consensus algorithm of the data transmission chain adopts the Practical Byzantine Fault Tolerance (PBFT). The PBFT algorithm provides (n-1)/3 fault tolerance while ensuring availability and security. That is, in a blockchain system with n nodes, no more than (n-1)/3 nodes can be tolerated as malicious nodes, which greatly improves the fault tolerance rate of the consensus algorithm, resists malicious attacks, and protects system consistency.

本发明还提供一种融合区块链与隐私求交技术的医疗数据共享系统,如图3所示,该系统主要包括以下五个模块:The present invention also provides a medical data sharing system integrating blockchain and privacy protection technology, as shown in FIG3 , the system mainly includes the following five modules:

区块链框架模块:建立医疗区块链系统,提供底层支持、分配并确认区块链中各个节点的功能与地位,为医疗数据的交换提供可信任的安全环境与隐私保护;具体地,建立的医疗区块链系统包括两条独立并行的区块链:摘要搜索链与数据传输链;Blockchain framework module: Establish a medical blockchain system, provide underlying support, allocate and confirm the functions and status of each node in the blockchain, and provide a trusted security environment and privacy protection for the exchange of medical data; specifically, the established medical blockchain system includes two independent and parallel blockchains: summary search chain and data transmission chain;

数据摘要上传模块:将医疗机构储存在本地的医疗数据提取为摘要形式,并将医疗数据摘要通过共识机制上传到摘要搜索链;Data summary upload module: extracts the medical data stored locally by medical institutions into summary form, and uploads the medical data summary to the summary search chain through a consensus mechanism;

数据摘要搜索与筛选模块:对摘要搜索链中的医疗数据摘要进行搜索,根据搜索方提供的搜索条件对医疗数据摘要进行筛选,并将筛选结构返回给医疗数据所属的医疗机构;Data summary search and screening module: Search the medical data summaries in the summary search chain, screen the medical data summaries according to the search conditions provided by the searcher, and return the screening structure to the medical institution to which the medical data belongs;

数据摘要匹配与对齐模块:对筛选出的医疗数据摘要基于隐私求交技术进行多家医疗机构的匹配与对齐,并将对齐结果返回给医疗数据所属的医疗机构;Data summary matching and alignment module: matches and aligns the screened medical data summaries across multiple medical institutions based on privacy intersection technology, and returns the alignment results to the medical institution to which the medical data belongs;

数据传递与共享模块:收到筛选或对齐结果的医疗机构若同意共享医疗数据,则通过基于密文策略的属性加密方法将待共享医疗数据上传到数据传输链,由满足属性条件的搜索方解密获取。Data transmission and sharing module: If the medical institution that receives the screening or alignment results agrees to share the medical data, the medical data to be shared will be uploaded to the data transmission chain through an attribute encryption method based on the ciphertext strategy, and will be decrypted and obtained by the search party that meets the attribute conditions.

上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。All relevant contents of each step involved in the above method embodiment can be referred to the functional description of the corresponding functional module, and will not be repeated here.

与前述融合区块链与隐私求交技术的医疗数据共享方法的实施例相对应,本发明还提供了一种融合区块链与隐私求交技术的医疗数据共享设备的实施例。Corresponding to the aforementioned embodiment of the medical data sharing method integrating blockchain and privacy intersection technology, the present invention also provides an embodiment of a medical data sharing device integrating blockchain and privacy intersection technology.

参见图4,本发明实施例提供的一种融合区块链与隐私求交技术的医疗数据共享设备,包括存储器和一个或多个处理器,所述存储器中存储有可执行代码,所述处理器执行所述可执行代码时,用于实现上述实施例中的一种融合区块链与隐私求交技术的医疗数据共享方法。Referring to FIG. 4 , an embodiment of the present invention provides a medical data sharing device that integrates blockchain and privacy intersection technology, including a memory and one or more processors. The memory stores executable code. When the processor executes the executable code, it is used to implement a medical data sharing method that integrates blockchain and privacy intersection technology in the above embodiment.

本发明提供的一种融合区块链与隐私求交技术的医疗数据共享设备的实施例可以应用在任意具备数据处理能力的设备上,该任意具备数据处理能力的设备可以为诸如计算机等设备或装置。设备实施例可以通过软件实现,也可以通过硬件或者软硬件结合的方式实现。以软件实现为例,作为一个逻辑意义上的设备,是通过其所在任意具备数据处理能力的设备的处理器将非易失性存储器中对应的计算机程序指令读取到内存中运行形成的。从硬件层面而言,如图4所示,为本发明提供的一种融合区块链与隐私求交技术的医疗数据共享设备所在任意具备数据处理能力的设备的一种硬件结构图,除了图4所示的处理器、内存、网络接口、以及非易失性存储器之外,实施例中设备所在的任意具备数据处理能力的设备通常根据该任意具备数据处理能力的设备的实际功能,还可以包括其他硬件,对此不再赘述。The embodiment of a medical data sharing device that integrates blockchain and privacy intersection technology provided by the present invention can be applied to any device with data processing capabilities, and the device with data processing capabilities can be a device or apparatus such as a computer. The device embodiment can be implemented by software, or by hardware or a combination of software and hardware. Taking software implementation as an example, as a device in a logical sense, it is formed by the processor of any device with data processing capabilities in which it is located to read the corresponding computer program instructions in the non-volatile memory into the memory and run it. From the hardware level, as shown in Figure 4, it is a hardware structure diagram of any device with data processing capabilities where a medical data sharing device that integrates blockchain and privacy intersection technology provided by the present invention is located. In addition to the processor, memory, network interface, and non-volatile memory shown in Figure 4, any device with data processing capabilities where the device in the embodiment is located can also include other hardware according to the actual function of the device with data processing capabilities, which will not be repeated.

上述设备中各个单元的功能和作用的实现过程具体详见上述方法中对应步骤的实现过程,在此不再赘述。The implementation process of the functions and effects of each unit in the above-mentioned device is specifically described in the implementation process of the corresponding steps in the above-mentioned method, and will not be repeated here.

对于设备实施例而言,由于其基本对应于方法实施例,所以相关之处参见方法实施例的部分说明即可。以上所描述的设备实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本发明方案的目的。本领域普通技术人员在不付出创造性劳动的情况下,即可以理解并实施。As for the device embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment. The device embodiment described above is only schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of the present invention. A person of ordinary skill in the art can understand and implement it without paying creative labor.

本发明实施例还提供一种计算机可读存储介质,其上存储有程序,该程序被处理器执行时,实现上述实施例中的一种融合区块链与隐私求交技术的医疗数据共享方法。An embodiment of the present invention also provides a computer-readable storage medium on which a program is stored. When the program is executed by a processor, a medical data sharing method that integrates blockchain and privacy-enhancing technology in the above embodiment is implemented.

所述计算机可读存储介质可以是前述任一实施例所述的任意具备数据处理能力的设备的内部存储单元,例如硬盘或内存。所述计算机可读存储介质也可以是任意具备数据处理能力的设备的外部存储设备,例如所述设备上配备的插接式硬盘、智能存储卡(Smart Media Card,SMC)、SD卡、闪存卡(Flash Card)等。进一步的,所述计算机可读存储介质还可以既包括任意具备数据处理能力的设备的内部存储单元也包括外部存储设备。所述计算机可读存储介质用于存储所述计算机程序以及所述任意具备数据处理能力的设备所需的其他程序和数据,还可以用于暂时地存储已经输出或者将要输出的数据。The computer-readable storage medium may be an internal storage unit of any device with data processing capability described in any of the aforementioned embodiments, such as a hard disk or a memory. The computer-readable storage medium may also be an external storage device of any device with data processing capability, such as a plug-in hard disk, a smart media card (SMC), an SD card, a flash card, etc. equipped on the device. Furthermore, the computer-readable storage medium may also include both an internal storage unit and an external storage device of any device with data processing capability. The computer-readable storage medium is used to store the computer program and other programs and data required by any device with data processing capability, and may also be used to temporarily store data that has been output or is to be output.

上述实施例用来解释说明本发明,而不是对本发明进行限制,在本发明的精神和权利要求的保护范围内,对本发明作出的任何修改和改变,都落入本发明的保护范围。The above embodiments are used to illustrate the present invention rather than to limit the present invention. Any modification and change made to the present invention within the spirit of the present invention and the protection scope of the claims shall fall within the protection scope of the present invention.

Claims (4)

1.一种融合区块链与隐私求交技术的医疗数据共享方法,其特征在于,包括:1. A medical data sharing method integrating blockchain and privacy protection technology, characterized by comprising: 建立医疗区块链系统,所述医疗区块链系统包括两条独立并行的区块链:摘要搜索链与数据传输链;Establishing a medical blockchain system, the medical blockchain system comprising two independent and parallel blockchains: a summary search chain and a data transmission chain; 所述摘要搜索链由医疗机构与监管机构节点组成,储存医疗机构上传的医疗数据摘要,并由监管平台作为搜索功能的外部客户端;The summary search chain is composed of nodes of medical institutions and regulatory agencies, storing medical data summaries uploaded by medical institutions, and the regulatory platform serves as an external client for the search function; 所述数据传输链由医疗机构、监管机构与第三方机构节点组成,储存医疗机构筛选、对齐后上传的医疗数据,由监管机构负责第三方机构的权限管理,完成医疗机构之间、医疗机构与第三方机构之间的数据共享;The data transmission chain is composed of nodes of medical institutions, regulatory agencies and third-party institutions, storing medical data uploaded after screening and alignment by medical institutions. The regulatory agency is responsible for the authority management of third-party institutions, and completes data sharing between medical institutions and between medical institutions and third-party institutions. 将医疗机构储存在本地的医疗数据提取为摘要形式,并将医疗数据摘要通过共识机制上传到摘要搜索链;所述医疗数据摘要的上传具体为:将医疗机构储存在本地的医疗数据提取为约定好的摘要形式,由医疗机构定期创建区块并按时间顺序相连,创建的区块通过各医疗机构节点之间的共识完成医疗数据摘要的上链;Extract the medical data stored locally by the medical institution into a summary form, and upload the medical data summary to the summary search chain through a consensus mechanism; the specific uploading of the medical data summary is: extract the medical data stored locally by the medical institution into an agreed summary form, and the medical institution regularly creates blocks and connects them in chronological order, and the created blocks complete the upload of the medical data summary to the chain through the consensus between the nodes of each medical institution; 对摘要搜索链中的医疗数据摘要进行搜索,根据搜索方提供的搜索条件对医疗数据摘要进行筛选,并将筛选结构返回给医疗数据所属的医疗机构;所述医疗数据摘要的搜索与筛选具体为:Search the medical data abstracts in the abstract search chain, filter the medical data abstracts according to the search conditions provided by the search party, and return the filter structure to the medical institution to which the medical data belongs; the search and filter of the medical data abstracts are specifically as follows: 医疗机构根据安全等级确定安全参数,生成自身的公钥和私钥;Medical institutions determine security parameters based on security levels and generate their own public and private keys; 医疗机构通过自身的公钥对待上链的医疗数据摘要进行加密生成密文,对所有医疗数据摘要的密文均进行上链;Medical institutions use their own public keys to encrypt the medical data summaries to be uploaded to the chain to generate ciphertext, and upload the ciphertext of all medical data summaries to the chain; 当搜索方通过监管机构提供的中间平台对医疗数据摘要进行搜索时,监管机构将搜索方的搜索条件发送给摘要搜索链上所有参与共识的医疗机构;When the searcher searches for medical data summaries through the intermediary platform provided by the regulatory agency, the regulatory agency sends the searcher's search conditions to all medical institutions participating in the consensus on the summary search chain; 各医疗机构根据搜索条件通过自身的私钥生成陷门;Each medical institution generates a trapdoor using its own private key based on the search criteria; 智能合约根据医疗机构上链的陷门,对储存在链上的医疗机构的所有加密摘要进行搜索,对比陷门和每个加密摘要,筛选出符合搜索条件的加密摘要;The smart contract searches all encrypted summaries of medical institutions stored on the chain according to the trapdoors uploaded by the medical institutions, compares the trapdoors with each encrypted summary, and selects the encrypted summaries that meet the search criteria; 智能合约将筛选出的加密摘要通知其所属的医疗机构,医疗机构对加密摘要通过自身的私钥进行解密,得到解密后的医疗数据摘要;The smart contract notifies the medical institution to which the selected encrypted summary belongs. The medical institution decrypts the encrypted summary using its own private key to obtain the decrypted medical data summary. 对筛选出的医疗数据摘要基于隐私求交技术进行多家医疗机构的匹配与对齐,并将对齐结果返回给医疗数据所属的医疗机构;所述医疗数据摘要的匹配与对齐采用基于Diffie-Hellman密钥交换算法的隐私求交技术,通过可交换加密函数实现两次交换加密顺序的加密操作,使得参与双方对于交集数据得到完全相同的不可逆密文;The selected medical data summaries are matched and aligned with multiple medical institutions based on the privacy intersection technology, and the alignment results are returned to the medical institution to which the medical data belongs; the matching and alignment of the medical data summaries adopts the privacy intersection technology based on the Diffie-Hellman key exchange algorithm, and the encryption operation of exchanging the encryption order twice is realized through the exchangeable encryption function, so that the participating parties obtain exactly the same irreversible ciphertext for the intersection data; 收到筛选或对齐结果的医疗机构若同意共享医疗数据,则通过基于密文策略的属性加密方法将待共享医疗数据上传到数据传输链,由满足属性条件的搜索方解密获取;所述医疗数据的共享具体为:If the medical institution that receives the screening or alignment results agrees to share the medical data, the medical data to be shared will be uploaded to the data transmission chain through an attribute encryption method based on a ciphertext strategy, and will be decrypted and obtained by the search party that meets the attribute conditions; the sharing of the medical data is specifically as follows: 参与数据共享的医疗机构根据安全参数生成公钥和主密钥;Medical institutions participating in data sharing generate public keys and master keys based on security parameters; 对于待共享的医疗数据,医疗机构按照待共享的搜索方指定的要求生成访问结构,并结合公钥对待共享的医疗数据进行加密保护生成密文,医疗机构通过共识将生成的密文上传到数据传输链;For the medical data to be shared, the medical institution generates an access structure according to the requirements specified by the search party to be shared, and encrypts the medical data to be shared with the public key to generate ciphertext. The medical institution uploads the generated ciphertext to the data transmission chain through consensus; 各搜索方将自身拥有的属性和主密钥结合生成用于解密的私钥,对于满足属性条件的搜索方,使用生成的私钥对加密的医疗数据进行解密,获得满足搜索条件的医疗数据,完成医疗数据的安全共享。Each search party combines its own attributes and the master key to generate a private key for decryption. For search parties that meet the attribute conditions, the generated private key is used to decrypt the encrypted medical data to obtain medical data that meets the search conditions, thereby completing the secure sharing of medical data. 2.根据权利要求1所述的融合区块链与隐私求交技术的医疗数据共享方法,其特征在于,对于待进行医疗数据摘要匹配与对齐的任意两家医疗机构,分别记为A和B,匹配与对齐流程如下:2. According to the medical data sharing method integrating blockchain and privacy intersection technology as described in claim 1, it is characterized in that for any two medical institutions to be matched and aligned with medical data summaries, they are respectively denoted as A and B, and the matching and alignment process is as follows: 对于医疗机构A,选择随机数α作为私钥,对每个筛选出的医疗数据摘要进行哈希操作,使用私钥α对哈希值进行加密生成密文U A 上链,将密文U A 通过监管机构节点发送给医疗机构B;For medical institution A, a random number α is selected as the private key, and a hash operation is performed on each screened medical data summary. The private key α is used to encrypt the hash value to generate the ciphertext U A on the chain, and the ciphertext U A is sent to medical institution B through the regulatory agency node; 对于医疗机构B,选择随机数β作为私钥,对每个筛选出的医疗数据摘要进行哈希操作,使用私钥β对哈希值进行加密生成密文U B 上链,将密文U B 通过监管机构节点发送给医疗机构A;For medical institution B, a random number β is selected as the private key, and a hash operation is performed on each screened medical data summary. The private key β is used to encrypt the hash value to generate the ciphertext U B on the chain, and the ciphertext U B is sent to medical institution A through the regulatory agency node; 医疗机构B对于接收到的密文U A 使用私钥β进行二次加密生成密文U AB 并再次上链;医疗机构A对于接收到的密文U B 使用私钥α进行二次加密生成密文U BA 并再次上链;Medical institution B uses private key β to re-encrypt the received ciphertext U A to generate ciphertext U AB and upload it to the chain again; medical institution A uses private key α to re-encrypt the received ciphertext U B to generate ciphertext U BA and upload it to the chain again; 通过部署在摘要搜索链上的智能合约比较密文U BA U AB U BA U AB 中一致的医疗数据摘要即为交集数据U =U BA U AB The ciphertexts U BA and U AB are compared through the smart contract deployed on the summary search chain. The consistent medical data summaries in U BA and U AB are the intersection data U = U BA U AB . 3.一种利用权利要求1或2所述方法实现的融合区块链与隐私求交技术的医疗数据共享系统,其特征在于,包括:3. A medical data sharing system integrating blockchain and privacy-enforcing technology implemented by the method of claim 1 or 2, characterized in that it includes: 区块链框架模块:建立医疗区块链系统,所述医疗区块链系统包括两条独立并行的区块链:摘要搜索链与数据传输链;Blockchain framework module: establish a medical blockchain system, which includes two independent and parallel blockchains: a summary search chain and a data transmission chain; 数据摘要上传模块:将医疗机构储存在本地的医疗数据提取为摘要形式,并将医疗数据摘要通过共识机制上传到摘要搜索链;Data summary upload module: extracts the medical data stored locally by medical institutions into summary form, and uploads the medical data summary to the summary search chain through a consensus mechanism; 数据摘要搜索与筛选模块:对摘要搜索链中的医疗数据摘要进行搜索,根据搜索方提供的搜索条件对医疗数据摘要进行筛选,并将筛选结构返回给医疗数据所属的医疗机构;Data summary search and screening module: Search the medical data summaries in the summary search chain, screen the medical data summaries according to the search conditions provided by the searcher, and return the screening structure to the medical institution to which the medical data belongs; 数据摘要匹配与对齐模块:对筛选出的医疗数据摘要基于隐私求交技术进行多家医疗机构的匹配与对齐,并将对齐结果返回给医疗数据所属的医疗机构;Data summary matching and alignment module: matches and aligns the selected medical data summaries across multiple medical institutions based on privacy intersection technology, and returns the alignment results to the medical institution to which the medical data belongs; 数据传递与共享模块:收到筛选或对齐结果的医疗机构若同意共享医疗数据,则通过基于密文策略的属性加密方法将待共享医疗数据上传到数据传输链,由满足属性条件的搜索方解密获取。Data transmission and sharing module: If the medical institution that receives the screening or alignment results agrees to share the medical data, the medical data to be shared will be uploaded to the data transmission chain through an attribute encryption method based on the ciphertext strategy, and will be decrypted and obtained by the search party that meets the attribute conditions. 4.一种融合区块链与隐私求交技术的医疗数据共享设备,包括存储器和一个或多个处理器,所述存储器中存储有可执行代码,其特征在于,所述处理器执行所述可执行代码时,实现如权利要求1或2所述的融合区块链与隐私求交技术的医疗数据共享方法。4. A medical data sharing device that integrates blockchain and privacy intersection technology, comprising a memory and one or more processors, wherein the memory stores executable code, and wherein when the processor executes the executable code, the medical data sharing method that integrates blockchain and privacy intersection technology as described in claim 1 or 2 is implemented.
CN202410052287.6A 2024-01-15 2024-01-15 Medical data sharing method and system integrating blockchain and privacy protection technology Active CN117577248B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410052287.6A CN117577248B (en) 2024-01-15 2024-01-15 Medical data sharing method and system integrating blockchain and privacy protection technology

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410052287.6A CN117577248B (en) 2024-01-15 2024-01-15 Medical data sharing method and system integrating blockchain and privacy protection technology

Publications (2)

Publication Number Publication Date
CN117577248A CN117577248A (en) 2024-02-20
CN117577248B true CN117577248B (en) 2024-04-05

Family

ID=89886493

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410052287.6A Active CN117577248B (en) 2024-01-15 2024-01-15 Medical data sharing method and system integrating blockchain and privacy protection technology

Country Status (1)

Country Link
CN (1) CN117577248B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118395490A (en) * 2024-04-22 2024-07-26 浙江大学 Data sharing and privacy intersection method and device based on blockchain

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113553615A (en) * 2021-07-07 2021-10-26 深圳前海新心数字科技有限公司 A Matching Query Method for Private Data Sharing System
CN116032647A (en) * 2023-01-11 2023-04-28 新晨科技股份有限公司 Method, device and storage medium for realizing high-frequency privacy query on blockchain
WO2023098294A1 (en) * 2021-12-02 2023-06-08 深圳前海微众银行股份有限公司 Heterogeneous data processing method and apparatus, and electronic device
CN116633522A (en) * 2023-05-30 2023-08-22 同济大学 Two-party privacy intersection method and system based on blockchain
CN116702209A (en) * 2023-06-25 2023-09-05 重庆邮电大学 Verifiable privacy protection set intersection method for medical data
CN116842557A (en) * 2023-04-07 2023-10-03 浙江大学 Image supervision platform and method based on privacy intersection and blockchain
CN117035571A (en) * 2023-08-16 2023-11-10 南京鼓楼医院 Multi-center hospital scientific research data modeling method based on federal learning

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113553615A (en) * 2021-07-07 2021-10-26 深圳前海新心数字科技有限公司 A Matching Query Method for Private Data Sharing System
WO2023098294A1 (en) * 2021-12-02 2023-06-08 深圳前海微众银行股份有限公司 Heterogeneous data processing method and apparatus, and electronic device
CN116032647A (en) * 2023-01-11 2023-04-28 新晨科技股份有限公司 Method, device and storage medium for realizing high-frequency privacy query on blockchain
CN116842557A (en) * 2023-04-07 2023-10-03 浙江大学 Image supervision platform and method based on privacy intersection and blockchain
CN116633522A (en) * 2023-05-30 2023-08-22 同济大学 Two-party privacy intersection method and system based on blockchain
CN116702209A (en) * 2023-06-25 2023-09-05 重庆邮电大学 Verifiable privacy protection set intersection method for medical data
CN117035571A (en) * 2023-08-16 2023-11-10 南京鼓楼医院 Multi-center hospital scientific research data modeling method based on federal learning

Also Published As

Publication number Publication date
CN117577248A (en) 2024-02-20

Similar Documents

Publication Publication Date Title
WO2021179661A1 (en) Cross-blockchain data mutual storage method, apparatus and device, and storage medium
Rai PcBEHR: patient-controlled blockchain enabled electronic health records for healthcare 4.0
Fan et al. TraceChain: A blockchain‐based scheme to protect data confidentiality and traceability
Reen et al. Decentralized patient centric e-health record management system using blockchain and IPFS
CN109409100B (en) Information storage and sharing platform applied to medical data
CN110299195A (en) The electronic health record shared system and application method with secret protection based on alliance's chain
CN112307501B (en) Big data system based on block chain technology, storage method and using method
CN114338038B (en) Storage system and inadvertent transmission method for blockchain data confidential query
CN112231756A (en) FL-EM-GMM medical user privacy protection method and system
CN113764060B (en) A medical data management system and patient-authorized medical record sharing method based on dual blockchains
CN111916217A (en) Blockchain-based medical data management method, system, storage medium and terminal
Ma et al. Integrating blockchain and ZK-ROLLUP for efficient healthcare data privacy protection system via IPFS
CN114553582A (en) Electronic medical record sharing method based on national cryptographic algorithm and IPFS
CN111680306B (en) Cooperative access control revocation method based on attribute
Yu et al. Blockchain-based multi-role healthcare data sharing system
CN117577248B (en) Medical data sharing method and system integrating blockchain and privacy protection technology
CN114880715A (en) Power data security sharing method and system based on homomorphic encryption intelligent contract
Chen et al. A privacy protection method based on key encapsulation mechanism in medical blockchain
Wu et al. Electronic health records sharing based on consortium blockchain
Liu et al. Blockchain-based medical data storage and sharing system
Saraswat et al. Health chain-block chain based electronic healthcare record system with access and permission management
Wen et al. A Blockchain‐Based Privacy Preservation Scheme in Mobile Medical
CN113486082B (en) Outsourcing data access control system based on block chain
CN114911795A (en) Medical data processing method and application
Lu et al. Network data security sharing system based on blockchain

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant