CN112769831B - Block chain-oriented multichannel creation method in untrusted network environment - Google Patents

Block chain-oriented multichannel creation method in untrusted network environment Download PDF

Info

Publication number
CN112769831B
CN112769831B CN202110036409.9A CN202110036409A CN112769831B CN 112769831 B CN112769831 B CN 112769831B CN 202110036409 A CN202110036409 A CN 202110036409A CN 112769831 B CN112769831 B CN 112769831B
Authority
CN
China
Prior art keywords
channel
application
transaction
node
block
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
CN202110036409.9A
Other languages
Chinese (zh)
Other versions
CN112769831A (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.)
Ouye Yunshang Co ltd
Original Assignee
Ouye Yunshang 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 Ouye Yunshang Co ltd filed Critical Ouye Yunshang Co ltd
Priority to CN202110036409.9A priority Critical patent/CN112769831B/en
Publication of CN112769831A publication Critical patent/CN112769831A/en
Application granted granted Critical
Publication of CN112769831B publication Critical patent/CN112769831B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/04Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
    • H04L63/0428Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/02Network architectures or network communication protocols for network security for separating internal from external traffic, e.g. firewalls
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/18Network architectures or network communication protocols for network security using different networks or channels, e.g. using out of band channels
    • 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/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • H04L67/025Protocols based on web technology, e.g. hypertext transfer protocol [HTTP] for remote control or remote monitoring of applications
    • 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
    • H04L67/1095Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes
    • 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
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]

Abstract

The invention relates to a multi-channel creation method facing block chains in an untrusted network environment, which divides channel types into two types, namely a system channel and an application channel, wherein the system channel is defined by a system and is used for managing the application channel, the method comprises the steps of creating a system creation block and creating or configuring a modification block of a plurality of application channels, and all nodes are positioned in the system channel and are completed through configuring the creation block; the application channel is customized by a user and comprises an application creation block and a plurality of blocks containing transaction information, all nodes in the application channel commonly maintain a blockchain, only the nodes in the application channel can process transactions belonging to the application channel, and one node can participate in a plurality of application channels.

Description

Block chain-oriented multichannel creation method in untrusted network environment
Technical Field
The invention relates to the technical field of blockchains, in particular to a multichannel creation method oriented to blockchains in an untrusted network environment.
Background
The blockchain (blockchain) is used as a decentralized, non-tamperable, traceable, trusted and multi-party commonly maintained distributed database, and trusted data sharing is realized among multiple parties which are not mutually aware and mutually not trusted without any third party trusted mechanism by integrating multiple technologies such as P2P protocol, asymmetric encryption, consensus mechanism, blockchain structure and the like. However, most blockchain systems (e.g., hyperledger Fabric) currently fail to provide data confidentiality while providing a multi-channel design in an untrusted network environment, and in fact, the privacy protection problem of blockchains is more important among non-trusted participants than in other ways of data sharing.
A direct data privacy protection method adopts a multi-channel deployment structure, one node can be added into different channels according to application requirements, the nodes added into the same channel jointly maintain the same block data, different channels are isolated from each other, and nodes in non-channels cannot access transactions on the channels. Thus, the privacy data is effectively protected, and the parallel processing efficiency of the data and the utilization of the data storage space are improved.
Currently, under a blockchain multichannel architecture, blockchain nodes commonly perform consensus through a consensus algorithm, namely a PBFT (practical Bayesian fault tolerance algorithm), and global consensus for ordering transactions is formed in a system. And then processing the transaction according to the sequence sub-channels after consensus. As long as the processing process can ensure certainty, all nodes of the same channel can finally reach a consistent state, and the same local data is generated. In Fabric architecture, however, the consensus service (ordering global transactions) is done by the Orderer node, which acts as a trusted party responsible for receiving all transactions for all channels for ordering. There is no protocol that can provide a multi-channel architecture while guaranteeing data confidentiality in the presence of untrusted Orderer, so Fabric architecture is not viable in a general environment.
Disclosure of Invention
The invention aims to overcome the defects of the prior art and provide a multi-channel creation method facing to a block chain in an untrusted network environment.
The aim of the invention can be achieved by the following technical scheme:
a multi-channel creation method facing to block chain under the un-trusted network environment, the method introduces the design of the multi-channel in the block chain, divide the channel type into two kinds of systematic channel and application channel, the said systematic channel is defined by the system, is used for taking charge of managing the application channel, including a systematic creation block and creation or configuration modification block of a plurality of application channels, all nodes are located in systematic channel, the creation of the systematic channel is equivalent to the initialization of the block chain, finish through the configuration creation block; the application channel is customized by a user and comprises an application creation block and a plurality of blocks containing transaction information, all nodes in the application channel commonly maintain a blockchain, and only the nodes in the application channel can process the transaction belonging to the application channel, and one node can participate in a plurality of application channels.
The method specifically comprises the following steps:
1) Creating a system channel and initializing a block chain system;
2) The node initiates an application channel creation transaction to create a new application channel;
3) The node initiates an application channel configuration modification transaction to modify the configuration information of the application channel;
4) Nodes in the application channel pack and execute transactions belonging to the channel;
5) The new node joins the application channel, synchronizes the configuration of the application channel and the blockchain data.
The step 1) specifically comprises the following steps:
11 Each node determines configuration information of the blockchain system, including channel names, nodes in the channels and the like, and writes the configuration information into a local storage;
12 The node constructs a corresponding block for storing configuration information of the blockchain system, the block being an originating block of the blockchain system, the originating block being a first block on the blockchain that is used for initialization and does not include other transaction information.
In the step 1), when a new node joins the blockchain network, the node stores configuration information and blocks of the blockchain system, and specifically includes the following steps:
131 The node stores the created block of the block chain system, obtains the configuration information of the system channel, and is used for ensuring that all nodes are consistent with the configuration of the block chain system;
132 The node synchronizes the block to the highest block of the blockchain to obtain the whole blockchain of the system channel, so that all nodes in the blockchain network achieve data consistency.
In the step 2), the application channels are created by user definition, different application channels are encrypted by adopting different encryption modes, and only nodes in the channels can decrypt and package the transactions belonging to the channels, and the method specifically comprises the following steps:
21 When creating a new application channel, the node initiates a channel creation transaction, specifically:
22 Channel creation transaction is sent to the blockchain network, and after consensus is reached, all nodes package this transaction out of blocks:
23 A node belonging to the application channel creates a channel from this transaction.
The step 21) specifically comprises the following steps:
the node creating the application channel determines a channel encryption mode, and the encryption mode can be known only by the nodes in the channel;
the channel configuration information in the channel creation transaction comprises a channel name, nodes in the channel, a channel encryption mode, channel transaction packaging strategy information and the like, each node can only package the transaction of the channel where the node is located in a multi-channel environment, and an initial packaging method is set when the channel is created so as to dynamically switch the packaging method according to the channel condition;
and for the channel creation transaction, encrypting by a corresponding channel encryption mode so as to ensure confidentiality of channel configuration information.
Said step 22), specifically comprising the following sub-steps:
221 All nodes pack the encrypted application channel creation transaction, uplink the blockchain of the system channel, the channel creation transaction belongs to the system channel, all nodes pack the transaction of the system channel, and add the blockblocks to the blockchain of the system channel;
222 When the nodes belonging to the application channel are packaged, the decryption mode corresponding to the channel encryption mode is adopted to decrypt the transaction, so that the corresponding channel creation transaction is obtained.
Said step 23), specifically comprising the following sub-steps:
231 After decryption, the node obtains configuration information in the application channel creation transaction, including channel names, nodes in the channel, channel encryption mode information and the like, and stores the configuration information to the local;
232 A block is constructed by the node to store the application channel creation transaction, and the block is used as the creation block of the application channel.
In the step 3), the modification of the application channel configuration is implemented by initiating a channel configuration modification transaction by a node in the application channel, and the method specifically comprises the following steps:
31 A node of the application channel constructs an application channel configuration modification transaction, the transaction comprising all configuration information of the modified channel;
32 The node encrypts the channel configuration modification transaction by adopting a corresponding channel encryption mode and sends the encrypted channel configuration modification transaction to the blockchain network for consensus;
33 Channel configuration modification transaction belongs to system channel transaction, and all nodes in the blockchain network pack the channel configuration modification transaction out;
34 Nodes within the application channel update the configuration of the application channel in accordance with the channel configuration modification transaction.
Said step 33) comprises the following sub-steps:
331 All nodes in the blockchain network directly pack the encrypted channel configuration modification transaction into blocks, and add the blocks to the system channel blockchain, and the system channel manages application channels and records the creation and configuration modification of all application channels in the system;
332 When the node belonging to the application channel is packaged into a block, decrypting the transaction by adopting a decryption mode corresponding to the channel encryption mode, and obtaining the changed channel configuration information.
Said step 34) comprises the following sub-steps:
341 The node obtains the decrypted channel configuration modification transaction, and replaces the original local channel configuration information with the channel configuration information after modification;
342 The node creates a block memory channel configuration modification transaction, and adds the block as a configuration block to the application channel blockchain, the application channel records the change history of the configuration itself, so that other nodes which later join the channel can achieve the consistency of data and configuration by means of the synchronous blockchain.
12. The method for creating a multi-channel for a blockchain in an untrusted network environment according to claim 1, wherein the step 4) specifically includes the steps of:
41 The node constructs an application channel transaction, encrypts the application channel transaction by using an encryption mode of the application channel, and sends the encrypted transaction to the blockchain network for consensus;
42 The application channel transaction belongs to the application channel, and after consensus is reached, only the nodes in the application channel pack the application channel out.
Said step 42) comprises the following sub-steps:
421 The node sorts the agreed transactions, only the system channel transactions and the transactions of the application channels in which the node participates are reserved, and other transactions are all discarded;
422 The node packs the application channel transaction according to the channel transaction packing method in the channel configuration and decrypts the transaction correspondingly according to the channel encryption mode when packing;
423 A node performs a transaction and adds the block containing the transaction to the corresponding application channel blockchain.
The step 5) specifically comprises the following steps:
51 When a new node joins an application channel, saving an creation block of the application channel and obtaining configuration information of the channel from the creation block;
52 The new node synchronizes the blockchain of the application channel to the highest block, so as to obtain the transaction data of the blockchain of the application channel, thereby ensuring the consistency of the blockchain data in the channel;
53 Searching whether a configuration block exists in the synchronized application channel block chain or not by the node, if so, synchronizing the configuration of the application channel with the content of the latest configuration block, and synchronizing the configuration block to ensure that the nodes in the same application channel are consistent in configuration.
Compared with the prior art, the invention has the following advantages:
the invention designs a multi-channel construction method facing to the block chain aiming at the block chain in an untrusted environment, and fills the defect of a data isolation and confidentiality method in the untrusted environment of the block chain; all nodes in the block chain system are in a system channel, so that the consistency of the overall configuration of the block chain is ensured; different application channels have different encryption modes, so that the different channels are isolated from each other, and only nodes in the channels know the encryption mode and decrypt transactions belonging to the channels, thereby realizing the construction of a blockchain multi-channel and solving the problem that data isolation and data sharing cannot be realized simultaneously in an untrusted environment; the user can build the application channels in a self-defined way, the nodes can participate in a plurality of application channels and the data among the channels are not communicated, so that the parallel processing efficiency of the data and the confidentiality of the blockchain system are improved.
Drawings
FIG. 1 is a flow chart of system channel creation in the present invention.
FIG. 2 is a flow chart of application channel creation in the present invention.
FIG. 3 is a diagram illustrating an exemplary blockchain multi-channel environment in which the present invention may be implemented.
FIG. 4 is a diagram illustrating an overall design flow of multiple channels according to the present invention.
FIG. 5 is a flowchart illustrating an embodiment of a modification of the configuration of an application channel according to the present invention.
FIG. 6 is a diagram illustrating an example of an application channel transaction initiation and process flow in accordance with the present invention.
FIG. 7 is a diagram illustrating a node participating in multiple channels according to the present invention.
Detailed Description
The invention will now be described in detail with reference to the drawings and specific examples.
The invention provides a multi-channel creation method for a blockchain, which is designed for solving the problem of multi-channel creation of blockchain nodes in an untrusted environment, wherein data of different channels adopts different encryption modes, transactions propagated in a blockchain network are encrypted according to the channel in which the nodes are located, each node participates in a consensus process of the transactions in the network, but each node only stores account book data of the channel in which the node participates, and the privacy of the channel data is ensured by a cryptography means.
The invention is realized by the following means:
the design of introducing multiple channels in a blockchain, channels fall into two categories: the system channel and the application channel are defined by the system and are responsible for managing the application channel, all nodes are in the system channel, and the creation of the system channel is equivalent to the initialization of a block chain and is completed by configuring an creation block; the application channels are customized by users, nodes in the channels jointly maintain a blockchain, only the nodes in the channels can process transactions of the channels, and one node can participate in a plurality of application channels, and the method comprises the following specific steps:
step 1: creating a system channel and initializing a block chain system;
the channels in the blockchain are divided into a system channel and an application channel, wherein the system channel is defined by a system and is used for managing the application channel, and the method specifically comprises the following substeps:
step 1-1: the configuration information of the blockchain system, such as Channel names, nodes in the channels and the like, is determined through negotiation among the nodes, and is written into a local storage, for example, the system Channel names are Sys_channel, and the nodes a, b and c participate in the system Channel;
step 1-2: the node constructs a corresponding block to store a series of configurations of the block chain system determined by negotiation, the block is an originating block of the block chain system, the originating block is the first block on the block chain and is used for initialization, and other transaction information is not included;
step 1-3: the new node wants to join the blockchain network, then it needs to save the configuration information of the blockchain system and the blocks, specifically including the following sub-steps:
step 1-3-1: the nodes store the created blocks of the block chain system and acquire configuration information of system channels, so that the configuration of all the nodes to the block chain system is consistent;
step 1-3-2: synchronizing the block by the node to the highest block of the block chain to obtain the whole block chain of the system channel, so that all nodes in the block chain network achieve data consistency;
step 2: the node initiates an application channel creation transaction to create a new application channel;
the application channels are created by user definition, different application channels are encrypted by adopting different encryption modes, and only nodes in the channels can decrypt and package transactions belonging to the channels, and the method specifically comprises the following substeps:
step 2-1: when creating a new application channel, the node needs to initiate a channel creation transaction, which specifically includes the following sub-steps:
step 2-1-1: the node creating the application Channel needs to determine a Channel encryption mode through negotiation, and the encryption mode is known only to the node in the Channel, for example, the application Channel channel_1 adopts the encryption mode (1), all transactions belonging to the channel_1 are encrypted by using the encryption mode (1), and in addition, the Channel creation transaction and the configuration modification transaction belong to the system Channel, but the Channel creation transaction and the configuration modification transaction relate to the detailed configuration of the Channel channel_1, so the encryption mode is also used by using the encryption mode (1);
step 2-1-2: the channel creation transaction comprises channel configuration information such as channel names, nodes in the channels, channel encryption modes, channel transaction packaging strategies and the like, each node can only package the transaction of the channel where the node is located in a multi-channel environment, and the packaging method is required to be dynamically switched according to the channel condition, so that an initial packaging method is required to be set when the channel is created;
step 2-1-3: for channel creation transaction, encryption is needed by using a corresponding channel encryption mode, so that confidentiality of channel configuration information is ensured;
step 2-2: the channel creation transaction is sent to the blockchain network, and after consensus is reached, all nodes package the transaction into blocks, specifically comprising the following sub-steps:
step 2-2-1: all nodes pack the encrypted application channel creation transaction out of blocks, uplink the blockchain of the system channel, the channel creation transaction belongs to the system channel, and all nodes need to pack the transaction of the system channel and add the blocks to the blockchain of the system channel;
step 2-2-2: when the nodes belonging to the channel are packaged, decrypting the transaction by adopting a decryption mode corresponding to a channel encryption mode to obtain a corresponding channel creation transaction;
step 2-3: the node belonging to the application channel creates a channel according to the transaction, comprising the following sub-steps:
step 2-3-1: after decryption, the node obtains configuration information in the application channel creation transaction, such as channel name, nodes in the channel, channel encryption mode and the like, and stores the information to the local;
step 2-3-2: the node constructs a block to store the application Channel to create the transaction, and takes the block as an creation block of the application Channel, for example, an application Channel channel_1, wherein the creation block contains all configuration information of the channel_1, such as nodes a and b contained in the channel_1, an encryption mode (1) adopted by the channel_1, an initial time interval packing method adopted by the channel_1 and the like;
step 3, the node initiates an application channel configuration modification transaction to modify the configuration information of the application channel;
the configuration of the application channel can be changed, for example, the packing mode of the modification channel is changed, and the node in the channel initiates a channel configuration modification transaction to realize the change of the application channel configuration, which specifically comprises the following substeps:
step 3-1: the node constructs an application Channel configuration modification transaction, wherein the transaction comprises all configuration information of a modified Channel, for example, a packaging method of the channel_1 is modified into a transaction quantity packaging method, and then the initial packaging method of the channel_1 in the Channel configuration information contained in the application Channel configuration modification transaction is the transaction quantity packaging method;
step 3-2: the node encrypts the channel configuration modification transaction by adopting the channel encryption mode and sends the encrypted channel configuration modification transaction to the blockchain network for consensus;
step 3-3: the channel configuration modification transaction belongs to a system channel transaction, and all nodes in the blockchain network pack the system channel transaction out of blocks, and specifically comprises the following sub-steps:
step 3-3-1: all nodes in the blockchain network directly pack encrypted channel configuration modification transactions into blocks, and add the blocks to a system channel blockchain, and the system channel manages application channels, and records the creation and configuration modification of all application channels in the system;
step 3-3-2: when the node belonging to the channel packs out the block, decrypting the transaction by adopting a decryption mode corresponding to the channel encryption mode, and obtaining modified channel configuration information;
step 3-4: the node in the application channel modifies the transaction to update the configuration of the application channel according to the channel configuration, and specifically comprises the following substeps:
step 3-4-1: the node obtains the decrypted channel configuration modification transaction, and replaces the original local channel configuration by the modified channel configuration information;
step 3-4-2: the node creates a block storage channel configuration modification transaction, and adds the block as a configuration block to an application channel blockchain, and the application channel records the change history of the configuration of the application channel, so that other nodes which later join the channel can achieve the consistency of data and configuration in a mode of synchronizing the blockchain;
step 4: the node in the application channel packs the transaction belonging to the channel and executes, and specifically comprises the following substeps:
step 4-1: the node constructs an application Channel transaction, encrypts the application Channel transaction by using a Channel encryption mode, sends the encrypted transaction to a blockchain network for consensus, for example, the transaction of the application Channel channel_1 encrypts the transaction by adopting an encryption mode (1);
step 4-2: the application channel transaction belongs to an application channel, and after consensus is achieved, only nodes in the channel pack the application channel transaction out of blocks, and the method specifically comprises the following sub-steps:
step 4-2-1: the node sorts the agreed transactions, only the system Channel transactions and the transactions of the application channels in which the node participates, for example, the node a participates in the application channel_1, so that the node a can reserve the transactions of the system Channel Sys_channel and the application Channel channel_1, and other transactions are discarded;
step 4-2-2: the node packs the application Channel transaction according to the Channel transaction packing method in the Channel configuration and then packs the application Channel transaction according to the Channel encryption mode, for example, the node decrypts the transaction of the application Channel channel_1 in a mode corresponding to the encryption mode (1) and packs the application Channel transaction according to the time interval packing method;
step 4-2-3: the node executes the transaction and adds the block containing the transaction to the corresponding application channel blockchain;
step 5: if a new node is to be added to the application channel, the configuration of the application channel and the blockchain data need to be synchronized, and the method specifically comprises the following substeps:
step 5-1: the node joins the application channel, needs to save the creation block of the application channel, obtains the configuration information of the channel from this;
step 5-2: the node needs to synchronize the blockchain of the application channel to the highest block so as to obtain the transaction data of the blockchain of the application channel, thereby ensuring the consistency of the blockchain data in the channel;
step 5-3: the node searches whether there is a configuration block in the synchronized application Channel block chain, if yes, the configuration of the application Channel is synchronized with the content of the latest configuration block, for example, the application Channel channel_1 has a Channel configuration modification transaction, the block chain of the node has a configuration block, the content in the latest configuration block is the configuration adopted by the Channel channel_1 at the moment, and the configuration block is synchronized so that the nodes in the same application Channel are consistent in configuration.
Examples
As shown in fig. 1, the system channel is defined by a system, and is used for managing an application channel, the creation of the system channel is equivalent to the initialization of a blockchain system, the configuration information of the blockchain is determined through negotiation between nodes, such as nodes in the system channel, the nodes store the configuration information locally, a block storing the configuration information is constructed as an creation block of the blockchain of the system channel, and all nodes in the blockchain network are in the system channel, so that each node can obtain the configuration information in the creation block of the system channel, and maintain the blockchain of the system channel.
As shown in FIG. 2, the application channel is user-defined, and nodes within the application channel maintain the same blockchain, and only nodes within the channel can process transactions within the channel. The figure describes a process from the initiation of an application Channel channel_1 creation transaction by a node a to the creation of channel_1, and the specific functional steps are as follows:
step 1: negotiating among nodes to determine an encryption mode (1) of an application Channel channel_1;
step 2: the node a initiates the application Channel channel_1 to create a transaction Tx, wherein the transaction contains various configuration information of the Channel channel_1, such as Channel name channel_1, encryption mode (1) and the like, and then the node a encrypts the transaction Tx in the encryption mode (1) and sends the encrypted transaction to a blockchain network for consensus;
step 3: all nodes in the blockchain network pack the encrypted channel_1 creation transaction, and attach the blocks to the system Channel blockchain;
step 4: the node belonging to channel_1 decrypts the transaction Tx, obtains the configuration information of channel_1 and stores the configuration information to the local, and then uses a deterministic packing rule to store the Channel creation transaction in a block, wherein the block is an creation block of the application Channel channel_1.
In the case of multiple channels, as shown in fig. 3, each node in the network maintains a blockchain of the system Channel, all nodes are within the system Channel sys_channel, and therefore all nodes package transactions of the system Channel. In addition, each node maintains a blockchain of the application Channel where the node is located, and there are three application channels, channel_1, channel_2 and channel_3 in the figure, wherein the node in Channel channel_1 only packages the transaction belonging to channel_1, the node in Channel channel_2 only packages the transaction belonging to channel_2, and the node in channel_3 only packages the transaction belonging to channel_3. Node a belongs to both channels channel_1 and channel_2, so node a will be packaged for transactions to both application channels.
As shown in fig. 4, only the application channel creation transaction is considered in this figure, and a channel configuration modification example is shown in fig. 5. In the figure, the creating blocks in the system Channel blockchain store the configuration information of the system Channel Sys_Channel, the three blocks are the blocks formed by the application Channel creating transaction which adopts the encryption mode of each application Channel, for example, the application Channel Channel_1 adopts the encryption mode (1), the Channel creating transaction of the application Channel Channel_1 adopts the encryption mode (1), only the nodes in Channel_1 can obtain the configuration information of the Channel by adopting the corresponding decryption mode, other nodes can only obtain the encrypted transaction information, the nodes in Channel_1 create one block to store the decrypted configuration information and use the decrypted configuration information as the creating block of the application Channel blockchain, and all the nodes in the blockchain network can package the channel_1 Channel creating transaction and add the blocks to the system Channel blockchain.
As shown in fig. 5, the process from the node initiating the configuration modification transaction to the application channel completing the configuration update is described, and the specific functional steps are as follows:
step 1: node a constructs a configuration modification transaction Tx for an application Channel channel_1, wherein the configuration modification transaction Tx comprises all Channel configuration information of which modification is completed, the node a encrypts the transaction by adopting a channel_1 encryption mode (1), and sends the configuration modification transaction of which encryption is completed to a blockchain network for consensus;
step 2: all nodes in the blockchain network carry out deterministic packing on the encrypted configuration modification transaction, and the formed blocks are added to a system channel blockchain;
step 3: the node in the application Channel channel_1 decrypts the transaction, replaces the original configuration information by using the decrypted application Channel configuration information, constructs a block to store the modified Channel configuration, and then adds the block as a configuration block to the blockchain of the application Channel channel_1.
As shown in fig. 6, the process from the initiation of a transaction by a node to the completion of the execution of the uplink by the transaction is described, and the specific functional steps are as follows:
step 1: the node a constructs a transaction Tx belonging to an application Channel channel_1, encrypts the transaction by adopting an encryption method (1), and sends the encrypted transaction to a blockchain network for consensus;
step 2: the node of the non-application channel_1 identifies the Channel where the node does not participate in the trade station in the deterministic packing sorting process, and directly discards the trade;
step 3: and in the packing process, the nodes in the application channel_1 decrypt the transaction by adopting a corresponding decryption method to obtain the transaction Tx specific information, pack the transaction Tx specific information into blocks, and add the blocks to the block chain of the application Channel channel_1.
As shown in fig. 7, in the multi-Channel environment, each node is in a system Channel and maintains a blockchain of the system Channel, besides, each node may participate in a plurality of application channels and maintain a blockchain for each application Channel, in which node a participates in a system Channel sys_channel and application channels channel_1 and channel_3, and the system Channel blockchain stores encrypted Channel creation transactions and configuration modification transactions of the application channels channel_1 and channel_3. Each application channel has a unique encryption scheme, which is known only to nodes within the channel. The creation of the application channels, the configuration modification of the transactions and the transactions in the channels are encrypted by adopting the encryption mode of the corresponding channels, so that other nodes in the blockchain network can only know which application channels exist in the network through the blockchain of the system channels, but cannot know the configuration information of the application channels.
The protection of the present invention is not limited to the above embodiments. Variations and advantages that would occur to one skilled in the art are included in the invention without departing from the spirit and scope of the inventive concept, and the claims appended hereto are intended to be protected.

Claims (4)

1. A multi-channel creation method facing to a block chain in an untrusted network environment is characterized in that the method introduces a multi-channel design in the block chain, and divides channel types into two types of system channels and application channels, wherein the system channels are defined by a system and are used for managing the application channels, the system channels comprise a system creation block and creation or configuration modification blocks of a plurality of application channels, all nodes are positioned in the system channels, the creation of the system channels is equivalent to the initialization of the block chain, and the creation of the system channels is completed by configuring the creation block; the application channel is customized by a user and comprises an application creation block and a plurality of blocks containing transaction information, all nodes in the application channel commonly maintain a blockchain, and only the nodes in the application channel can process the transaction belonging to the application channel, and one node can participate in a plurality of application channels;
the method specifically comprises the following steps:
1) Creating a system channel and initializing a block chain system;
2) The node initiates an application channel creation transaction to create a new application channel;
3) The node initiates an application channel configuration modification transaction to modify the configuration information of the application channel;
4) Nodes in the application channel pack and execute transactions belonging to the channel;
5) Adding new nodes into the application channel, and synchronizing configuration of the application channel and block chain data;
in the step 2), the application channels are created by user definition, different application channels are encrypted by adopting different encryption modes, and only nodes in the channels can decrypt and package the transactions belonging to the channels, and the method specifically comprises the following steps:
21 When creating a new application channel, the node initiates a channel creation transaction, specifically:
22 Channel creation transaction is sent to the blockchain network, and after consensus is reached, all nodes package this transaction out of blocks:
23 A node belonging to the application channel creates a channel according to the transaction;
the step 21) specifically comprises the following steps:
the node creating the application channel determines a channel encryption mode, and the encryption mode can be known only by the nodes in the channel;
the channel configuration information in the channel creation transaction comprises a channel name, nodes in the channel, a channel encryption mode and channel transaction packaging strategy information, each node can only package the transaction of the channel where the node is located in a multi-channel environment, and an initial packaging method is set when the channel is created so as to dynamically switch the packaging method according to the channel condition;
for channel creation transaction, encrypting by a corresponding channel encryption mode to ensure confidentiality of channel configuration information;
said step 22), specifically comprising the following sub-steps:
221 All nodes pack the encrypted application channel creation transaction, uplink the blockchain of the system channel, the channel creation transaction belongs to the system channel, all nodes pack the transaction of the system channel, and add the blockblocks to the blockchain of the system channel;
222 When the nodes belonging to the application channel are packaged, decrypting the transaction by adopting a decryption mode corresponding to the channel encryption mode to obtain a corresponding channel creation transaction;
said step 23), specifically comprising the following sub-steps:
231 After decryption, the node obtains configuration information in the application channel creation transaction, including channel names, nodes in the channel and channel encryption mode information, and stores the configuration information to the local;
232 The node constructs a block to store the application channel to create transaction, and takes the block as the creation block of the application channel;
in the step 3), the modification of the application channel configuration is implemented by initiating a channel configuration modification transaction by a node in the application channel, and the method specifically comprises the following steps:
31 A node of the application channel constructs an application channel configuration modification transaction, the transaction comprising all configuration information of the modified channel;
32 The node encrypts the channel configuration modification transaction by adopting a corresponding channel encryption mode and sends the encrypted channel configuration modification transaction to the blockchain network for consensus;
33 Channel configuration modification transactions belong to the system channel transactions, which are packaged out by all nodes in the blockchain network,
34 The node in the application channel modifies the configuration of the transaction update application channel according to the channel configuration;
said step 33) comprises the following sub-steps:
331 All nodes in the blockchain network directly pack the encrypted channel configuration modification transaction into blocks, and add the blocks to the system channel blockchain, and the system channel manages application channels and records the creation and configuration modification of all application channels in the system;
332 When the node belonging to the application channel packs out the block, decrypting the transaction by adopting a decryption mode corresponding to the channel encryption mode, and obtaining the changed channel configuration information;
said step 34) comprises the following sub-steps:
341 The node obtains the decrypted channel configuration modification transaction, and replaces the original local channel configuration information with the channel configuration information after modification;
342 The node creates a block storage channel configuration modification transaction, and adds the block as a configuration block to an application channel blockchain, and the application channel records the change history of the configuration of the application channel, so that other nodes which later join the channel can achieve the consistency of data and configuration in a synchronous blockchain mode;
the step 4) specifically comprises the following steps:
41 The node constructs an application channel transaction, encrypts the application channel transaction by using an encryption mode of the application channel, and sends the encrypted transaction to the blockchain network for consensus;
42 The application channel transaction belongs to the application channel, and after consensus is achieved, only nodes in the application channel pack the application channel transaction out;
said step 42) comprises the following sub-steps:
421 The node sorts the agreed transactions, only the system channel transactions and the transactions of the application channels in which the node participates are reserved, and other transactions are all discarded;
422 The node packs the application channel transaction according to the channel transaction packing method in the channel configuration and decrypts the transaction correspondingly according to the channel encryption mode when packing;
423 A node performs a transaction and adds the block containing the transaction to the corresponding application channel blockchain.
2. The method for creating a multi-channel for a blockchain in an untrusted network environment according to claim 1, wherein the step 1) specifically comprises the following steps:
11 Each node determines configuration information of the blockchain system, including a channel name and nodes in the channel, and writes the configuration information into a local storage;
12 The node constructs a corresponding block for storing configuration information of the blockchain system, the block being an originating block of the blockchain system, the originating block being a first block on the blockchain that is used for initialization and does not include other transaction information.
3. The method for creating the multi-channel for the blockchain in the untrusted network environment according to claim 1, wherein in the step 1), when a new node joins the blockchain network, the node saves configuration information and blocks of the blockchain system, and the method specifically comprises the following steps:
131 The node stores the created block of the block chain system, obtains the configuration information of the system channel, and is used for ensuring that all nodes are consistent with the configuration of the block chain system;
132 The node synchronizes the block to the highest block of the blockchain to obtain the whole blockchain of the system channel, so that all nodes in the blockchain network achieve data consistency.
4. The method for creating a multi-channel for a blockchain in an untrusted network environment according to claim 1, wherein said step 5) specifically comprises the steps of:
51 When a new node joins an application channel, saving an creation block of the application channel and obtaining configuration information of the channel from the creation block;
52 The new node synchronizes the blockchain of the application channel to the highest block, so as to obtain the transaction data of the blockchain of the application channel, thereby ensuring the consistency of the blockchain data in the channel;
53 Searching whether a configuration block exists in the synchronized application channel block chain or not by the node, if so, synchronizing the configuration of the application channel with the content of the latest configuration block, and synchronizing the configuration block to ensure that the nodes in the same application channel are consistent in configuration.
CN202110036409.9A 2021-01-12 2021-01-12 Block chain-oriented multichannel creation method in untrusted network environment Active CN112769831B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110036409.9A CN112769831B (en) 2021-01-12 2021-01-12 Block chain-oriented multichannel creation method in untrusted network environment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110036409.9A CN112769831B (en) 2021-01-12 2021-01-12 Block chain-oriented multichannel creation method in untrusted network environment

Publications (2)

Publication Number Publication Date
CN112769831A CN112769831A (en) 2021-05-07
CN112769831B true CN112769831B (en) 2023-08-08

Family

ID=75701539

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110036409.9A Active CN112769831B (en) 2021-01-12 2021-01-12 Block chain-oriented multichannel creation method in untrusted network environment

Country Status (1)

Country Link
CN (1) CN112769831B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109993546A (en) * 2019-02-18 2019-07-09 西安西电链融科技有限公司 A kind of drug traceability system and implementation method based on RFID and block chain
CN110264200A (en) * 2019-05-29 2019-09-20 中国工商银行股份有限公司 Block chain data processing method and device
US10476847B1 (en) * 2017-12-08 2019-11-12 Symbiont.Io, Inc. Systems, methods, and devices for implementing a smart contract on a distributed ledger technology platform
CN111476548A (en) * 2020-04-16 2020-07-31 山东师范大学 Title review method and system based on block chain
CN111669267A (en) * 2020-05-15 2020-09-15 西安纸贵互联网科技有限公司 Consensus mechanism configuration and endorsement strategy configuration method of block chain

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11050822B2 (en) * 2019-06-05 2021-06-29 International Business Machines Corporation Secure data dissemination

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10476847B1 (en) * 2017-12-08 2019-11-12 Symbiont.Io, Inc. Systems, methods, and devices for implementing a smart contract on a distributed ledger technology platform
CN109993546A (en) * 2019-02-18 2019-07-09 西安西电链融科技有限公司 A kind of drug traceability system and implementation method based on RFID and block chain
CN110264200A (en) * 2019-05-29 2019-09-20 中国工商银行股份有限公司 Block chain data processing method and device
CN111476548A (en) * 2020-04-16 2020-07-31 山东师范大学 Title review method and system based on block chain
CN111669267A (en) * 2020-05-15 2020-09-15 西安纸贵互联网科技有限公司 Consensus mechanism configuration and endorsement strategy configuration method of block chain

Also Published As

Publication number Publication date
CN112769831A (en) 2021-05-07

Similar Documents

Publication Publication Date Title
WO2020108019A1 (en) Consortium blockchain-based data transfer method and device
CN108600227B (en) Medical data sharing method and device based on block chain
CN109120639B (en) Data cloud storage encryption method and system based on block chain
CN112380565A (en) Secure multi-party computing method based on trusted hardware and block chain
CN113259455B (en) Cross-subnet interaction method and device
US20210328786A1 (en) Blockchain integrated station and cryptographic acceleration card, key management methods and apparatuses
US11595187B2 (en) Communication device and communication method used in decentralized network
WO2020221085A1 (en) Relay method for quantum key, device, system, apparatus, and storage medium
Sayeed et al. Efficient perfectly secure message transmission in synchronous networks
CN110688666B (en) Data encryption and preservation method in distributed storage
CN110677241B (en) Quantum network virtualization architecture method and device
CN107315967B (en) Data matching method and device and computer readable storage medium
KR20110039944A (en) Method for generating dynamic group key
CN114785622B (en) Access control method, device and storage medium for multi-identification network
WO2024001022A1 (en) Cross-subnet calling
Traverso et al. Dynamic and verifiable hierarchical secret sharing
CN115174061A (en) Message transmission method and device based on block chain relay communication network system
CN114205093B (en) Block chain message transmission method, device, client and storage medium
CN112769831B (en) Block chain-oriented multichannel creation method in untrusted network environment
US10887091B2 (en) Multi-hop security amplification
CN102664730A (en) 128 bit secret key expansion method based on AES (Advanced Encryption Standard)
WO2024001037A1 (en) Message transmission method and apparatus, electronic device and storage medium
CN112804233A (en) Block chain multi-channel-oriented block packing method and device and storage medium
CN113923228A (en) Cross-chain interaction method and device
Chida et al. High-throughput secure AES computation

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