[go: up one dir, main page]

HK1259242B - Blockchain data processing method, device, processing equipment and system - Google Patents

Blockchain data processing method, device, processing equipment and system Download PDF

Info

Publication number
HK1259242B
HK1259242B HK19101545.7A HK19101545A HK1259242B HK 1259242 B HK1259242 B HK 1259242B HK 19101545 A HK19101545 A HK 19101545A HK 1259242 B HK1259242 B HK 1259242B
Authority
HK
Hong Kong
Prior art keywords
contract
data
temporary
blockchain
key
Prior art date
Application number
HK19101545.7A
Other languages
Chinese (zh)
Other versions
HK1259242A1 (en
Inventor
王虎森
陆旭明
Original Assignee
创新先进技术有限公司
Filing date
Publication date
Application filed by 创新先进技术有限公司 filed Critical 创新先进技术有限公司
Priority to HK19101545.7A priority Critical patent/HK1259242B/en
Publication of HK1259242A1 publication Critical patent/HK1259242A1/en
Publication of HK1259242B publication Critical patent/HK1259242B/en

Links

Description

一种区块链数据处理方法、装置、处理设备及系统Blockchain data processing method, device, processing equipment and system

技术领域Technical Field

本说明书实施例方案属于计算机数据处理的技术领域,尤其涉及一种区块链数据处理方法、装置、处理设备及系统。The embodiments of this specification belong to the technical field of computer data processing, and in particular, to a blockchain data processing method, apparatus, processing equipment, and system.

背景技术Background Art

随着互联网的迅速发展,各类数据成爆发式涌现和增长。其中,区块链因其自身的去中心化、不可篡改、分布式等特点,目前已成为许多技术领域中的重点关注和研究的方向。With the rapid development of the internet, all kinds of data are emerging and growing explosively. Blockchain, due to its inherent decentralization, immutability, and distribution, has become a key focus and research direction in many technology fields.

前在区块链中主要是基于交易驱动区块链数据的更新,如形成一段时间内的交易的摘要信息,连同上一块区块链的摘要存储后形成新的区块。一种区块链应用中,双方可以线下约定好合同内容或合同的执行,然后将相关的数据存放在区块链上。合同在上链(将数据存储到区块链上的过程)过程中通常可以使用一些加密方式对合同进行加密,以保障合同的内容安全,防止非法合同产生或合同的非法篡改。但一些应用场景下也会发生合同参与方的秘钥信息被恶意盗取、丢失等情况,这对区块链会产生较大的数据安全隐患,也会降低区块链用户对提供的区块链服务的安全信任,用户的服务体验也会降低。Previously, blockchain data updates were primarily driven by transactions. For example, a summary of transactions over a period of time was generated and stored together with the summary of the previous blockchain block to form a new block. In one blockchain application, two parties can agree on the content or execution of a contract offline and then store the relevant data on the blockchain. Contracts are typically encrypted during the on-chain process (the process of storing data on the blockchain) to ensure the security of their content and prevent the creation of illegal contracts or unauthorized tampering with them. However, in some application scenarios, the private key information of contract participants can be maliciously stolen or lost. This poses a significant data security risk to the blockchain, reduces users' trust in the security of the provided blockchain services, and reduces the user experience.

因此,在区块链数据服务中亟需一种可以更加有效提高数据安全性的解决方案。Therefore, there is an urgent need for a solution that can more effectively improve data security in blockchain data services.

发明内容Summary of the Invention

本说明书实施例目的在于提供一种区块链数据处理方法、装置、处理设备及系统,合同的各个参与方可以使用产生的临时密钥进行数据的处理,生成更加安全、可靠的区块链数据。The embodiments of this specification aim to provide a blockchain data processing method, apparatus, processing equipment, and system, whereby each party to a contract can use the generated temporary key to process data and generate more secure and reliable blockchain data.

本说明书实施例提供的一种区块链数据处理方法、装置、处理设备及系统是包括以下方式实现的:The blockchain data processing method, apparatus, processing device, and system provided in the embodiments of this specification are implemented in the following ways:

一种区块链数据处理方法,所述方法包括:A blockchain data processing method, the method comprising:

生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;Generate a temporary key for the target contract, wherein the temporary key includes a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm;

基于所述临时密钥生成所述目标合同在区块链上的区块链数据。Generate blockchain data of the target contract on the blockchain based on the temporary key.

一种区块链数据处理方法,所述方法包括:A blockchain data processing method, the method comprising:

接收并存储目标合同的创建数据,所述创建数据包括由合同参与方生成目标合同的临时密钥,基于所述临时密钥生成对所述目标合同进行处理后上传到区块链的数据信息,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;以及,Receiving and storing creation data of a target contract, the creation data including a temporary key generated by a contract participant for the target contract, generating data information of the target contract processed based on the temporary key and then uploaded to the blockchain, the temporary key including a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm; and

接收合同执行数据;Receive contract execution data;

利用所述目标合同参与方对应的公钥对所述合同执行数据进行签名验证;Using the public key corresponding to the target contract participant to perform signature verification on the contract execution data;

若所述签名验证通过,则将存储的目标合同更新为所述加密新合同。If the signature verification is successful, the stored target contract is updated to the encrypted new contract.

一种区块链数据处理装置,所述装置包括:A blockchain data processing device, comprising:

临时密钥生成模块,用于生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;A temporary key generation module, configured to generate a temporary key for a target contract, wherein the temporary key includes a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm;

合同加密签名处理模块,用于基于所述临时密钥生成所述目标合同在区块链上的区块链数据。The contract encryption signature processing module is used to generate the blockchain data of the target contract on the blockchain based on the temporary key.

一种区块链数据处理设备,所述处理设备包括处理器以及用于存储处理器可执行指令的存储器,所述处理器执行所述指令时实现:A blockchain data processing device, comprising a processor and a memory for storing processor-executable instructions, wherein when the processor executes the instructions:

生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;Generate a temporary key for the target contract, wherein the temporary key includes a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm;

基于所述临时密钥生成所述目标合同在区块链上的区块链数据。Generate blockchain data of the target contract on the blockchain based on the temporary key.

一种区块链系统,包括区块链终端、区块链服务器,所述区块链终端和区块链服务器分别包括至少一个处理器用于存储处理器可执行指令的存储器,所述区块链终端的处理器执行所述指令时实现:A blockchain system includes a blockchain terminal and a blockchain server, wherein the blockchain terminal and the blockchain server each include at least one processor and a memory for storing processor-executable instructions, and when the processor of the blockchain terminal executes the instructions, the following is achieved:

本说明书实施例中合同参与方所涉及的任意一项实施例方法中步骤;Any step in any embodiment method involved by the contract participants in the embodiments of this specification;

所述区块链服务器的处理器执行所述指令时实现:When the processor of the blockchain server executes the instructions, the following is achieved:

本说明书实施例中合同参与方所涉及的任意一项区块链在链上数据处理的方法步骤。The method steps for on-chain data processing of any blockchain involved in the contract participants in the embodiments of this specification.

本说明书实施例提供的一种区块链数据处理方法、装置、处理设备及系统,合同参与方关于目标合同相关操作中的加密处理可以使用临时生成的秘钥进行处理,如合同的签署、加密、验证等。临时密钥处理后的数据信息再上传到区块链中进行存储,可以有效保障在链下各个合同参与方对合同数据的安全处理,同时提高了区块链中数据存储的安全性。The embodiments of this specification provide a blockchain data processing method, apparatus, processing device, and system. Contract participants can use temporarily generated secret keys to perform encryption processing related to the target contract, such as contract signing, encryption, and verification. Data processed with the temporary key is then uploaded to the blockchain for storage, effectively ensuring the secure processing of contract data by each contract participant off-chain while also improving the security of data storage within the blockchain.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

为了更清楚地说明本说明书实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本说明书中记载的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of this specification or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments recorded in this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

图1是本说明书所述方法实施例的一个处理流程示意图;FIG1 is a schematic diagram of a processing flow of an embodiment of the method described in this specification;

图2是本说明书提供的一个合同创建过程中利用临时密钥进行数据处理的方法实施例示意图;FIG2 is a schematic diagram of an embodiment of a method for processing data using a temporary key during a contract creation process provided in this specification;

图3是本说明书提供的一个合同创建过程中利用临时密钥进行数据处理的实施示例示意图;FIG3 is a schematic diagram of an implementation example of using a temporary key to process data during a contract creation process provided in this specification;

图4是本说明书提供的一种区块链数据处理方法中合同执行实施例流程示意图;FIG4 is a flow chart of an embodiment of contract execution in a blockchain data processing method provided in this specification;

图5是本说明书提供的一个合同执行过程中利用临时密钥进行数据处理的实施示例示意图;FIG5 is a schematic diagram of an implementation example of using a temporary key to process data during contract execution provided in this specification;

图6是本说明书所述方法另一个实施例的处理流程示意图;FIG6 is a schematic diagram of a processing flow of another embodiment of the method described in this specification;

图7是本发明实施例的一种区块链数据处理设备硬件结构框图;FIG7 is a block diagram of the hardware structure of a blockchain data processing device according to an embodiment of the present invention;

图8是本说明书提供的一种区块链数据处理装置实施例的模块结构示意图。FIG8 is a schematic diagram of the module structure of an embodiment of a blockchain data processing device provided in this specification.

具体实施方式DETAILED DESCRIPTION

为了使本技术领域的人员更好地理解本说明书中的技术方案,下面将结合本说明书实施例中的附图,对本说明书实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本说明书中的一部分实施例,而不是全部的实施例。基于本说明书中的一个或多个实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都应当属于本说明书实施例保护的范围。To help those skilled in the art better understand the technical solutions in this specification, the following will provide a clear and complete description of the technical solutions in the embodiments of this specification, in conjunction with the accompanying drawings. Obviously, the described embodiments are only some of the embodiments in this specification, not all of them. All other embodiments obtained by those skilled in the art based on one or more embodiments in this specification without creative work should fall within the scope of protection of the embodiments of this specification.

所谓区块链技术,简称BT(Blockchain technology),也被称之为分布式账本技术,是一种互联网数据库技术,其特点包括去中心化、公开透明本、数据无法篡改。目前区块链技术已经从单纯的数字货币应用延伸到经济社会的各个领域,如金融服务、供应链管理、文化娱乐、房地产、医疗保健、电子商务等应用场景。区块链中多个用户个体或群体或机构之间可以基于区块链技术特征建立联盟区块链或私有链,加入区块链并成为其中的成员。成员之间的进行的交易数据可以存储到区块链中,例如链下签署的合同内容可以存储的区块链中。Blockchain technology, also known as BT (Blockchain Technology), is an internet database technology characterized by decentralization, transparency, and data immutability. Blockchain technology has expanded beyond simple digital currency applications to encompass diverse sectors of the economy and society, including financial services, supply chain management, entertainment, real estate, healthcare, and e-commerce. Based on the characteristics of blockchain technology, multiple users, groups, or institutions can establish consortium blockchains or private chains, join them, and become members. Transaction data between members can be stored on the blockchain, such as the content of contracts signed off-chain.

需要说明的是,本说明书实施例中所述的链下或后续涉及的链上主要是指是否是在区块链上进行的数据操作,如线下用户商谈签署合约、认证机构进行身份证实、颁发证书等进行的区块链之外的操作可以为链下相关的操作,将公钥或证书提交到区块链上、区块链节点的验证、数据存储等可以为链上相关的操作,如将数据提交到区块链上进行存储可以称为上链。It should be noted that the off-chain or subsequent on-chain operations described in the embodiments of this specification mainly refer to whether the data operations are performed on the blockchain. Operations outside the blockchain, such as offline users negotiating and signing contracts, certification agencies performing identity verification, issuing certificates, etc., can be off-chain related operations, and submitting public keys or certificates to the blockchain, verification of blockchain nodes, data storage, etc. can be on-chain related operations. For example, submitting data to the blockchain for storage can be called on-chain.

传统的合同通常是合同参与方经过商议和讨论达成一致后,记录在纸张上。本说明书实施例中所涉及的合同,可以以数字化或其他计算机数据存储形式(如量子计算机)存储记录区块链上。本说明书实施例所述的合同可以包括合同的创建合同、合同的执行。所述的创建可以包括一个或多个合同参与方或者第三方预先拟定格式合同,可以预定一些必要的权利/义务,格式合同的具体内容事项可以根据参与方合作需求进行设置和确定。格式合同确定后可以基于临时密钥的处理后存储到区块链上,格式合同对应的数据可以称为创建数据。合同参与方若基于格式合同进行了合同内容的填充、修改、更新等生成新的合同,或者合同参与方确认内容并签署生效的可以称为合同的执行,如合同参与方A和B线下对目标合同T_C(一个预先创建的格式合同)的执行过程达成共识生成包含了合同新内容的新合同。新合同的内容可以再使用临时密钥处理后存储到区块链上。本说明书一个或多个实施例方案中合同的创建和合同的执行中区块链节点均可以使用临时密钥参与其中的处理。图1是本说明书提供的所述一种区块链数据处理方法实施例的流程示意图具体的,如图1所示,所述方法可以包括:Traditional contracts are typically recorded on paper after the parties reach an agreement through negotiation and discussion. The contracts discussed in the embodiments of this specification can be stored digitally or in other computer data storage formats (such as quantum computers) on a blockchain. The contracts described in the embodiments of this specification can include contract creation and contract execution. Creation can involve one or more contract parties or a third party pre-drafting a standard contract, which can pre-define certain necessary rights and obligations. The specific content of the standard contract can be set and determined based on the cooperation needs of the parties. Once the standard contract is finalized, it can be stored on the blockchain after processing using a temporary key. The data corresponding to the standard contract can be referred to as creation data. Contract execution occurs when the contract parties add, modify, or update the contract content based on the standard contract to generate a new contract, or when the contract parties confirm the content and sign it to effectuate the contract. For example, contract parties A and B reach a consensus offline on the execution process of target contract T_C (a pre-created standard contract) to generate a new contract containing the new contract content. The content of the new contract can then be processed using a temporary key and stored on the blockchain. In one or more embodiments of this specification, blockchain nodes can participate in both contract creation and contract execution using temporary keys. FIG1 is a flow chart of an embodiment of a blockchain data processing method provided in this specification. Specifically, as shown in FIG1 , the method may include:

S0:生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥。S0: Generate a temporary key for the target contract, where the temporary key includes a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm.

一般的,可以由合同参与方生成对应于某个目标合同的临时密钥,不同的合同参与方可以各自独立生成自己的临时密钥。当然,其他的实施方案中,也可以所有或部分合同参与方的临时密钥由指定的某个处理设备,然后按照一定的规则分发给对应的合同参与方,这种合同参与方利用接收的临时密钥作用在目标合同上的情况对于合同参与方处理终端而言也可以归属为生成(确定)目标合同的临时密钥的一种情况。所述的合同参与方通常是指包括合同所涉及的参与方,如合同内容涉及参与方A和B。本实施例不排除所述的合同参与方还可以包括约定允许的其他参与方,如不涉及合同业务内容的第三方、担保方、监管方等。合同可以有多种存在形式,如相同的合同参与方可以创建不同的合同,如合同参与方A和B可以创建合同T_C1,还可以再创建合同T_C2。同一个参与方不同的合作方可以创建不同的合同,如合同参与方A与B创建合同T_C3,同时合同参与方A与D可以创建合同T_C4。为便于描述,本实施例中可以将合同参与方处理的合同称为目标合同,当然,目标合同可以随着后续其他的处理,如合同的执行、状态的变更等可以有对应其他名称。Generally, a temporary key corresponding to a target contract can be generated by a contract participant, and different contract participants can each independently generate their own temporary keys. Of course, in other implementation schemes, the temporary keys of all or part of the contract participants can be distributed to the corresponding contract participants according to certain rules by a designated processing device. This situation in which the contract participant uses the received temporary key to act on the target contract can also be classified as a situation in which a temporary key of the target contract is generated (determined) for the contract participant processing terminal. The contract participants generally refer to the parties involved in the contract, such as the contract content involves participants A and B. This embodiment does not exclude that the contract participants can also include other parties allowed by the agreement, such as third parties, guarantors, regulators, etc. that are not involved in the contract business content. Contracts can have multiple forms of existence, such as the same contract participants can create different contracts, such as contract participants A and B can create contract T_C1, and can also create contract T_C2. Different partners of the same participant can create different contracts, such as contract participants A and B create contract T_C3, while contract participants A and D can create contract T_C4. For ease of description, in this embodiment, the contract processed by the contract participants can be called the target contract. Of course, the target contract can have other corresponding names as other subsequent processes, such as contract execution, status changes, etc.

本说明书的一些实施例中,涉及到合同的处理,如合同内容的确定、合同加密等可以使用临时密钥进行加密或签名处理。在本实施区块链数据处理的应用场景中,可以采用与非对称加密算法生成临时密钥,临时密钥可以包括临时公钥和临时私钥。与对称加密算法不同,非对称加密算法需要两个密钥:公开密钥(publickey)和私有密钥(privatekey),或简称公钥和私钥。公开密钥与私有密钥是一对,如果用公开密钥对数据进行加密,只有用对应的私有密钥才能解密;如果用私有密钥对数据进行加密,那么只有用对应的公开密钥才能解密。在本说明书的一些实施例场景中,所述的临时密钥的应用方式主要包括:临时公钥加密后使用临时私钥进行解密、临时私钥签名后使用临时公钥进行验证。非对称加密中使用的算法可以包括:RSA、Elgamal、背包算法、Rabin、D-H、ECC(椭圆曲线加密算法)等。In some embodiments of this specification, temporary keys may be used for encryption or signing related to contract processing, such as determining contract content and encrypting contracts. In this application scenario involving blockchain data processing, asymmetric encryption algorithms can be used to generate temporary keys, which can include temporary public keys and temporary private keys. Unlike symmetric encryption algorithms, asymmetric encryption algorithms require two keys: a public key and a private key, or simply a public key and a private key. The public key and private key form a pair. If data is encrypted with the public key, it can only be decrypted with the corresponding private key; if data is encrypted with the private key, it can only be decrypted with the corresponding public key. In some embodiments of this specification, the use of temporary keys primarily includes: decrypting data after encrypting it with a temporary public key, and verifying data after signing it with a temporary private key using a temporary public key. Algorithms used in asymmetric encryption include RSA, Elgamal, Knapsack, Rabin, D-H, and ECC (Elliptic Curve Cryptography).

S2:基于所述临时密钥生成所述目标合同在区块链上的区块链数据。S2: Generate blockchain data of the target contract on the blockchain based on the temporary key.

使用临时密钥对目标合同进行处理,生成的区块链数据可以存储到区块链上。如一个示例中,合同参与方A和B对达成共识的目标合同T_C1各自分别使用私钥签名后上传到区块链,或者,根据区块链的数据处理要求还可以包括其他的数据处理,如合同加密后再利用合同参与方各自的私钥签名,或者连同各个合同参与的公钥一同上链。The target contract is processed using the temporary key, and the resulting blockchain data can be stored on the blockchain. For example, in one example, contract participants A and B each sign the agreed-upon target contract T_C1 using their own private keys and upload it to the blockchain. Alternatively, other data processing can be included based on the blockchain's data processing requirements, such as encrypting the contract and then signing it using the private keys of each contract participant, or uploading it to the blockchain along with the public keys of each contract participant.

本说明书中所述的临时密钥的更新方式可以根据自定义的设计。一般的,一份合同使用一个临时密钥对可以更加有效的提高区块链数据的安全性。如本说明书的一些实施例中,所述的临时密钥可以对一份目标合同进行相关联处理的加密或签名处理,如合同参与方A每次处理不同目标合同时使用不同的临时密钥对。其他的实施例中一个临时密钥对可以多次使用,如合同参与方A的临时密钥对仅对3份合同的数据处理有效,在对第4分合同处理时需要更换新的秘钥对。或者,其他的实施例中,临时密钥也可以根据合同参与方来设置更换方式,如合同参与方A于合同参与方B的多份合同使用相同的临时密钥PK1、SK1,若有新的合同参与方C加入,即合同涉及的参与方包括A、B、C,则合同参与方A需要使用新的临时密钥PK2、SK2,或者合同参与方A与合同参与方C签署的合同使用新的临时密钥PK3、SK3。同理的,合同参与方B或C也可以参照合同参与方A的方式执行相同的临时密钥更换策略。上述中的PK表示为公钥,SK表示为私钥。下述中涉及到的TPK或tpk表示为临时公钥,相应的TSK或tsk表示为临时私钥,如tpk_A可以表示合同参与方A的临时公钥。The temporary key update method described in this specification can be customized. Generally, using a single temporary key pair for each contract can more effectively improve the security of blockchain data. For example, in some embodiments of this specification, the temporary key can be used to encrypt or sign related processes for a target contract. For example, contract participant A uses a different temporary key pair each time it processes a different target contract. In other embodiments, a single temporary key pair can be used multiple times. For example, contract participant A's temporary key pair is only valid for processing data from three contracts, requiring a new key pair for processing the fourth contract. Alternatively, in other embodiments, the temporary key can be updated based on the contract participants. For example, if contract participant A uses the same temporary keys PK1 and SK1 for multiple contracts with contract participant B, and a new contract participant C joins, meaning the contract involves parties A, B, and C, contract participant A must use new temporary keys PK2 and SK2, or the contract signed by contract participant A and contract participant C must use new temporary keys PK3 and SK3. Similarly, contract participants B or C can also implement the same temporary key update strategy as contract participant A. In the above, PK represents the public key, and SK represents the private key. In the following, TPK or tpk represents the temporary public key, and the corresponding TSK or tsk represents the temporary private key. For example, tpk_A can represent the temporary public key of contract participant A.

因此,本说明书所述方法的另一个实施例中,所述临时密钥可以:Therefore, in another embodiment of the method described in this specification, the temporary key may be:

S02:基于不同的合同参与方、不同的目标合同中的至少一项进行临时密钥更新。S02: Performing a temporary key update based on at least one of different contract participants and different target contracts.

如合同参与方的变化或对于不同的目标合同的内容,可以生成新的临时公钥和临时私钥。例如一个示例中,合同参与方A和B签署不同的合同时可以使用不同的临时密钥对,合同参与方A和B、合同参与方A和C签署相同的合同时,合同参与方A分别针对A和B使用不同的临时密钥对。另外,所述的不同的目标合同可以包括不同的合同内容,也可以包括不同的合同签署时间,如合同参与方和合同内容不变的情况下,不同时间或不同时间段进行合同数据处理时可以更新临时密钥。一种实施场景中,面对不同的交易参与方,或者,每次交易时都更改临时密钥,使得区块链上交易与交易之间难以关联,可以有效防止对区块链账本数据的违法或违约或其他恶意的数据分析,有效提高区块链数据的安全性。If there is a change in the parties to the contract or for different target contract contents, a new temporary public key and temporary private key can be generated. For example, in one example, when contract parties A and B sign different contracts, they can use different temporary key pairs. When contract parties A and B, or contract parties A and C sign the same contract, contract party A uses different temporary key pairs for A and B respectively. In addition, the different target contracts can include different contract contents, and can also include different contract signing times. For example, if the contract parties and contract contents remain unchanged, the temporary key can be updated when the contract data is processed at different times or different time periods. In one implementation scenario, facing different transaction participants, or changing the temporary key each time a transaction is made, it is difficult to associate transactions on the blockchain, which can effectively prevent illegal or breach of contract or other malicious data analysis of blockchain ledger data, and effectively improve the security of blockchain data.

另一种实施方式中,所述的临时密钥可以根据预先的设定进行周期性的更换,如每个合同参与方的临时密钥对一天更换一次。更换周期可以预先统一设定,也可以根据合同参与方的权限(如权重、甲方或乙方身份、信用级别、股权等)等设置不同的更换频率,如合同参与方A为重要的资产管理方,其临时密钥对为一天更换一次,其合作方B、C的临时密钥对为一周更换一次。因此,本说明书所述方法的另一个实施例中,所述临时密钥包括:In another embodiment, the temporary key can be replaced periodically according to a pre-set setting, such as the temporary key pair of each contract participant is replaced once a day. The replacement cycle can be pre-set uniformly, or different replacement frequencies can be set according to the authority of the contract participants (such as weight, identity of Party A or Party B, credit level, equity, etc.). For example, if contract participant A is an important asset manager, its temporary key pair is replaced once a day, and the temporary key pairs of its partners B and C are replaced once a week. Therefore, in another embodiment of the method described in this specification, the temporary key includes:

S04:基于预设的更换周期进行临时密钥更新。S04: Update the temporary key based on the preset replacement period.

一个示例中,基于更换周期和合同参与方的权限的临时密钥更新策略均使用,可以设置相同权限的合同参与方设置相同的更换周期,或者相同权限的合同参与方设置不同的更换周期,如甲方A每天更换一次临时密钥对,乙方B每周更换一次临时密钥对,乙方C每三天更换一次临时密钥对。In one example, temporary key update strategies based on the replacement cycle and the authority of the contract participants are both used. Contract participants with the same authority can be set to the same replacement cycle, or contract participants with the same authority can be set to different replacement cycles, such as Party A changes the temporary key pair once a day, Party B changes the temporary key pair once a week, and Party C changes the temporary key pair every three days.

本说明书的一些实施例中,更新后的密钥信息仍然可以继续保留在区块链节点中。In some embodiments of this specification, the updated key information may still continue to be retained in the blockchain node.

本说明书实施例采用临时密钥处理后的数据信息再上传到区块链中进行存储,可以有效保障在链下各个合同参与方对合同数据的安全处理,同时提高了区块链中数据存储的安全性。The embodiments of this specification use data information processed with a temporary key and then uploaded to the blockchain for storage, which can effectively ensure the secure processing of contract data by each contract participant off-chain, while improving the security of data storage in the blockchain.

下面以另一个具体的合同创建的应用场景为例对本说明书实施方案进行说明。具体的,图2是本说明书提供的所述一种区块链数据处理方法实施例的流程示意图。虽然本说明书提供了如下述实施例或附图所示的方法操作步骤或装置结构,但基于常规或者无需创造性的劳动在所述方法或装置中可以包括更多或者部分合并后更少的操作步骤或模块单元。在逻辑性上不存在必要因果关系的步骤或结构中,这些步骤的执行顺序或装置的模块结构不限于本说明书实施例或附图所示的执行顺序或模块结构。所述的方法或模块结构的在实际中的装置、服务器或终端产品应用时,可以按照实施例或者附图所示的方法或模块结构进行顺序执行或者并行执行(例如并行处理器或者多线程处理的环境、甚至包括分布式处理、服务器集群的实施环境)。The following describes the implementation scheme of this specification using another specific application scenario of contract creation as an example. Specifically, Figure 2 is a flow chart of an embodiment of the blockchain data processing method provided in this specification. Although this specification provides the method operation steps or device structure shown in the following embodiments or figures, the method or device may include more or fewer operation steps or module units after partial merger based on routine or no creative work. In steps or structures that do not logically have a necessary causal relationship, the execution order of these steps or the module structure of the device is not limited to the execution order or module structure shown in the embodiments or figures of this specification. When the method or module structure described is applied in actual devices, servers, or terminal products, it can be executed sequentially or in parallel according to the method or module structure shown in the embodiments or figures (for example, in a parallel processor or multi-threaded processing environment, or even in a distributed processing or server cluster implementation environment).

所述的合同创建可以包括前述所述的格式合同的创建,也可以包括正式合同的签署确认。后续的还可以包括合同的执行的处理。当然,下述实施例的描述并不对基于本说明书的其他可扩展到的技术方案构成限制。例如其他的实施场景中,还可以包括备忘录、合约、规章、报表、公示等单方或双方或多方需要存储到区块链上以更新区块链节点数据进行的数据操作。具体的一种实施例如图2所示,本说明书提供的所述方法的另一种实施例中,所述区块链数据包括所述目标合同的创建数据,以及采用下述方式确定所述创建数据:The contract creation may include the creation of the aforementioned format contract, and may also include the signing and confirmation of the formal contract. The subsequent process may also include the execution of the contract. Of course, the description of the following embodiment does not limit other technical solutions that can be expanded based on this specification. For example, other implementation scenarios may also include memoranda, contracts, regulations, reports, announcements, etc., which need to be stored on the blockchain by one party or both parties or multiple parties to update the blockchain node data. A specific embodiment is shown in Figure 2. In another embodiment of the method provided in this specification, the blockchain data includes the creation data of the target contract, and the creation data is determined in the following manner:

S20:合同参与方各互相发送各自生成的临时密钥中的临时公钥;S20: The contract participants send each other the temporary public key generated by each of them;

S22:所述合同参与方利用本端的临时私钥对包括所述目标合同、各个合同参与方的临时公钥的数据信息进行签名,生成所述合同参与方各自对应的第一签名数据;S22: The contract participant uses the temporary private key of the local end to sign the data information including the target contract and the temporary public key of each contract participant, thereby generating first signature data corresponding to each contract participant;

S24:利用监管方的监管密钥对预定合同信息进行加密,生成加密合同,所述预定合同信息包括所述目标合同、各个合同参与方的临时公钥、所述第一签名数据;S24: Encrypting the predetermined contract information using the supervisory key of the supervisor to generate an encrypted contract, wherein the predetermined contract information includes the target contract, the temporary public key of each contract participant, and the first signature data;

S26:确定各个合同参与方利用相应的临时私钥对所述加密合同进行签名后,基于签名后的数据、合同参与方的临时公钥确定所述目标合同的创建数据。S26: After each contract participant signs the encrypted contract using a corresponding temporary private key, the creation data of the target contract is determined based on the signed data and the temporary public keys of the contract participants.

上述中的S20的执行中,对于单侧合同参与方的处理设备而言,可以理解为发送本端生成的临时公钥至其他合同参与方。所述的其他合同参与方通常包括涉及双方利益的合同参与,或签署合同的参与方,其他的实施例中也可以包括预定的合法的其他参与方。生成的创建数据可以直接上链存储到区块链中作为区块链数据,或者还可以在上链之前或上链之后再进行其他的数据处理后存储。图3是本说明书提供的一个合同创建过程中利用临时密钥进行数据处理的实施示例示意图。如图3所示,假设目标合同涉及合同参与方A、B两方。A和B为联盟链的成员,分别持有相应的证书。该证书可以证明其为区块链上的合法成员,可以进行区块链上合同的创建、执行等处理。In the execution of S20 mentioned above, for the processing device of a unilateral contract participant, it can be understood as sending the temporary public key generated by this end to other contract participants. The other contract participants generally include contract participants involving the interests of both parties, or participants who sign the contract. Other embodiments may also include predetermined legal other participants. The generated creation data can be directly uploaded to the chain and stored in the blockchain as blockchain data, or it can be stored after other data processing before or after being uploaded to the chain. Figure 3 is a schematic diagram of an implementation example of using a temporary key for data processing during a contract creation process provided in this specification. As shown in Figure 3, it is assumed that the target contract involves two contract participants A and B. A and B are members of the alliance chain and hold corresponding certificates respectively. The certificate can prove that it is a legal member on the blockchain and can perform the creation, execution and other processing of the contract on the blockchain.

A和B可以各自独立生成自己的临时密钥对(tpk_A,tsk_A)、(tpk_B,tsk_B)。双方的临时公钥可以通过建立的端到端的加密通道进行数据传输。如基于SSL(Secure SocketsLayer安全套接层)协议的端到端加密通道。这样可以进一步提高数据传输的安全性。为了支持区块链上的两个用户的端到端线下通信需求,用户(包括合同参与方)通常需要相互校验身份,并且能够同区块链进行通信,通过区块链查询对方身份,并核实是区块链合法用户。具体的一个流程可以包括如下:A and B can each independently generate their own temporary key pairs (tpk_A, tsk_A) and (tpk_B, tsk_B). The temporary public keys of both parties can be transmitted through an established end-to-end encrypted channel, such as an end-to-end encrypted channel based on the SSL (Secure Sockets Layer) protocol. This can further improve the security of data transmission. To support the end-to-end offline communication needs of two users on the blockchain, users (including contract participants) generally need to verify each other's identities and be able to communicate with the blockchain, query the other party's identity through the blockchain, and verify that they are legitimate blockchain users. A specific process may include the following:

(1)用户A、B通过区块链注册机构,可以以智能合约或者非智能合约的形式将实体信息和数字身份注册在区块链平台上。区块链平台对注册机构的签名进行校验,通过后,A、B的实体信息和数字身份被存储在区块链上。数字身份可以包含用户的公钥和私钥等,实体信息可以包含用户的姓名、身份证等信息。(1) Users A and B can register their physical information and digital identity on the blockchain platform through a blockchain registration agency in the form of a smart contract or a non-smart contract. The blockchain platform verifies the signature of the registration agency. If it passes, A and B's physical information and digital identity are stored on the blockchain. The digital identity can include the user's public key and private key, and the physical information can include the user's name, ID card, and other information.

(2)用户A和用户B建立一个加密通道。A、B首先相互发送对方的数字身份摘要到区块链平台,平台查询到A、B是合法用户后,给A、B返回确认消息,否则发回否定消息,A、B通信中止。(2) User A and User B establish an encrypted channel. A and B first send each other’s digital identity summaries to the blockchain platform. After the platform verifies that A and B are legitimate users, it returns a confirmation message to A and B. Otherwise, it sends a negative message and the communication between A and B is terminated.

(3)为了确认B的身份,A可以从B获取查询的授权(即对A查询请求的签名),向区块链提交查询申请。B同理做此步骤提交对A的查询。(3) To confirm B’s identity, A can obtain the query authorization from B (i.e., the signature of A’s query request) and submit the query request to the blockchain. B similarly performs the same step to submit a query to A.

(4)区块链平台检验A、B的查询和授权签名,同时查到A、B是区块链用户,将A、B的实体信息分别发送给双方。若A或B不是区块链用户,则返回失败消息。A、B通信中止。(4) The blockchain platform verifies A and B’s query and authorization signatures, and if it finds that A and B are blockchain users, it sends A and B’s entity information to both parties. If A or B is not a blockchain user, a failure message is returned. Communication between A and B is terminated.

(5)A、B对对方实体信息核实后,利用数字身份建立加密通道,交换消息,如交换临时公钥。(5) After A and B verify each other's entity information, they use digital identities to establish an encrypted channel and exchange messages, such as exchanging temporary public keys.

A和B相互发送临时公钥后,可以分别使用自己的私钥对(目标合同的合同内容,tpk_A,tpk_B)进行签名,生成各自对应的私钥签名后的数据,在此可以统一称为第一签名数据,同样的,对目标合同的合同内容的签名也可以简称为对目标合同的签名。如A可以使用私钥tsk_A对(目标合同,tpk_A,tpk_B)签名生成A的第一签名数据sigA,B使用私钥tsk_B对(目标合同,tpk_A,tpk_B)签名生成B的第一签名数据sigB。第一签名数据也可以相互发送,如A将sigA发送给B。After A and B exchange their temporary public keys, they can each use their own private key to sign the target contract's contract content, tpk_A, tpk_B, generating data signed by their respective private keys. This data is collectively referred to as the first signature data. Similarly, the signature of the target contract's contract content can also be referred to as the signature of the target contract. For example, A can use private key tsk_A to sign the target contract, tpk_A, tpk_B, generating A's first signature data sigA, while B can use private key tsk_B to sign the target contract, tpk_A, tpk_B, generating B's first signature data sigB. The first signature data can also be sent back and forth, such as A sending sigA to B.

一些实施例应用场景中,合同的交易可以受到监管方的监管,可以查阅、审核、审查、阻止合同,监管基于合同的非法行为。一些实施例中,所述的监管方可以包括合法监管机构,如中央银行、证监会等国家金融监管机构,可以使用监管密钥来监督区块链交易。另一些实施例中也可以预先在合约规则中约定具有监管效力的监管方,如指定的一个或多个成员,或者另一种实施方式中可以约定在达到预定的数量或比例的成员认同某个成员,该成员具有监管权利。达到预定数量或比例的成员在此可以成员监管成员组,如区块链中有10个成员,可以预定若7个成员或者70%的成员认同成员A,则成员A可以作为监管方。In some embodiments, contract transactions can be supervised by regulators, who can review, audit, examine, and block contracts, and supervise illegal activities based on contracts. In some embodiments, the regulators can include legitimate regulatory agencies, such as national financial regulatory agencies such as the central bank and the China Securities Regulatory Commission, which can use regulatory keys to oversee blockchain transactions. In other embodiments, the regulators with regulatory power can be agreed upon in advance in the contract rules, such as one or more designated members, or in another embodiment, it can be agreed that if a predetermined number or proportion of members recognize a certain member, the member will have regulatory rights. Members who reach a predetermined number or proportion can form a member supervision group. For example, if there are 10 members in the blockchain, it can be predetermined that if 7 members or 70% of the members recognize member A, member A can serve as the regulator.

因此,在本实施例实施场景中,还可以监管方的监管密钥对目标合同的相关信息进行加密。本实施例实施场景中监管方的监管密钥可以为非对称加密算法的公钥,当然,本说明书不排除其他的实施例中,监管密钥也可以采用其他加密算法生成。使用监管方广播的公钥加密的信息内容可以包括目标合同(合同内容)、所有合同参与方的临时公钥、所有合同参与方的签名数据,或者还可以包括所有合同参与方的证书。如A使用监管密钥key对(目标合同,tpk_A,tpk_B,sigA,sigB,certA,certB)进行加密,生成加密合同。加密合同可以由任意一个合同参与方处理后生成。这样,监管方可以使用自己对应的解密密钥,如私钥,从区块链中获取目标合同,验证合同参与方是否非法,合同内容是否违法等,以进行对区块链上合同的监督和约束。如,监管方使用解密合同,查阅合同内容以及国外合作方后,发现存在合同存在涉及国防专利的技术非法转让,则可以通过提交区块链交易阻止该合同的进行。当然,其他的实施例中,如果涉及该目标合同的交易对于其他区块链成员C可见,那么也可以使用C的公钥进行加密。使用C的公钥加密以及成员C使用自己私钥解密查看目标合同等的处理方式可以参考上述监管方的处理,在此不做赘述。Therefore, in the implementation scenario of this embodiment, the supervisor's supervisory key can also be used to encrypt relevant information about the target contract. In this implementation scenario, the supervisor's supervisory key can be the public key of an asymmetric encryption algorithm. Of course, this specification does not exclude the possibility that in other embodiments, the supervisory key can be generated using other encryption algorithms. The information encrypted using the public key broadcast by the supervisor can include the target contract (contract content), the temporary public keys of all contract participants, the signature data of all contract participants, or even the certificates of all contract participants. For example, A uses the supervisory key key to encrypt (target contract, tpk_A, tpk_B, sigA, sigB, certA, certB) to generate an encrypted contract. The encrypted contract can be generated after processing by any contract participant. In this way, the supervisor can use its corresponding decryption key, such as a private key, to retrieve the target contract from the blockchain and verify whether the contract participants are illegal and whether the contract content is illegal, thereby supervising and regulating contracts on the blockchain. For example, if the supervisor decrypts the contract, reviews the contract content and the foreign partner, and discovers that the contract involves the illegal transfer of technology involving national defense patents, it can submit a blockchain transaction to block the contract. Of course, in other embodiments, if the transaction involving the target contract is visible to other blockchain member C, it can also be encrypted using C's public key. The processing method of using C's public key to encrypt and member C to decrypt and view the target contract using its own private key can refer to the processing of the supervisor above and will not be repeated here.

生成的加密合同在上链之前,各个合同参与方可以对该加密合同进行私钥签名,签名后的数据连同各个合同参与方的临时公钥tpk_A、tpk_B作为存储到区块链上的创建数据。Before the generated encrypted contract is uploaded to the blockchain, each contract participant can sign the encrypted contract with a private key. The signed data together with the temporary public keys tpk_A and tpk_B of each contract participant are used as the creation data stored on the blockchain.

创建数据可以提交到区块链上进行存储。当然,区块链上还可以设置有智能合约平台,所述的创建数据可以提交到智能合约平台,由智能合约平台进行管理。The creation data can be submitted to the blockchain for storage. Of course, the blockchain can also be provided with a smart contract platform, and the creation data can be submitted to the smart contract platform for management.

上述实施例描述了合同创建存储到区块链上利用临时密钥处理的实施场景。下面对合同执行时利用临时密钥的处理实施场景进行说明。图4是本说明书提供的一种区块链数据处理方法中合同执行实施例流程示意图,如图4所示,所述区块链数据还可以包括合同执行数据,及采用下述方式确定所述合同执行数据:The above embodiment describes an implementation scenario where a contract is created and stored on a blockchain using a temporary key. The following describes an implementation scenario where a temporary key is used during contract execution. Figure 4 is a flow chart of an embodiment of contract execution in a blockchain data processing method provided in this specification. As shown in Figure 4, the blockchain data may also include contract execution data, and the contract execution data may be determined using the following method:

S40:利用所述监管密钥对确定的新合同进行加密,生成加密新合同,所述新合同由合同参与方线下对所述目标合同的执行过程达成共识后确定;S40: Encrypting the determined new contract using the supervision key to generate an encrypted new contract, wherein the new contract is determined after the contract participants reach a consensus on the execution process of the target contract offline;

S42:各个合同参与方可以利用所述加密新合同对应的临时私钥对所述加密新合同进行签名,生成第二签名数据;S42: Each contract participant may sign the encrypted new contract using the temporary private key corresponding to the encrypted new contract to generate second signature data;

S44:基于所述第二签名数据、加密新合同确定合同执行数据。S44: Based on the second signature data, encrypt the new contract and determine the contract execution data.

上述S42的执行处理,对于合同参与方的处理装置而言,可以理解为确定各个合同参与方对所述加密新合同的签名后,基于所述第二签名数据、加密新合同确定合同执行数据。例如一个合同参与方确定其他所有合同参与方(包括自己)均使用了临时私钥进行签名后,则将各方签名后的第二签名数据和加密新合同确定为合同执行数据。然后可以将合同执行数据提交至区块链。上述S42中所示加密新合同对应的临时密钥可以与所述加密新合同对应的目标合同在创建时使用的临时密钥相同,也可以不相同。例如对于在更新合同内容签署确定的新合同时已经达到了临时密钥更换周期,此时再对加密新合同进行签名时使用的临时密钥与之前对应的目标合同创建存储到区块链上时的临时密钥不相同。更新的临时密钥可以通过提交交易更新至区块链相应的数据中。The execution process of the above S42 can be understood as, for the processing device of the contract participants, determining the signature of each contract participant on the encrypted new contract, and then determining the contract execution data based on the second signature data and the encrypted new contract. For example, after a contract participant determines that all other contract participants (including himself) have used a temporary private key to sign, the second signature data signed by each party and the encrypted new contract are determined as the contract execution data. The contract execution data can then be submitted to the blockchain. The temporary key corresponding to the encrypted new contract shown in the above S42 can be the same as the temporary key used when the target contract corresponding to the encrypted new contract was created, or it can be different. For example, when the new contract is signed and confirmed to update the contract content, the temporary key replacement cycle has been reached. At this time, the temporary key used when signing the encrypted new contract is different from the temporary key when the corresponding target contract was created and stored on the blockchain. The updated temporary key can be updated to the corresponding data in the blockchain by submitting a transaction.

图5是本说明书提供的一个合同执行过程中利用临时密钥进行数据处理的实施示例示意图。如图5所示,假设合同的执行涉及A、B双方利益。A、B线下对合同执行过程达成共识,如增加或修改了合同内容,形成新合同v1。A或B对新合同利用监管密钥key加密,生成加密新合同V1。然后各个合同参与方分别可以利用对应的原目标合同的临时私钥签名,如A可以利用目标合同建立时的临时私钥tsk_A进行签名后,再由B使用临时私钥tsk_B进行签名。所有合同参与方签名后的数据连同加密新合同一起上链。包括所述第二签名数据、加新合同的将要提交至区块链的数据可以称为合同执行数据,或者提交到区块链保存后也可以称为合同执行数据,上述目标合同的创建数据同理。在此过程,与新建合同不同的是,A、B在执行合同状态转移的过程中,可以不需要获取监管方授权,如合同的变更、合同的生效、合同的中断、合同的终止等,在合同参与方使用监管公钥加密,然后各个合同参与方私钥签名确定新合同或者合同的状态转移后,合同内容以及合同状态即可以生效。除特殊规定情况下,可以无需获取监管方授权。Figure 5 is a schematic diagram of an implementation example provided in this specification for using a temporary key to process data during the execution of a contract. As shown in Figure 5, assume that the execution of a contract involves the interests of both parties A and B. A and B reach a consensus on the contract execution process offline, such as adding or modifying the contract content, to form a new contract v1. A or B encrypts the new contract using the supervisory key key to generate an encrypted new contract V1. Each contract participant can then use the temporary private key of the corresponding original target contract to sign. For example, A can use the temporary private key tsk_A used when establishing the target contract to sign, and then B can use the temporary private key tsk_B to sign. The data signed by all contract participants is uploaded to the blockchain together with the encrypted new contract. The data to be submitted to the blockchain, including the second signature data and the new contract, can be called contract execution data, or after being submitted to the blockchain for storage, it can also be called contract execution data. The same applies to the creation data of the target contract mentioned above. Unlike creating a new contract, A and B do not need to obtain the regulator's authorization when executing contract status transfers, such as contract changes, contract entry into force, contract interruption, and contract termination. Once the contract participants encrypt the contract or contract status transfer using the regulator's public key and then sign with their private keys to confirm the new contract or contract status transfer, the contract content and contract status will take effect. Unless otherwise specified, there is no need to obtain the regulator's authorization.

上述实施例所述可以由合同参与方的处理设备执行,可以包括与区块链节点的服务器通信的设备,或者在区块链节点的服务器上执行。进一步的,所有私钥签名加密新合同上传到区块链上后,区块链节点可以利用合同对应的公钥进行签名验证,以确定合同执行的合法性/合规性。如区块链上的智能合约平台可以利用加密新合同对应的目标合同参与方的公钥tpk_A、tpk_B校验签名。若校验通过,则可以将存储的目标合同更新为所述加密新合同。因此,对于区块链节点的处理设备来说,所述方法还可以包括:The above embodiments can be executed by the processing equipment of the contract participants, which may include a device that communicates with the server of the blockchain node, or be executed on the server of the blockchain node. Furthermore, after all new contracts encrypted with private key signatures are uploaded to the blockchain, the blockchain node can use the public key corresponding to the contract to verify the signature to determine the legality/compliance of the contract execution. For example, the smart contract platform on the blockchain can use the public keys tpk_A and tpk_B of the target contract participants corresponding to the encrypted new contract to verify the signature. If the verification passes, the stored target contract can be updated to the encrypted new contract. Therefore, for the processing equipment of the blockchain node, the method may also include:

S60:利用所述目标合同参与方对应的公钥对所述合同执行数据进行签名验证;S60: Using the public key corresponding to the target contract participant to perform signature verification on the contract execution data;

S62:若所述签名验证通过,则将存储的目标合同更新为所述加密新合同。S62: If the signature verification passes, the stored target contract is updated to the encrypted new contract.

基于上述描述,针对区块链节点的处理设备,本说明书还提供所述方法的另一个实施例,如图6所示,所述方法包括:Based on the above description, this specification also provides another embodiment of the method for a processing device of a blockchain node, as shown in FIG6 , the method comprising:

S80:接收并存储目标合同的创建数据,所述创建数据包括由合同参与方生成目标合同的临时密钥,基于所述临时密钥生成对所述目标合同进行处理后上传到区块链的数据信息,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;以及,S80: Receive and store creation data of the target contract, the creation data including a temporary key generated by the contract participants for the target contract, data information generated based on the temporary key and then processed and uploaded to the blockchain, the temporary key including a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm; and

S82:接收合同执行数据;S82: receiving contract execution data;

S84:利用所述目标合同参与方对应的公钥对所述合同执行数据进行签名验证;S84: Using the public key corresponding to the target contract participant to perform signature verification on the contract execution data;

S86:若所述签名验证通过,则将存储的目标合同更新为所述加密新合同。S86: If the signature verification passes, the stored target contract is updated to the encrypted new contract.

需要说明的是,本说明书实施例上述所述的可以在区块链的客户端或区块链节点的服务器上实现,例如客户端使用临时密钥对合同创建和执行的处理,区块链节点的服务器存储的区块链数据为使用临时密钥处理的数据,服务器使用存储的临时公钥来验证合同的变更或状态转移等。It should be noted that the above-mentioned embodiments of this specification can be implemented on the client of the blockchain or the server of the blockchain node. For example, the client uses a temporary key to process the creation and execution of the contract, the blockchain data stored on the server of the blockchain node is data processed using a temporary key, and the server uses the stored temporary public key to verify changes to the contract or state transfer, etc.

本说明书中上述方法的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。相关之处参见方法实施例的部分说明即可。In this specification, the various embodiments of the above method are described in a progressive manner. The same or similar parts between the various embodiments can be referred to each other. Each embodiment focuses on the differences from other embodiments. For related parts, please refer to the partial description of the method embodiment.

本申请实施例所提供的方法实施例可以在区块链终端、区块链服务器或者类似的运算装置中执行。以运行在区块链节点设备(可以为客户端,或单台服务器或服务器集群)上为例,图7是本发明实施例的一种区块链数据处理设备的硬件结构框图。如图7所示,处理设备10可以包括一个或多个(图中仅示出一个)处理器102(处理器102可以包括但不限于微处理器MCU或可编程逻辑器件FPGA等的处理装置)、用于存储数据的存储器104、以及用于通信功能的传输模块106。本领域普通技术人员可以理解,图7所示的结构仅为示意,其并不对上述电子装置的结构造成限定。例如,处理设备10还可包括比图7中所示更多或者更少的组件,例如还可以包括其他的处理硬件,如GPU(Graphics Processing Unit,图像处理器),或者具有与图7所示不同的配置。The method embodiments provided in the embodiments of this application can be executed in a blockchain terminal, blockchain server, or similar computing device. Taking the example of a blockchain node device (which can be a client, a single server, or a server cluster), FIG7 is a hardware block diagram of a blockchain data processing device according to an embodiment of the present invention. As shown in FIG7 , the processing device 10 may include one or more (only one is shown) processors 102 (processor 102 may include, but is not limited to, a microprocessor MCU or a programmable logic device FPGA, etc.), a memory 104 for storing data, and a transmission module 106 for communication functions. Those skilled in the art will understand that the structure shown in FIG7 is merely illustrative and does not limit the structure of the electronic device described above. For example, the processing device 10 may include more or fewer components than shown in FIG7 , for example, other processing hardware such as a GPU (Graphics Processing Unit), or have a configuration different from that shown in FIG7 .

存储器104可用于存储应用软件的软件程序以及模块,如本发明实施例中的搜索方法对应的程序指令/模块,处理器102通过运行存储在存储器104内的软件程序以及模块,从而执行各种功能应用以及数据处理,即实现上述导航交互界面内容展示的处理方法。存储器104可包括高速随机存储器,还可包括非易失性存储器,如一个或者多个磁性存储装置、闪存、或者其他非易失性固态存储器。在一些实例中,存储器104可进一步包括相对于处理器102远程设置的存储器,这些远程存储器可以通过网络连接至处理设备10。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The memory 104 can be used to store software programs and modules of application software, such as the program instructions/modules corresponding to the search method in the embodiment of the present invention. The processor 102 executes various functional applications and data processing by running the software programs and modules stored in the memory 104, that is, to implement the processing method for displaying the content of the above-mentioned navigation interactive interface. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include a memory remotely located relative to the processor 102, and these remote memories may be connected to the processing device 10 via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

传输模块106用于经由一个网络接收或者发送数据。上述的网络具体实例可包括计算机终端10的通信供应商提供的无线网络。在一个实例中,传输模块106包括一个网络适配器(Network Interface Controller,NIC),其可通过基站与其他网络设备相连从而可与互联网进行通讯。在一个实例中,传输模块106可以为射频(Radio Frequency,RF)模块,其用于通过无线方式与互联网进行通讯。The transmission module 106 is configured to receive or transmit data via a network. A specific example of the aforementioned network may include a wireless network provided by the communications provider of the computer terminal 10. In one embodiment, the transmission module 106 includes a network interface controller (NIC), which can be connected to other network devices via a base station to enable communication with the Internet. In another embodiment, the transmission module 106 may be a radio frequency (RF) module, which is configured to communicate with the Internet wirelessly.

基于上述所述的区块链数据处理的方法,本说明书还提供一种区块链数据处理装置。所述的装置可以包括使用了本说明书实施例所述方法的系统(包括分布式系统)、软件(应用)、模块、组件、服务器、客户端等并结合必要的实施硬件的设备装置。基于同一创新构思,本说明书提供的一种实施例中的处理装置如下面的实施例所述。由于装置解决问题的实现方案与方法相似,因此本说明书实施例具体的处理装置的实施可以参见前述方法的实施,重复之处不再赘述。尽管以下实施例所描述的装置较佳地以软件来实现,但是硬件,或者软件和硬件的组合的实现也是可能并被构想的。具体的,如图8所示,一种区块链数据处理装置可以包括:Based on the above-mentioned method for processing blockchain data, this specification also provides a blockchain data processing device. The device may include a system (including a distributed system), software (application), module, component, server, client, etc. using the method described in the embodiment of this specification and combined with necessary implementation hardware. Based on the same innovative concept, the processing device in one embodiment provided in this specification is as described in the following embodiment. Since the implementation scheme and method for solving the problem of the device are similar, the implementation of the specific processing device in the embodiment of this specification can refer to the implementation of the aforementioned method, and the repetitions will not be repeated. Although the device described in the following embodiments is preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceived. Specifically, as shown in Figure 8, a blockchain data processing device may include:

临时密钥生成模块201,可以用于生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;A temporary key generation module 201 may be used to generate a temporary key for a target contract, wherein the temporary key includes a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm;

合同加密签名处理模块202,可以用于基于所述临时密钥生成所述目标合同在区块链上的区块链数据。The contract encryption signature processing module 202 can be used to generate the blockchain data of the target contract on the blockchain based on the temporary key.

需要说明的是,本说明书实施例上述所述的处理装置,根据相关方法实施例的描述还可以包括其他的实施方式。具体的实现方式可以参照方法实施例的描述,在此不作一一赘述。It should be noted that the processing device described in the embodiments of this specification may also include other implementations according to the description of the relevant method embodiments. Specific implementations can refer to the description of the method embodiments and will not be described in detail here.

本说明书实施例提供的设备型号识别方法可以在计算机中由处理器执行相应的程序指令来实现,如使用windows/Linux操作系统的c++/java语言在PC端/服务器端实现,或其他例如android、iOS系统相对应的应用设计语言集合必要的硬件实现,或者基于量子计算机的处理逻辑实现等。具体的,本说明书提供的一种处理设备实现上述方法的实施例中,所述处理设备可以包括处理器以及用于存储处理器可执行指令的存储器,所述处理器执行所述指令时实现:The device model identification method provided in the embodiments of this specification can be implemented in a computer by a processor executing corresponding program instructions, such as using the C++/Java language of the Windows/Linux operating system on a PC/server, or other application design languages corresponding to Android and iOS systems, with the necessary hardware, or based on the processing logic of a quantum computer. Specifically, in an embodiment of the above method implemented by a processing device provided in this specification, the processing device may include a processor and a memory for storing processor-executable instructions, and when the processor executes the instructions, the following is achieved:

生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;Generate a temporary key for the target contract, wherein the temporary key includes a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm;

基于所述临时密钥生成所述目标合同在区块链上的区块链数据。Generate blockchain data of the target contract on the blockchain based on the temporary key.

基于前述方法实施例描述,所述装置的另一个实施例中,所述临时密钥基于不同的合同参与方、不同的目标合同中的至少一项进行临时密钥更新。Based on the description of the aforementioned method embodiment, in another embodiment of the apparatus, the temporary key is updated based on at least one of different contract participants and different target contracts.

基于前述方法实施例描述,所述装置的另一个实施例中,所述临时密钥基于预设的更换周期进行临时密钥更新。Based on the description of the aforementioned method embodiment, in another embodiment of the device, the temporary key is updated based on a preset replacement period.

基于前述方法实施例描述,所述设备的另一个实施例中,所述处理器执行包括下述步骤确定目标合同的创建数据:Based on the description of the aforementioned method embodiment, in another embodiment of the device, the processor performs the following steps to determine the creation data of the target contract:

发送本端生成的临时公钥至其他合同参与方;Send the temporary public key generated by this end to other contract participants;

利用本端的临时私钥对包括所述目标合同、各个合同参与方的临时公钥的数据信息进行签名,生成所述合同参与方各自对应的第一签名数据;Using the temporary private key of the local end to sign the data information including the target contract and the temporary public key of each contract participant, to generate first signature data corresponding to each of the contract participants;

利用监管方的监管密钥对预定合同信息进行加密,生成加密合同,所述预定合同信息包括所述目标合同、各个合同参与方的临时公钥、所述第一签名数据;Encrypting the predetermined contract information using the supervisory key of the supervisor to generate an encrypted contract, the predetermined contract information including the target contract, the temporary public key of each contract participant, and the first signature data;

确定各个合同参与方利用相应的临时私钥对所述加密合同进行签名后,基于签名后的数据、合同参与方的临时公钥确定所述目标合同的创建数据。After it is determined that each contract participant uses the corresponding temporary private key to sign the encrypted contract, the creation data of the target contract is determined based on the signed data and the temporary public keys of the contract participants.

基于前述方法实施例描述,所述设备的另一个实施例中,所述处理器还执行:Based on the description of the foregoing method embodiment, in another embodiment of the device, the processor further performs:

将所述创建数据提交至区块链。The creation data is submitted to the blockchain.

基于前述方法实施例描述,所述设备的另一个实施例中,所述处理器执行包括下述步骤确定合同执行创建数据:Based on the description of the aforementioned method embodiment, in another embodiment of the device, the processor performs the following steps to determine the contract execution creation data:

利用所述监管密钥对确定的新合同进行加密,生成加密新合同,所述新合同由合同参与方线下对所述目标合同的执行过程达成共识后确定;Encrypting the determined new contract using the supervisory key to generate an encrypted new contract, wherein the new contract is determined after the contract participants reach a consensus on the execution process of the target contract offline;

利用所述目标合同对应的临时私钥对所述加密新合同进行签名,生成第二签名数据;Signing the encrypted new contract using the temporary private key corresponding to the target contract to generate second signature data;

确定各个合同参与方对所述加密新合同的签名后,基于所述第二签名数据、加密新合同确定合同执行数据。After the signatures of the encrypted new contract by each contract participant are determined, the contract execution data is determined based on the second signature data and the encrypted new contract.

基于前述方法实施例描述,所述设备的另一个实施例中,所述处理器发送的临时公钥包括使用建立的端到端的加密通道进行数据传输。Based on the description of the foregoing method embodiment, in another embodiment of the device, the temporary public key sent by the processor includes using an established end-to-end encrypted channel for data transmission.

本说明书提供的另一种处理设备实现上述方法的实施例可以应用于区块链上数据的处理,如区块链上智能合约平台的服务器,或区块链节点服务器。具体的,一个实施例中,所述处理设备可以包括处理器以及用于存储处理器可执行指令的存储器,所述处理器执行所述指令时实现:Another embodiment of the above-mentioned method implemented by a processing device provided in this specification can be applied to data processing on a blockchain, such as a server of a smart contract platform on a blockchain, or a blockchain node server. Specifically, in one embodiment, the processing device may include a processor and a memory for storing processor-executable instructions. When the processor executes the instructions, it can achieve the following:

接收并存储目标合同的创建数据,所述创建数据包括由合同参与方生成目标合同的临时密钥,基于所述临时密钥生成对所述目标合同进行处理后上传到区块链的数据信息,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;以及,Receiving and storing creation data of a target contract, the creation data including a temporary key generated by a contract participant for the target contract, generating data information of the target contract processed based on the temporary key and then uploaded to the blockchain, the temporary key including a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm; and

接收合同执行数据;Receive contract execution data;

利用所述目标合同参与方对应的公钥对所述合同执行数据进行签名验证;Using the public key corresponding to the target contract participant to perform signature verification on the contract execution data;

若所述签名验证通过,则将存储的目标合同更新为所述加密新合同。If the signature verification is successful, the stored target contract is updated to the encrypted new contract.

上述的指令可以存储在多种计算机可读存储介质中。所述计算机可读存储介质可以包括用于存储信息的物理装置,可以将信息数字化后再以利用电、磁或者光学等方式的媒体加以存储。本实施例所述的计算机可读存储介质有可以包括:利用电能方式存储信息的装置如,各式存储器,如RAM、ROM等;利用磁能方式存储信息的装置如,硬盘、软盘、磁带、磁芯存储器、磁泡存储器、U盘;利用光学方式存储信息的装置如,CD或DVD。当然,还有其他方式的可读存储介质,例如量子存储器、石墨烯存储器等等。本实施例中所述的装置或服务器或客户端或或处理设备或系统中的指令同上描述。The above instructions can be stored in a variety of computer-readable storage media. The computer-readable storage medium may include a physical device for storing information, which can digitize the information and then store it in a medium using electrical, magnetic or optical means. The computer-readable storage medium described in this embodiment may include: devices that use electrical energy to store information, such as various memories, such as RAM, ROM, etc.; devices that use magnetic energy to store information, such as hard disks, floppy disks, magnetic tapes, magnetic core memories, bubble memories, USB flash drives; devices that use optical means to store information, such as CDs or DVDs. Of course, there are other types of readable storage media, such as quantum memories, graphene memories, etc. The instructions in the device, server, client, or processing device or system described in this embodiment are the same as described above.

基于前述所述,本说明书实施例还提供一种区块链系统。所述系统包括区块链终端、区块链服务器,所述区块链终端和区块链服务器分别包括至少一个处理器用于存储处理器可执行指令的存储器,所述区块链终端的处理器执行所述指令时实现:Based on the foregoing, an embodiment of this specification further provides a blockchain system. The system includes a blockchain terminal and a blockchain server, wherein the blockchain terminal and the blockchain server each include at least one processor for storing processor-executable instructions. When the processor of the blockchain terminal executes the instructions, the following are achieved:

上述方法实施例中合同参与方所涉及的任意一项实施例方法中步骤;Any steps in any embodiment of the method involved by the contract participants in the above method embodiment;

所述区块链服务器的处理器执行所述指令时实现:When the processor of the blockchain server executes the instructions, the following is achieved:

上述方法实施例中合同参与方所涉及的任意一项区块链在链上数据处理的方法步骤。The method steps for on-chain data processing of any blockchain involved in the contract participants in the above method embodiment.

所述的区块链终端与区块链节点服务器可以为客户端/服务器的架构,一些实施场景中区块链终端与区块链节点服务器可以为相同的处理设备。The blockchain terminal and blockchain node server may be a client/server architecture. In some implementation scenarios, the blockchain terminal and blockchain node server may be the same processing device.

需要说明的是,本说明书实施例上述所述的装置、处理设备、终端、服务器、系统,根据相关方法实施例的描述还可以包括其他的实施方式。具体的实现方式可以参照方法实施例的描述,在此不作一一赘述。It should be noted that the apparatus, processing device, terminal, server, and system described in the embodiments of this specification may also include other implementation methods according to the description of the relevant method embodiments. Specific implementation methods can refer to the description of the method embodiments and will not be described in detail here.

本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于硬件+程序类实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。The various embodiments in this specification are described in a progressive manner. Similar portions between the various embodiments can be referenced to each other. Each embodiment focuses on the differences between the other embodiments. In particular, the hardware + program embodiments are generally similar to the method embodiments, so their description is relatively simple. For relevant portions, refer to the description of the method embodiments.

上述对本说明书特定实施例进行了描述。其它实施例在所附权利要求书的范围内。在一些情况下,在权利要求书中记载的动作或步骤可以按照不同于实施例中的顺序来执行并且仍然可以实现期望的结果。另外,在附图中描绘的过程不一定要求示出的特定顺序或者连续顺序才能实现期望的结果。在某些实施方式中,多任务处理和并行处理也是可以的或者可能是有利的。The foregoing description of this specification describes specific embodiments. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims can be performed in an order different from that described in the embodiments and still achieve the desired results. Furthermore, the processes depicted in the accompanying drawings do not necessarily require the specific order shown or the sequential order to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.

本说明书实施例提供的一种区块链数据处理方法、装置、处理设备及系统,合同参与方关于目标合同相关操作中的加密处理可以使用临时生成的秘钥进行处理,如合同的签署、加密、验证等。临时密钥处理后的数据信息再上传到区块链中进行存储,可以有效保障在链下各个合同参与方对合同数据的安全处理,同时提高了区块链中数据存储的安全性。The embodiments of this specification provide a blockchain data processing method, apparatus, processing device, and system. Contract participants can use temporarily generated secret keys to perform encryption processing related to the target contract, such as contract signing, encryption, and verification. Data processed with the temporary key is then uploaded to the blockchain for storage, effectively ensuring the secure processing of contract data by each contract participant off-chain while also improving the security of data storage within the blockchain.

虽然本申请提供了如实施例或流程图所述的方法操作步骤,但基于常规或者无创造性的劳动可以包括更多或者更少的操作步骤。实施例中列举的步骤顺序仅仅为众多步骤执行顺序中的一种方式,不代表唯一的执行顺序。在实际中的装置或客户端产品执行时,可以按照实施例或者附图所示的方法顺序执行或者并行执行(例如并行处理器或者多线程处理的环境)。Although the present application provides method operation steps as described in the embodiments or flowcharts, more or fewer operation steps may be included based on conventional or non-creative work. The order of steps listed in the embodiments is only one way of executing the steps among many steps and does not represent the only execution order. When the actual device or client product is executed, it can be executed in sequence or in parallel according to the method shown in the embodiments or the drawings (for example, in a parallel processor or multi-threaded processing environment).

尽管本说明书实施例内容中提到SSL的加密通信、合同建立和执行的定义描述、公钥私钥进行的加密签名等之类的数据获取、定义、交互、计算、判断、加密等操作和数据描述,但是,本说明书实施例并不局限于必须是符合行业通信标准、标准非对称加密算法、通信协议和标准数据模型/模板或本说明书实施例所描述的情况。某些行业标准或者使用自定义方式或实施例描述的实施基础上略加修改后的实施方案也可以实现上述实施例相同、等同或相近、或变形后可预料的实施效果。应用这些修改或变形后的数据获取、存储、判断、处理方式等获取的实施例,仍然可以属于本说明书的可选实施方案范围之内。Although the embodiments of this specification mention the data acquisition, definition, interaction, calculation, judgment, encryption and other operations and data descriptions such as SSL encrypted communication, contract establishment and execution, and encrypted signatures performed by public and private keys, the embodiments of this specification are not limited to the situations that must comply with industry communication standards, standard asymmetric encryption algorithms, communication protocols and standard data models/templates or the embodiments of this specification. Certain industry standards or slightly modified implementation plans based on the implementation described in the custom method or embodiment can also achieve the same, equivalent or similar, or predictable implementation effects after deformation of the above embodiments. The embodiments obtained by applying these modified or deformed data acquisition, storage, judgment, processing methods, etc. can still fall within the scope of the optional implementation plans of this specification.

在20世纪90年代,对于一个技术的改进可以很明显地区分是硬件上的改进(例如,对二极管、晶体管、开关等电路结构的改进)还是软件上的改进(对于方法流程的改进)。然而,随着技术的发展,当今的很多方法流程的改进已经可以视为硬件电路结构的直接改进。设计人员几乎都通过将改进的方法流程编程到硬件电路中来得到相应的硬件电路结构。因此,不能说一个方法流程的改进就不能用硬件实体模块来实现。例如,可编程逻辑器件(Programmable Logic Device,PLD)(例如现场可编程门阵列(Field Programmable GateArray,FPGA))就是这样一种集成电路,其逻辑功能由用户对器件编程来确定。由设计人员自行编程来把一个数字系统“集成”在一片PLD上,而不需要请芯片制造厂商来设计和制作专用的集成电路芯片。而且,如今,取代手工地制作集成电路芯片,这种编程也多半改用“逻辑编译器(logic compiler)”软件来实现,它与程序开发撰写时所用的软件编译器相类似,而要编译之前的原始代码也得用特定的编程语言来撰写,此称之为硬件描述语言(Hardware Description Language,HDL),而HDL也并非仅有一种,而是有许多种,如ABEL(Advanced Boolean Expression Language)、AHDL(Altera Hardware DescriptionLanguage)、Confluence、CUPL(Cornell University Programming Language)、HDCal、JHDL(Java Hardware Description Language)、Lava、Lola、MyHDL、PALASM、RHDL(RubyHardware Description Language)等,目前最普遍使用的是VHDL(Very-High-SpeedIntegrated Circuit Hardware Description Language)与Verilog。本领域技术人员也应该清楚,只需要将方法流程用上述几种硬件描述语言稍作逻辑编程并编程到集成电路中,就可以很容易得到实现该逻辑方法流程的硬件电路。In the 1990s, technological improvements could be clearly distinguished as either hardware improvements (for example, improvements to circuit structures like diodes, transistors, and switches) or software improvements (improvements to process flows). However, with the advancement of technology, many process flow improvements today can now be considered direct improvements to hardware circuit structures. Designers almost always create the corresponding hardware circuit structure by programming the improved process flow into the hardware circuit. Therefore, it cannot be said that a process flow improvement cannot be implemented using hardware modules. For example, a programmable logic device (PLD), such as a field programmable gate array (FPGA), is an integrated circuit whose logical function is determined by user programming. Designers can "integrate" a digital system on a PLD through their own programming, without having to hire a chip manufacturer to design and manufacture a dedicated integrated circuit chip. Moreover, nowadays, instead of manually fabricating integrated circuit chips, this programming is mostly done using "logic compiler" software. This is similar to the software compiler used when developing programs. Before compilation, the original code must also be written in a specific programming language, called a hardware description language (HDL). There is not just one HDL, but many, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, RHDL (Ruby Hardware Description Language), etc. The most commonly used ones are VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art will also understand that by simply programming the method flow in one of these hardware description languages and then programming it into an integrated circuit, a hardware circuit that implements the logic method flow can be easily obtained.

控制器可以按任何适当的方式实现,例如,控制器可以采取例如微处理器或处理器以及存储可由该(微)处理器执行的计算机可读程序代码(例如软件或固件)的计算机可读介质、逻辑门、开关、专用集成电路(Application Specific Integrated Circuit,ASIC)、可编程逻辑控制器和嵌入微控制器的形式,控制器的例子包括但不限于以下微控制器:ARC 625D、Atmel AT91SAM、Microchip PIC18F26K20以及Silicone Labs C8051F320,存储器控制器还可以被实现为存储器的控制逻辑的一部分。本领域技术人员也知道,除了以纯计算机可读程序代码方式实现控制器以外,完全可以通过将方法步骤进行逻辑编程来使得控制器以逻辑门、开关、专用集成电路、可编程逻辑控制器和嵌入微控制器等的形式来实现相同功能。因此这种控制器可以被认为是一种硬件部件,而对其内包括的用于实现各种功能的装置也可以视为硬件部件内的结构。或者甚至,可以将用于实现各种功能的装置视为既可以是实现方法的软件模块又可以是硬件部件内的结构。The controller can be implemented in any suitable manner. For example, the controller can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers. Examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320. The memory controller can also be implemented as part of the control logic of the memory. Those skilled in the art will also know that in addition to implementing the controller in a purely computer-readable program code format, the controller can be implemented in the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers by logically programming the method steps. Therefore, such a controller can be considered a hardware component, and the devices included therein for implementing various functions can also be considered as structures within the hardware component. Or even, the devices for implementing various functions can be considered as both software modules that implement the method and structures within the hardware component.

上述实施例阐明的系统、装置、模块或单元,具体可以由计算机芯片或实体实现,或者由具有某种功能的产品来实现。一种典型的实现设备为计算机。具体的,计算机例如可以为个人计算机、膝上型计算机、车载人机交互设备、蜂窝电话、相机电话、智能电话、个人数字助理、媒体播放器、导航设备、电子邮件设备、游戏控制台、平板计算机、可穿戴设备或者这些设备中的任何设备的组合。The systems, devices, modules, or units described in the above embodiments may be implemented by computer chips or entities, or by products having certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, an in-vehicle human-computer interaction device, a cellular phone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.

虽然本说明书实施例提供了如实施例或流程图所述的方法操作步骤,但基于常规或者无创造性的手段可以包括更多或者更少的操作步骤。实施例中列举的步骤顺序仅仅为众多步骤执行顺序中的一种方式,不代表唯一的执行顺序。在实际中的装置或终端产品执行时,可以按照实施例或者附图所示的方法顺序执行或者并行执行(例如并行处理器或者多线程处理的环境,甚至为分布式数据处理环境)。术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、产品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、产品或者设备所固有的要素。在没有更多限制的情况下,并不排除在包括所述要素的过程、方法、产品或者设备中还存在另外的相同或等同要素。Although the present specification embodiment provides the method operation steps as described in the embodiment or flow chart, more or less operation steps may be included based on conventional or non-creative means. The order of steps listed in the embodiment is only one way in the order of execution of many steps and does not represent a unique execution order. When the device or terminal product in practice is executed, it can be performed in sequence or in parallel according to the method shown in the embodiment or the accompanying drawings (such as a parallel processor or a multi-threaded processing environment, or even a distributed data processing environment). The term "comprise", "comprising" or any other variant thereof is intended to cover non-exclusive inclusion, so that the process, method, product or equipment including a series of elements not only include those elements, but also include other elements not clearly listed, or also include elements inherent to such process, method, product or equipment. In the absence of more restrictions, it is not excluded that there are other identical or equivalent elements in the process, method, product or equipment including the elements.

为了描述的方便,描述以上装置时以功能分为各种模块分别描述。当然,在实施本说明书实施例时可以把各模块的功能在同一个或多个软件和/或硬件中实现,也可以将实现同一功能的模块由多个子模块或子单元的组合实现等。以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。For the convenience of description, the above devices are described in terms of functions divided into various modules. Of course, when implementing the embodiments of this specification, the functions of each module can be implemented in the same or multiple software and/or hardware, or the modules that implement the same function can be implemented by a combination of multiple sub-modules or sub-units, etc. The device embodiments described above are merely schematic. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

本领域技术人员也知道,除了以纯计算机可读程序代码方式实现控制器以外,完全可以通过将方法步骤进行逻辑编程来使得控制器以逻辑门、开关、专用集成电路、可编程逻辑控制器和嵌入微控制器等的形式来实现相同功能。因此这种控制器可以被认为是一种硬件部件,而对其内部包括的用于实现各种功能的装置也可以视为硬件部件内的结构。或者甚至,可以将用于实现各种功能的装置视为既可以是实现方法的软件模块又可以是硬件部件内的结构。Those skilled in the art will also appreciate that, in addition to implementing the controller in pure computer-readable program code, it is entirely possible to implement the same functionality by logically programming the method steps in the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, embedded microcontrollers, and the like. Therefore, such a controller can be considered a hardware component, and the devices included therein for implementing various functions can also be considered structures within the hardware component. Alternatively, the devices for implementing various functions can be considered both software modules implementing the method and structures within the hardware component.

本发明是参照根据本发明实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present invention is described with reference to the flowcharts and/or block diagrams of the methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and/or box in the flowchart and/or block diagram, as well as the combination of processes and/or boxes in the flowchart and/or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce a device for implementing the functions specified in one or more processes in the flowchart and/or one or more boxes in the block diagram.

这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a product including an instruction device that implements the functions specified in one or more processes in the flowchart and/or one or more boxes in the block diagram.

这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, so that the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one or more processes in the flowchart and/or one or more boxes in the block diagram.

在一个典型的配置中,计算设备包括一个或多个处理器(CPU)、输入/输出接口、网络接口和内存。In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.

内存可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM)。内存是计算机可读介质的示例。Memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and/or non-volatile memory in the form of read-only memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.

计算机可读介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。计算机的存储介质的例子包括,但不限于相变内存(PRAM)、静态随机存取存储器(SRAM)、动态随机存取存储器(DRAM)、其他类型的随机存取存储器(RAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、快闪记忆体或其他内存技术、只读光盘只读存储器(CD-ROM)、数字多功能光盘(DVD)或其他光学存储、磁盒式磁带,磁带磁磁盘存储或其他磁性存储设备或任何其他非传输介质,可用于存储可以被计算设备访问的信息。按照本文中的界定,计算机可读介质不包括暂存电脑可读媒体(transitory media),如调制的数据信号和载波。Computer-readable media includes permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. The information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include transitory computer-readable media (transitory media), such as modulated data signals and carrier waves.

本领域技术人员应明白,本说明书的实施例可提供为方法、系统或计算机程序产品。因此,本说明书实施例可采用完全硬件实施例、完全软件实施例或结合软件和硬件方面的实施例的形式。而且,本说明书实施例可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art will appreciate that the embodiments of this specification may be provided as methods, systems, or computer program products. Therefore, the embodiments of this specification may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the embodiments of this specification may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

本说明书实施例可以在由计算机执行的计算机可执行指令的一般上下文中描述,例如程序模块。一般地,程序模块包括执行特定任务或实现特定抽象数据类型的例程、程序、对象、组件、数据结构等等。也可以在分布式计算环境中实践本说明书实施例,在这些分布式计算环境中,由通过通信网络而被连接的远程处理设备来执行任务。在分布式计算环境中,程序模块可以位于包括存储设备在内的本地和远程计算机存储介质中。Embodiments of this specification may be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, and the like that perform specific tasks or implement specific abstract data types. Embodiments of this specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communications network. In distributed computing environments, program modules may be located in local and remote computer storage media, including storage devices.

本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于系统实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。在本说明书的描述中,参考术语“一个实施例”、“一些实施例”、“示例”、“具体示例”、或“一些示例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或者特点包含于本说明书实施例的至少一个实施例或示例中。在本说明书中,对上述术语的示意性表述不必须针对的是相同的实施例或示例。而且,描述的具体特征、结构、材料或者特点可以在任一个或多个实施例或示例中以合适的方式结合。此外,在不相互矛盾的情况下,本领域的技术人员可以将本说明书中描述的不同实施例或示例以及不同实施例或示例的特征进行结合和组合。The various embodiments in this specification are described in a progressive manner. Similar or identical parts between the various embodiments can be referenced across them. Each embodiment focuses on the differences from the other embodiments. In particular, since the system embodiments are generally similar to the method embodiments, their description is relatively simple. For relevant parts, reference can be made to the description of the method embodiments. Throughout this specification, reference to the terms "one embodiment," "some embodiments," "example," "specific example," or "some examples" means that the specific features, structures, materials, or characteristics described in conjunction with that embodiment or example are included in at least one embodiment or example of the embodiments in this specification. In this specification, the schematic representations of these terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, those skilled in the art may combine and integrate the different embodiments or examples, and features of different embodiments or examples, described in this specification, without conflict.

以上所述仅为本说明书实施例的实施例而已,并不用于限制本说明书实施例。对于本领域技术人员来说,本说明书实施例可以有各种更改和变化。凡在本说明书实施例的精神和原理之内所作的任何修改、等同替换、改进等,均应包含在本说明书实施例的权利要求范围之内。The above description is merely an example of the embodiments of this specification and is not intended to limit the embodiments of this specification. For those skilled in the art, various modifications and variations of the embodiments of this specification are possible. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the embodiments of this specification shall be included within the scope of the claims of the embodiments of this specification.

Claims (15)

1.一种区块链数据处理方法,所述方法包括:1. A blockchain data processing method, the method comprising: 生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;Generate a temporary key for the target contract, the temporary key including a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm; 基于所述临时密钥生成所述目标合同在区块链上的区块链数据;Generate blockchain data of the target contract on the blockchain based on the temporary key; 所述区块链数据包括所述目标合同的创建数据,以及采用下述方式确定所述创建数据:The blockchain data includes the creation data of the target contract, and the creation data is determined in the following manner: 发送本端生成的临时公钥至其他合同参与方;Send the temporary public key generated on this end to other contract participants; 利用本端的临时私钥对包括所述目标合同、各个合同参与方的临时公钥的数据信息进行签名,生成所述合同参与方各自对应的第一签名数据;The temporary private key of the local end is used to sign the data information including the target contract and the temporary public keys of each contract participant, thereby generating the first signature data corresponding to each contract participant; 利用监管方的监管密钥对预定合同信息进行加密,生成加密合同,所述预定合同信息包括所述目标合同、各个合同参与方的临时公钥、所述第一签名数据;The regulatory key of the regulator is used to encrypt the pre-contract information to generate an encrypted contract. The pre-contract information includes the target contract, the temporary public keys of each contract participant, and the first signature data. 确定各个合同参与方利用相应的临时私钥对所述加密合同进行签名后,基于签名后的数据、合同参与方的临时公钥确定所述目标合同的创建数据。After each contract participant signs the encrypted contract using their respective temporary private key, the creation data of the target contract is determined based on the signed data and the temporary public keys of the contract participants. 2.如权利要求1所述的方法,所述临时密钥基于不同的合同参与方、不同的目标合同中的至少一项进行临时密钥更新。2. The method of claim 1, wherein the temporary key is updated based on at least one of different contract participants and different target contracts. 3.如权利要求1所述的方法,所述临时密钥基于预设的更换周期进行临时密钥更新。3. The method as described in claim 1, wherein the temporary key is updated based on a preset replacement cycle. 4.如权利要求1所述的方法,还包括:4. The method of claim 1, further comprising: 将所述创建数据提交到区块链上进行存储。The creation data is submitted to the blockchain for storage. 5.如权利要求1所述的方法,所述区块链数据还包括合同执行数据,及采用下述方式确定所述合同执行数据:5. The method of claim 1, wherein the blockchain data further includes contract execution data, and the contract execution data is determined in the following manner: 利用所述监管密钥对确定的新合同进行加密,生成加密新合同,所述新合同由合同参与方线下对所述目标合同的执行过程达成共识后确定;The new contract is encrypted using the regulatory key to generate an encrypted new contract. The new contract is determined by the contract participants after reaching a consensus offline on the execution process of the target contract. 利用所述加密新合同对应的临时私钥对所述加密新合同进行签名,生成第二签名数据;The encrypted new contract is signed using the temporary private key corresponding to the encrypted new contract to generate second signature data; 确定各个合同参与方对所述加密新合同的签名后,基于所述第二签名数据、加密新合同确定合同执行数据。After confirming the signatures of each contract participant on the encrypted new contract, contract execution data is determined based on the second signature data and the encrypted new contract. 6.如权利要求1所述的方法,发送的临时公钥包括使用建立的端到端的加密通道进行数据传输。6. The method of claim 1, wherein the temporary public key sent includes data transmission using an established end-to-end encrypted channel. 7.一种区块链数据处理方法,所述方法包括:7. A blockchain data processing method, the method comprising: 接收并存储目标合同的创建数据,所述创建数据包括由合同参与方生成目标合同的临时密钥,基于所述临时密钥生成对所述目标合同进行处理后上传到区块链的数据信息,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;以及,The system receives and stores creation data for a target contract, including a temporary key generated by the contract participants, and generates data information based on the temporary key to process the target contract before uploading it to the blockchain. The temporary key includes a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm. 接收合同执行数据;Receive contract execution data; 利用所述目标合同参与方对应的公钥对所述合同执行数据进行签名验证;The contract execution data is signed and verified using the public key corresponding to the target contract participant. 若所述签名验证通过,则将存储的目标合同更新为加密新合同;If the signature verification passes, the stored target contract will be updated to a new encrypted contract; 其中,采用下述方式确定所述创建数据:The creation data is determined in the following manner: 发送本端生成的临时公钥至其他合同参与方;Send the temporary public key generated on this end to other contract participants; 利用本端的临时私钥对包括所述目标合同、各个合同参与方的临时公钥的数据信息进行签名,生成所述合同参与方各自对应的第一签名数据;The temporary private key of the local end is used to sign the data information including the target contract and the temporary public keys of each contract participant, thereby generating the first signature data corresponding to each contract participant; 利用监管方的监管密钥对预定合同信息进行加密,生成加密合同,所述预定合同信息包括所述目标合同、各个合同参与方的临时公钥、所述第一签名数据;The regulatory key of the regulator is used to encrypt the pre-contract information to generate an encrypted contract. The pre-contract information includes the target contract, the temporary public keys of each contract participant, and the first signature data. 确定各个合同参与方利用相应的临时私钥对所述加密合同进行签名后,基于签名后的数据、合同参与方的临时公钥确定所述目标合同的创建数据。After each contract participant signs the encrypted contract using their respective temporary private key, the creation data of the target contract is determined based on the signed data and the temporary public keys of the contract participants. 8.一种区块链数据处理装置,所述装置包括:8. A blockchain data processing device, the device comprising: 临时密钥生成模块,用于生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;A temporary key generation module is used to generate a temporary key for the target contract, wherein the temporary key includes a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm; 合同加密签名处理模块,用于基于所述临时密钥生成所述目标合同在区块链上的区块链数据;A contract encryption and signature processing module is used to generate blockchain data of the target contract on the blockchain based on the temporary key; 所述区块链数据包括所述目标合同的创建数据,以及采用下述方式确定所述创建数据:The blockchain data includes the creation data of the target contract, and the creation data is determined in the following manner: 合同参与方发送本端生成的临时公钥至其他合同参与方;The contract participant sends the temporary public key generated on its own end to the other contract participants; 所述合同参与方利用本端的临时私钥对包括所述目标合同、各个合同参与方的临时公钥的数据信息进行签名,生成所述合同参与方各自对应的第一签名数据;The contract participants use their own temporary private keys to sign data information including the target contract and the temporary public keys of each contract participant, generating first signature data corresponding to each contract participant. 利用监管方的监管密钥对预定合同信息进行加密,生成加密合同,所述预定合同信息包括所述目标合同、各个合同参与方的临时公钥、所述第一签名数据;The regulatory key of the regulator is used to encrypt the pre-contract information to generate an encrypted contract. The pre-contract information includes the target contract, the temporary public keys of each contract participant, and the first signature data. 确定各个合同参与方利用相应的临时私钥对所述加密合同进行签名后,基于签名后的数据、合同参与方的临时公钥确定所述目标合同的创建数据。After each contract participant signs the encrypted contract using their respective temporary private key, the creation data of the target contract is determined based on the signed data and the temporary public keys of the contract participants. 9.一种区块链数据处理设备,所述区块链数据处理设备包括处理器以及用于存储处理器可执行指令的存储器,所述处理器执行所述指令时实现:9. A blockchain data processing device, the blockchain data processing device comprising a processor and a memory for storing processor-executable instructions, wherein the processor, when executing the instructions, implements: 生成目标合同的临时密钥,所述临时密钥包括基于非对称加密算法生成的临时公钥和临时私钥;Generate a temporary key for the target contract, the temporary key including a temporary public key and a temporary private key generated based on an asymmetric encryption algorithm; 基于所述临时密钥生成所述目标合同在区块链上的区块链数据;Generate blockchain data of the target contract on the blockchain based on the temporary key; 所述处理器执行包括下述步骤确定目标合同的创建数据:The processor performs the following steps to determine the creation data of the target contract: 发送本端生成的临时公钥至其他合同参与方;Send the temporary public key generated on this end to other contract participants; 利用本端的临时私钥对包括所述目标合同、各个合同参与方的临时公钥的数据信息进行签名,生成所述合同参与方各自对应的第一签名数据;The temporary private key of the local end is used to sign the data information including the target contract and the temporary public keys of each contract participant, thereby generating the first signature data corresponding to each contract participant; 利用监管方的监管密钥对预定合同信息进行加密,生成加密合同,所述预定合同信息包括所述目标合同、各个合同参与方的临时公钥、所述第一签名数据;The regulatory key of the regulator is used to encrypt the pre-contract information to generate an encrypted contract. The pre-contract information includes the target contract, the temporary public keys of each contract participant, and the first signature data. 确定各个合同参与方利用相应的临时私钥对所述加密合同进行签名后,基于签名后的数据、合同参与方的临时公钥确定所述目标合同的创建数据。After each contract participant signs the encrypted contract using their respective temporary private key, the creation data of the target contract is determined based on the signed data and the temporary public keys of the contract participants. 10.如权利要求9所述的区块链数据处理设备,所述临时密钥基于不同的合同参与方、不同的目标合同中的至少一项进行临时密钥更新。10. The blockchain data processing device as described in claim 9, wherein the temporary key is updated based on at least one of different contract participants and different target contracts. 11.如权利要求9所述的区块链数据处理设备,所述临时密钥基于预设的更换周期进行临时密钥更新。11. The blockchain data processing device as described in claim 9, wherein the temporary key is updated based on a preset replacement cycle. 12.如权利要求9所述的区块链数据处理设备,所述处理器还执行:12. The blockchain data processing device of claim 9, wherein the processor further performs: 将所述创建数据提交至区块链。Submit the creation data to the blockchain. 13.如权利要求9所述的区块链数据处理设备,所述处理器执行包括下述步骤确定合同执行创建数据:13. The blockchain data processing device of claim 9, wherein the processor performs the following steps to determine contract execution creation data: 利用所述监管密钥对确定的新合同进行加密,生成加密新合同,所述新合同由合同参与方线下对所述目标合同的执行过程达成共识后确定;The new contract is encrypted using the regulatory key to generate an encrypted new contract. The new contract is determined by the contract participants after reaching a consensus offline on the execution process of the target contract. 利用所述加密新合同对应的临时私钥对所述加密新合同进行签名,生成第二签名数据;The encrypted new contract is signed using the temporary private key corresponding to the encrypted new contract to generate second signature data; 确定各个合同参与方对所述加密新合同的签名后,基于所述第二签名数据、加密新合同确定合同执行数据。After confirming the signatures of each contract participant on the encrypted new contract, contract execution data is determined based on the second signature data and the encrypted new contract. 14.如权利要求9所述的区块链数据处理设备,所述处理器发送的临时公钥包括使用建立的端到端的加密通道进行数据传输。14. The blockchain data processing device of claim 9, wherein the temporary public key sent by the processor includes data transmission using an established end-to-end encrypted channel. 15.一种区块链系统,包括区块链终端、区块链服务器,所述区块链终端和区块链服务器分别包括至少一个处理器用于存储处理器可执行指令的存储器,所述区块链终端的处理器执行所述指令时实现:15. A blockchain system, comprising a blockchain terminal and a blockchain server, wherein the blockchain terminal and the blockchain server each include at least one processor and a memory for storing processor-executable instructions, wherein the processor of the blockchain terminal executes the instructions to achieve: 权利要求1-6的任意一项所述的方法步骤;The method steps according to any one of claims 1-6; 所述区块链服务器的处理器执行所述指令时实现权利要求7所述的方法步骤。When the processor of the blockchain server executes the instructions, it implements the steps of the method described in claim 7.
HK19101545.7A 2019-01-29 Blockchain data processing method, device, processing equipment and system HK1259242B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
HK19101545.7A HK1259242B (en) 2019-01-29 Blockchain data processing method, device, processing equipment and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
HK19101545.7A HK1259242B (en) 2019-01-29 Blockchain data processing method, device, processing equipment and system

Publications (2)

Publication Number Publication Date
HK1259242A1 HK1259242A1 (en) 2019-11-29
HK1259242B true HK1259242B (en) 2021-04-16

Family

ID=

Similar Documents

Publication Publication Date Title
TWI703470B (en) Block chain data processing method, device, processing equipment and system
TWI696375B (en) Blockchain data processing method, device, processing equipment and system
TWI706276B (en) Block chain data processing method, device, processing equipment and system
TWI701933B (en) Block chain data processing method, device, processing equipment and system
TW201947436A (en) Data processing method and apparatus of blockchain member management, server and system
CN113315745A (en) Data processing method, device, equipment and medium
CN109635572A (en) A kind of contract signing method, apparatus and terminal device based on block chain
WO2022267314A1 (en) Data processing method and apparatus based on smart contract
CN113206746B (en) A digital certificate management method and device
CN113206745B (en) Digital certificate management method and device
CN113179169B (en) A digital certificate management method and device
HK1259242A1 (en) Blockchain data processing method, device, processing equipment and system
HK1259242B (en) Blockchain data processing method, device, processing equipment and system
CN115134136B (en) System, method, device, storage medium and computing device for socializing based on blockchain
HK1261852A1 (en) Blockchain data processing method and device, processing equipment and system
HK1262886A1 (en) Blockchain data processing method, device and equipment, and system
HK1261591A1 (en) Blockchain data processing method, apparatus and device, and blockchain system
CN116032535A (en) Transaction broadcasting method in block chain system and block chain node