Disclosure of Invention
The technical problem of the invention is solved: the ocean data resource sharing method based on the block chain is characterized in that a brand-new decentralized system architecture and a calculation paradigm are adopted to design an ocean data resource sharing application mode, the ocean data resource sharing block chain is constructed based on a block chain technology, a breakthrough is formed aiming at the existing problems, the free release, the autonomous discovery and the flexible delivery of ocean data are realized, the transaction process is safe, controllable and comprehensive, and the firm guarantee is provided for the safe sharing and transaction of ocean big data.
In order to solve the technical problem, the invention discloses a block chain-based ocean data resource sharing method, which comprises the following steps:
the data owner broadcasts the description information of the ocean data released this time to all nodes on the data storage chain;
all nodes on the chain select whether to participate in the storage competition according to a filtering rule pre-configured by an administrator, the data storage right is distributed, and the competition becomes a data storage party;
after the data storage party generates the data, a piece of storage request information is issued to the data owner according to the address of the data owner contained in the description information issued by the data owner;
after receiving the storage request information, the data owner takes a set number of signature tokens as storage cost, and sends the encrypted marine data to the data storage party in a point-to-point mode through an SHA256 algorithm;
after the data storage side finishes the marine data storage, the description information of the marine data is expanded to be used as block data to be issued to a data storage chain after being used as self address, a new block is generated to be linked to the tail of the block chain, a time stamp is printed, the successful storage is declared after the nodes on the chain achieve consensus, and each user node can directly access the node retrieval block record on the chain to carry out marine data retrieval.
In the above block chain-based marine data resource sharing method, the method further includes:
after the description information of the marine data is obtained, the data requester sends data transaction request information and a signed token of the data price to the data depositor according to the address of the data depositor maintained in the description information;
after receiving the data transaction request information, the data owner sends a transaction authentication request to the data owner;
the data owner returns transaction authentication confirmation information after confirmation;
after receiving the transaction authentication confirmation information, the data storage party sends the ocean data to the data requesting party;
and the data requester decrypts the received ocean data according to the private key of the data requester to obtain the real ocean data.
In the above block chain-based marine data resource sharing method, the method further includes:
the data request party decrypts the received ocean data according to the private key of the data request party to obtain real ocean data, and then the real ocean data is verified;
if the verification is correct, the data owner sends the transaction confirmation information to the data storage party, and the data storage party pays the token to the data owner after receiving the confirmation information.
In the above block chain-based marine data resource sharing method, the method further includes:
after the token payment is successful, the data storage party issues the records of the transaction as block data to a data transaction chain, a new block is generated to be linked to the tail of the block chain, a timestamp is printed, after the nodes on the chain achieve consensus, the transaction is declared to be finished, and each user node can directly access the node retrieval block records on the chain to perform marine data retrieval.
The invention has the following advantages:
(1) the invention discloses a block chain-based ocean data resource sharing method, which adopts a brand-new decentralized system architecture and a calculation paradigm to design an ocean data resource sharing application mode, constructs an ocean data resource sharing block chain based on a block chain technology, forms a breakthrough to the existing problems, realizes free release, autonomous discovery and flexible delivery of ocean data, has safe, controllable and comprehensive supervision in a transaction process, and provides solid guarantee for safe sharing and transaction of ocean big data.
(2) The invention discloses a marine data resource sharing method based on a block chain, which establishes a marine data transaction block chain consisting of all users and agent nodes, stores all transaction information as block records on the transaction chain, forms a marine data storage block chain as an auxiliary chain by all the agent nodes, stores entry information of data as block data on the storage chain, and stores the data on all strong agent nodes in a decentralized storage mode.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the embodiments of the present invention will be described in detail with reference to the accompanying drawings.
Referring to fig. 1, a flowchart illustrating steps of a block chain-based ocean data resource sharing method according to an embodiment of the present invention is shown. In this embodiment, the method for sharing marine data resources based on a blockchain includes:
step 101, the data owner broadcasts the description information of the ocean data released this time to all nodes on the data storage chain.
And 102, selecting whether to participate in the storage competition according to a filtering rule pre-configured by an administrator by all nodes on the chain, distributing data storage rights, and enabling the competition to become a data storage party.
In this embodiment, after the data owner broadcasts the description information of the current distributed marine data to all nodes on the data storage chain, all nodes on the chain select whether to participate in the current storage competition according to a filtering rule pre-configured by an administrator, for example, all nodes participating in the competition allocate data storage rights by a dynamic priority method combining a random number method and a "least recently allocated" method, and the competition becomes a data storage party, so that the purpose of decentralized storage is achieved, the system load is balanced, and the disaster tolerance capability is strong.
And 103, after the data storage party generates the data, issuing a piece of storage request information to the data owner according to the address of the data owner contained in the description information issued by the data owner.
And step 104, after receiving the storage request information, the data owner takes a set number of signature tokens as storage cost, and sends the encrypted ocean data to the data storage party in a point-to-point mode through the SHA256 algorithm. The safety of ocean data is guaranteed, and a data storage party cannot obtain real data.
And 105, after the data storage party finishes the marine data storage, expanding the description information of the marine data to be used as block data to be issued to the data storage chain after the self address is expanded, generating a new block link to the tail part of the block chain and stamping a time stamp, declaring the successful storage after the nodes on the chain achieve consensus, and enabling each user node to directly access the node retrieval block record on the chain to perform marine data retrieval. Under the consensus mechanism, the user node can directly search the block records maintained at the agent node of the alliance, and the searching efficiency is improved.
In a preferred embodiment of the present invention, the method for sharing marine data resources based on blockchains may further include: after the description information of the marine data is obtained, the data requester sends data transaction request information and a signed token of the data price to the data depositor according to the address of the data depositor maintained in the description information; after receiving the data transaction request information, the data owner sends a transaction authentication request to the data owner; the data owner returns transaction authentication confirmation information after confirmation; after receiving the transaction authentication confirmation information, the data storage party sends the ocean data to the data requesting party; and the data requester decrypts the received ocean data according to the private key of the data requester to obtain the real ocean data.
In a preferred embodiment of the present invention, the method for sharing marine data resources based on blockchains may further include: the data request party decrypts the received ocean data according to the private key of the data request party to obtain real ocean data, and then the real ocean data is verified; if the verification is correct, the data owner sends the transaction confirmation information to the data storage party, and the data storage party pays the token to the data owner after receiving the confirmation information.
In a preferred embodiment of the present invention, the method for sharing marine data resources based on blockchains may further include: after the token payment is successful, the data storage party issues the records of the transaction as block data to a data transaction chain, a new block is generated to be linked to the tail of the block chain, a timestamp is printed, after the nodes on the chain achieve consensus, the transaction is declared to be finished, and each user node can directly access the node retrieval block records on the chain to perform marine data retrieval.
Among them, it should be noted that:
one, alliance chain
Referring to fig. 2, a schematic structural diagram of a federation chain in an embodiment of the present invention is shown. The alliance chain is a special blockchain, nodes on the blockchain are artificially divided into a plurality of alliances, alliance agent nodes are established, only the alliance agent nodes execute a consensus algorithm, and the alliances are connected through local area networks. By adopting the alliance chain design, the number of the consensus nodes on the block chain is greatly reduced, the quality of the consensus nodes is improved, the network overhead is greatly reduced, and the time required for achieving the consensus is shortened. The invention takes a sea-related management department, a scientific research unit and related enterprises as target users and network nodes, and takes user nodes as units to construct a marine data alliance chain, and establishes two management nodes, namely a strong agent and a weak agent, for executing a consensus algorithm according to the scale and data processing capacity of different organizations, thereby forming a strong alliance and a weak alliance.
(1) User node
The basic nodes in the alliance chain are actually controlled by common users in the alliance to complete the functions of data issuing, requesting and trading, and the user nodes do not store data and keep accounts, so that the user nodes are lighter, have lower network requirements and can adapt to the multi-source heterogeneous environment.
(2) Proxy node
The supervision and accounting nodes in the alliance chain are provided with one for each alliance and are actually controlled by an alliance administrator, after one transaction in the alliance chain occurs, all agent nodes account for the transaction together, and therefore each agent node holds a copy of the whole alliance chain bill, the openness and the non-tamper property of the bill are guaranteed, and the safety and supervision requirements are met. In addition, the agent nodes are divided into strong agent nodes and weak agent nodes, when a user requests to upload data, the data information is broadcasted to all the strong agent nodes in the block chain, all the strong agent nodes receiving the information determine whether to participate in the storage competition or not through the information, then all the strong agent nodes participating in the competition compete for the data storage right together, and after the storage is finished, a data index entry is generated and broadcasted to all the strong agents and the weak agents in the block chain. The alliance where the strong proxy node successfully storing the data is located can obtain certain bandwidth rewards, and the method is suitable for the strong alliance which has large data demand and strong server data processing capacity. And the weak proxy node only updates the data index in real time and does not participate in data storage, so that the weak proxy node is suitable for a weak alliance with small data demand and weak server data processing capacity.
(3) Double strand design
Because the ocean data has larger information quantity, the direct storage on the block chain can cause overlarge network load, so that only the transaction information and the data index are stored on the block, and the data is handed to each strong agent node for decentralized storage. Aiming at the characteristics of ocean data, the platform provides a double-chain design with a data transaction chain as a main chain and a data storage chain as an auxiliary chain:
the data transaction chain is composed of all strong and weak agents, common consensus is carried out, and each transaction information on the platform is recorded. The block data is stored in the chain in a public way, so that the credibility, traceability and non-tamper property of the transaction record are met.
The data storage chain is composed of all strong and weak agents, wherein the strong agent nodes are used for actually storing the ocean data, and the strong and weak agents jointly execute consensus. The design ensures that each alliance has a node on a storage chain, and each user node can directly carry out data retrieval to the agent node of the alliance through the local area network, so that the efficiency is higher and the network load is reduced.
Two, DPOS-based consensus mechanism
A consensus agreement or platform is the core of a distributed ledger. The more the decision making power is dispersed, the lower the efficiency of the system for achieving consensus is, but the system is stable and has high satisfaction; the more centralized the decision making, the more likely the system will reach a consensus list and the more likely the individuality will occur. Therefore, what consensus mechanism is used determines the efficiency and stability of the overall system. The core problem to be solved by the consensus mechanism is how to achieve consensus when there is a node doing malicious in the network, i.e. whether the network has Byzantine fault tolerance capability. Currently, widely used consensus mechanisms include PoW, PoS, DPoS, PBFT, etc., in view of the byzantine fault tolerance problem. The invention improves the traditional DPoS (rights authorization certification) consensus mechanism, changes the mode that the traditional DPoS determines proxy accounting nodes through voting into the mode that the accounting rights are directly distributed to the proxy nodes of all alliances, and verifies and accounts the transaction, so that each alliance comprises an accounting node, and the accounting node is a proxy node under the actual control of an alliance administrator. The network load of a block chain is reduced to a great extent by adopting a DPoS consensus mechanism, the full network computing power is saved compared with a workload Proof (POW) consensus mechanism adopted by bitcoin, and the Byzantine fault tolerance can be still allowed; the whole consensus process is simplified by abandoning the modification of the authorization voting process, and the accounting right is fixedly granted to the agent node with higher hardware performance under the supervision of the alliance administrator, so that the system is more reliable and has stronger supervision.
Third, data verification based on SHA256 Hash algorithm
The hashing algorithm maps an input value of arbitrary length to a shorter, fixed-length binary value. The SHA256 algorithm is one of hash algorithms that maps an input of arbitrary length to a fixed length output of 256 bits, this binary value being called the hash value. In a block chain, all transaction data are subjected to SHA256 hash operation twice and stored in a Merkle tree, and a digital signature of the transaction is generated at the same time, so that the integrity and the existence of the transaction in a block are rapidly summarized and verified.
Four, decentralized data storage
The traditional data storage is centralized storage depending on a data center, and in such a storage mode, if the load of a data server is too large or a hacker attack is encountered, the efficiency and the security cannot be guaranteed. In contrast, decentralized storage distributes data to multiple network nodes, similar to the distributed ledger technology of the block chain, and the regional or global characteristics of remote distribution are utilized, so that the problem is solved to a great extent. In the invention, ocean data resources held by users are stored in a decentralized mode, and all strong proxy nodes finish the storage work of ocean data together, thereby reducing the network load of the system and having a certain disaster tolerance capability, and ensuring that the whole system is safer and more efficient.
In summary, the marine data resource sharing method based on the block chain according to the present invention realizes marine data resource sharing based on the block chain, and the block chain frees more data by its trustiness, security and non-tamper-ability, thereby promoting mass growth of data. The traceability characteristic of the block chain enables the records of each step of data acquisition, transaction, circulation and calculation analysis to be reserved on the block chain, so that the quality of the data obtains unprecedented strong trust endorsements, and the correctness of the data analysis result and the data mining effect are also ensured. The block chain can further standardize the use of data and refine the authorization range. The desensitized data transaction circulation is beneficial to breaking through an information isolated island, establishing a data transverse circulation mechanism, and gradually promoting to form a data transaction scene based on globalization based on a value transfer network of a block chain. Secondly, by using a block chain technology, the right of the ocean data can be confirmed through a timestamp and a Hash algorithm, and the existence, authenticity and uniqueness of a piece of monitoring data, an analysis result and the like are proved. Once the right is confirmed on the block chain, the subsequent transaction of the ocean data can be recorded in real time, the full life cycle of the ocean data can be traced, the circulation can be accelerated and effectively integrated in all links of the ocean data value chain, the value creation cycle is shortened, the value transfer of the data content is realized, and the credibility, auditability and transparency of the transfer process are ensured. Therefore, the characteristics of decentralization, non-falsification, safety and credibility of the block chain technology can well solve the problems of data authenticity, data safety and data right transaction in ocean data sharing, the rights and interests of data owners can be guaranteed, the data transaction cost is reduced, an information isolated island is broken through, a data transverse circulation mechanism is established, and the block chain technology is technically feasible when applied to the field of ocean data open sharing and value-added circulation.
The embodiments in the present description are all described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other.
The above description is only for the best mode of the present invention, but the scope of the present invention is not limited thereto, and any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope of the present invention are included in the scope of the present invention.
Those skilled in the art will appreciate that the invention may be practiced without these specific details.