Secure data exchange method and device based on block chain
By publishing data description information in the blockchain repository and performing multi-layer encryption processing, combined with the decentralized characteristics of blockchain, the problems of poor data security and low efficiency in the existing technology are solved, and data efficiency is achieved. Secure exchange and sharing.
Patent Information
- Application Number
- CN202411113736.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-14
- Publication Date
- 2024-12-03
AI Technical Summary
The existing blockchain-based data exchange methods have shortcomings in data security and efficiency, especially the problems of difficult tampering and low efficiency in data exchange.
By publishing data description information in the blockchain repository, AES, TripleDES and Blowfish are encrypted according to the importance of data, and using the decentralized characteristics of blockchain for data storage and access management, ensuring that data is in the exchange process security and traceability in
Improve the security and efficiency of data exchange, ensure the immutability and traceability of data, prevent illegal access, and simplify the authentication process.
Smart Images

Figure CN119071041A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data exchange, and more specifically to a secure data exchange method and device based on blockchain. Background Art
[0002] We have entered the era of big data. In addition to data collection and analysis, data exchange and sharing have become increasingly important. At present, various fields usually have established databases with detailed data, but the databases of various industries and even different units in the same industry are often customized according to their own business needs, which leads to huge differences in system environment and data platform. At the beginning of construction, there is usually a lack of design for data exchange and sharing, forming a "barrier" to data exchange.
[0003] Setting up a data center for data exchange can be applied to a wider range than the point-to-point model, but all data needs to be exchanged through the data center, which makes the construction and maintenance costs of the data center high, and the improvement of data exchange efficiency is also relatively limited.
[0004] Blockchain technology is an emerging technology in the field of information technology and the foundation for building the value Internet. It is an information technology that integrates multiple technologies including distributed data storage, peer-to-peer networks, and cryptographic technology. It has the characteristics of decentralization, openness, and autonomy. Its decentralized trust nature provides us with a feasible solution for the fair exchange of data. At the same time, its distributed storage and data tamper-resistant characteristics are also very suitable for designing secure data sharing solutions.
[0005] In the prior art, such as patent No. 202110819885.8, a multimodal transport data exchange system and method based on blockchain is disclosed, which uses the public key of the recipient for encryption, and the recipient uses the private key to decrypt the data when receiving the data, so as to read the data safely; however, this method requires the exchange request end to encrypt the public key of the receiving end and the data to be exchanged with a secret key and send them to the exchange server. The data exchange server encrypts the exchange data with the public key of the receiving end and sends it to the data receiving end. After receiving the data, the data receiving end uses its own private key to decrypt the data and obtain the exchanged data. However, in order to ensure the security of the data during the data exchange process, the data sender transmits the data multiple times to the exchange server, resulting in a decrease in the efficiency of the data exchange work. In addition, the security of the encrypted files in the data exchange process of different importance is not highly guaranteed. After the data exchange process is tampered with, it is impossible to trace which link has been tampered with.
[0006] Therefore, how to provide a secure data exchange method and device based on blockchain is an urgent problem that technicians in this field need to solve. Summary of the invention
[0007] The present invention aims to solve the problems of poor data security and low efficiency in the existing data exchange process, and proposes a secure data exchange method and device based on blockchain.
[0008] The present invention provides a blockchain-based secure data exchange method, comprising:
[0009] The sending end receives the target data and publishes the description information of the target data to the blockchain repository;
[0010] The sender encrypts the target data, generates ciphertext information and stores it in the blockchain repository;
[0011] The access end obtains access rights to the target data from the blockchain repository, and accesses the ciphertext information of the corresponding target data in the blockchain database according to the access rights;
[0012] The access end decrypts the ciphertext information to achieve data exchange.
[0013] Preferably, the description information includes: importance information of the target data and access permission information of the target data.
[0014] Preferably, the sending end encrypts the target data, generates ciphertext information and stores it in the blockchain repository, including:
[0015] According to the importance information of the target data, the target data is divided into first-category sub-target data, second-category sub-target data and third-category sub-target data;
[0016] Encrypt the first type of sub-target data according to the AES encryption algorithm to generate the first type of ciphertext information;
[0017] The second type of sub-target data is encrypted according to the TripleDES algorithm to generate the second type of ciphertext information;
[0018] The third type of sub-target data is encrypted according to the Blowfish algorithm to generate the third type of ciphertext information;
[0019] The first type of ciphertext information, the second type of ciphertext information, and the third type of ciphertext information are stored in the blockchain repository.
[0020] Preferably, the access terminal obtains access rights to the target data from the blockchain repository, and accesses the ciphertext information of the corresponding target data in the blockchain database according to the access rights, including:
[0021] The access end issues an access request for target data to the blockchain repository;
[0022] The blockchain infrastructure obtains the access request from the blockchain repository, approves the access request, and publishes access permission approval information to the blockchain repository;
[0023] The access end obtains the access permission reply information from the blockchain repository, and accesses the ciphertext information of the target data in response according to the access permission reply information result.
[0024] Preferably, the blockchain infrastructure obtains the access request from the blockchain repository, approves the access request, and publishes access permission approval information to the blockchain repository, including:
[0025] The blockchain infrastructure obtains the access request from the blockchain repository and authenticates the access request;
[0026] According to the authentication result, the security of the access request is verified;
[0027] Approve access requests based on their security;
[0028] According to the approval result and access request, the target data is matched on the access end to obtain the access permission approval information;
[0029] The access permission approval information is sent to the blockchain repository.
[0030] Preferably, the access end decrypts the ciphertext information, including:
[0031] The access terminal determines whether the ciphertext information is the first type of ciphertext information, the second type of ciphertext information, or the third type of ciphertext information, and performs decryption processing according to the corresponding decryption rules of the first type of ciphertext information, the second type of ciphertext information, and the third type of ciphertext information.
[0032] An electronic device comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements a blockchain-based secure data exchange method when executing the program.
[0033] It can be seen from the above technical solutions that, compared with the prior art, the present invention discloses a secure data exchange method and device based on blockchain, builds a decentralized data exchange system based on blockchain, realizes efficient data exchange and sharing, and effectively protects the security of exchanged data. The specific beneficial effects are:
[0034] (1) Data is divided according to its importance and encrypted and decrypted using different methods, which ensures the security of exchanged data to a certain extent and improves the traceability of the converted target data;
[0035] (2) The tamper-proof feature of blockchain is used to make the importance information and access permission information stored in the blockchain repository tamper-proof, thus ensuring data security;
[0036] (3) The access request sent by the access end is approved through the blockchain to prevent the access end of illegal users from intercepting data, ensuring the security of data exchange. At the same time, it simplifies the process of verifying the identity of the access end and improves the efficiency of data exchange. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] Figure 1 A flowchart of a secure data exchange method based on blockchain provided by the present invention. DETAILED DESCRIPTION
[0038] The following will be combined with the accompanying drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work belong to the scope of protection of the present invention. It should be noted that the embodiments of the present invention and the features in the embodiments can be combined with each other without conflict.
[0039] Specific implementation method 1: refer to Figure 1 Specifically describing this embodiment, a secure data exchange method based on blockchain described in this embodiment includes:
[0040] The sender receives the target data and publishes the description information of the target data to the blockchain repository;
[0041] The sender encrypts the target data, generates ciphertext information and stores it in the blockchain repository;
[0042] The access end obtains the access rights of the target data from the blockchain repository, and accesses the ciphertext information of the corresponding target data in the blockchain database according to the access rights;
[0043] The access end decrypts the ciphertext information to achieve data exchange.
[0044] In a specific embodiment, the description information includes: importance information of the target data and access permission information of the target data.
[0045] Specifically, the access permission information includes the access permission relationship between the sending end and the access end;
[0046] More specifically, it also includes identity authentication information of the trust certificate.
[0047] In a specific embodiment, the sending end encrypts the target data, generates ciphertext information and stores it in the blockchain repository, including:
[0048] According to the importance information of the target data, the target data is divided into first-category sub-target data, second-category sub-target data and third-category sub-target data;
[0049] Encrypt the first type of sub-target data according to the AES encryption algorithm to generate the first type of ciphertext information;
[0050] The second type of sub-target data is encrypted according to the TripleDES algorithm to generate the second type of ciphertext information;
[0051] The third type of sub-target data is encrypted according to the Blowfish algorithm to generate the third type of ciphertext information;
[0052] The first type of ciphertext information, the second type of ciphertext information, and the third type of ciphertext information are stored in the blockchain repository.
[0053] Specifically, the first type of sub-target data is the data with the highest degree of importance;
[0054] The Advanced Encryption Standard (AES) is a trusted standard algorithm used by the U.S. government and other organizations. Although the 128-bit form is very secure, AES also uses 192-bit and 256-bit keys for very demanding encryption purposes. AES is recognized as being strong enough to withstand all attacks except brute force. Many Internet security experts believe that AES will eventually be the preferred standard for encrypting data in the private sector. Therefore, the most important first-class sub-target data is encrypted and decrypted according to the Advanced Encryption Standard (AES) to ensure data security.
[0055] Specifically, the second type of sub-target data is data such as UNIX passwords and ATM PINs. According to TripleDES, the DES algorithm is applied three times to each data block, which is usually used to encrypt UNIX passwords and ATM PINs.
[0056] Specifically, the third type of sub-target data is the most widely used surface data with low importance and high application;
[0057] Blowfish is another algorithm designed to replace DES. This symmetric tool divides the message into 64-bit blocks and encrypts them individually. Blowfish has a reputation for speed, flexibility, and indestructibility. Therefore, encrypting and decrypting the third sub-target data according to Blowfish can improve the response speed while ensuring data security.
[0058] In a specific embodiment, the access end obtains access rights to the target data from the blockchain repository, and accesses the ciphertext information of the corresponding target data in the blockchain database according to the access rights, including:
[0059] The access end issues an access request for the target data to the blockchain repository;
[0060] The blockchain infrastructure obtains the access request from the blockchain repository, approves the access request, and publishes the access permission approval information to the blockchain repository;
[0061] The access end obtains access permission approval information from the blockchain repository, and accesses the ciphertext information of the target data in response based on the access permission approval information result.
[0062] Specifically, the blockchain infrastructure is a node-trusted blockchain and customizable software and hardware resources, specifications and services supporting the blockchain, which are built based on blockchain construction tools, PKI systems and customized rules, and are used to support the data security sharing and exchange platform system. Among them, the blockchain infrastructure is used to approve access requests sent by the access end;
[0063] In a specific embodiment, the blockchain infrastructure obtains an access request from the blockchain repository, approves the access request, and publishes the access permission approval information to the blockchain repository, including:
[0064] The blockchain infrastructure obtains the access request from the blockchain repository and authenticates the access request;
[0065] According to the authentication result, the security of the access request is verified;
[0066] Approve access requests based on their security;
[0067] According to the approval result and access request, the target data is matched on the access end to obtain the access permission approval information;
[0068] Send access permission approval information to the blockchain repository.
[0069] Specifically, the trust certificate is authenticated based on the access permission information of the target data stored in the blockchain database. If the authentication is successful, the sender of the access request will be approved for the accessible data at the same time, so that the access end can access the target data information within the permission range.
[0070] Specifically, the blockchain infrastructure receives the random number a of the access request from the access end and generates a random number b;
[0071] Determine the data relationship between random number a and random number b based on the access permission relationship between the sending end and the access end;
[0072] Receive the random number a, signature value and the access end's own certificate;
[0073] Based on the identity authentication information of the trust certificate pre-stored in the blockchain database, the access request of the access terminal is approved.
[0074] In a specific embodiment, the access end performs decryption processing on the ciphertext information, including:
[0075] The access end determines whether the ciphertext information is the first type of ciphertext information, the second type of ciphertext information, or the third type of ciphertext information, and performs decryption processing according to the corresponding decryption rules of the first type of ciphertext information, the second type of ciphertext information, and the third type of ciphertext information.
[0076] Specific implementation method 2: An electronic device described in this implementation method includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and is characterized in that a blockchain-based secure data exchange method is implemented when the processor executes the program.
[0077] It can be seen from the above technical solutions that, compared with the prior art, the present invention discloses a secure data exchange method and device based on blockchain, builds a distributed data exchange system based on blockchain, realizes efficient data exchange and sharing, and effectively protects the security of exchanged data. The specific beneficial effects are:
[0078] (1) Data is divided according to its importance and encrypted and decrypted using different methods, which ensures the security of exchanged data to a certain extent and improves the traceability of the converted target data;
[0079] (2) The tamper-proof feature of blockchain is used to make the importance information and access permission information stored in the blockchain repository tamper-proof, thus ensuring data security;
[0080] (3) The access request sent by the access end is approved through the blockchain to prevent the access end of illegal users from intercepting data, ensuring the security of data exchange. At the same time, it simplifies the process of verifying the identity of the access end and improves the efficiency of data exchange.
[0081] Although the present invention is described herein with reference to specific embodiments, it should be understood that these embodiments are merely examples of the principles and applications of the present invention. It should therefore be understood that many modifications may be made to the exemplary embodiments and that other arrangements may be devised without departing from the spirit and scope of the present invention as defined by the appended claims. It should be understood that the various dependent claims and features described herein may be combined in a manner different from that described in the original claims. It should also be understood that the features described in conjunction with a single embodiment may be used in other described embodiments.
Claims
1. A secure data exchange method based on blockchain, characterized in that: include: The sending end receives the target data and publishes the description information of the target data to the blockchain repository; The sender encrypts the target data, generates ciphertext information and stores it in the blockchain repository; The access end obtains access rights to the target data from the blockchain repository, and accesses the ciphertext information of the corresponding target data in the blockchain database according to the access rights; The access end decrypts the ciphertext information to achieve data exchange.
2. A blockchain-based secure data exchange method according to claim 1, characterized in that: The description information includes: importance information of the target data and access permission information of the target data.
3. A blockchain-based secure data exchange method according to claim 2, characterized in that: The sending end encrypts the target data, generates ciphertext information and stores it in the blockchain repository, including: According to the importance information of the target data, the target data is divided into first-category sub-target data, second-category sub-target data and third-category sub-target data; Encrypt the first type of sub-target data according to the AES encryption algorithm to generate the first type of ciphertext information; The second type of sub-target data is encrypted according to the TripleDES algorithm to generate the second type of ciphertext information; The third type of sub-target data is encrypted according to the Blowfish algorithm to generate the third type of ciphertext information; The first type of ciphertext information, the second type of ciphertext information, and the third type of ciphertext information are stored in the blockchain repository.
4. A blockchain-based secure data exchange method according to claim 1, characterized in that: The access end obtains access rights to the target data from the blockchain repository, and accesses the ciphertext information of the corresponding target data in the blockchain database according to the access rights, including: The access end issues an access request for target data to the blockchain repository; The blockchain infrastructure obtains the access request from the blockchain repository, approves the access request, and publishes access permission approval information to the blockchain repository; The access end obtains the access permission reply information from the blockchain repository, and accesses the ciphertext information of the target data in response according to the access permission reply information result.
5. A blockchain-based secure data exchange method according to claim 4, characterized in that: The blockchain infrastructure obtains the access request from the blockchain repository, approves the access request, and publishes access permission approval information to the blockchain repository, including: The blockchain infrastructure obtains the access request from the blockchain repository and authenticates the access request; and identifies the security of the access request based on the authentication result; The access request is approved according to the security of the access request; according to the approval result and the access request, the target data is matched on the access end to obtain the access permission approval information; and the access permission approval information is sent to the blockchain repository.
6. A blockchain-based secure data exchange method according to claim 3, characterized in that: The access end decrypts the ciphertext information, including: The access terminal determines whether the ciphertext information is the first type of ciphertext information, the second type of ciphertext information, or the third type of ciphertext information, and performs decryption processing according to the corresponding decryption rules of the first type of ciphertext information, the second type of ciphertext information, and the third type of ciphertext information.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the blockchain-based secure data exchange method as described in any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Multimodal transport data exchange system and method based on block chain
CN113556393A
