CN113489671A - Cross-alliance-link communication method and device, computer equipment and storage medium - Google Patents
Cross-alliance-link communication method and device, computer equipment and storage medium Download PDFInfo
- Publication number
- CN113489671A CN113489671A CN202110514589.7A CN202110514589A CN113489671A CN 113489671 A CN113489671 A CN 113489671A CN 202110514589 A CN202110514589 A CN 202110514589A CN 113489671 A CN113489671 A CN 113489671A
- Authority
- CN
- China
- Prior art keywords
- cross
- chain
- nodes
- node
- service
- 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.)
- Granted
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/10—Network architectures or network communication protocols for network security for controlling access to devices or network resources
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1097—Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/60—Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Hardware Design (AREA)
- Computer Security & Cryptography (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Abstract
The invention relates to the technical field of block chain cross-chain communication, which uses high-performance service based on an intelligent contract and cross-chain service consensus based on a verifiable random function to improve the performance and the safety of the cross-chain service. Specifically, disclosed are a cross-federation communication method, device, computer equipment and storage medium, the method comprising: submitting a cross-chain request, deploying an intelligent contract for providing cross-chain service on a block chain A, and initiating a cross-chain request to a block chain B from the intelligent contract for providing the cross-chain service on the block chain A; selecting a node cross chain, and selecting N nodes from k nodes in a service node pool to a block chain B for cross chain through a verifiable random function; performing cross-link data consensus, wherein data obtained by each node is subjected to consensus and excitation through a verifiable random function in an intelligent contract, and a result is stored in a service data pool; and reading the chain crossing data, executing the specific chain crossing operation on the blockchain B by the chain crossing nodes, and writing the result back to the blockchain A contract.
Description
Technical Field
The present application relates to the field of block chain cross-link communication technologies, and in particular, to a cross-alliance chain communication method and apparatus, a computer device, and a storage medium.
Background
In the current mainstream block chain system, public chains such as bitcoin and ether house, alliance chains such as hyper-hedger Fabric and ant block chain, and the like, the structure and node composition of each block chain system are completely different, so that efficient data intercommunication is difficult to realize, and an information isolated island using the chains as units is formed, namely, different block chains cannot interoperate. The core of cross-chain interoperation is data intercommunication, however, in the case that one node only runs one block chain, how to obtain data of another block chain in the running process, for example, a financial block chain obtains data of a logistics block chain to perform services such as loan credit, becomes an important and urgent industry pain point. Thus, a need exists for a cross-chain technique for a federated chain system to enable interoperation between different chains.
The mainstream cross-chaining technology in the industry can be broadly divided into hash time locking, notary mechanism, side chain/repeater mechanism, etc. Hash time locking and the like, a large amount of time locking is relied on to ensure the security, thereby sacrificing the performance and failing to meet the high-performance business requirement under the alliance chain. In order to achieve higher cross-link performance, many cross-link technologies adopt a notary mechanism, a side chain relay mechanism and the like, and the mechanisms can lead to centralization of certain programs and reduce the security of a block chain network.
Disclosure of Invention
The application provides a cross-alliance chain communication method, a cross-alliance chain communication device, computer equipment and a storage medium, so that the performance and the safety of cross-chain communication are improved.
In a first aspect, the present application provides a cross-alliance chain communication method, which is configured to implement communication between two blockchains, where the two blockchains are a blockchain a and a blockchain B, respectively, and include a service node pool and a service data pool, where the service node pool is configured to maintain node lists of the blockchain a and the blockchain B at the same time, and the service data pool includes data in cross-chain interaction; the method comprises the following steps:
submitting a cross-chain request, deploying an intelligent contract for providing cross-chain service on a block chain A, and initiating a cross-chain request to a block chain B from the intelligent contract for providing the cross-chain service on the block chain A;
selecting a node cross chain, and selecting N nodes from k nodes in a service node pool to a block chain B for cross chain through a verifiable random function;
performing cross-link data consensus, wherein data obtained by each node is subjected to consensus and excitation through a verifiable random function in an intelligent contract, and a result is stored in a service data pool;
and reading the chain crossing data, executing the specific chain crossing operation on the blockchain B by the chain crossing nodes, and writing the result back to the blockchain A contract.
In a second aspect, the present application further provides a cross-federation chain communication device, the device including:
the cross-chain request unit is used for submitting a cross-chain request, deploying an intelligent contract for providing cross-chain service on the block chain A, and initiating the cross-chain request to the block chain B from the intelligent contract for providing the cross-chain service on the block chain A;
the node selection unit is used for selecting node cross-chaining and selecting N nodes from k nodes in the service node pool to a block chain B for cross-chaining through a verifiable random function;
the data consensus unit is used for performing cross-link data consensus, and data obtained by each node is consensus and excited in an intelligent contract through a verifiable random function, and a result is stored in a service data pool;
and the execution unit is used for reading the cross-chain data, executing the cross-chain specific operation on the blockchain B by the cross-chain node, and writing the result back to the blockchain A contract.
In a third aspect, the present application further provides a computer device comprising a memory and a processor; the memory is used for storing a computer program; the processor is configured to execute the computer program and implement the cross-federation link communication method when executing the computer program.
In a fourth aspect, the present application also provides a computer-readable storage medium storing a computer program, which when executed by a processor causes the processor to implement the cross-federation chain communication method as described above.
The application discloses a cross-alliance chain communication method, a cross-alliance chain communication device, equipment and a storage medium, wherein a cross-chain request is submitted, an intelligent contract for providing cross-chain service is deployed on a block chain A, and the block chain A initiates a cross-chain request to a block chain B; selecting a node cross chain, and selecting N nodes from k nodes in a service node pool to a block chain B for cross chain through a verifiable random function; performing cross-link data consensus, wherein data obtained by each node is subjected to consensus and excitation through a verifiable random function in an intelligent contract, and a result is stored in a service data pool; and reading the chain crossing data, executing the specific chain crossing operation on the blockchain B by the chain crossing nodes, and writing the result back to the blockchain A contract. The method can improve the performance and the safety of cross-link communication.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
FIG. 1 is a schematic flow chart diagram illustrating a method for cross-federation communication according to an embodiment of the present application;
FIG. 2 is a flow diagram illustrating exemplary sub-steps of a method for cross-federation communication provided by an embodiment of the present application;
FIG. 3 is a schematic flow chart diagram illustrating another sub-step of a method for cross-federation communication provided by an embodiment of the present application;
fig. 4 is a schematic block diagram of a cross-alliance communication device according to an embodiment of the present disclosure;
fig. 5 is a schematic block diagram of a computer device according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some, but not all, embodiments of the present application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The flow diagrams depicted in the figures are merely illustrative and do not necessarily include all of the elements and operations/steps, nor do they necessarily have to be performed in the order depicted. For example, some operations/steps may be decomposed, combined or partially combined, so that the actual execution sequence may be changed according to the actual situation.
The embodiment of the application provides a cross-alliance-link communication method and device, computer equipment and a storage medium. The cross-alliance chain communication method can be applied to a terminal or a server to realize communication between two block chains and improve the performance and safety performance of cross-chain communication of the block chains.
Some embodiments of the present application will be described in detail below with reference to the accompanying drawings. The embodiments described below and the features of the embodiments can be combined with each other without conflict.
Referring to fig. 1, fig. 1 is a schematic flowchart illustrating a cross-federation communication method according to an embodiment of the present application. The method is used for realizing communication between two block chains, and is called as a block chain A and a block chain B hereinafter, and comprises a service node pool and a service data pool, wherein the service node pool is used for simultaneously maintaining node lists of the block chain A and the block chain B, receiving a cross-chain request from the block chain A, and returning block chain state data or a cross-chain transaction structure to the block chain A after performing cross-chain operation on the block chain B. The service data pool includes data in cross-chain interactions, such as state data, transaction data, etc. on blockchain B.
The cross-federation-chain communication method of the application comprises the steps S101 to S104.
S101, submitting a cross-chain request, deploying an intelligent contract for providing cross-chain service on a block chain A, and initiating the cross-chain request to a block chain B from the cross-chain service intelligent contract on the block chain A.
The blockchain A is blockchain data maintained by a plurality of nodes, the part of data is disclosed for all blockchain accounting nodes, and an intelligent contract for providing cross-chain service is deployed on the blockchain A. Block chain B is another block chain, and block chain a is to read data on block chain B. And the cross-chain service intelligent contract is used for accepting a cross-chain transaction request on the blockchain and continuously providing cross-chain data, and the contract is deployed on the blockchain A and provides data of the blockchain B for the blockchain A. The cross-chain service intelligent contract comprises the service node pool and the service data pool.
S102, selecting node cross-linking, and selecting N nodes from k nodes in the service node pool to a block chain B for cross-linking through a verifiable random function.
Specifically, the step is to select a node to perform cross-chain service. The service node pool simultaneously maintains a node list of data of the blockchain A and the blockchain B, receives a cross-chain request from the blockchain A, performs cross-chain operation on the blockchain B and returns blockchain state data and a cross-chain transaction result to the A.
Each node in the service node pool achieves consensus through a verifiable random function, and N nodes are selected To the blockchain B To carry out a cross-chain request, namely, the transaction of < Type, To, Input > is executed on the blockchain B.
And S103, cross-chain data consensus, wherein data obtained by each node is subjected to consensus and excitation through a verifiable random function in an intelligent contract, and the result is stored.
Specifically, the data obtained by each node comprises state data and transaction data, consensus and incentive are achieved in the intelligent contract through a verifiable random function, and the result is stored in a service data pool.
And S104, reading the cross-chain data, executing the specific operation of the cross-chain on the block chain B by the cross-chain node, and writing the result back to the contract of the block chain A.
Specifically, this step is to read the cross-chain data. And the cross-link node executes the specific cross-link operation on the blockchain B, and writes the result back to the blockchain A contract, so that the transaction on the blockchain A can acquire the information of the blockchain B through the cross-link service contract.
Since the cross-federation communication method can be applied to a terminal or a server, the trained model needs to be stored in the terminal or the server. The terminal can be an electronic device such as a mobile phone, a tablet computer, a notebook computer, a desktop computer, a personal digital assistant and a wearable device; the servers may be independent servers or server clusters.
If the method is applied to the terminal, in order to ensure the normal operation of the terminal, the target recognition model obtained by training needs to be compressed, and the compressed model is stored in the terminal.
The compression processing specifically includes pruning, quantization, huffman coding and the like on the target recognition model to reduce the size of the target recognition model, so that the target recognition model can be conveniently stored in a terminal with small capacity.
In the method for communication across federation chains provided in the above embodiment, an intelligent contract providing a cross-chain service is deployed on a blockchain a, and a cross-chain request is initiated to a cross-chain service intelligent contract on the blockchain a to a blockchain B; selecting N nodes from k nodes in the service node pool to a block chain B for chain crossing through a verifiable random function; the data obtained by each node is identified and excited in the intelligent contract through a verifiable random function, and the result is stored; and the cross-chain node executes the specific cross-chain operation on the blockchain B, writes the result back into the blockchain A contract, and the transaction on the blockchain A can acquire the information of the blockchain B from the cross-chain service contract. In steps S101 and S104, data is submitted and read asynchronously in real time through an intelligent contract, a block chain A requests for transaction, then the transaction is executed on a block chain B, and then a result is written back to the block chain A. In S102 and S103, the cross-link data consensus ensures the overall correctness of the data through the game on the probability, and does not need to add extra confirmation, dispute and arbitration time, thereby further shortening the time of cross-link communication.
In an alternative embodiment, the fields of the cross-chain request include: request type, target contract, target input, and number of cross-link points. The request type includes a status request or a transaction request. The target contract is an intelligent contract executed on the blockchain B, and the target input is transaction input executed on the blockchain B. The number of the cross-link points is the required number of the cross-link points. The number N of chain-crossing points is related to the commission charge of the chain-crossing request, the commission charge is used for exciting the chain-crossing point to provide service and is in direct proportion to the number N of chain-crossing points, and the formula is shown as follows;
CrossFeescall(N)=N*Feecall
CrossFeessend(N)=N*Feesend
wherein, the request unit prices of the status request Call and the transaction request Send are FeecallAnd FeesendAnd is determined by each federation party at the time of deployment of the cross-chain service contract.
Referring to fig. 2, fig. 2 is a schematic flowchart illustrating a sub-step S102 of a cross-federation chain communication method according to an embodiment of the present application. Including step S1021 to step S1022.
S1021, calculating k nodes in the service node pool through respective private keys according to hexadecimal coded values of cross-chain request contents to obtain respective verifiable random numbers, and simultaneously generating certificates and verifying random number certificates of other nodes by each node.
Specifically, k nodes in the service node pool calculate, through respective private keys, respective verifiable random numbers according to hexadecimal coded values of the cross-chain request content, as shown in the following formula:
Ri=VRF_Hash(PriKeyi,Hex(Type+To+Input))
wherein R isiFor each random value obtained by k nodes, VRF _ Hash () is the VRF computation function, PriKeyiIs the private key of each node.
Meanwhile, each node generates a certificate and verifies the random number certificates of other nodes, as shown in the following formula:
Pi=VRF_Prove(PriKeyi,Hex(Type+To+Input))
Validi=VRF_Verify(PubKeyi,Hex(Type+To+Input),Ri,Pi)
wherein, VRF _ Prove () is a function for generating proof of specific VRF algorithm, VRF _ Verify () is a function for verifying validity of the random number, PubKeyiA public key published for node i.
Each node can verify the correctness of the random numbers of the k nodes through an intelligent contract so as to ensure the accuracy and the safety of the random process. If all Valid of each node verifiesiIf both are correct, the next step is performed. S202, calculating k nodes in the service node pool through respective private keys according to hexadecimal coded values of cross-chain request contents to obtain respective verifiable random numbers, and simultaneously generating certificates and verifying random number certificates of other nodes by each node.
Specifically, k random numbers in S201 are aggregated to obtain an average value of the random numbers, the absolute values of the nodes from the average value are arranged in an ascending order to obtain the first N nodes, and the N nodes are used as random nodes, as shown in the following formula.
Valuei=|Ri-Average|
Wherein Average is an Average Value obtained by aggregating random numbers, ValueiAnd obtaining the first N nodes for executing the cross-chain transaction after ascending order for the value used for sorting.
Referring to fig. 3, fig. 3 is a schematic flowchart of sub-step S103 of the cross-federation chain communication method of the present application, which includes steps S1031-S1033.
And S1031, executing N nodes of the cross-chain, calculating to obtain respective verifiable random numbers according to hexadecimal coded values of the cross-chain result through respective private keys, and simultaneously generating certificates and verifying random number certificates of other nodes by each node.
Specifically, N nodes of the cross-chain are executed, and respective verifiable random numbers are calculated according to hexadecimal coded values of the cross-chain result through respective private keys, as shown in the following formula:
Ri=VRF_Hash(PriKeyi,Hex(Datai))
wherein R isiFor cross-link fruit DataiEncodes the random values obtained after the respective nodes are randomized.
Meanwhile, each node generates a certificate and verifies the random number certificates of other nodes, as shown in the following formula:
Pi=VRF-Prove(PriKeyi,Hex(Datai))
Validi=VRF-Verify(PubKeyi,Hex(Datai),Ri,Pi)
similarly, each node will verify the correctness of the random number of each node for its respective result by the intelligent dating program if all Valid values verified by each nodeiIf both are correct, the next step is performed.
S1032, the obtained N random numbers are aggregated, the average value of the random numbers is obtained, the absolute value of each random number from the average value is calculated, the result with the larger absolute value is assumed to be the correct result, and the corresponding cross-link result is written into a service data pool.
Specifically, the same conversion permutation as in a is performed on N random numbers in B1, as shown in the following formula:
Valuei=|Ri-Average|
wherein, ValueiThe maximum result is the assumed correct result and is marked as ValueX. Corresponding DataXAs a result of the assumed correctness, to the service data pool for subsequent contract invocations on blockchain a.
And S1033, awarding all the nodes which are equal to the cross-link result by the intelligent contract, and punishing the nodes which are not equal to the cross-link result by the intelligent contract.
Intelligent contracts automatically for all Data equalsXFor Fee in the corresponding node icallOr FeesendAnd for Data not equal toXData ofiFee in fine marginwrong. Likewise, FeewrongThe contract is deployed by various federation parties, with negotiation settings, and has the following properties:
Feewrong>>k*Feesend>k*Feecall
wherein, FeewrongFor penalizing costs, FeecallRequesting fees for transactions, FeesendFor the cross-link request fee, k is a scaling factor, and k is specified by the federation negotiation.
In a longer time period, the wrong data submitted by the node is different from the correct data submitted by other nodes, and a penalty is obtained. For the cross-link nodes, the correct data is submitted for benefit to obtain the cross-link reward in a long term. Therefore, through the above processes and settings, when acquiring cross-link data or executing a transaction, each cross-link node tends to submit correct data in a game, and data which is submitted incorrectly is subjected to greater punishment, so that the correctness of the cross-link data as a whole is ensured.
Compared with the prior art, the method has the following advantages that:
1. high performance.
According to the invention, cross-chain service is provided for the block chain through the native intelligent contract on the block chain, so that the cross-chain service contract can be called in real time by the transaction and the contract on the chain, the asynchronous cross-chain request and return process is decoupled, and compared with the existing work of Hash time locking and the like, the required time is shorter, and the flexibility and the performance are higher.
2. And (4) safety.
According to the invention, through the verifiable random function, high randomness and safety are provided for the selection of the cross-link nodes, and through the game and the excitation mechanism among the nodes, the safety of correctly obtaining consensus of the cross-link result is improved. Compared with the existing cross-link work of notary, side chain, repeater and the like, the method has higher safety in node selection and cross-link result consensus.
Referring to fig. 4, fig. 4 is a schematic block diagram of a cross-federation chain communication device according to an embodiment of the present application, where the device may be configured in a server for executing the aforementioned cross-federation chain communication method.
As shown in fig. 4, the cross-federation chain communication device 200 includes: a cross-chain request unit 201, a node selection unit 202, a data consensus unit 203 and an execution unit 204.
A cross-chain request unit 201, configured to submit a cross-chain request, deploy an intelligent contract providing a cross-chain service on the blockchain a, and initiate a cross-chain request to the blockchain B from the cross-chain service intelligent contract on the blockchain a;
a node selecting unit 202, configured to select a node cross-link, and select N nodes from k nodes in the service node pool to a blockchain B for cross-link through a verifiable random function;
the data consensus unit 203 is used for performing cross-link data consensus, and data obtained by each node is consensus and stimulated through a verifiable random function in an intelligent contract, and a result is stored in a service data pool;
the execution unit 204 is configured to read the inter-chain data, execute the inter-chain specific operation on the blockchain B by the inter-chain node, and write the result back to the blockchain a contract.
It should be noted that, as will be clear to those skilled in the art, for convenience and brevity of description, the specific working processes of the apparatus and the units described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The apparatus described above may be implemented in the form of a computer program which is executable on a computer device as shown in fig. 5.
Referring to fig. 5, fig. 5 is a schematic block diagram of a computer device according to an embodiment of the present disclosure. The computer device may be a server or a terminal.
Referring to fig. 5, the computer device includes a processor, a memory, and a network interface connected through a system bus, wherein the memory may include a nonvolatile storage medium and an internal memory.
The non-volatile storage medium may store an operating system and a computer program. The computer program includes program instructions that, when executed, cause a processor to perform any of the cross-federation chain communication methods.
The processor is used for providing calculation and control capability and supporting the operation of the whole computer equipment.
The internal memory provides an environment for the execution of a computer program on a non-volatile storage medium, which when executed by the processor, causes the processor to perform any of the cross-federation chain communication methods.
The network interface is used for network communication, such as sending assigned tasks and the like. Those skilled in the art will appreciate that the architecture shown in fig. 5 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
It should be understood that the Processor may be a Central Processing Unit (CPU), and the Processor may be other general purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components, etc. Wherein a general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
Wherein, in one embodiment, the processor is configured to execute a computer program stored in the memory to implement the steps of:
submitting a cross-chain request, deploying an intelligent contract for providing cross-chain service on a block chain A, and initiating a cross-chain request to a block chain B from the intelligent contract for providing the cross-chain service on the block chain A; selecting a node cross chain, and selecting N nodes from k nodes in a service node pool to a block chain B for cross chain through a verifiable random function; performing cross-link data consensus, wherein data obtained by each node is subjected to consensus and excitation through a verifiable random function in an intelligent contract, and a result is stored in a service data pool; and reading the chain crossing data, executing the specific chain crossing operation on the blockchain B by the chain crossing nodes, and writing the result back to the blockchain A contract.
In an embodiment of the present application, a computer-readable storage medium is further provided, where a computer program is stored in the computer-readable storage medium, where the computer program includes program instructions, and the processor executes the program instructions to implement any one of the cross-federation link communication methods provided in the embodiment of the present application.
The computer-readable storage medium may be an internal storage unit of the computer device described in the foregoing embodiment, for example, a hard disk or a memory of the computer device. The computer readable storage medium may also be an external storage device of the computer device, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like provided on the computer device.
While the invention has been described with reference to specific embodiments, the scope of the invention is not limited thereto, and those skilled in the art can easily conceive various equivalent modifications or substitutions within the technical scope of the invention. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.
Claims (8)
1. A communication method across alliance chains is used for realizing communication between two block chains, wherein the two block chains are a block chain A and a block chain B respectively and comprise a service node pool and a service data pool, the service node pool is used for maintaining node lists of the block chain A and the block chain B simultaneously, and the service data pool comprises data in cross-chain interaction; it is characterized by comprising:
submitting a cross-chain request, deploying an intelligent contract for providing cross-chain service on a block chain A, and initiating a cross-chain request to a block chain B from the intelligent contract for providing the cross-chain service on the block chain A;
selecting a node cross chain, and selecting N nodes from k nodes in a service node pool to a block chain B for cross chain through a verifiable random function;
performing cross-link data consensus, wherein data obtained by each node is subjected to consensus and excitation through a verifiable random function in an intelligent contract, and a result is stored in a service data pool;
and reading the chain crossing data, executing the specific chain crossing operation on the blockchain B by the chain crossing nodes, and writing the result back to the blockchain A contract.
2. The method of claim 1, wherein the fields of the cross-chaining request comprise: the method comprises the steps of requesting types, target contracts, target inputs and cross-link points, wherein the requesting types comprise state requests or transaction requests, the target contracts are intelligent contracts executed on a blockchain B, the target inputs are transaction inputs executed on the blockchain B, and the cross-link points are required cross-link points.
3. The method of claim 1, wherein selecting N nodes from k nodes in the service node pool to perform cross-chaining on the blockchain B by a verifiable random function comprises:
k nodes in the service node pool calculate respective verifiable random numbers according to hexadecimal coded values of the cross-chain request content through respective private keys, and simultaneously each node generates a certificate and verifies the random number certificates of other nodes;
and aggregating the k random numbers to obtain the average value of the random numbers, and arranging the absolute values of the distances between each node and the average value in an ascending order to obtain the first N nodes as random nodes.
4. A method for communication across federation chains as claimed in claim 3 wherein the status data and transaction data obtained at each node is consensus and incentivized by verifiable random functions in smart contracts and the results are stored, including:
executing N nodes of the cross-chain, calculating to obtain respective verifiable random numbers according to hexadecimal coded values of the cross-chain result through respective private keys, and simultaneously generating a certificate and verifying random number certificates of other nodes by each node;
aggregating the obtained N random numbers to obtain the average value of the random numbers, calculating the absolute value of the distance between each random number and the average value, assuming that the result with the larger absolute value is the correct result, and writing the corresponding cross-link result into a service data pool;
the intelligent contract rewards all nodes which are equal to the cross-link result, and the intelligent contract penalizes the nodes which are not equal to the cross-link result.
5. The cross-federation chain communication method of claim 4, wherein the reward comprises a cross-chain request fee and a transaction request fee; the penalty fee > k cross-chain request fee > k transaction request fee.
6. A cross-federation chain communication device, comprising:
the cross-chain request unit is used for submitting a cross-chain request, deploying an intelligent contract for providing cross-chain service on the block chain A, and initiating the cross-chain request to the block chain B from the intelligent contract for providing the cross-chain service on the block chain A;
the node selection unit is used for selecting node cross-chaining and selecting N nodes from k nodes in the service node pool to a block chain B for cross-chaining through a verifiable random function;
the data consensus unit is used for performing cross-link data consensus, and data obtained by each node is consensus and excited in an intelligent contract through a verifiable random function, and a result is stored in a service data pool;
and the execution unit is used for reading the cross-chain data, executing the cross-chain specific operation on the blockchain B by the cross-chain node, and writing the result back to the blockchain A contract.
7. A computer device, wherein the computer device comprises a memory and a processor;
the memory is used for storing a computer program;
the processor, configured to execute the computer program and, when executing the computer program, implement the cross-federation chain communication method according to any one of claims 1 to 5.
8. A computer-readable storage medium storing a computer program which, when executed by a processor, causes the processor to implement the cross-federation chain communication method of any one of claims 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110514589.7A CN113489671B (en) | 2021-05-11 | 2021-05-11 | Cross-alliance chain communication method and device based on verifiable random function |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110514589.7A CN113489671B (en) | 2021-05-11 | 2021-05-11 | Cross-alliance chain communication method and device based on verifiable random function |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113489671A true CN113489671A (en) | 2021-10-08 |
CN113489671B CN113489671B (en) | 2023-07-11 |
Family
ID=77932726
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110514589.7A Active CN113489671B (en) | 2021-05-11 | 2021-05-11 | Cross-alliance chain communication method and device based on verifiable random function |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113489671B (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114331447A (en) * | 2022-03-15 | 2022-04-12 | 北京溪塔科技有限公司 | Cross-link message submitting method and device |
CN114362956A (en) * | 2021-12-23 | 2022-04-15 | 华南理工大学 | Cross-link communication architecture and method of alliance link |
CN114374633A (en) * | 2022-01-07 | 2022-04-19 | 广东工业大学 | Credible Internet of things cloud service evaluation method and system based on intelligent contract |
CN114612103A (en) * | 2022-05-10 | 2022-06-10 | 中国信息通信研究院 | Method, device, system, medium and electronic equipment for cross-block chain transaction |
CN115052001A (en) * | 2022-06-09 | 2022-09-13 | 上海万向区块链股份公司 | Extensibility solution, system and medium for federation chains |
CN115309515A (en) * | 2022-10-10 | 2022-11-08 | 北京理工大学 | Cross-chain transaction processing method, device and equipment based on block chain |
CN116523518A (en) * | 2023-07-03 | 2023-08-01 | 中铱数字科技有限公司 | Cross-channel data access method, system and storage medium based on blockchain |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110445616A (en) * | 2019-07-15 | 2019-11-12 | 杭州复杂美科技有限公司 | A kind of block is packaged the determining method of packing sequence, equipment and the storage medium of node |
US20190354518A1 (en) * | 2018-05-01 | 2019-11-21 | Michael Zochowski | Chain mesh network for decentralized transaction systems |
US20200013027A1 (en) * | 2018-07-06 | 2020-01-09 | Decentralized Finance Labs, Inc. | Hybrid proof of work and proof of stake consensus to reduce circulating tokens in a blockchain system |
WO2020133326A1 (en) * | 2018-12-29 | 2020-07-02 | 北京建极练科技有限公司 | Blockchain generation method and system, and computer storage medium and electronic device |
CN111951108A (en) * | 2020-08-10 | 2020-11-17 | 神话科技传媒(深圳)有限公司上海分公司 | Chain structure design method with intelligent contract block chain with complete picture |
CN112287029A (en) * | 2020-11-17 | 2021-01-29 | 北京物资学院 | Block chain multi-chain cross-chain system and implementation mechanism thereof |
CN112418860A (en) * | 2020-12-07 | 2021-02-26 | 苏州科技大学 | Block chain efficient management framework based on cross-chain technology and working method |
-
2021
- 2021-05-11 CN CN202110514589.7A patent/CN113489671B/en active Active
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20190354518A1 (en) * | 2018-05-01 | 2019-11-21 | Michael Zochowski | Chain mesh network for decentralized transaction systems |
US20200013027A1 (en) * | 2018-07-06 | 2020-01-09 | Decentralized Finance Labs, Inc. | Hybrid proof of work and proof of stake consensus to reduce circulating tokens in a blockchain system |
WO2020133326A1 (en) * | 2018-12-29 | 2020-07-02 | 北京建极练科技有限公司 | Blockchain generation method and system, and computer storage medium and electronic device |
CN110445616A (en) * | 2019-07-15 | 2019-11-12 | 杭州复杂美科技有限公司 | A kind of block is packaged the determining method of packing sequence, equipment and the storage medium of node |
CN111951108A (en) * | 2020-08-10 | 2020-11-17 | 神话科技传媒(深圳)有限公司上海分公司 | Chain structure design method with intelligent contract block chain with complete picture |
CN112287029A (en) * | 2020-11-17 | 2021-01-29 | 北京物资学院 | Block chain multi-chain cross-chain system and implementation mechanism thereof |
CN112418860A (en) * | 2020-12-07 | 2021-02-26 | 苏州科技大学 | Block chain efficient management framework based on cross-chain technology and working method |
Non-Patent Citations (2)
Title |
---|
张亮等: "区块链技术综述", 《计算机工程》 * |
张亮等: "区块链技术综述", 《计算机工程》, no. 05, 18 March 2019 (2019-03-18) * |
Cited By (13)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114362956B (en) * | 2021-12-23 | 2023-08-18 | 华南理工大学 | Cross-link communication architecture and method of alliance chains |
CN114362956A (en) * | 2021-12-23 | 2022-04-15 | 华南理工大学 | Cross-link communication architecture and method of alliance link |
CN114374633A (en) * | 2022-01-07 | 2022-04-19 | 广东工业大学 | Credible Internet of things cloud service evaluation method and system based on intelligent contract |
CN114374633B (en) * | 2022-01-07 | 2023-11-10 | 广东工业大学 | Trusted Internet of things cloud service evaluation method and system based on intelligent contracts |
CN114331447A (en) * | 2022-03-15 | 2022-04-12 | 北京溪塔科技有限公司 | Cross-link message submitting method and device |
CN114612103A (en) * | 2022-05-10 | 2022-06-10 | 中国信息通信研究院 | Method, device, system, medium and electronic equipment for cross-block chain transaction |
CN114612103B (en) * | 2022-05-10 | 2022-08-02 | 中国信息通信研究院 | Method, device, system, medium and electronic equipment for cross-block chain transaction |
CN115052001A (en) * | 2022-06-09 | 2022-09-13 | 上海万向区块链股份公司 | Extensibility solution, system and medium for federation chains |
CN115052001B (en) * | 2022-06-09 | 2024-04-05 | 上海万向区块链股份公司 | Extendibility solving method, system and medium for alliance chain |
CN115309515A (en) * | 2022-10-10 | 2022-11-08 | 北京理工大学 | Cross-chain transaction processing method, device and equipment based on block chain |
CN115309515B (en) * | 2022-10-10 | 2023-01-31 | 北京理工大学 | Cross-chain transaction processing method, device and equipment based on block chain |
CN116523518A (en) * | 2023-07-03 | 2023-08-01 | 中铱数字科技有限公司 | Cross-channel data access method, system and storage medium based on blockchain |
CN116523518B (en) * | 2023-07-03 | 2023-09-15 | 中铱数字科技有限公司 | Cross-channel data access method, system and storage medium based on blockchain |
Also Published As
Publication number | Publication date |
---|---|
CN113489671B (en) | 2023-07-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN113489671B (en) | Cross-alliance chain communication method and device based on verifiable random function | |
JP7284747B2 (en) | Execution of smart contracts with distributed cooperation | |
CN108900364B (en) | Block chain network management method, block chain network management device, block chain network management medium and electronic equipment | |
CN111095324B (en) | Parallel execution of transactions in a distributed ledger system | |
WO2018158936A1 (en) | Block chain management device, block chain management method and program | |
CN113221183B (en) | Method, device and system for realizing privacy protection of multi-party collaborative update model | |
CN111612600B (en) | Block chain auction method, equipment, storage medium and block chain system | |
CN109274717A (en) | Shared storage method, device, medium and electronic equipment based on block chain | |
CN108510315B (en) | Resource publishing method and related equipment | |
CN111985007A (en) | Contract signing and executing method and device based on block chain | |
CN112163929B (en) | Service recommendation method, device, computer equipment and storage medium | |
CN110245182B (en) | Method, apparatus, device and medium for processing distributed data | |
CN110348835A (en) | A kind of fictitious assets transfer method, device, server and storage medium | |
CN108876485A (en) | A kind of advertisement scheme is than original text method, server and computer-readable medium | |
CN111260364B (en) | Block chain-based extensible quick payment method and system | |
CN112765481A (en) | Data processing method and device, computer and readable storage medium | |
CN113592645B (en) | Data verification method and device | |
CN114741446A (en) | Data uplink method, device, terminal and storage medium | |
CN113947491A (en) | Leader node determination method, device, equipment and medium based on power block chain | |
CN112507323A (en) | Model training method and device based on unidirectional network and computing equipment | |
CN112084348A (en) | Method and device for determining relevance | |
CN112163846A (en) | Payment scheme determination method, device and system based on block chain | |
CN114363363B (en) | Data storage method, device, equipment and medium based on multiple chains | |
CN110009348A (en) | A kind of allograph method, system and the electronic equipment of block chain | |
CN113971552B (en) | Batch data processing method, device, equipment and storage medium |
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 |