CN108769173B - Block chain implementation method and equipment for running intelligent contracts - Google Patents

Block chain implementation method and equipment for running intelligent contracts Download PDF

Info

Publication number
CN108769173B
CN108769173B CN201810491690.3A CN201810491690A CN108769173B CN 108769173 B CN108769173 B CN 108769173B CN 201810491690 A CN201810491690 A CN 201810491690A CN 108769173 B CN108769173 B CN 108769173B
Authority
CN
China
Prior art keywords
node
transaction
block
nodes
intelligent contract
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810491690.3A
Other languages
Chinese (zh)
Other versions
CN108769173A (en
Inventor
潘涛
王毅敏
郝庆晟
王兴旺
张为
杨子民
钱烨
朱林
李�杰
洪刚
张龙澎
王磊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Orange Lion Sports (Shanghai) Co.,Ltd.
Orange Lion Sports Co.,Ltd.
Original Assignee
Ali Sports Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ali Sports Co Ltd filed Critical Ali Sports Co Ltd
Priority to CN201810491690.3A priority Critical patent/CN108769173B/en
Publication of CN108769173A publication Critical patent/CN108769173A/en
Application granted granted Critical
Publication of CN108769173B publication Critical patent/CN108769173B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3247Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving digital signatures
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3263Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving certificates, e.g. public key certificate [PKC] or attribute certificate [AC]; Public key infrastructure [PKI] arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2209/00Additional information or applications relating to cryptographic mechanisms or cryptographic arrangements for secret or secure communication H04L9/00
    • H04L2209/56Financial cryptography, e.g. electronic payment or e-cash
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2463/00Additional details relating to network architectures or network communication protocols for network security covered by H04L63/00
    • H04L2463/102Additional details relating to network architectures or network communication protocols for network security covered by H04L63/00 applying security measure for e-commerce

Abstract

The invention provides a block chain implementation method and equipment for running intelligent contracts, wherein a client initiates a transaction proposal to a plurality of accounting nodes; each accounting node verifies the validity of the transaction proposal, executes the verification to be a valid transaction proposal, and returns the proposal result to the client; the client side waits for a plurality of accounting nodes to respond to the transaction proposal, compares the proposal results, re-initiates the transaction proposal if the proposal results are inconsistent, and submits the proposal results to a consensus node group if the proposal results are consistent; the consensus node group collects the proposal result, verifies the validity of the proposal result, packs the proposal result into an undetermined block, sends the undetermined block to the accounting node, packs the transaction proposal only containing successful verification into a block and adds the block to the block chain after removing the transaction proposal of failed verification.

Description

Block chain implementation method and equipment for running intelligent contracts
Technical Field
The invention relates to a method and equipment for realizing a block chain for running an intelligent contract.
Background
The problem that a server for operating a blockchain node is overloaded exists in the process of operating an intelligent contract by an existing blockchain.
Disclosure of Invention
The invention aims to provide a method and equipment for realizing a block chain for running an intelligent contract.
In order to solve the above problem, the present invention provides a method for implementing a blockchain for running an intelligent contract, including:
dividing the block chain link point roles into a client, an accounting node and a common node group;
storing a set of public and private keys at the client, setting the client for initiating a transaction;
saving a group of key pairs at the accounting node, setting the accounting node as a storage distributed account book, and operating an intelligent contract and verifying a transaction;
storing a group of key pairs in the consensus nodes, setting the consensus nodes as a storage distributed account book, operating an intelligent contract, verifying transactions, sequencing a plurality of transactions in a block and achieving sequenced consensus among all the consensus nodes;
the client packs the intelligent contract calling instruction into a transaction proposal and initiates the transaction proposal to a plurality of accounting nodes;
each accounting node verifies the validity of the transaction proposal, executes the transaction proposal verified to be valid, and returns the proposal result to the client;
the client side waits for a plurality of accounting nodes to respond to the transaction proposal, compares the proposal results, re-initiates the transaction proposal if the proposal results are inconsistent, and submits the proposal results to a consensus node group if the proposal results are consistent;
the common identification node group collects the proposal result, verifies the validity of the proposal result, adds a serial number to the proposal result verified to be valid, packs the proposal result into an undetermined block when the serial number reaches a preset serial number threshold or the waiting time for collecting the proposal result reaches a preset time threshold, sends the undetermined block to the accounting node, verifies the transaction proposal in the undetermined block, packs the transaction proposal only containing successful verification into a block to be added to a block chain after the transaction proposal failed to be verified is eliminated, verifies the transaction proposal in the undetermined block after the accounting node receives the undetermined block of the common identification node, packs the transaction proposal only containing successful verification into a block to be added to the block chain after the transaction proposal failed to be verified is eliminated.
Further, in the above method, before the client packages the smart contract invocation instruction into a transaction proposal and initiates the transaction proposal to the plurality of accounting nodes, the method further includes:
dividing the corresponding operating systems of the client, the accounting nodes and the consensus node group into six parts including a data layer, a network layer, a consensus layer, a contract layer, an authorization layer and an application layer;
the data layer is set to comprise a key value database and a database management module, and is used for storing block data and data generated by intelligent contracts and providing an interface for increasing, deleting, modifying and checking the intelligent contract data, the data layer defines the structure of a distributed account book in the block chain, the account book consists of a block chain and a world state, wherein the block chain is a traceable linked list consisting of blocks, the blocks consist of block heads, block data and metadata, the blocks consist of transaction proposals, and the transaction proposals have two types: the method comprises the steps of deploying transaction and calling transaction, wherein the deploying transaction is a record for writing an intelligent contract file into a block, and the record content comprises a file source code, a deployer, a version number, configuration information and a transaction unique identifier; the calling transaction is the record of the intelligent contract calling process, and the record content comprises the block height of the intelligent contract source code, the transaction unique identifier, the intelligent contract method name, the calling parameter and the digital signatures of a transaction initiator and an executor; the world state is a set of states of all intelligent contracts, and the state is an expression mode of the intelligent contracts for finally operating the database; the intelligent contract operation result is represented by a read-write set, the read-write set consists of a read set and a write set, and the write set is a set of states generated by one-time calling of the intelligent contract;
the method comprises the steps that a network layer is set to manage a point-to-point network, the network layer comprises a data transmission protocol, a node exploration module, a data synchronization module and a broadcast transaction module, wherein the data transmission protocol is a final consistency algorithm and realizes a Gossip protocol and is used for synchronizing data of each node of a block chain, the synchronization process is a flow of sending, receiving, updating, sending back again and updating again in a synchronization period, one node is randomly selected in each period, and finally the data are spread to all nodes; the node exploration module manages a list of known node IP addresses in the network, the list is manually input when a blockchain network is deployed, when a new node joins the network, the exploration module generates an exploration message, the exploration message comprises authorization obtained by the node in the blockchain network and the known node list, the authorization is given by the authorization layer, the data transmission protocol sends and receives the exploration message, a receiver node is selected from the node list, an exploration message is broadcasted to the receiver, the exploration module of the receiver compares the local known node list after receiving the message, if the exploration message comprises a local node IP, the IP is added to the local node list, if the exploration message does not comprise the local node IP, the local list is not updated, an exploration response is sent back to a sender of the exploration message after the comparison is completed, and the exploration response content comprises the authorization of the node and the updated known node list, after receiving the exploration response, the receiver updates the local node list in the same way according to the response content, and then sends back a response message of the exploration response, and the receiver updates the node list again; the data synchronization module sends and receives data synchronization messages, the synchronization messages are divided into synchronization block heights and synchronization block data, the synchronization block heights comprise the local block heights of nodes and digital signatures of messages, the synchronization block data comprise block contents needing to be updated and digital signatures of the messages, the synchronization messages are broadcast to other nodes according to a data transmission protocol, the nodes send the synchronization block height messages at regular time, and when the receiver block heights are found to be larger than the block heights of the nodes, the synchronization block data messages are sent to obtain the latest blocks; the broadcast transaction module is divided into a client side, an accounting node side and a consensus node side, and provides different functions for different roles. The client side sends a transaction proposal generated by the application layer to the accounting node, the accounting node side sends an operation result back to the client side, the client side processes the result into a transaction message and sends the transaction message to the consensus node, the transaction message comprises a processing result of the accounting node and a digital signature of the message, and the consensus node side receives the transaction message and sends the consensus result to the accounting node after processing;
setting the consensus layer to enable all consensus nodes to form a consensus node group, wherein the consensus node group receives a transaction initiated by a client and sorts a plurality of transactions through a consensus algorithm, and the consensus algorithm is realized by a PBFT algorithm;
setting the contract layer to comprise an intelligent contract packaging and running system, a contract code checker and a transaction circulation module, wherein for the deployment transaction, the contract code checker performs static scanning on the intelligent contract code to intercept a malicious program, the packaging and running system checks whether the intelligent contract can be run by the system after checking, and the transaction circulation module sends the intelligent contract file to the network layer for processing after checking; for calling transaction, the contract code checker scans the intelligent contract code statically to intercept malicious programs, inputs input parameters contained in the transaction into the packaging and operating system after checking, the packaging and operating system operates the intelligent contract code and then outputs an operation result to the transaction circulation module, and the circulation module processes the operation result into a read-write set with a version number and sends the read-write set to a network layer for processing;
the authorization layer is set to comprise a digital certificate issuing mechanism and a node registration and verification module, wherein the authorization layer authorizes the node to join the block chain network and verifies the validity of the node;
the method comprises the steps that the application layer is set to comprise digital certificate and key management, a client side SDK, a command line interface and a remote calling interface, wherein the application layer provides an interactive mode of the client side and a block chain, and provides an application authorization API, a transaction proposal API, an authorization result callback API, an execution intelligent contract API and an execution result callback API for the client side in a code calling and command line mode.
Further, in the above method, the digital certificate issuing authority is commonly maintained by the related organizations participating in the smart contract, the digital certificate issuing authority holds a group of key pairs, the key pairs are generated by an ECDSA algorithm, the public keys in the key pairs held by the digital certificate issuing authority inform all nodes in the network, the private key in the key pair is owned by the issuing authority, the nodes can join the block chain network after being granted with the digital certificate and the private key by the digital certificate issuing authority, the digital signature algorithm ensures that the digital certificate and the private key cannot be forged, the digital signature uses a group of key pairs, the key pair used by the digital signature is signed and issued by the digital certificate issuing authority, the nodes need to apply for authorization to the digital certificate issuing authority before joining the network, the digital certificate issuing authority generates a group of key pairs for the nodes after applying, and the public keys and the node information are stored as the digital certificate, the digital certificate signing and issuing organization uses a private key of the digital certificate signing and issuing organization to digitally sign the certificate, the signed digital certificate and a node private key are stored by nodes, the nodes carry the digital certificate on all messages broadcasted in a network and use the private key of the digital certificate signing and digitally sign the messages, other nodes check the validity of a sender after receiving the broadcast, the check is divided into certificate validity check and certificate holding check, the certificate validity check is to check whether the certificate is generated by the digital certificate signing and issuing organization, an ECC algorithm is used to verify whether the content of the digital certificate is signed by the digital certificate signing and issuing organization, the certificate holding check ensures that the nodes obtain the certificate from the digital certificate signing and issuing organization but not copy the certificates of other nodes, and the ECC algorithm is used to verify whether the broadcast content and the broadcasted digital signature accord with a public key in the digital certificate.
Further, in the method, the client side SDK is divided into Java SDK, PHP SDK, Go SDK, and corresponds to the client sides implemented by different programming languages, respectively, and the client side SDK converts the codes of the different programming languages into JSON character strings and sends the JSON character strings to the remote invocation interface; the command line interface converts the input of the command line into a JSON character string and sends the JSON character string to the remote calling interface; the receiving and output data formats of the remote calling interface are JSON character strings, and data are transmitted through an HTTP (hyper text transport protocol), wherein for an application authorization API (application program interface), the received data are analyzed into application information and sent to a network layer, and the API is called back to notify a client through an authorization result; and for the transaction proposal API, analyzing the received data into an intelligent contract calling instruction, generating a transaction proposal digital signature by using a private key and attaching a digital certificate as a transaction proposal message to be sent to a network layer, and calling back the API to notify the client through the execution result after the local account book of the node is updated.
According to another aspect of the present invention, there is also provided a block chain implementation device for running an intelligent contract, including:
the client is used for packaging the intelligent contract calling instruction into a transaction proposal, initiating the transaction proposal to a plurality of accounting nodes, waiting for the plurality of accounting nodes to respond to the transaction proposal, comparing the proposal results, if the proposal results are not consistent, reinitiating the transaction proposal, and if the proposal results are consistent, submitting the proposal results to a consensus node group;
the system comprises a bookkeeping node, a block chain and a block chain, wherein the bookkeeping node is used for storing a group of key pairs, storing a distributed account book, operating an intelligent contract and verifying transactions, and is used for verifying the validity of a transaction proposal and executing the transaction proposal verified as valid, returning a proposal result to a client, verifying the transaction proposal in a pending block after the bookkeeping node receives the pending block of a common node, and packaging the transaction proposal only containing successful verification into a block after rejecting the transaction proposal failed verification to be added to the block chain;
the consensus node is used for storing a group of key pairs, storing a distributed account book, operating an intelligent contract, verifying transactions, sequencing a plurality of transactions in a block and achieving sequenced consensus among all the consensus nodes; the consensus node group is used for collecting the proposal result, verifying the validity of the proposal result, adding a serial number to the proposal result verified to be valid, packing the proposal result into an undetermined block when the serial number reaches a preset serial number threshold or the waiting time for collecting the proposal result reaches a preset time threshold, sending the undetermined block to the accounting node, verifying the transaction proposal in the undetermined block, and packing the transaction proposal only containing successful verification into a block after removing the transaction proposal failed in verification to be added to a block chain.
Further, the above apparatus further includes:
the data layer comprises a key value database and a database management module, the data layer is used for storing block data and data generated by intelligent contracts and providing an interface for increasing, deleting, modifying and checking the intelligent contract data, the data layer defines the structure of a distributed account book in a block chain, the account book consists of the block chain and world states, the block chain is a traceable linked list consisting of blocks, the blocks consist of block heads, block data and metadata, the blocks consist of transaction proposals, and the transaction proposals have two types: the method comprises the steps of deploying transaction and calling transaction, wherein the deploying transaction is a record for writing an intelligent contract file into a block, and the record content comprises a file source code, a deployer, a version number, configuration information and a transaction unique identifier; the calling transaction is the record of the intelligent contract calling process, and the record content comprises the block height of the intelligent contract source code, the transaction unique identifier, the intelligent contract method name, the calling parameter and the digital signatures of a transaction initiator and an executor; the world state is a set of states of all intelligent contracts, and the state is an expression mode of the intelligent contracts for finally operating the database; the intelligent contract operation result is represented by a read-write set, the read-write set consists of a read set and a write set, and the write set is a set of states generated by one-time calling of the intelligent contract;
the network layer is used for managing a point-to-point network and comprises a data transmission protocol, a node exploration module, a data synchronization module and a broadcast transaction module, wherein the data transmission protocol is a final consistency algorithm and realizes a Gossip protocol and is used for synchronizing data of each node of a block chain; a node discovery module for managing a list of known node IP addresses in the network, the list being manually entered when a blockchain network is deployed, the discovery module generating a discovery message when a new node joins the network, the discovery message including an authorization obtained by the node in the blockchain network and a list of known nodes, the authorization being given by said authorization layer, the data transfer protocol sending and receiving the discovery message, selecting a recipient node from the list of nodes, and broadcasting a discovery message to the recipient, the recipient's discovery module comparing the list of known nodes after receiving the message, adding an IP to the list of local nodes if the discovery message includes a locally unavailable IP, and not updating the local list if the IP is not included, sending back a discovery response to the sender of the discovery message after the comparison is completed, the discovery response including the node's own authorization and the updated list of known nodes, after receiving the exploration response, the receiver updates the local node list in the same way according to the response content, and then sends back a response message of the exploration response, and the receiver updates the node list again; the data synchronization module is used for sending and receiving data synchronization messages, the synchronization messages are divided into synchronization block heights and synchronization block data, the synchronization block heights comprise the local block heights of the nodes and digital signatures of the messages, the synchronization block data comprise block contents to be updated and digital signatures of the messages, the synchronization messages are broadcast to other nodes according to a data transmission protocol, the nodes send the synchronization block height messages at regular time, and when the receiver block heights are found to be larger than the block heights of the nodes, the synchronization block data messages are sent to obtain the latest blocks; the broadcast transaction module is used for being divided into a client side, an accounting node side and a consensus node side and providing different functions for different roles. The client side sends a transaction proposal generated by the application layer to the accounting node, the accounting node side sends an operation result back to the client side, the client side processes the result into a transaction message and sends the transaction message to the consensus node, the transaction message comprises a processing result of the accounting node and a digital signature of the message, and the consensus node side receives the transaction message and sends the consensus result to the accounting node after processing;
the system comprises a consensus layer and a consensus layer, wherein the consensus layer is used for enabling all consensus nodes to form a consensus node group, the consensus node group receives a transaction initiated by a client and sequences a plurality of transactions through a consensus algorithm, and the consensus algorithm is realized by a PBFT algorithm;
the contract layer comprises an intelligent contract packaging and operating system, a contract code checker and a transaction flow module, wherein for the deployment transaction, the contract code checker performs static scanning on the intelligent contract code to intercept a malicious program, the packaging and operating system checks whether the intelligent contract can be operated by the system after checking, and the transaction flow module sends the intelligent contract file to the network layer for processing after checking; for calling transaction, the contract code checker scans the intelligent contract code statically to intercept malicious programs, inputs input parameters contained in the transaction into the packaging and operating system after checking, the packaging and operating system operates the intelligent contract code and then outputs an operation result to the transaction circulation module, and the circulation module processes the operation result into a read-write set with a version number and sends the read-write set to a network layer for processing;
the authorization layer comprises a digital certificate issuing mechanism and a node registration and verification module, wherein the authorization layer authorizes the node and is used for joining the block chain network and verifying the validity of the node;
and the application layer comprises digital certificate and key management, a client SDK, a command line interface and a remote calling interface, wherein the application layer is used for providing an interactive mode of the client and the block chain, and providing an application authorization API, a transaction proposal API, an authorization result callback API, an execution intelligent contract API and an execution result callback API for the client in a code calling and command line mode.
Further, in the above device, the digital certificate issuing authority is commonly maintained by related organizations participating in the smart contract, the digital certificate issuing authority holds a group of key pairs, the key pairs are generated by an ECDSA algorithm, public keys in the key pairs held by the digital certificate issuing authority inform all nodes in the network, a private key in the key pair is owned by the issuing authority, the nodes can join the blockchain network only after being granted with the digital certificate and the private key by the digital certificate issuing authority, the digital certificate and the private key are guaranteed not to be forged by the digital signature algorithm, the digital signature uses a group of key pairs, the key pair used by the digital signature is signed and issued by the digital certificate issuing authority, the nodes need to apply for authorization to the digital certificate issuing authority before joining the network, the digital certificate issuing authority generates a group of key pairs for the nodes after applying, and the public keys and the node information are stored as the digital certificate, the digital certificate signing and issuing organization uses a private key of the digital certificate signing and issuing organization to digitally sign the certificate, the signed digital certificate and a node private key are stored by nodes, the nodes carry the digital certificate on all messages broadcasted in a network and use the private key of the digital certificate signing and digitally sign the messages, other nodes check the validity of a sender after receiving the broadcast, the check is divided into certificate validity check and certificate holding check, the certificate validity check is to check whether the certificate is generated by the digital certificate signing and issuing organization, an ECC algorithm is used to verify whether the content of the digital certificate is signed by the digital certificate signing and issuing organization, the certificate holding check ensures that the nodes obtain the certificate from the digital certificate signing and issuing organization but not copy the certificates of other nodes, and the ECC algorithm is used to verify whether the broadcast content and the broadcasted digital signature accord with a public key in the digital certificate.
Further, in the above device, the client SDK is divided into Java SDK, PHP SDK, Go SDK, and corresponds to clients implemented in different programming languages, respectively, and the client SDK is configured to convert codes of different programming languages into JSON character strings and send the JSON character strings to the remote invocation interface; the command line interface is used for converting the input of the command line into a JSON character string and sending the JSON character string to the remote calling interface; the receiving and output data formats of the remote calling interface are JSON character strings and are used for transmitting data through an HTTP (hyper text transport protocol), wherein for an application authorization API (application programming interface), the received data is analyzed into application information and sent to a network layer, and the API is called back to notify a client through an authorization result; and for the transaction proposal API, analyzing the received data into an intelligent contract calling instruction, generating a transaction proposal digital signature by using a private key and attaching a digital certificate as a transaction proposal message to be sent to a network layer, and calling back the API to notify the client through the execution result after the local account book of the node is updated.
According to another aspect of the present application, there is also provided a computer readable medium having computer readable instructions stored thereon, the computer readable instructions being executable by a processor to implement the method of any one of the above.
According to another aspect of the present application, there is also provided an apparatus for information processing at a network device, the apparatus comprising a memory for storing computer program instructions and a processor for executing the program instructions, wherein the computer program instructions, when executed by the processor, trigger the apparatus to perform any of the methods described above.
Compared with the prior art, the intelligent contract calling instruction is packaged into the transaction proposal through the client, and the transaction proposal is initiated to a plurality of accounting nodes; each accounting node verifies the validity of the transaction proposal, executes the transaction proposal verified to be valid, and returns the proposal result to the client; the client side waits for a plurality of accounting nodes to respond to the transaction proposal, compares the proposal results, re-initiates the transaction proposal if the proposal results are inconsistent, and submits the proposal results to a consensus node group if the proposal results are consistent; the consensus node group collects the proposal results, verifies the validity of the proposal results, adds sequence numbers to the proposal results verified to be valid, when the sequence number reaches a preset sequence number threshold or the waiting time for collecting the proposal result reaches a preset time threshold, packaging the proposed results into a pending block, sending the pending block to the accounting node, meanwhile, the transaction proposal in the pending block is verified, the transaction proposal which only contains successful verification is packed into a block and added to a block chain after the transaction proposal which fails verification is eliminated, meanwhile, after the bookkeeping node receives the undetermined block of the consensus node, the transaction proposal in the undetermined block is verified, the transaction proposal only containing successful verification is packed into a block to be added to the block chain after the transaction proposal with failed verification is removed, the process of operating the intelligent contract by the block chain is optimized, and the server burden of operating the block chain node can be effectively reduced.
Drawings
FIG. 1 is a flow diagram of a method for implementing a blockchain for running intelligent contracts according to an embodiment of the invention;
FIG. 2 is a block data structure diagram according to an embodiment of the invention.
Detailed Description
In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below.
As shown in fig. 1, the present invention provides a method for implementing a blockchain for running an intelligent contract, including:
step S1, dividing the block chain link point roles into a client, an accounting node and a common node group;
step S2, storing a set of public and private keys at the client, and setting the client for initiating a transaction;
step S3, saving a group of key pairs in the accounting node, setting the accounting node as a storage distributed ledger, and operating intelligent contracts and verifying transactions;
step S4, a group of key pairs are stored in the consensus node, the consensus node is set to store a distributed account book, an intelligent contract is operated, the transaction is verified, a plurality of transactions in the block are sequenced, and the sequenced consensus is achieved among all the consensus nodes;
step S5, the client packs the intelligent contract calling instruction into a transaction proposal and initiates the transaction proposal to a plurality of accounting nodes;
step S6, each accounting node verifies the validity of the transaction proposal, executes the transaction proposal verified to be valid, and returns the proposal result to the client;
step S7, the client end waits for a plurality of accounting nodes to respond the transaction proposal, compares the proposal results, re-initiates the transaction proposal if the proposal results are not consistent, and submits the proposal results to a consensus node group if the proposal results are consistent;
step S8, the consensus node group collects the proposal result, verifies the validity of the proposal result, adds a serial number to the proposal result verified to be valid, packs the proposal result into an undetermined block when the serial number reaches a preset serial number threshold or the waiting time for collecting the proposal result reaches a preset time threshold, sends the undetermined block to the accounting node, verifies the transaction proposal in the undetermined block, packs the transaction proposal only containing successful verification into a block to be added to a block chain after removing the transaction proposal with failed verification, verifies the transaction proposal in the undetermined block after receiving the undetermined block of the consensus node, packs the transaction proposal only containing successful verification into a block to be added to the block chain after removing the transaction proposal with failed verification.
The client packs the intelligent contract calling instruction into a transaction proposal and initiates the transaction proposal to a plurality of accounting nodes; each accounting node verifies the validity of the transaction proposal, executes the transaction proposal verified to be valid, and returns the proposal result to the client; the client side waits for a plurality of accounting nodes to respond to the transaction proposal, compares the proposal results, re-initiates the transaction proposal if the proposal results are inconsistent, and submits the proposal results to a consensus node group if the proposal results are consistent; and the consensus node group collects the proposal result, verifies the validity of the proposal result, adds a serial number to the proposal result verified to be valid, packs the proposal result into a pending block when the serial number reaches a preset serial number threshold or the waiting time for collecting the proposal result reaches a preset time threshold, sends the pending block to the accounting node, verifies the transaction proposal in the pending block, packs the transaction proposal only containing successful verification into a block to be added to the block chain after removing the transaction proposal failed in verification, and simultaneously carries out the same verification operation and packs the transaction proposal into a block to be added to the block chain after receiving the pending block of the consensus node.
The block chain is realized by using a Go programming language, the intelligent contract running environment is Golang running, and the information broadcasted on the block chain is an intelligent contract execution instruction and result.
In an embodiment of the method for implementing a blockchain of running intelligent contracts, in step S5, the client packages an intelligent contract invocation instruction into a transaction proposal, and before initiating the transaction proposal to a plurality of accounting nodes, the method further includes:
dividing the corresponding operating systems of the client, the accounting nodes and the consensus node group into six parts including a data layer, a network layer, a consensus layer, a contract layer, an authorization layer and an application layer;
the data layer is set to comprise a key value database and a database management module, and is used for storing block data and data generated by intelligent contracts and providing an interface for increasing, deleting, modifying and checking the intelligent contract data, the data layer defines the structure of a distributed account book in the block chain, the account book consists of a block chain and a world state, wherein the block chain is a traceable linked list consisting of blocks, the blocks consist of block heads, block data and metadata, the blocks consist of transaction proposals, and the transaction proposals have two types: the method comprises the steps of deploying transaction and calling transaction, wherein the deploying transaction is a record for writing an intelligent contract file into a block, and the record content comprises a file source code, a deployer, a version number, configuration information and a transaction unique identifier; the calling transaction is the record of the intelligent contract calling process, and the record content comprises the block height of the intelligent contract source code, the transaction unique identifier, the intelligent contract method name, the calling parameter and the digital signatures of a transaction initiator and an executor; the world state is a set of states of all intelligent contracts, and the state is an expression mode of the intelligent contracts for finally operating the database; the intelligent contract operation result is represented by a read-write set, the read-write set consists of a read set and a write set, wherein the write set is a set of states generated by one-time calling of the intelligent contract, and the Data structure of the Block can be shown as a Block Header (Block Header), Data (Data) and metadata (Meta Data) in FIG. 2;
the network layer is arranged to manage a peer-to-peer network, the network layer comprising a data transmission protocol, a node discovery module, a data synchronization module and a broadcast transaction module, wherein,
the data transmission protocol is a final consistency algorithm, realizes a Gossip protocol and is used for synchronizing data of each node of a block chain, the synchronization process is a flow of sending, receiving, updating, sending back again and updating again in a synchronization period, each period randomly selects one node, and finally the data is transmitted to all nodes;
the node exploration module manages a list of known node IP addresses in the network, the list is manually input when a blockchain network is deployed, when a new node joins the network, the exploration module generates an exploration message, the exploration message comprises authorization obtained by the node in the blockchain network and the known node list, the authorization is given by the authorization layer, the data transmission protocol sends and receives the exploration message, a receiver node is selected from the node list, an exploration message is broadcasted to the receiver, the exploration module of the receiver compares the local known node list after receiving the message, if the exploration message comprises a local node IP, the IP is added to the local node list, if the exploration message does not comprise the local node IP, the local list is not updated, an exploration response is sent back to a sender of the exploration message after the comparison is completed, and the exploration response content comprises the authorization of the node and the updated known node list, after receiving the exploration response, the receiver updates the local node list in the same way according to the response content, and then sends back a response message of the exploration response, and the receiver updates the node list again;
the data synchronization module sends and receives data synchronization messages, the synchronization messages are divided into synchronization block heights and synchronization block data, the synchronization block heights comprise the local block heights of nodes and digital signatures of messages, the synchronization block data comprise block contents needing to be updated and digital signatures of the messages, the synchronization messages are broadcast to other nodes according to a data transmission protocol, the nodes send the synchronization block height messages at regular time, and when the receiver block heights are found to be larger than the block heights of the nodes, the synchronization block data messages are sent to obtain the latest blocks;
the broadcast transaction module is divided into a client side, an accounting node side and a consensus node side, and provides different functions for different roles. The client side sends a transaction proposal generated by the application layer to the accounting node, the accounting node side sends an operation result back to the client side, the client side processes the result into a transaction message and sends the transaction message to the consensus node, the transaction message comprises a processing result of the accounting node and a digital signature of the message, and the consensus node side receives the transaction message and sends the consensus result to the accounting node after processing;
the consensus layer is arranged to enable all consensus nodes to form a consensus node group, the consensus node group receives a transaction initiated by a client and sequences a plurality of transactions through a consensus algorithm, the consensus algorithm is realized by a PBFT algorithm, and the consensus node group can ensure that the sequencing of each transaction inside the node group is consistent;
setting the contract layer to comprise an intelligent contract packaging and running system, a contract code checker and a transaction circulation module, wherein for the deployment transaction, the contract code checker performs static scanning on the intelligent contract code to intercept a malicious program, the packaging and running system checks whether the intelligent contract can be run by the system after checking, and the transaction circulation module sends the intelligent contract file to the network layer for processing after checking; for calling transaction, the contract code checker scans the intelligent contract code statically to intercept malicious programs, inputs input parameters contained in the transaction into the packaging and operating system after checking, the packaging and operating system operates the intelligent contract code and then outputs an operation result to the transaction circulation module, and the circulation module processes the operation result into a read-write set with a version number and sends the read-write set to a network layer for processing;
the authorization layer is set to comprise a digital certificate issuing mechanism and a node registration and verification module, wherein the authorization layer authorizes the node to join the block chain network and verifies the validity of the node; the digital certificate signing and issuing organization is commonly maintained by related organizations participating in an intelligent contract, the digital certificate signing and issuing organization holds a group of key pairs, the key pairs are generated by an ECDSA algorithm, public keys in the key pairs held by the digital certificate signing and issuing organization inform all nodes in a network, a private key in the key pair is owned by the signing and issuing organization only, the nodes can be added into a block chain network after being granted with a digital certificate and a private key by the digital certificate signing and issuing organization, the digital certificate and the private key cannot be forged by the digital signature algorithm, the digital signature uses a group of key pairs, the key pair used by the digital signature is signed and issued by the digital certificate signing and issuing organization, the nodes are required to apply for authorization to the digital certificate signing and issuing organization before being added into the network, the digital certificate signing and issuing organization generates a group of key pairs for the nodes after applying, and stores the public key and the node information as a digital certificate, the digital certificate signing and issuing organization uses a private key of the digital certificate signing and issuing organization to digitally sign the certificate, the signed digital certificate and a node private key are stored by nodes, the nodes carry the digital certificate on all messages broadcasted in a network and use the private key of the digital certificate signing and digitally sign the messages, other nodes check the legality of a sender after receiving the broadcast, the check is divided into certificate validity check and certificate holding check, the certificate validity check is to check whether the certificate is generated by the digital certificate signing and issuing organization, an ECC algorithm is used to verify whether the content of the digital certificate is signed by the digital certificate signing and issuing organization, the certificate holding check ensures that the nodes obtain the certificate from the digital certificate signing and issuing organization but not copy the certificates of other nodes, and the ECC algorithm is used to verify whether the broadcast content and the broadcasted digital signature conform to the public key in the digital certificate;
setting the application layer to comprise digital certificate and key management, a client SDK, a command line interface and a remote calling interface, wherein the application layer provides an interactive mode of the client and a block chain, and provides an application authorization API, a transaction proposal API, an authorization result callback API, an execution intelligent contract API and an execution result callback API to the client in a code calling and command line mode;
the client side SDK is divided into Java SDK, PHP SDK and Go SDK which respectively correspond to client sides realized by different programming languages, and converts codes of different programming languages into JSON character strings and sends the JSON character strings to a remote calling interface; the command line interface converts the input of the command line into a JSON character string and sends the JSON character string to the remote calling interface; the receiving and output data format of the remote calling interface is JSON character string, and transmits data through HTTP protocol, wherein,
for the application authorization API, analyzing the received data into application information, sending the application information to the network layer, and calling back the API to notify the client through an authorization result; and for the transaction proposal API, analyzing the received data into an intelligent contract calling instruction, generating a transaction proposal digital signature by using a private key and attaching a digital certificate as a transaction proposal message to be sent to a network layer, and calling back the API to notify the client through the execution result after the local account book of the node is updated.
According to another aspect of the present invention, there is also provided a block chain implementation device for running an intelligent contract, including:
the client is used for packaging the intelligent contract calling instruction into a transaction proposal, initiating the transaction proposal to a plurality of accounting nodes, waiting for the plurality of accounting nodes to respond to the transaction proposal, comparing the proposal results, if the proposal results are not consistent, reinitiating the transaction proposal, and if the proposal results are consistent, submitting the proposal results to a consensus node group;
the system comprises a bookkeeping node, a block chain and a block chain, wherein the bookkeeping node is used for storing a group of key pairs, storing a distributed account book, operating an intelligent contract and verifying transactions, and is used for verifying the validity of a transaction proposal and executing the transaction proposal verified as valid, returning a proposal result to a client, verifying the transaction proposal in a pending block after the bookkeeping node receives the pending block of a common node, and packaging the transaction proposal only containing successful verification into a block after rejecting the transaction proposal failed verification to be added to the block chain;
the consensus node is used for storing a group of key pairs, storing a distributed account book, operating an intelligent contract, verifying transactions, sequencing a plurality of transactions in a block and achieving sequenced consensus among all the consensus nodes; the consensus node group is used for collecting the proposal result, verifying the validity of the proposal result, adding a serial number to the proposal result verified to be valid, packing the proposal result into an undetermined block when the serial number reaches a preset serial number threshold or the waiting time for collecting the proposal result reaches a preset time threshold, sending the undetermined block to the accounting node, verifying the transaction proposal in the undetermined block, and packing the transaction proposal only containing successful verification into a block after removing the transaction proposal failed in verification to be added to a block chain.
In an embodiment of the block chain implementation device for running the intelligent contract, the block chain implementation device includes:
the data layer comprises a key value database and a database management module, the data layer is used for storing block data and data generated by intelligent contracts and providing an interface for increasing, deleting, modifying and checking the intelligent contract data, the data layer defines the structure of a distributed account book in a block chain, the account book consists of the block chain and world states, the block chain is a traceable linked list consisting of blocks, the blocks consist of block heads, block data and metadata, the blocks consist of transaction proposals, and the transaction proposals have two types: the method comprises the steps of deploying transaction and calling transaction, wherein the deploying transaction is a record for writing an intelligent contract file into a block, and the record content comprises a file source code, a deployer, a version number, configuration information and a transaction unique identifier; the calling transaction is the record of the intelligent contract calling process, and the record content comprises the block height of the intelligent contract source code, the transaction unique identifier, the intelligent contract method name, the calling parameter and the digital signatures of a transaction initiator and an executor; the world state is a set of states of all intelligent contracts, and the state is an expression mode of the intelligent contracts for finally operating the database; the intelligent contract operation result is represented by a read-write set, the read-write set consists of a read set and a write set, and the write set is a set of states generated by one-time calling of the intelligent contract;
the network layer is used for managing a point-to-point network and comprises a data transmission protocol, a node exploration module, a data synchronization module and a broadcast transaction module, wherein the data transmission protocol is a final consistency algorithm and realizes a Gossip protocol and is used for synchronizing data of each node of a block chain; a node discovery module for managing a list of known node IP addresses in the network, the list being manually entered when a blockchain network is deployed, the discovery module generating a discovery message when a new node joins the network, the discovery message including an authorization obtained by the node in the blockchain network and a list of known nodes, the authorization being given by said authorization layer, the data transfer protocol sending and receiving the discovery message, selecting a recipient node from the list of nodes, and broadcasting a discovery message to the recipient, the recipient's discovery module comparing the list of known nodes after receiving the message, adding an IP to the list of local nodes if the discovery message includes a locally unavailable IP, and not updating the local list if the IP is not included, sending back a discovery response to the sender of the discovery message after the comparison is completed, the discovery response including the node's own authorization and the updated list of known nodes, after receiving the exploration response, the receiver updates the local node list in the same way according to the response content, and then sends back a response message of the exploration response, and the receiver updates the node list again; the data synchronization module is used for sending and receiving data synchronization messages, the synchronization messages are divided into synchronization block heights and synchronization block data, the synchronization block heights comprise the local block heights of the nodes and digital signatures of the messages, the synchronization block data comprise block contents to be updated and digital signatures of the messages, the synchronization messages are broadcast to other nodes according to a data transmission protocol, the nodes send the synchronization block height messages at regular time, and when the receiver block heights are found to be larger than the block heights of the nodes, the synchronization block data messages are sent to obtain the latest blocks; the broadcast transaction module is used for being divided into a client side, an accounting node side and a consensus node side and providing different functions for different roles. The client side sends a transaction proposal generated by the application layer to the accounting node, the accounting node side sends an operation result back to the client side, the client side processes the result into a transaction message and sends the transaction message to the consensus node, the transaction message comprises a processing result of the accounting node and a digital signature of the message, and the consensus node side receives the transaction message and sends the consensus result to the accounting node after processing;
the system comprises a consensus layer and a consensus layer, wherein the consensus layer is used for enabling all consensus nodes to form a consensus node group, the consensus node group receives a transaction initiated by a client and sequences a plurality of transactions through a consensus algorithm, and the consensus algorithm is realized by a PBFT algorithm;
the contract layer comprises an intelligent contract packaging and operating system, a contract code checker and a transaction flow module, wherein for the deployment transaction, the contract code checker performs static scanning on the intelligent contract code to intercept a malicious program, the packaging and operating system checks whether the intelligent contract can be operated by the system after checking, and the transaction flow module sends the intelligent contract file to the network layer for processing after checking; for calling transaction, the contract code checker scans the intelligent contract code statically to intercept malicious programs, inputs input parameters contained in the transaction into the packaging and operating system after checking, the packaging and operating system operates the intelligent contract code and then outputs an operation result to the transaction circulation module, and the circulation module processes the operation result into a read-write set with a version number and sends the read-write set to a network layer for processing;
the authorization layer comprises a digital certificate issuing mechanism and a node registration and verification module, wherein the authorization layer authorizes the node and is used for joining the block chain network and verifying the validity of the node;
and the application layer comprises digital certificate and key management, a client SDK, a command line interface and a remote calling interface, wherein the application layer is used for providing an interactive mode of the client and the block chain, and providing an application authorization API, a transaction proposal API, an authorization result callback API, an execution intelligent contract API and an execution result callback API for the client in a code calling and command line mode.
In one embodiment of the block chain implementation device for operating the intelligent contract, the digital certificate issuing authority is commonly maintained by related organizations participating in the intelligent contract, the digital certificate issuing authority holds a group of key pairs, the key pairs are generated by an ECDSA algorithm, public keys in the key pairs held by the digital certificate issuing authority inform all nodes in a network, private keys in the key pairs only have the issuing authority, the nodes can be added into the block chain network after being granted with digital certificates and private keys by the digital certificate issuing authority, the digital certificates and the private keys are guaranteed to be unforgeable by a digital signature algorithm, the digital signatures use a group of key pairs, the key pairs used by the digital signatures are signed and issued by the digital certificate issuing authority, the nodes need to apply for authorization to the digital certificate issuing authority before adding into the network, and the digital certificate issuing authority generates a group of key pairs for the nodes after applying, the public key and the node information are stored as a digital certificate, a digital certificate signing authority uses a self private key to digitally sign the certificate, the signed digital certificate and the node private key are stored by the node, the node carries the digital certificate on all messages broadcast in the network and uses the self private key to digitally sign the messages, and the other nodes check the legality of the sender after receiving the broadcast, wherein the check comprises certificate validity check and certificate holding check, the certificate validity check is to check whether the certificate is generated by the digital certificate issuing authority, an ECC algorithm is used for verifying whether the content of the digital certificate is signed by the digital certificate issuing authority, the certificate holding check ensures that the nodes obtain the certificate from the digital certificate issuing authority instead of copying the certificates of the other nodes, and the ECC algorithm is used for verifying whether the broadcast content and the broadcast digital signature conform to the public key in the digital certificate.
In an embodiment of the block chain implementation device for running the intelligent contract, the client SDK is divided into Java SDK, PHP SDK and Go SDK, and corresponds to clients implemented by different programming languages, respectively, and the client SDK is used for converting codes of different programming languages into JSON character strings and sending the JSON character strings to the remote call interface; the command line interface is used for converting the input of the command line into a JSON character string and sending the JSON character string to the remote calling interface; the receiving and output data formats of the remote calling interface are JSON character strings and are used for transmitting data through an HTTP (hyper text transport protocol), wherein for an application authorization API (application programming interface), the received data is analyzed into application information and sent to a network layer, and the API is called back to notify a client through an authorization result; and for the transaction proposal API, analyzing the received data into an intelligent contract calling instruction, generating a transaction proposal digital signature by using a private key and attaching a digital certificate as a transaction proposal message to be sent to a network layer, and calling back the API to notify the client through the execution result after the local account book of the node is updated.
According to another aspect of the present application, there is also provided a computer readable medium having computer readable instructions stored thereon, the computer readable instructions being executable by a processor to implement the method of any one of the above.
According to another aspect of the present application, there is also provided an apparatus for information processing at a network device, the apparatus comprising a memory for storing computer program instructions and a processor for executing the program instructions, wherein the computer program instructions, when executed by the processor, trigger the apparatus to perform any of the methods described above.
For details of the embodiments of the apparatuses and the storage medium, reference may be made to corresponding parts of the embodiments of the methods, and details are not described herein again.
The embodiments in the present description are 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.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
It will be apparent to those skilled in the art that various changes and modifications may be made in the invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (10)

1. A method for implementing a blockchain for running intelligent contracts is characterized by comprising the following steps:
dividing the block chain link point roles into a client, a billing node and a consensus node;
storing a set of public and private keys at the client, and setting the client for initiating a transaction;
saving a group of key pairs at the accounting node, setting the accounting node as a storage distributed account book, and operating an intelligent contract and verifying a transaction;
storing a group of key pairs in the consensus nodes, setting the consensus nodes as a storage distributed account book, operating an intelligent contract, verifying transactions, sequencing a plurality of transactions in a block and achieving sequenced consensus among all the consensus nodes;
the client packs the intelligent contract calling instruction into a transaction proposal and initiates the transaction proposal to a plurality of accounting nodes;
each accounting node verifies the validity of the transaction proposal, executes the transaction proposal verified to be valid, and returns a transaction proposal result to the client;
the client side waits for a plurality of accounting nodes to respond to the transaction proposal, compares transaction proposal results, re-initiates the transaction proposal if the transaction proposal results are inconsistent, and submits the transaction proposal results to a consensus node group if the transaction proposal results are consistent, wherein the consensus node group is formed by a plurality of consensus nodes;
the common identification node group collects the transaction proposal result, verifies the validity of the transaction proposal result, adds a serial number to the transaction proposal result verified to be valid, packs the transaction proposal result into an undetermined block when the serial number reaches a preset serial number threshold or the waiting time for collecting the transaction proposal result reaches a preset time threshold, sends the undetermined block to the accounting node, verifies the transaction proposal in the undetermined block, packs the transaction proposal only containing successful verification into a block after removing the transaction proposal with failed verification and adds the block to a block chain, verifies the transaction proposal in the undetermined block after the accounting node receives the undetermined block of the common identification node, packs the transaction proposal only containing successful verification into a block after removing the transaction proposal with failed verification and adds the block to the block chain.
2. A blockchain implementation method of running smart contracts as recited in claim 1 wherein the client packages smart contract invocation instructions into a transaction proposal, further comprising, prior to initiating the transaction proposal to the plurality of accounting nodes:
dividing the corresponding operating systems of the client, the accounting nodes and the consensus node group into six parts including a data layer, a network layer, a consensus layer, a contract layer, an authorization layer and an application layer;
the data layer is set to comprise a key value database and a database management module, and is used for storing block data and data generated by an intelligent contract and providing an interface for increasing, deleting, modifying and checking the intelligent contract data, the data layer defines the structure of a distributed account book in a block chain, the distributed account book consists of the block chain and world states, wherein the block chain is a traceable linked list consisting of blocks, the blocks consist of block heads, block data and metadata, the blocks consist of transaction proposals, and the transaction proposals have two types: the method comprises the steps of deploying transaction and calling transaction, wherein the deploying transaction is a record for writing an intelligent contract file into a block, and the record content comprises a file source code, a deployer, a version number, configuration information and a transaction unique identifier; the calling transaction is the record of the intelligent contract calling process, and the record content comprises the block height of the intelligent contract source code, the transaction unique identifier, the intelligent contract method name, the calling parameter and the digital signatures of a transaction initiator and an executor; the world state is a set of states of all intelligent contracts, and the state is an expression mode of the final operation on the key value database after the intelligent contracts are operated; the intelligent contract operation result is represented by a read-write set, the read-write set consists of a read set and a write set, and the write set is a set of states generated by one-time calling of the intelligent contract;
the method comprises the steps that a network layer is set to manage a point-to-point network, the network layer comprises a data transmission protocol, a node exploration module, a data synchronization module and a broadcast transaction module, wherein the data transmission protocol is a final consistency algorithm and realizes a GossIP protocol and is used for synchronizing data of each node of a block chain, the synchronization process is a flow of sending, receiving, updating, sending back again and updating again in a synchronization period, one node is randomly selected in each period, and finally the data are spread to all nodes; the node exploration module manages a list of known node IP addresses in the network, the list is manually input when a blockchain network is deployed, when a new node joins the network, the node exploration module generates an exploration message, the exploration message comprises authorization obtained by the node in the blockchain network and the known node list, the authorization is given by an authorization layer, the data transmission protocol sends and receives the exploration message, a receiver node is selected from the known node list, an exploration message is broadcasted to the receiver, the node exploration module of the receiver compares the local known node list after receiving the message, if the exploration message comprises a local node IP address, the IP address is added to the local known node list, if the exploration message does not comprise the local known node list, the local known node list is not updated, and after the comparison is completed, an exploration response is sent back to a sender of the exploration message, the exploration response content comprises the authorization of the node and the updated known node list, the receiver updates the local known node list in the same way according to the response content after receiving the exploration response, and then sends back the response message of the exploration response, and the receiver updates the local known node list again; the data synchronization module sends and receives data synchronization messages, wherein the data synchronization messages are divided into synchronization block heights and synchronization block data, the synchronization block heights comprise the local block heights of nodes and digital signatures of messages, the synchronization block data comprise block contents needing to be updated and digital signatures of the messages, the data synchronization messages are broadcast to other nodes according to a data transmission protocol, the nodes send the synchronization block height messages at regular time, and when the receiver block heights are found to be larger than the self block heights, the synchronization block data messages are sent to obtain the latest blocks; the broadcast transaction module is divided into a client side, an accounting node side and a consensus node side, different functions are provided for different roles, the client side sends a transaction proposal generated by an application layer to the accounting node, the accounting node side sends an operation result back to the client, the client side processes the operation result into a transaction message and sends the transaction message to the consensus node, the transaction message comprises the operation result of the accounting node and a digital signature of the message, and the consensus node side receives the transaction message and sends the consensus result to the accounting node after processing;
setting the consensus layer to enable all consensus nodes to form a consensus node group, wherein the consensus node group receives a transaction initiated by a client and sorts a plurality of transactions through a consensus algorithm, and the consensus algorithm is realized by a PBFT algorithm;
setting the contract layer to comprise an intelligent contract packaging and running system, a contract code checker and a transaction circulation module, wherein for the deployment transaction, the contract code checker performs static scanning on the intelligent contract code to intercept a malicious program, the intelligent contract packaging and running system checks whether the intelligent contract can be run by the system or not after checking, and the transaction circulation module sends the intelligent contract file to the network layer for processing after checking; for calling transaction, the contract code checker scans the intelligent contract code statically to intercept malicious programs, inputs input parameters contained in the transaction to the intelligent contract packaging and operating system after checking, the intelligent contract packaging and operating system outputs an operating result to the transaction flow module after operating the intelligent contract code, and the transaction flow module processes the operating result into a read-write set with a version number and sends the read-write set to a network layer for processing;
the authorization layer is set to comprise a digital certificate issuing mechanism and a node registration and verification module, wherein the authorization layer authorizes the node to join the block chain network and verifies the validity of the node;
the method comprises the steps that the application layer is set to comprise digital certificate and key management, a client side SDK, a command line interface and a remote calling interface, wherein the application layer provides an interactive mode of the client side and a block chain, and provides an application authorization API, a transaction proposal API, an authorization result callback API, an execution intelligent contract API and an execution result callback API for the client side in a code calling and command line mode.
3. The method as claimed in claim 2, wherein the digital certificate issuing authority is commonly maintained by the related organizations participating in the smart contract, the digital certificate issuing authority holds a group of key pairs, the key pairs are generated by the ECDSA algorithm, the public key of the key pair held by the digital certificate issuing authority informs all nodes in the network, the private key of the key pair is owned by the digital certificate issuing authority, the nodes can join the blockchain network only after being granted the digital certificate and the private key by the digital certificate issuing authority, the digital signature algorithm ensures that the digital certificate and the private key cannot be forged, the digital signature uses a group of key pairs, the key pair used by the digital signature is signed and issued by the digital certificate issuing authority, the node must apply for authorization to the digital certificate issuing authority before joining the network, and the digital certificate issuing authority generates a group of key pairs for the node after applying, the public key and the node information are stored as a digital certificate, a digital certificate signing authority uses a self private key to digitally sign the certificate, the signed digital certificate and the node private key are stored by the node, the node carries the digital certificate on all messages broadcast in the network and uses the self private key to digitally sign the messages, and the other nodes check the legality of the sender after receiving the broadcast, wherein the check comprises certificate validity check and certificate holding check, the certificate validity check is to check whether the certificate is generated by the digital certificate issuing authority, an ECC algorithm is used for verifying whether the content of the digital certificate is signed by the digital certificate issuing authority, the certificate holding check ensures that the nodes obtain the certificate from the digital certificate issuing authority instead of copying the certificates of the other nodes, and the ECC algorithm is used for verifying whether the broadcast content and the broadcast digital signature conform to the public key in the digital certificate.
4. The method for implementing a blockchain of running an intelligent contract according to claim 2, wherein the client SDK is divided into Java SDK, PHP SDK and Go SDK, and respectively corresponds to client sides implemented by different programming languages, and the client SDK converts codes of different programming languages into JSON character strings and sends the JSON character strings to the remote invocation interface; the command line interface converts the input of the command line into a JSON character string and sends the JSON character string to the remote calling interface; the receiving and output data formats of the remote calling interface are JSON character strings, and data are transmitted through an HTTP (hyper text transport protocol), wherein for an application authorization API (application program interface), the received data are analyzed into application information and sent to a network layer, and the API is called back to notify a client through an authorization result; and for the transaction proposal API, analyzing the received data into an intelligent contract calling instruction, generating a transaction proposal digital signature by using a private key and attaching a digital certificate as a transaction proposal message to be sent to a network layer, and calling back the API to notify the client through the execution result after the local account book of the node is updated.
5. A blockchain implementation device that runs smart contracts, comprising:
the client is used for packaging the intelligent contract calling instruction into a transaction proposal, initiating the transaction proposal to a plurality of accounting nodes, waiting for the plurality of accounting nodes to respond to the transaction proposal, comparing the transaction proposal results, if the transaction proposal results are inconsistent, reinitiating the transaction proposal, if the transaction proposal results are consistent, submitting the transaction proposal results to a consensus node group, and forming the consensus node group by the plurality of consensus nodes;
the system comprises a bookkeeping node, a block chain and a block chain, wherein the bookkeeping node is used for storing a group of key pairs, storing a distributed account book, operating an intelligent contract and verifying transactions, and is used for verifying the validity of a transaction proposal and executing the transaction proposal verified as valid, returning a transaction proposal result to a client, verifying the transaction proposal in a pending block after the bookkeeping node receives the pending block of a common node, and packaging the transaction proposal only containing successful verification into a block to be added to the block chain after rejecting the transaction proposal failed in verification;
the consensus node is used for storing a group of key pairs, storing a distributed account book, operating an intelligent contract, verifying transactions, sequencing a plurality of transactions in a block and achieving sequenced consensus among all the consensus nodes; the consensus node group is used for collecting the transaction proposal result, verifying the validity of the transaction proposal result, adding a serial number to the transaction proposal result verified to be valid, packing the transaction proposal result into an undetermined block when the serial number reaches a preset serial number threshold or the waiting time for collecting the transaction proposal result reaches a preset time threshold, sending the undetermined block to the accounting node, verifying the transaction proposal in the undetermined block, and packing the transaction proposal only containing successful verification into a block to be added to a block chain after the transaction proposal failed in verification is eliminated.
6. A blockchain implementation device running intelligent contracts as recited in claim 5 further comprising:
the data layer comprises a key value database and a database management module, the data layer is used for storing block data and data generated by intelligent contracts and providing an interface for increasing, deleting, modifying and checking the intelligent contract data, the data layer defines the structure of a distributed account book in a block chain, the distributed account book consists of the block chain and world states, the block chain is a traceable linked list consisting of blocks, the blocks consist of block heads, block data and metadata, the blocks consist of transaction proposals, and the transaction proposals have two types: the method comprises the steps of deploying transaction and calling transaction, wherein the deploying transaction is a record for writing an intelligent contract file into a block, and the record content comprises a file source code, a deployer, a version number, configuration information and a transaction unique identifier; the calling transaction is the record of the intelligent contract calling process, and the record content comprises the block height of the intelligent contract source code, the transaction unique identifier, the intelligent contract method name, the calling parameter and the digital signatures of a transaction initiator and an executor; the world state is a set of states of all intelligent contracts, and the state is an expression mode of the final operation on the key value database after the intelligent contracts are operated; the intelligent contract operation result is represented by a read-write set, the read-write set consists of a read set and a write set, and the write set is a set of states generated by one-time calling of the intelligent contract;
the network layer is used for managing a point-to-point network and comprises a data transmission protocol, a node exploration module, a data synchronization module and a broadcast transaction module, wherein the data transmission protocol is a final consistency algorithm and realizes a GossIP protocol and is used for synchronizing data of each node of a block chain; a node discovery module for managing a list of known node IP addresses in the network, the list being manually entered when a blockchain network is deployed, the node discovery module generating a discovery message when a new node joins the network, the discovery message including an authorization obtained by the node in the blockchain network and the list of known nodes, the authorization being given by an authorization layer, the data transfer protocol sending and receiving the discovery message, selecting a recipient node from the list of known nodes, and broadcasting a discovery message to the recipient, the recipient node discovery module comparing the list of known nodes after receiving the message, adding the IP address to the list of known nodes if the discovery message includes a local node IP address, and not updating the list of known nodes if the discovery message does not include the local node IP address, sending a discovery response back to the sender of the discovery message after the comparison is completed, the exploration response content comprises the authorization of the node and the updated known node list, the receiver updates the local known node list in the same way according to the response content after receiving the exploration response, and then sends back the response message of the exploration response, and the receiver updates the local known node list again; the data synchronization module is used for sending and receiving data synchronization messages, the data synchronization messages are divided into synchronization block heights and synchronization block data, the synchronization block heights comprise the local block heights of the nodes and the digital signatures of the messages, the synchronization block data comprise block contents to be updated and the digital signatures of the messages, the data synchronization messages are broadcast to other nodes according to a data transmission protocol, the nodes send the synchronization block height messages at regular time, and when the receiver block heights are found to be larger than the block heights of the nodes, the synchronization block data messages are sent to obtain the latest blocks; the broadcast transaction module is used for being divided into a client side, an accounting node side and a consensus node side and providing different functions for different roles, the client side sends a transaction proposal generated by an application layer to the accounting node, the accounting node side sends an operation result back to the client, the client side processes the operation result into a transaction message and sends the transaction message to the consensus node, the transaction message comprises the operation result of the accounting node and a digital signature of the message, and the consensus node side receives the transaction message and sends the consensus result to the accounting node after the transaction message is processed;
the system comprises a consensus layer and a consensus layer, wherein the consensus layer is used for enabling all consensus nodes to form a consensus node group, the consensus node group receives a transaction initiated by a client and sequences a plurality of transactions through a consensus algorithm, and the consensus algorithm is realized by a PBFT algorithm;
the contract layer comprises an intelligent contract packaging and running system, a contract code checker and a transaction flow module, wherein for the deployment transaction, the contract code checker performs static scanning on the intelligent contract code to intercept a malicious program, the intelligent contract packaging and running system checks whether the intelligent contract can be run by the system or not after checking, and the transaction flow module sends the intelligent contract file to the network layer for processing after checking; for calling transaction, the contract code checker scans the intelligent contract code statically to intercept malicious programs, inputs input parameters contained in the transaction to the intelligent contract packaging and operating system after checking, the intelligent contract packaging and operating system outputs an operating result to the transaction flow module after operating the intelligent contract code, and the transaction flow module processes the operating result into a read-write set with a version number and sends the read-write set to a network layer for processing;
the authorization layer comprises a digital certificate issuing mechanism and a node registration and verification module, wherein the authorization layer authorizes the node and is used for joining the block chain network and verifying the validity of the node;
the application layer comprises a digital certificate and key management layer, a client side SDK, a command line interface and a remote calling interface, wherein the application layer is used for providing an interactive mode of the client side and a block chain, and providing an application authorization API, a transaction proposal API, an authorization result callback API, an execution intelligent contract API and an execution result callback API for the client side in a code calling and command line mode.
7. The blockchain implementation apparatus for running smart contracts according to claim 6, wherein the digital certificate issuing authority is commonly maintained by related organizations participating in the smart contracts, the digital certificate issuing authority holds a group of key pairs, the key pairs are generated by the ECDSA algorithm, public keys in the key pairs held by the digital certificate issuing authority inform all nodes in the network, private keys in the key pairs are owned by the digital certificate issuing authority, the nodes can join the blockchain network only after being granted with digital certificates and private keys by the digital certificate issuing authority, the digital certificates and the private keys are guaranteed to be not counterfeitable by the digital signature algorithm, the digital signature uses a group of key pairs, the key pairs used by the digital signature are signed and issued by the digital certificate issuing authority, authorization must be applied to the digital certificate issuing authority before the nodes join the network, and the digital certificate issuing authority generates a group of key pairs for the nodes after application, the public key and the node information are stored as a digital certificate, a digital certificate signing authority uses a self private key to digitally sign the certificate, the signed digital certificate and the node private key are stored by the node, the node carries the digital certificate on all messages broadcast in the network and uses the self private key to digitally sign the messages, and the other nodes check the legality of the sender after receiving the broadcast, wherein the check comprises certificate validity check and certificate holding check, the certificate validity check is to check whether the certificate is generated by the digital certificate issuing authority, an ECC algorithm is used for verifying whether the content of the digital certificate is signed by the digital certificate issuing authority, the certificate holding check ensures that the nodes obtain the certificate from the digital certificate issuing authority instead of copying the certificates of the other nodes, and the ECC algorithm is used for verifying whether the broadcast content and the broadcast digital signature conform to the public key in the digital certificate.
8. The device for implementing a blockchain of running an intelligent contract according to claim 7, wherein the client SDK is divided into Java SDK, PHP SDK, Go SDK, and corresponds to client sides implemented by different programming languages, respectively, and the client SDK is configured to convert codes of different programming languages into JSON character strings and send the JSON character strings to the remote invocation interface; the command line interface is used for converting the input of the command line into a JSON character string and sending the JSON character string to the remote calling interface; the receiving and output data formats of the remote calling interface are JSON character strings and are used for transmitting data through an HTTP (hyper text transport protocol), wherein for an application authorization API (application programming interface), the received data is analyzed into application information and sent to a network layer, and the API is called back to notify a client through an authorization result; and for the transaction proposal API, analyzing the received data into an intelligent contract calling instruction, generating a transaction proposal digital signature by using a private key and attaching a digital certificate as a transaction proposal message to be sent to a network layer, and calling back the API to notify the client through the execution result after the local account book of the node is updated.
9. A computer readable medium having computer readable instructions stored thereon which are executable by a processor to implement the method of any one of claims 1 to 4.
10. An apparatus for information processing at a network device, the apparatus comprising a memory for storing computer program instructions and a processor for executing the computer program instructions, wherein the computer program instructions, when executed by the processor, trigger the apparatus to perform the method of any one of claims 1 to 4.
CN201810491690.3A 2018-05-21 2018-05-21 Block chain implementation method and equipment for running intelligent contracts Active CN108769173B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810491690.3A CN108769173B (en) 2018-05-21 2018-05-21 Block chain implementation method and equipment for running intelligent contracts

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810491690.3A CN108769173B (en) 2018-05-21 2018-05-21 Block chain implementation method and equipment for running intelligent contracts

Publications (2)

Publication Number Publication Date
CN108769173A CN108769173A (en) 2018-11-06
CN108769173B true CN108769173B (en) 2021-11-09

Family

ID=64007505

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810491690.3A Active CN108769173B (en) 2018-05-21 2018-05-21 Block chain implementation method and equipment for running intelligent contracts

Country Status (1)

Country Link
CN (1) CN108769173B (en)

Families Citing this family (76)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
SG11201903566XA (en) 2018-11-07 2019-05-30 Alibaba Group Holding Ltd Regulating blockchain confidential transactions
KR102208891B1 (en) 2018-11-07 2021-01-29 어드밴스드 뉴 테크놀로지스 씨오., 엘티디. Encrypted transaction information recovery from blockchain confidential transactions
CN109327459B (en) * 2018-11-12 2020-12-01 崔晓晖 Consensus method for union block chain network
CN109547200A (en) * 2018-11-21 2019-03-29 上海点融信息科技有限责任公司 Certificate distribution method and corresponding calculating equipment and medium in block chain network
CN109493053A (en) * 2018-11-22 2019-03-19 质数链网科技成都有限公司 A kind of anonymous deal method for alliance's block catenary system
CN109726229B (en) * 2018-11-30 2023-10-10 深圳市元征科技股份有限公司 Block chain data storage method and device
CN109587238B (en) * 2018-12-03 2021-08-03 百度在线网络技术(北京)有限公司 Data processing and synchronizing method, device, equipment and storage medium of block chain
CN109697217B (en) * 2018-12-06 2021-04-06 成都佰纳瑞信息技术有限公司 Block chain transaction processing method
CN110851496B (en) * 2018-12-07 2023-03-14 深圳市智税链科技有限公司 Method, apparatus, accounting node and medium for querying transaction information in blockchain network
CN109377230B (en) * 2018-12-11 2020-01-14 四川大学 Method and device for realizing intelligent contract in block chain based on directed graph
CN110046991B (en) 2018-12-12 2020-08-11 阿里巴巴集团控股有限公司 Data processing method and system based on intelligent contract of block chain
CN110046992A (en) 2018-12-12 2019-07-23 阿里巴巴集团控股有限公司 A kind of transaction Hash acquisition methods and system based on block chain intelligence contract
CN110035105B (en) * 2018-12-13 2021-09-21 创新先进技术有限公司 Screen recording evidence obtaining method and system based on block chain and electronic equipment
CN111327648B (en) * 2018-12-13 2022-04-12 北京果仁宝软件技术有限责任公司 Processing method and system based on block chain intelligent contract
CN109785130B (en) * 2018-12-17 2021-05-28 金蝶软件(中国)有限公司 Block chain random consensus method and device, computer equipment and storage medium
CN110032599B (en) 2018-12-20 2020-05-05 阿里巴巴集团控股有限公司 Data structure reading and updating method and device, and electronic equipment
CN110020542B (en) 2018-12-20 2020-05-19 阿里巴巴集团控股有限公司 Data reading and writing method and device and electronic equipment
CN110032568B (en) * 2018-12-20 2020-05-12 阿里巴巴集团控股有限公司 Data structure reading and updating method and device, and electronic equipment
CN111369243B (en) * 2018-12-24 2023-07-14 航天信息股份有限公司 Distributed accounting method and device
CN110009338B (en) * 2018-12-25 2020-10-23 创新先进技术有限公司 Accounting method and device based on block chain and electronic equipment
CN109683867A (en) * 2018-12-27 2019-04-26 石更箭数据科技(上海)有限公司 A kind of method and device thereof, medium, terminal for docking block chain
AU2018347204B2 (en) * 2018-12-28 2020-10-22 Advanced New Technologies Co., Ltd. Smart contract whitelists
KR102294223B1 (en) * 2018-12-28 2021-08-30 어드밴스드 뉴 테크놀로지스 씨오., 엘티디. Parallel execution of transactions in a blockchain network based on a smart transaction whitelist
AU2018347203B2 (en) * 2018-12-28 2021-01-21 Advanced New Technologies Co., Ltd. Parallel execution of transactions in a blockchain network
CN109814905B (en) * 2019-01-17 2023-06-16 上海边界智能科技有限公司 Software upgrading method and device based on blockchain
CN109800334A (en) * 2019-01-18 2019-05-24 杭州复杂美科技有限公司 A kind of key assignments generation method, database tamper resistant method equipment and storage medium
CN109918946B (en) * 2019-03-08 2019-12-10 浙江雲禾智能设备有限公司 big data security processing system and method based on block chain technology
CN112966311A (en) * 2019-03-15 2021-06-15 创新先进技术有限公司 Intelligent contract checking method and device and electronic equipment
CN110060056A (en) * 2019-03-18 2019-07-26 阿里巴巴集团控股有限公司 A kind of business confirmation method and system based on block chain intelligence contract
CN110622488B (en) 2019-03-27 2021-02-09 创新先进技术有限公司 System and method for managing user interaction with blockchains
CN110058878B (en) * 2019-04-04 2022-12-02 交通银行股份有限公司 Fabric block chain configuration method and system based on intelligent contract
CN109993658A (en) * 2019-04-15 2019-07-09 北京杰视通科技发展有限公司 Electricity based on block chain really weighs method, intelligent terminal and block chain node
CN110177079B (en) * 2019-04-17 2021-10-15 北京百度网讯科技有限公司 Calling system and calling method of intelligent contract
US11177938B2 (en) * 2019-04-19 2021-11-16 International Business Machines Corporation Database composite endorsement
US11416548B2 (en) * 2019-05-02 2022-08-16 International Business Machines Corporation Index management for a database
CN110233823A (en) * 2019-05-06 2019-09-13 深圳壹账通智能科技有限公司 Block chain implementation method, system and storage medium
CN110288470B (en) * 2019-05-14 2020-09-15 山东开创云计算有限公司 Water right transaction method and system based on block chain
CN110148003A (en) * 2019-05-26 2019-08-20 贾渊培 A kind of carbon emissions trading method and system
US11188521B2 (en) * 2019-06-05 2021-11-30 International Business Machines Corporation Flexible transaction validation
CN110535654B (en) * 2019-07-23 2021-09-14 平安科技(深圳)有限公司 Block chain based parallel system deployment method and device and computer equipment
CN110413304B (en) * 2019-07-31 2023-07-14 中国工商银行股份有限公司 Intelligent contract hot upgrading method and device based on block chain network
CN110647757A (en) * 2019-08-15 2020-01-03 深圳壹账通智能科技有限公司 Data processing method based on intelligent contract and related device
CN110473106A (en) * 2019-08-21 2019-11-19 腾讯科技(深圳)有限公司 A kind of method and relevant apparatus of trading processing
CN110572281B (en) * 2019-08-23 2021-12-21 华南理工大学 Credible log recording method and system based on block chain
CN110633076B (en) * 2019-09-16 2021-05-04 杭州趣链科技有限公司 Method for automatically generating identity intelligent contract Java client program
CN110602138B (en) * 2019-09-26 2021-06-11 腾讯科技(深圳)有限公司 Data processing method and device for block chain network, electronic equipment and storage medium
CN112579343A (en) * 2019-09-27 2021-03-30 阿里巴巴集团控股有限公司 Block link point data recovery method and device
CN110599069B (en) * 2019-09-29 2023-06-20 腾讯科技(深圳)有限公司 Application evaluation method and device based on block chain network
CN111063092B (en) * 2019-10-15 2022-02-01 京东科技信息技术有限公司 Lottery drawing method and device based on block chain, electronic equipment and storage medium
CA3098767A1 (en) * 2019-10-16 2020-01-16 Alipay (Hangzhou) Information Technology Co., Ltd. Implementing a blockchain-based web service
CN110716745A (en) * 2019-10-21 2020-01-21 星矿科技(北京)有限公司 Method for constructing off-center community by using block chain and intelligent contract
CN110956542B (en) * 2019-11-07 2021-05-18 支付宝(杭州)信息技术有限公司 Block chain system and operation method, device and equipment thereof
WO2020035090A2 (en) * 2019-11-08 2020-02-20 Alipay (Hangzhou) Information Technology Co., Ltd. Lightweight decentralized application platform
CN110852648A (en) * 2019-11-19 2020-02-28 腾讯科技(深圳)有限公司 Data processing method and device and computer storage medium
CN111224782B (en) * 2019-11-22 2021-06-25 腾讯科技(深圳)有限公司 Data verification method based on digital signature, intelligent device and storage medium
CN111008218B (en) * 2019-12-04 2022-05-24 福州博泉网络科技有限公司 Method and system for structured storage of data on block chain
CN110751486B (en) * 2019-12-17 2020-05-01 北京连琪科技有限公司 Intelligent contract replay proof method, system, electronic equipment and storage medium
CN111242630A (en) * 2019-12-19 2020-06-05 广州宏算信息科技有限公司 Settlement method and device based on block chain and storage medium
CN111311258B (en) * 2020-01-20 2023-07-21 布比(北京)网络技术有限公司 Block chain-based trusted transaction method, device, system, equipment and medium
CN111639127B (en) * 2020-05-11 2022-05-13 支付宝实验室(新加坡)有限公司 Method, system, device and equipment for updating intelligent contract
CN115552868A (en) * 2020-05-12 2022-12-30 北京沃东天骏信息技术有限公司 System and method for establishing consensus in distributed communications
CN111597537B (en) * 2020-05-20 2021-09-10 腾讯科技(深圳)有限公司 Block chain network-based certificate issuing method, related equipment and medium
CN111767215B (en) * 2020-06-23 2023-08-08 中国工商银行股份有限公司 Block chain continuous integration test method, device and system
CN112104606B (en) * 2020-08-12 2022-06-17 北京智融云河科技有限公司 Credible execution method and system based on random multiple nodes
CN112101942B (en) * 2020-09-18 2022-10-04 腾讯科技(深圳)有限公司 Transaction request processing method, system, device and equipment based on block chain
CN112150146B (en) * 2020-09-22 2023-11-03 京东科技控股股份有限公司 Block processing method, device, equipment and storage medium of block chain
CN112422526B (en) * 2020-11-03 2023-02-03 山西特信环宇信息技术有限公司 Cone block chain consensus system, method and network
CN112904734A (en) * 2020-12-23 2021-06-04 上海上实龙创智能科技股份有限公司 Intelligent household appliance control system and method based on Internet of things and block chain double gateways
CN112671920B (en) * 2020-12-29 2022-09-06 杭州中科先进技术研究院有限公司 Sewage automatic control method based on block chain
CN113037864B (en) * 2021-04-07 2022-11-29 郑州师范学院 Data storage system and data storage method
CN113254961A (en) * 2021-05-26 2021-08-13 杭州云象网络技术有限公司 Method for calling hardware cryptographic interface based on go language encapsulation
CN113342838B (en) * 2021-08-06 2021-11-09 腾讯科技(深圳)有限公司 Data processing method, device and equipment based on block chain and readable storage medium
CN113965566A (en) * 2021-10-11 2022-01-21 浪潮云信息技术股份公司 BFT consensus algorithm implementation method and system based on Header-Sig flow
CN115293769B (en) * 2022-10-08 2022-12-27 中铱数字科技有限公司 Dynamic management and check node system based on block chain
CN117217856B (en) * 2023-08-28 2024-03-19 成都雨链科技有限公司 Platform unified large market cooperation method based on block chain
CN117635333A (en) * 2024-01-11 2024-03-01 国网山东省电力公司电力科学研究院 Block chain transaction execution method and block chain link point

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9849364B2 (en) * 2016-02-02 2017-12-26 Bao Tran Smart device
CN106878071B (en) * 2017-01-25 2020-09-15 上海钜真金融信息服务有限公司 Block chain consensus mechanism based on Raft algorithm
CN107103473A (en) * 2017-04-27 2017-08-29 电子科技大学 A kind of intelligent contract implementation method based on block chain
CN107332701A (en) * 2017-06-26 2017-11-07 中国人民银行数字货币研究所 The method and system of management node
CN107464118A (en) * 2017-08-16 2017-12-12 济南浪潮高新科技投资发展有限公司 A kind of data trade method based on block chain intelligence contract
CN107911216B (en) * 2017-10-26 2020-07-14 矩阵元技术(深圳)有限公司 Block chain transaction privacy protection method and system

Also Published As

Publication number Publication date
CN108769173A (en) 2018-11-06

Similar Documents

Publication Publication Date Title
CN108769173B (en) Block chain implementation method and equipment for running intelligent contracts
CN109936457B (en) Block chain multi-party witness method, device, equipment and computer readable storage medium
CN110535660B (en) Evidence obtaining service system based on block chain
CN108492183B (en) Block chain account transaction method, system and computer readable storage medium
CN103227719B (en) Generate the system and method without key digital multi-signature
CN105573828B (en) A kind of operation processing method and device
CN109981279B (en) Block chain system, communication method, device, equipment and medium
US20200403796A1 (en) Platform and method of certification of an electronic contract for electronic identification and trust services (eidas)
CN111258599B (en) Firmware upgrade method, system and computer readable storage medium
CN105262588A (en) Log-in method based on dynamic password, account number management server and mobile terminal
CN112069550B (en) Electronic contract evidence-storing system based on intelligent contract mode
JP2022527610A (en) Methods and equipment for propagating blocks in blockchain networks
CN114567643B (en) Cross-blockchain data transfer method, device and related equipment
US20230344821A1 (en) Platform and method of certification of an electronic notice for electronic identification and trust services (eidas)
CN111488372A (en) Data processing method, device and storage medium
CN111008206A (en) Method and device for storing state data of cross-chain transaction and storage medium
CN113032837A (en) Anonymous authentication method and system for open platform
CN110740038A (en) Block chain and communication method, gateway, communication system and storage medium thereof
CN109918867B (en) Peer-to-peer system file tracing method based on block chain
CN113112269B (en) Multiple signature method, computer device, and storage medium
CN111524011B (en) Parallel link consensus validation method, apparatus, and storage medium
CN114092093A (en) Block chain transaction processing method and device, electronic equipment and readable medium
CN112182009A (en) Data updating method and device of block chain and readable storage medium
CN111932326A (en) Data processing method based on block chain network and related equipment
CN111212037A (en) Advertisement data processing method and device

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
CP01 Change in the name or title of a patent holder
CP01 Change in the name or title of a patent holder

Address after: 200093 No. 640, Longchang Road, Yangpu District, Shanghai

Patentee after: Orange Lion Sports (Shanghai) Co.,Ltd.

Address before: 200093 No. 640, Longchang Road, Yangpu District, Shanghai

Patentee before: ALI SPORTS Co.,Ltd.

Address after: 200093 No. 640, Longchang Road, Yangpu District, Shanghai

Patentee after: Orange Lion Sports Co.,Ltd.

Address before: 200093 No. 640, Longchang Road, Yangpu District, Shanghai

Patentee before: Orange Lion Sports (Shanghai) Co.,Ltd.