Movatterモバイル変換


[0]ホーム

URL:


CN110009321A - A kind of transfer account method and system based on block chain intelligence contract - Google Patents

A kind of transfer account method and system based on block chain intelligence contract
Download PDF

Info

Publication number
CN110009321A
CN110009321ACN201811517585.9ACN201811517585ACN110009321ACN 110009321 ACN110009321 ACN 110009321ACN 201811517585 ACN201811517585 ACN 201811517585ACN 110009321 ACN110009321 ACN 110009321A
Authority
CN
China
Prior art keywords
block chain
money
assets
contract
virtual machine
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201811517585.9A
Other languages
Chinese (zh)
Other versions
CN110009321B (en
Inventor
戚奕统
谢桂鲁
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ant Chain Technology Co ltd
Original Assignee
Alibaba Group Holding Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Group Holding LtdfiledCriticalAlibaba Group Holding Ltd
Priority to CN201811517585.9ApriorityCriticalpatent/CN110009321B/en
Publication of CN110009321ApublicationCriticalpatent/CN110009321A/en
Priority to TW108134610Aprioritypatent/TWI719651B/en
Priority to PCT/CN2019/119086prioritypatent/WO2020119393A1/en
Application grantedgrantedCritical
Publication of CN110009321BpublicationCriticalpatent/CN110009321B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Classifications

Landscapes

Abstract

Disclose a kind of transfer account method and system based on block chain intelligence contract.On the one hand, definition enters and leaves checking command and is added in the instruction set of block chain virtual machine, meanwhile, deployment corresponds to the discrepancy check logic for entering and leaving checking command in block chain virtual machine.On the other hand, it is also necessary to the discrepancy checking command of definition be added in the instruction set of intelligent contract compiler, so that comprising entering and leaving checking command in the business intelligence contract through the compiling of intelligent contract compiler.The discrepancy check logic is, using homomorphic encryption algorithm, the sum of the amount of money for the small change assets that the amount of money and the money transfer transactions for verifying the specified assets of transferring accounts of money transfer transactions are specified, if equal to the sum of the amount of money for each cost assets that the money transfer transactions are specified.

Description

A kind of transfer account method and system based on block chain intelligence contract
Technical field
This specification embodiment is related to information technology field more particularly to a kind of side of transferring accounts based on block chain intelligence contractMethod and system.
Background technique
In the framework of ether mill, each external account and each user are corresponded, the behavior reality of transferring accounts between two usersUpper is exactly the behavior of transferring accounts between two external accounts.
Assuming that external account A wants to transfer accounts to external account B, then, external account A can be constructed comprising transfer amounts firstWith the money transfer transactions of the account address of external account B, then, which can be broadcast to each section in block chain networkPoint.After each node is verified money transfer transactions, money transfer transactions are executed, external account B is written into transfer amounts.
It should be noted that the remaining sum that each node generally comprises verifying external account A to the verifying item of money transfer transactions isNo abundance, i.e., whether the remaining sum of external account A is greater than or equal to transfer amounts, if so, being verified.It means that existingIn the framework of some ether mills, if to transfer accounts, the account balance and transfer amounts for the people that transfers accounts can all be exposed to areaEach node in block chain network.
Summary of the invention
The problem of account balance and transfer amounts can not be hidden for the existing transfer account method based on block chain, this explanationBook embodiment provides a kind of transfer account method and system based on block chain intelligence contract, and technical solution is as follows:
According to the 1st of this specification embodiment the aspect, a kind of transfer account method based on block chain intelligence contract, block are providedIt include entering and leaving checking command, also, be deployed in block chain virtual machine corresponding to the discrepancy school in the instruction set of chain virtual machineTest the discrepancy check logic of instruction;
Include the discrepancy checking command in the instruction set of intelligent contract compiler, is compiled through the intelligent contract compilerBusiness intelligence contract in include the discrepancy checking command;
It is disposed in block chain network and is stated business intelligence contract, the business intelligence contract is corresponding with user's asset table,User's asset table is for recording the corresponding assets of each external account, and for any assets, which is comprising encryption goldThe data of volume, the encryption amount of money are obtained after encrypting to the amount of money of the assets;
The transfer account method includes:
Node in the block chain network obtains money transfer transactions by external account of transferring accounts and is broadcast to other nodes;InstituteStating money transfer transactions includes transfer accounts assets, small change assets and at least one cost assets;
For each node in the block chain network, which passes through block chain when executing the money transfer transactionsVirtual machine calls the business intelligence contract and according to the discrepancy checking command in the business intelligence contract, triggering execution instituteDiscrepancy check logic is stated, to use homomorphic encryption algorithm, transfer accounts described in the verification amount of money of assets and the gold of the small change assetsWhether the sum of volume is equal to the sum of the amount of money of each cost assets;
If check results be it is yes, which executes the user in the business intelligence contract by block chain virtual machineAsset table modifies logic, to release the corresponding relationship of the transfer accounts external account and each cost assets, transfers accounts described in foundation outerThe corresponding relationship of portion's account and the small change assets, and establish the corresponding relationship of receipt on account external account Yu the assets of transferring accounts.
According to the 2nd of this specification embodiment the aspect, another transfer account method based on block chain intelligence contract, area are providedIt include entering and leaving checking command, also, be deployed in block chain virtual machine corresponding to the discrepancy in the instruction set of block chain virtual machineThe discrepancy check logic of checking command;
Include the discrepancy checking command in the instruction set of intelligent contract compiler, is compiled through the intelligent contract compilerBusiness intelligence contract in the Contract ID of intelligent contract is verified comprising entering and leaving, the discrepancys verification intelligence contract is to dispose in advanceIntelligent contract in the block chain network;
It is disposed in block chain network and is stated business intelligence contract, the business intelligence contract is corresponding with user's asset table,User's asset table is for recording the corresponding assets of each external account, and for any assets, which is comprising encryption goldThe data of volume, the encryption amount of money are obtained after encrypting to the amount of money of the assets;
The transfer account method includes:
Node in the block chain network obtains money transfer transactions by external account of transferring accounts and is broadcast to other nodes;InstituteStating money transfer transactions includes transfer accounts assets, small change assets and at least one cost assets;
For each node in the block chain network, which passes through block chain when executing the money transfer transactionsVirtual machine calls the business intelligence contract, and verifies intelligent contract according to the discrepancy in the business intelligence contractContract ID calls the discrepancy to verify intelligent contract;
According to the discrepancy checking command for entering and leaving and verifying in intelligent contract, triggering executes the discrepancy verification and patrols the nodeVolume, transfer accounts to use homomorphic encryption algorithm, described in verification the sum of the amount of money of assets and the amount of money of the small change assets whether etc.In the sum of the amount of money of each cost assets;
If check results be it is yes, which executes the user in the business intelligence contract by block chain virtual machineAsset table modifies logic, to release the corresponding relationship of the transfer accounts external account and each cost assets, transfers accounts described in foundation outerThe corresponding relationship of portion's account and the small change assets, and establish the corresponding relationship of receipt on account external account Yu the assets of transferring accounts.
According to the 3rd of this specification embodiment the aspect, a kind of block catenary system, including block chain network are provided;
It wherein, include entering and leaving checking command, also, be deployed in block chain virtual machine in the instruction set of block chain virtual machineCorresponding to the discrepancy check logic for entering and leaving checking command;It include that the discrepancy verifies in the instruction set of intelligent contract compilerIt instructs, includes the discrepancy checking command in the business intelligence contract through the intelligent contract compiler compiling;Block chain networkBusiness intelligence contract is stated in middle deployment, and the business intelligence contract is corresponding with user's asset table, and user's asset table is used forThe corresponding assets of each external account are recorded, for any assets, which is the data comprising encrypting the amount of money, the encryption amount of moneyIt is to be obtained after being encrypted to the amount of money of the assets;
Node in the block chain network obtains money transfer transactions by external account of transferring accounts and is broadcast to other nodes;The money transfer transactions include transfer accounts assets, small change assets and at least one cost assets;
Each node in the block chain network, by block chain virtual machine, is called when executing the money transfer transactionsThe business intelligence contract and according to the discrepancy checking command in the business intelligence contract, triggering, which executes discrepancys and verifies, patrolsVolume, transfer accounts to use homomorphic encryption algorithm, described in verification the sum of the amount of money of assets and the amount of money of the small change assets whether etc.In the sum of the amount of money of each cost assets;If check results be it is yes, by block chain virtual machine, execute the business intelligence contractIn user's asset table modify logic, to release the corresponding relationship of the transfer accounts external account and each cost assets, establish instituteThe corresponding relationship of transfer accounts external account and the small change assets is stated, and it is corresponding with the assets of transferring accounts to establish receipt on account external accountRelationship.
According to the 4th of this specification embodiment the aspect, a kind of block catenary system, including block chain network are provided;
It wherein, include entering and leaving checking command, also, be deployed in block chain virtual machine in the instruction set of block chain virtual machineCorresponding to the discrepancy check logic for entering and leaving checking command;It include that the discrepancy verifies in the instruction set of intelligent contract compilerIt instructs, includes the contract mark for entering and leaving the intelligent contract of verification in the business intelligence contract through the intelligent contract compiler compilingKnow, it is the intelligent contract being deployed in the block chain network in advance that the discrepancy, which verifies intelligent contract,;In the middle part of block chain networkThere is the business intelligence contract in administration, and the business intelligence contract is corresponding with user's asset table, and user's asset table is for recordingThe corresponding assets of each external account, for any assets, which is the data comprising encrypting the amount of money, which is pairWhat the amount of money of the assets obtained after being encrypted;
Node in the block chain network obtains money transfer transactions by external account of transferring accounts and is broadcast to other nodes;The money transfer transactions include transfer accounts assets, small change assets and at least one cost assets;
Each node in the block chain network, by block chain virtual machine, is called when executing the money transfer transactionsThe business intelligence contract, and according to the Contract ID of the intelligent contract of discrepancy verification in the business intelligence contract, it adjustsIntelligent contract is verified with the discrepancy;According to the discrepancy checking command for entering and leaving and verifying in intelligent contract, trigger described in executingCheck logic is entered and left, to use homomorphic encryption algorithm, transfer accounts described in the verification amount of money of assets and the amount of money of the small change assetsThe sum of whether be equal to each cost assets the sum of the amount of money;If check results be it is yes, by block chain virtual machine, execute the industryThe user's asset table being engaged in intelligent contract modifies logic, and to release, the external account of transferring accounts is corresponding with each cost assets to be closedSystem, the corresponding relationship of transfer accounts described in foundation external account and the small change assets, and establish receipt on account external account and transfer accounts with describedThe corresponding relationship of assets.
According to the 5th of this specification embodiment the aspect, a kind of block chain virtual machine is provided, for realizing above-mentioned 1st aspectWith the method for the 2nd aspect;
Wherein, including entering and leaving checking command, also, the block chain virtual machine in the instruction set of the block chain virtual machineIn be deployed with corresponding to it is described enter and leave checking command discrepancy check logic;
The discrepancy check logic includes:
For any money transfer transactions, using homomorphic encryption algorithm, the amount of money of the specified assets of transferring accounts of the money transfer transactions is verifiedThe sum of the amount of money for the small change assets specified with the money transfer transactions, if equal to the amount of money for each cost assets that the money transfer transactions are specifiedThe sum of.
According to the 6th of this specification embodiment the aspect, a kind of intelligent contract compiler is provided, for realizing above-mentioned 1st sideThe method in face;
Wherein, include entering and leaving checking command in the instruction set of the intelligent contract compiler, compiled through the intelligent contractIt include the discrepancy checking command in the business intelligence contract of device compiling.
According to the 7th of this specification embodiment the aspect, a kind of intelligent contract compiler is provided, for realizing above-mentioned 2nd sideThe method in face;
Wherein, include the discrepancy checking command in the instruction set of intelligent contract compiler, compiled through the intelligent contractThe Contract ID of intelligent contract is verified in the business intelligence contract of device compiling comprising entering and leaving, it is pre- that the discrepancy, which verifies intelligent contract,The intelligent contract being first deployed in the block chain network.
Technical solution provided by this specification embodiment, on the one hand, definition enters and leaves checking command and is added to block chainIn the instruction set of virtual machine, meanwhile, deployment corresponds to the discrepancy verification for entering and leaving checking command and patrols in block chain virtual machineVolume.On the other hand, it is also necessary to the discrepancy checking command of definition be added in the instruction set of intelligent contract compiler, so that through intelligenceDiscrepancy checking command can be included in the business intelligence contract of contract compiler compiling.The discrepancy check logic is, using homomorphismThe amount of money for the small change assets that Encryption Algorithm, the amount of money of the specified assets of transferring accounts of verification money transfer transactions and the money transfer transactions are specified itWith, if equal to the sum of the amount of money for each cost assets that the money transfer transactions are specified.In addition, business intelligence contract is corresponding with user's moneyTable is produced, user's asset table is for recording the corresponding assets of each external account, and for any assets, which is comprising addingThe data of the close amount of money, the encryption amount of money are obtained after encrypting to the amount of money of the assets.
So, if the business intelligence contract is deployed in block chain network, then, user is being transferred accountsWhen transaction, so that it may while the specified calling business intelligence contract executes the money transfer transactions, in turn, virtual machine is executing this turnWhen account is traded, the business intelligence contract will be called, and according to the discrepancy checking command in the business intelligence contract, triggeringExecute the discrepancy check logic disposed in advance.If check results be it is yes, turn out that money transfer transactions are feasible, and block chain virtual machine is justMoney transfer transactions can be executed and update user's asset table.
By this specification embodiment, by expanding block chain virtual machine and the instruction set of intelligent contract compilerExhibition allows block chain virtual machine to default support under the premise of not exposing account balance and transfer amounts, verifies more than accountThe whether enough transfer of payment amount of money of volume.
It should be understood that above general description and following detailed description be only it is exemplary and explanatory, notThis specification embodiment can be limited.
In addition, any embodiment in this specification embodiment does not need to reach above-mentioned whole effects.
Detailed description of the invention
In order to illustrate more clearly of this specification embodiment or technical solution in the prior art, below will to embodiment orAttached drawing needed to be used in the description of the prior art is briefly described, it should be apparent that, the accompanying drawings in the following description is onlyThe some embodiments recorded in this specification embodiment for those of ordinary skill in the art can also be attached according to theseFigure obtains other attached drawings.
Fig. 1 is a kind of process signal for coding method based on block chain intelligence contract that this specification embodiment providesFigure;
Fig. 2 is the process signal for another coding method based on block chain intelligence contract that this specification embodiment providesFigure;
Fig. 3 is a kind of process signal for coding/decoding method based on block chain intelligence contract that this specification embodiment providesFigure;
Fig. 4 is the process signal for another coding/decoding method based on block chain intelligence contract that this specification embodiment providesFigure;
Fig. 5 a~b is the deployment schematic diagram for the BASE64 coding-decoding operation that this specification embodiment provides;
Fig. 6 is that a kind of process for signature verification method based on block chain intelligence contract that this specification embodiment provides is shownIt is intended to;
Fig. 7 is the process for another signature verification method based on block chain intelligence contract that this specification embodiment providesSchematic diagram;
Fig. 8 a~b is the deployment schematic diagram for the RSA signature verification operation that this specification embodiment provides;
Fig. 9 is that a kind of process for data analysis method based on block chain intelligence contract that this specification embodiment provides is shownIt is intended to;
Figure 10 is a kind of process for data analysis method based on block chain intelligence contract that this specification embodiment providesSchematic diagram;
Figure 11 a~b is the deployment schematic diagram for the JSON parsing operation that this specification embodiment provides;
Figure 12 is a kind of process for data analysis method based on block chain intelligence contract that this specification embodiment providesSchematic diagram;
Figure 13 is a kind of process for data analysis method based on block chain intelligence contract that this specification embodiment providesSchematic diagram;
Figure 14 a~b is the deployment schematic diagram for the parsing operation that this specification embodiment provides;
Figure 15 is a kind of transaction Hash acquisition methods based on block chain intelligence contract that this specification embodiment providesFlow diagram;
Figure 16 is a kind of transaction Hash acquisition methods based on block chain intelligence contract that this specification embodiment providesFlow diagram;
Figure 17 a~b is the deployment schematic diagram that the transaction Hash that this specification embodiment provides obtains operation;
Figure 18 is a kind of process signal for transfer account method based on block chain intelligence contract that this specification embodiment providesFigure;
Figure 19 is a kind of transaction Hash acquisition methods based on block chain intelligence contract that this specification embodiment providesFlow diagram;
Figure 20 a~b is the deployment schematic diagram of the associated check operation for the money transfer transactions that this specification embodiment provides;
Figure 21 shows a kind of structural schematic diagram of block catenary system provided by this specification embodiment;
Figure 22 is the structural schematic diagram for configuring a kind of computer equipment of this specification embodiment method.
Specific embodiment
Herein, block chain virtual machine refers to that each block chain node is executing the execution program relied on when transaction.Block chain virtual machine provides performing environment for the transaction of block chain.
It should be noted that block chain virtual machine not only can be the ether mill virtual machine recorded in the agreement of ether mill(Ethereum Virtual Machine, EVM) can also be signified in other block chain agreements in addition to the agreement of ether millVirtual machine.
Herein, intelligent contract compiler will refer to for that programming language (such as solidity language) will be used to writeIntelligent contract is compiled into the journey for the machine language (such as bytecode, binary code) that block chain virtual machine can be identified and be executedSequence.It should be noted that being deployed in the intelligent contract in block chain network, generally refer to after intelligent contract compiler compilesIntelligent contract, i.e. the intelligent contract of bytecode form or binary code repressentation.
In ether mill agreement or the other similar block chain agreement in ether mill agreement, block chain virtual machine is in local dimensionThe mapping relations (as shown in table 1 below) between several groups instruction and operation are protected, also, block chain virtual machine is locally also deployed withThe code logic of each operation in table 1.1~command N of instruction is all the instruction of the defaulted support of block chain virtual machine, instruction 1~command N constitutes the instruction set of block chain virtual machine.Block chain virtual machine is when calling intelligent contract, if from intelligent contractIn read any instruction in table 1, the code logic for executing the corresponding operation of the instruction will be triggered.It should be noted thatInstruction as described herein is usually bytecode form or binary code repressentation.
Instruction 1Operation 1
Instruction 2Operation 2
Instruction 3Operation 3
…………
Command NOperate N
Table 1
Therefore, if it is desired to allowing any operation in block chain virtual machine execution table 1, it is necessary to be wanted in block chain virtual machineIt calls in intelligent contract, is previously written the corresponding instruction of the operation.It means that intelligent contract compiler is in advance to the intelligenceWhen contract is compiled, statement in intelligent contract (writing using programming language) can be realized to the interior of any operation in table 1Appearance is compiled into corresponding instruction, so that block chain virtual machine can identify.This requires intelligent contract compiler is also required to default1~command N of instruction in support matrix 1,1~command N of instruction constitute the instruction set of intelligent contract compiler.
In short, in ether mill agreement or the other similar block chain agreement in ether mill agreement, usually by block chainVirtual machine, intelligent contract compiler and the specific business demand of intelligent contract cooperative achievement.
But existing ether mill virtual machine is limited in the operation that locally default is supported, and business demand is complicatedMultiplicity.For example, existing ether mill virtual machine and the intelligent contract compiler in ether mill do not default the following operation of support, leadIt causes in the framework of existing ether mill, cannot achieve some dependent on the business demand operated as follows:
1, it is based on the coding-decoding operation of 64 printable characters (BASE64).
2, RSA signature verification operation;Wherein, RSA Algorithm be 1977 by Peter Lonard Lee Vista (Ron Rivest),A Di Shamir (Adi Shamir) and Leonard A Deman (Leonard Adleman), RSA Algorithm also hence obtains one's name.
3, to the processing operation of JS object numbered musical notation (JavaScript Object Notation, JSON) data;Wherein,JSON is a kind of common data interchange format, and JSON data are that have the data of this data interchange format.
4, to the processing operation of extensible markup language (eXtensible Markup Language, XML) data;ItsIn, XML is a kind of common data interchange format, and XML data is that have the data of this data interchange format.
5, the operation of the transaction Hash of currently performed transaction is obtained.
6, for a money transfer transactions, under the premise of not exposing the assets remaining sum and transfer amounts of the people that transfers accounts, judgement turnsWhether the assets remaining sum of account people pays the transfer amounts of this money transfer transactions enough.
Do not defaulted due to the intelligent contract compiler of existing ether mill virtual machine and ether mill and supports asking for aforesaid operationsTherefore topic in the prior art, is operated for any of the above-described kind, general use directly writes the code logic for realizing the operationEnter the mode of intelligent contract, so that ether mill virtual machine when executing transaction, calls intelligent contract to execute the code of the operationLogic.Although the code logic of aforesaid operations is written that is, ether mill virtual machine does not default support aforesaid operationsIntelligent contract, and allow the ether mill virtual machine call intelligence contract, ether mill virtual machine also may be implemented and execute aforesaid operationsPurpose.
But in practice, the local code logic disposed in advance is directly executed compared to ether mill virtual machine, ether mill is emptyThe efficiency that quasi- machine executes the code logic in intelligent contract is lower.
And core of the invention thought is, on the one hand, be extended, increase above-mentioned to the instruction set of block chain virtual machineCorresponding instruction is operated, while in the corresponding code logic of the local aforesaid operations of deployment in advance of block chain virtual machine, so that blockChain virtual machine can default support aforesaid operations.On the other hand, the instruction set of intelligent contract compiler is also extended, is increasedThe corresponding instruction of aforesaid operations.It wherein, is that the instruction set of block chain virtual machine is increased corresponding to the operation for same operationInstruction should be consistent with the increased instruction corresponding to the operation of instruction set for intelligence contract compiler.As shown in table 2.
Instruction 1Operation 1
Instruction 2Operation 2
Instruction 3Operation 3
BASE64 coded commandBASE64 encoding operation
…………
Command NOperate N
Table 2
In this way, by taking above-mentioned BASE64 encoding operation as an example, it can be when writing intelligent contract using programming language, in intelligenceIt can state to call BASE64 encoding operation in contract, intelligent contract compiler is when being compiled intelligent contract, by this section of soundIt is bright to be compiled into BASE64 coded command.After the intelligence contract is deployed in block chain network, user, can in the business of initiationIt is seted the tone with initiating to refer in transaction in business with the intelligence contract, in this way, block chain virtual machine is when the business of execution is initiated to trade, justThe intelligence contract can be called, and when reading BASE64 coded command from the intelligence contract, triggering is performed locally correspondingBASE64 codimg logic, to realize BASE64 encoding operation.
In order to make those skilled in the art more fully understand the technical solution in this specification embodiment, below in conjunction with thisAttached drawing in specification embodiment is described in detail the technical solution in this specification embodiment, it is clear that describedEmbodiment is only a part of the embodiment of this specification, instead of all the embodiments.The embodiment of base in this manual,Those of ordinary skill in the art's every other embodiment obtained, all should belong to the range of protection.
Below in conjunction with attached drawing, the technical solution that each embodiment of this specification provides is described in detail.It should be noted that due toThe technical idea that each embodiment below is based on all be it is similar, therefore, each embodiment hereafter can be mutually referring to understanding.
Embodiment one
Fig. 1 is a kind of process signal for coding method based on block chain intelligence contract that this specification embodiment providesFigure, comprising the following steps:
S100: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S102: for each node in the block chain network, which leads to when executing the business initiation transactionBlock chain virtual machine is crossed, the business intelligence contract is called.
S104: the node is by block chain virtual machine, according to the BASE64 coded command in the business intelligence contract, touchingHair executes the BASE64 codimg logic, to perform the encoding operation to data to be encoded.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include BASE64 coded command in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machineBASE64 codimg logic corresponding to the BASE64 coded command.
It 2) include the BASE64 coded command in the instruction set of intelligent contract compiler, through the intelligent contract compilerIt include the BASE64 coded command in the business intelligence contract of compiling.
3) it is disposed in block chain network and is stated business intelligence contract.
The business intelligence contract is to need to call intelligent contract corresponding to the business of BASE64 encoding function.
In each embodiment of this explanation, block chain network includes multiple nodes.Wherein, from software view, nodeRefer to the block chain program for realizing block chain function;From hardware view, node, which refers to, is equipped with block chain programUser equipment.In practical applications, each node can dock at least one client (or wallet), the transaction in block chainUsually client constructs.
The transaction described in each embodiment of this explanation (transaction) refers to that user passes through the visitor of block chainThe creation of family end, and a data for needing finally to be distributed in the distributed data base of block chain.Transaction is in block chain agreementA kind of data structure arranged, a data will be stored in block chain, it is necessary to be packaged into transaction.
Transaction in block chain, there are points of the transaction of narrow sense and the transaction of broad sense.The transaction of narrow sense refer to user toOne value Transfer of block chain publication;For example, transaction can be user in block in traditional bit coin block chain networkOne initiated in chain transfers accounts.And the transaction of broad sense refers to the business number being intended to business that user issues to block chainAccording to;For example, operator can build alliance's chain based on actual business demand, relies on alliance's chain and dispose some and valueShift it is unrelated it is other types of in line service (for example, business of renting a house, vehicle scheduling business, settlement of insurance claim business, credit takeBusiness, medical services etc.), and in this kind of alliance's chain, transaction, which can be one that user issues in alliance's chain, has business meaningThe service message or service request of figure.
In block chain network, user initiates business usually in the form of transaction.Specifically, node needs to obtain business hairIf playing the above-mentioned business intelligence contract of transaction is not the unique intelligent contract disposed in block chain network, business initiates transactionIn can also indicate the Contract ID of the business intelligence contract, the intelligent contract of required calling when executing clearly to trade.
Wherein, it is usually that user is constructed by client and is sent to node that business, which initiates transaction,.In general, blockThe client of chain network docking and each user correspond.
Business after being initiated transaction and being broadcast to other nodes by node, and for each node, the node is receivingIt states business to initiate after trading, needs to execute the business by business intelligence contract described in block chain virtual machine call and initiate to hand overEasily.Herein it should be noted that in block chain network, block chain virtual machine is deployed on each node, node executes friendshipYi Shi, the block chain virtual machine actually disposed on node are executing transaction.
In example 1, after business intelligence contract described in block chain virtual machine call, it can read the business intelligenceBytecode or binary code in contract simultaneously execute, when reading the BASE64 coded command in the business intelligence contract,It is equivalent to and specifies and need to carry out BASE64 encoding operation at this time, therefore, block chain virtual machine can trigger at this time executes preparatory portionIt is deployed on local BASE64 codimg logic, to perform the encoding operation to data to be encoded.
In practical applications, depending on the difference of specific business demand, data to be encoded can be contained within the business hairIt rises in transaction, also may include in the business intelligence contract, can also be that block chain virtual machine is executing the industryIt is generated when business initiation transaction.
It is initiated except transaction in addition, each node executes business except through block chain virtual machine, it is also necessary to be based on common recognition machineThe business is initiated transaction write-in block chain by system.
It is further to note that if block chain virtual machine refers to according to the BASE64 coding in the business intelligence contractTriggering is enabled to execute BASE64 codimg logic, then, used data transfer mode is usually that stack transmits (i.e. in the process of implementationIn data write-in stack after generally BASE64 being encoded), still, for the data after BASE64 is encoded, numberIt is unfixed according to length, if by the way of stack transmitting, it is desirable to may all be preset when data length for variousCorresponding BASE64 coded command, implements complex.
For this purpose, embodiment two below provides another coding method based on block chain intelligence contract.
Embodiment two
Fig. 2 is the process signal for another coding method based on block chain intelligence contract that this specification embodiment providesFigure, comprising the following steps:
S200: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S202: for each node in the block chain network, which leads to when executing the business initiation transactionBlock chain virtual machine is crossed, the business intelligence contract is called.
S204: the node encodes intelligence by block chain virtual machine, according to the BASE64 in the business intelligence contractThe Contract ID of energy contract, calls the intellectual coded contract of the BASE64.
S206: the node is by block chain virtual machine, and according in the intellectual coded contract of the BASE64, BASE64 is encodedInstruction, triggering executes the BASE64 codimg logic, to perform the encoding operation to data to be encoded.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include BASE64 coded command in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machineBASE64 codimg logic corresponding to the BASE64 coded command.
It 2) include the BASE64 coded command in the instruction set of intelligent contract compiler, through the intelligent contract compilerIt include the Contract ID of the intellectual coded contract of BASE64 in the business intelligence contract of compiling, the intellectual coded contract of BASE64 isThe intelligent contract being deployed in the block chain network in advance.
3) it is disposed in block chain network and is stated business intelligence contract.
Embodiment two and the difference of embodiment one essentially consist in, in example 2, industry described in block chain virtual machine callIt is engaged in after intelligent contract, when reading the Contract ID of the intellectual coded contract of the BASE64, is equivalent to and specifies and need at this timeFurther to call the intellectual coded contract of the BASE64.The intellectual coded contract of BASE64 described in block chain virtual machine call,It can read the bytecode or binary code in the intellectual coded contract of the BASE64, when reading the BASE64 coded commandWhen, it is equivalent to and specifies and need to be implemented BASE64 encoding operation at this time, therefore, it is preparatory that block chain virtual machine can trigger execution at this timeIt is deployed in local BASE64 codimg logic, to perform the encoding operation to data to be encoded.
That is, in example 2, intelligent contract compiler is when compiling business intelligence contract, if it find that businessBASE64 encoding operation is called in statement in intelligent contract, then this section will not be stated to compiling BASE64 coded command, but compiledAt the Contract ID of the intellectual coded contract of the BASE64.It, can be into this way, block chain virtual machine is when calling business intelligence contractThe one step intellectual coded contract of the BASE64.
In block chain technical field, the intellectual coded contract of BASE64 is actually a kind of precompile contract, block chainVirtual machine, can't be using the side of stack transmitting when calling and executing the precompile contract as BASE64 intellectual coded contractFormula carry out parameter transmitting, but can using memory transmitting by the way of carry out parameter transmitting (support be not fixed length data readingIt writes).
Embodiment three
Fig. 3 is a kind of process signal for coding method based on block chain intelligence contract that this specification embodiment providesFigure, comprising the following steps:
S300: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S302: for each node in the block chain network, which leads to when executing the business initiation transactionBlock chain virtual machine is crossed, the business intelligence contract is called.
S304: the node solves code instruction, touching by block chain virtual machine, according to the BASE64 in the business intelligence contractHair executes the BASE64 decode logic, is decoded operation to treat decoding data.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
It 1) include that BASE64 solves code instruction, also, is deployed in block chain virtual machine in the instruction set of block chain virtual machineBASE64 decode logic corresponding to BASE64 solution code instruction.
It 2) include that the BASE64 solves code instruction in the instruction set of intelligent contract compiler, through the intelligent contract compilerCode instruction is solved comprising the BASE64 in the business intelligence contract of compiling.
3) it is disposed in block chain network and is stated business intelligence contract.
Since BASE64 decoding operate is corresponding one group of operation with BASE64 encoding operation, related description ginsengSee embodiment one, repeats no more.
It should be noted that in practical applications, depending on the difference of specific business demand, data to be decoded, which can be, includesIt initiates also to may include in the business intelligence contract in transaction, can also be block chain virtual machine in the businessIt is generated when executing the business and initiating and trade.
In addition, in the third embodiment, being transmitted there is also previously described stack and realizing complicated problem, for this purpose, reality belowIt applies example four and provides another coding/decoding method based on block chain intelligence contract.
Example IV
Fig. 4 is the process signal for another coding/decoding method based on block chain intelligence contract that this specification embodiment providesFigure, comprising the following steps:
S200: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S202: for each node in the block chain network, which leads to when executing the business initiation transactionBlock chain virtual machine is crossed, the business intelligence contract is called.
S204: the node decodes intelligence by block chain virtual machine, according to the BASE64 in the business intelligence contractThe Contract ID of energy contract calls the BASE64 to decode intelligent contract.
S206: the node is decoded in intelligent contract by block chain virtual machine according to the BASE64, BASE64 decodingInstruction, triggering execute the BASE64 decode logic, are decoded operation to treat decoding data.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
It 1) include that BASE64 solves code instruction, also, is deployed in block chain virtual machine in the instruction set of block chain virtual machineBASE64 decode logic corresponding to BASE64 solution code instruction.
It 2) include that the BASE64 solves code instruction in the instruction set of intelligent contract compiler, through the intelligent contract compilerThe Contract ID of intelligent contract is decoded in the business intelligence contract of compiling comprising BASE64, the BASE64, which decodes intelligent contract, isThe intelligent contract being deployed in the block chain network in advance.
3) it is disposed in block chain network and is stated business intelligence contract.
The difference of example IV and embodiment three essentially consists in, in example IV, industry described in block chain virtual machine callIt is engaged in after intelligent contract, when reading the BASE64 and decoding the Contract ID of intelligent contract, is equivalent to and specifies and need at this timeThe BASE64 is further called to decode intelligent contract.BASE64 described in block chain virtual machine call decodes intelligent contract,It can read the bytecode or binary code in the intelligent contract of BASE64 decoding, solve code instruction when reading the BASE64When, it is equivalent to and specifies and need to be implemented BASE64 decoding operate at this time, therefore, it is preparatory that block chain virtual machine can trigger execution at this timeIt is deployed in local BASE64 decode logic, is decoded operation to treat decoding data.
Fig. 5 a is the BASE64 coding-decoding operation corresponding to embodiment one and embodiment three that this specification embodiment providesDeployment schematic diagram.As shown in Figure 5 a, first, for block chain virtual machine instruction set add BASE64 coded command and/orBASE64 solves code instruction, meanwhile, BASE64 codimg logic and/or BASE64 decode logic are disposed in block chain virtual machine.ItsTwo, the instruction set for intelligent contract compiler adds BASE64 coded command and/or BASE64 solves code instruction.Third, will pass throughThe business intelligence contract (solving code instruction comprising BASE64 coded command and/or BASE64) of intelligent contract compiler compiling is deployed inIn block chain network.
It should be noted that increasing function command for intelligent contract compiler (including various instructions described herein)When, generally requiring mutually should be intelligent contract compiler and increases the corresponding processing logic of the function command, (at such as parameter/return valueManage logic), so that business intelligence contract is also written in the corresponding processing logic of the function command by intelligent contract compiler.
For embodiment two and example IV, Fig. 5 b is corresponding to embodiment two and implementing for this specification embodiment offerThe deployment schematic diagram of the BASE64 coding-decoding operation of example four.As shown in Figure 5 b, first, the instruction set for block chain virtual machine is addedBASE64 coded command and/or BASE64 solve code instruction, meanwhile, disposed in block chain virtual machine BASE64 codimg logic and/Or BASE64 decode logic.Second, the instruction set for intelligent contract compiler adds BASE64 coded command and/or BASE64 solutionCode instruction.Third, by the business intelligence contract (conjunction comprising the intellectual coded contract of BASE64 by intelligent contract compiler compilingAbout identify the Contract ID that intelligent contract is decoded with BASE64) it is deployed in block chain network.
Embodiment five
Fig. 6 is that a kind of process for signature verification method based on block chain intelligence contract that this specification embodiment provides is shownIt is intended to, includes the following steps:
S600: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S602: for each node in the block chain network, which leads to when executing the business initiation transactionBlock chain virtual machine is crossed, the business intelligence contract is called.
S604: the node verifies instruction by block chain virtual machine, according to the RSA signature in the business intelligence contract,Triggering executes the RSA signature verifying logic, carries out RSA signature verification operation to sign to business.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include RSA signature verifying instruction in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machineRSA signature verifying logic corresponding to RSA signature verifying instruction.
2) include RSA signature verifying instruction in the instruction set of intelligent contract compiler, compiled through the intelligent contractInclude RSA signature verifying instruction in the business intelligence contract of device compiling.
3) it is disposed in block chain network and is stated business intelligence contract.
The business intelligence contract is to need to call intelligent contract corresponding to the business of RSA signature authentication function.
In example 1, after business intelligence contract described in block chain virtual machine call, it can read the business intelligenceBytecode or binary code in contract simultaneously execute, when reading the RSA signature verifying instruction in the business intelligence contract,It is equivalent to and specifies and need to carry out RSA signature verification operation at this time, therefore, block chain virtual machine can trigger at this time executes preparatory portionIt is deployed on local RSA signature verifying logic, carries out signature verification operations to sign to business.
In practical applications, depending on the difference of specific business demand, there are following several situations:
1) the business initiation transaction is signed comprising the business, business signature is corresponding is signed data and useIn the public key for verifying the business signature.
2) business initiates transaction and signs the corresponding abstract for being signed data comprising business signature, the businessAnd the public key for verifying the business signature.
3) business initiates transaction and is signed data comprising business signature, business signature are corresponding, describedBusiness intelligence contract includes the public key for verifying the business signature.
4) business initiates transaction and signs comprising business signature, the business corresponding to be signed plucking for dataIt wants, the business intelligence contract includes the public key for verifying the business signature.
It should be noted that if block chain virtual machine verifies instruction according to the RSA signature in the business intelligence contractTriggering executes RSA signature verifying logic, then, used data transfer mode is usually stack transmitting in the process of implementation.
In addition, the mode that memory transmitting also can be used in block chain virtual machine executes RSA signature verifying logic, (precompile is closedMode about), i.e., embodiment six below.
Embodiment six
Fig. 7 is that a kind of process for signature verification method based on block chain intelligence contract that this specification embodiment provides is shownIt is intended to, includes the following steps:
S700: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S702: for each node in the block chain network, which leads to when executing the business initiation transactionBlock chain virtual machine is crossed, the business intelligence contract is called.
S704: the node verifies intelligence by block chain virtual machine, according to the RSA signature in the business intelligence contractThe Contract ID of energy contract calls the RSA signature to verify intelligent contract.
S706: the node is verified the RSA signature in intelligent contract according to the RSA signature and is tested by block chain virtual machineCard instruction, triggering execute the RSA signature verifying logic, RSA signature verification operation are carried out to sign to business, to business labelName carries out RSA signature verification operation.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include RSA signature verifying instruction in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machineRSA signature verifying logic corresponding to RSA signature verifying instruction.
2) include RSA signature verifying instruction in the instruction set of intelligent contract compiler, compiled through the intelligent contractThe Contract ID of intelligent contract is verified in the business intelligence contract of device compiling comprising RSA signature, the RSA signature verifying intelligence is closedIt is approximately the intelligent contract being deployed in the block chain network in advance.
3) it is disposed in block chain network and is stated business intelligence contract.
Embodiment six and the difference of embodiment five essentially consist in, in embodiment six, industry described in block chain virtual machine callIt is engaged in after intelligent contract, when reading the RSA signature and verifying the Contract ID of intelligent contract, is equivalent to and specifies and need at this timeThe RSA signature is further called to verify intelligent contract.RSA signature described in block chain virtual machine call verifies intelligent contract,Also the bytecode or binary code in the intelligent contract of RSA signature verifying be can read, referred to when reading the RSA signature verifyingWhen enabling, it is equivalent to and specifies and need to be implemented RSA signature verification operation at this time, therefore, block chain virtual machine can trigger execution at this timeIt is deployed in local RSA signature verifying logic in advance, carries out RSA signature verification operation to sign to business.
That is, intelligent contract compiler is when compiling business intelligence contract, if it find that business in embodiment sixRSA signature verification operation is called in statement in intelligent contract, then this section of statement will not be compiled as to RSA signature verifying instruction, butIt is compiled into the Contract ID that the RSA signature verifies intelligent contract.In this way, block chain virtual machine is calling business intelligence contractWhen, it can further call the RSA signature to verify intelligent contract.
Fig. 8 a is the deployment signal for the RSA signature verification operation corresponding to embodiment five that this specification embodiment providesFigure.As shown in Figure 8 a, first, the instruction set for block chain virtual machine adds RSA signature verifying instruction, meanwhile, it is empty in block chainRSA signature verifying logic is disposed in quasi- machine.Second, the instruction set for intelligent contract compiler adds RSA signature verifying instruction.ItsThree, the business intelligence contract (including RSA signature verifying instruction) by intelligent contract compiler compiling is deployed in block link networkIn network.
Fig. 8 b is the deployment signal for the RSA signature verification operation corresponding to embodiment six that this specification embodiment providesFigure.As shown in Figure 8 b, first, the instruction set for block chain virtual machine adds RSA signature verifying instruction, meanwhile, it is empty in block chainRSA signature verifying logic is disposed in quasi- machine.Second, the instruction set for intelligent contract compiler adds RSA signature verifying instruction.ItsThree, by the business intelligence contract (verifying the Contract ID of intelligent contract comprising RSA signature) by intelligent contract compiler compilingIt is deployed in block chain network.
Embodiment seven
Fig. 9 is that a kind of process for data processing method based on block chain intelligence contract that this specification embodiment provides is shownIt is intended to, includes the following steps:
S900: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S902: for each node in the block chain network, which leads to when executing the business initiation transactionBlock chain virtual machine is crossed, the business intelligence contract is called.
S904: the node is by block chain virtual machine, according to the JSON process instruction in the business intelligence contract, triggeringThe JSON processing logic is executed, to carry out JSON processing operation to pending data.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include JSON process instruction in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machine pairThe JSON of JSON process instruction described in Ying Yu handles logic.
2) include the JSON process instruction in the instruction set of intelligent contract compiler, compiled through the intelligent contract compilerIt include the JSON process instruction in the business intelligence contract translated.
3) it is disposed in block chain network and is stated business intelligence contract.
The business intelligence contract is to need to call intelligent contract corresponding to the business of JSON processing function.JSON processingThe parsing of JSON data is specifically included to generate with JSON data.
In embodiment seven, after business intelligence contract described in block chain virtual machine call, the business intelligence can readBytecode or binary code in contract simultaneously execute, when reading the JSON process instruction in the business intelligence contract, phaseWhen needing to carry out JSON processing operation at this time in specifying, therefore, block chain virtual machine can trigger execution at this time and be deployed in advanceLocal JSON handles logic, to carry out JSON processing operation to pending data.
In practical applications, depending on the difference of specific business demand, the pending data be may include in the businessIt initiates also to may include in the business intelligence contract in transaction, can also be that block chain virtual machine executes the business hairIt is generated when playing transaction.
It is further to note that if block chain virtual machine is according to the JSON process instruction in the business intelligence contractTriggering executes JSON and handles logic, then, used data transfer mode is usually that stack transmitting is (i.e. general in the process of implementationThe data that JSON is handled out can be written in stack), still, for the data that JSON is handled out, data length is not solidFixed, it frequently can lead to realize by the way of stack transmitting complex.
It (prelists for this purpose, embodiment eight below provides another data processing method based on block chain intelligence contractTranslate the mode of contract).
Embodiment eight
Figure 10 is a kind of process for data processing method based on block chain intelligence contract that this specification embodiment providesSchematic diagram includes the following steps:
S1000: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S1002: for each node in the block chain network, the node when executing the business and initiating transaction,By block chain virtual machine, the business intelligence contract is called.
S1004: the node handles intelligence by block chain virtual machine, according to the JSON in the business intelligence contractThe Contract ID of contract calls the JSON to handle intelligent contract.
S1006: the node is handled the JSON processing in intelligent contract according to the JSON and is referred to by block chain virtual machineIt enables, triggering executes the JSON and handles logic, to carry out JSON processing operation to pending data.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include JSON process instruction in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machine pairThe JSON of JSON process instruction described in Ying Yu handles logic.
2) include the JSON process instruction in the instruction set of intelligent contract compiler, compiled through the intelligent contract compilerThe Contract ID of intelligent contract is handled in the business intelligence contract translated comprising JSON, it is preparatory portion that the JSON, which handles intelligent contract,The intelligent contract being deployed in the block chain network.
3) it is disposed in block chain network and is stated business intelligence contract.
Embodiment eight and the difference of embodiment seven essentially consist in, in embodiment eight, industry described in block chain virtual machine callIt is engaged in after intelligent contract, when reading the JSON and handling the Contract ID of intelligent contract, is equivalent to and specifies and need at this timeThe JSON is further called to handle intelligent contract.The intelligent contract of the processing of JSON described in block chain virtual machine call, also can readThe bytecode or binary code that the JSON is handled in intelligent contract are equivalent to bright when reading the JSON process instructionReally need to be implemented JSON processing operation at this time, therefore, block chain virtual machine at this time can trigger execution be deployed in advance it is localJSON handles logic, to carry out JSON processing operation to pending data.
That is, intelligent contract compiler is when compiling business intelligence contract, if it find that business in embodiment eightJSON processing operation is called in statement in intelligent contract, then this section of statement will not be compiled as JSON process instruction, but be compiled intoThe JSON handles the Contract ID of intelligent contract.In this way, block chain virtual machine, when calling business intelligence contract, meeting is furtherThe JSON is called to handle intelligent contract.
Figure 11 a is the deployment schematic diagram for the JSON processing operation corresponding to embodiment seven that this specification embodiment provides.As shown in fig. 11a, first, the instruction set for block chain virtual machine adds JSON process instruction, meanwhile, in block chain virtual machineIt disposes JSON and handles logic.Second, the instruction set for intelligent contract compiler adds JSON process instruction.Third, intelligence will be passed throughThe business intelligence contract (including JSON process instruction) of energy contract compiler compiling is deployed in block chain network.
Figure 11 b is the deployment schematic diagram for the JSON processing operation corresponding to embodiment eight that this specification embodiment provides.As shown in figure 11b, first, the instruction set for block chain virtual machine adds JSON process instruction, meanwhile, in block chain virtual machineIt disposes JSON and handles logic.Second, the instruction set for intelligent contract compiler adds JSON process instruction.Third, intelligence will be passed throughThe business intelligence contract (Contract ID comprising the intelligent contract of JSON processing) of energy contract compiler compiling is deployed in block link networkIn network.
Embodiment nine
Figure 12 is a kind of process for data processing method based on block chain intelligence contract that this specification embodiment providesSchematic diagram includes the following steps:
S1200: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S1202: for each node in the block chain network, the node when executing the business and initiating transaction,By block chain virtual machine, the business intelligence contract is called.
S1204: the node is by block chain virtual machine, according to the XML process instruction in the business intelligence contract, triggeringThe XML processing logic is executed, to carry out XML processing operation to pending data.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include XML process instruction in the instruction set of block chain virtual machine, also, be deployed with correspondence in block chain virtual machineLogic is handled in the XML of the XML process instruction.
2) include the XML process instruction in the instruction set of intelligent contract compiler, compiled through the intelligent contract compilerIt include the XML process instruction in the business intelligence contract translated.
3) it is disposed in block chain network and is stated business intelligence contract.
The business intelligence contract is to need intelligent contract corresponding to the business of call XML processing function.At the XMLReason specifically includes XML data parsing and generates with XML data.
In embodiment nine, after business intelligence contract described in block chain virtual machine call, the business intelligence can readBytecode or binary code in contract simultaneously execute, when reading the XML process instruction in the business intelligence contract, quiteIt needs to carry out XML processing operation at this time in specifying, therefore, block chain virtual machine can trigger execution at this time and be deployed in local in advanceXML handle logic, with to pending data carry out XML processing operation.
In practical applications, depending on the difference of specific business demand, the pending data be may include in the businessIt initiates also to may include in the business intelligence contract in transaction, can also be that block chain virtual machine executes the business hairIt is generated when playing transaction.
It is further to note that if block chain virtual machine is according to the XML process instruction in the business intelligence contractTriggering executes XML and handles logic, then, used data transfer mode is usually that stack transmitting is (i.e. general in the process of implementationThe data that XML is handled out can be written in stack), still, for the data that XML is handled out, data length is to be not fixed, it frequently can lead to realize by the way of stack transmitting complex.
It (prelists for this purpose, embodiment ten below provides another data processing method based on block chain intelligence contractTranslate the mode of contract).
Embodiment ten
Figure 13 is a kind of process for data processing method based on block chain intelligence contract that this specification embodiment providesSchematic diagram includes the following steps:
S1300: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S1302: for each node in the block chain network, the node when executing the business and initiating transaction,By block chain virtual machine, the business intelligence contract is called.
S1304: the node handles intelligence by block chain virtual machine, according to the XML in the business intelligence contractThe Contract ID of contract calls the XML to handle intelligent contract.
S1306: the node handles the XML process instruction in intelligent contract by block chain virtual machine, according to the XML,Triggering executes the XML and handles logic, to carry out XML processing operation to pending data.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include XML process instruction in the instruction set of block chain virtual machine, also, be deployed with correspondence in block chain virtual machineLogic is handled in the XML of the XML process instruction.
2) include the XML process instruction in the instruction set of intelligent contract compiler, compiled through the intelligent contract compilerThe Contract ID of intelligent contract is handled in the business intelligence contract translated comprising XML, it is to dispose in advance that the XML, which handles intelligent contract,Intelligent contract in the block chain network.
3) it is disposed in block chain network and is stated business intelligence contract.
Embodiment ten and the difference of embodiment nine essentially consist in, in embodiment ten, industry described in block chain virtual machine callBe engaged in after intelligent contract, when reading the XML and handling the Contract ID of intelligent contract, be equivalent to specify need at this time intoThe one step XML handles intelligent contract.The intelligent contract of the processing of XML described in block chain virtual machine call, also can read describedBytecode or binary code in the intelligent contract of XML processing are equivalent to when reading the XML process instruction and specify thisWhen need to be implemented XML processing operation, therefore, block chain virtual machine can trigger to execute at this time is deployed in local XML processing in advanceLogic, to carry out XML processing operation to pending data.
That is, intelligent contract compiler is when compiling business intelligence contract, if it find that business in embodiment tenCall XML processing operation is stated in intelligent contract, then this section of statement will not be compiled as XML process instruction, but be compiled into instituteState the Contract ID that XML handles intelligent contract.In this way, block chain virtual machine can be adjusted further when calling business intelligence contractIntelligent contract is handled with the XML.
Figure 14 a is the deployment schematic diagram for the XML processing operation corresponding to embodiment nine that this specification embodiment provides.Such asShown in Figure 14 a, first, the instruction set for block chain virtual machine adds XML process instruction, meanwhile, in the middle part of block chain virtual machineIt affixes one's name to XML and handles logic.Second, the instruction set for intelligent contract compiler adds XML process instruction.Third, will be closed by intelligenceThe business intelligence contract (including XML process instruction) of about compiler compiling is deployed in block chain network.
Figure 14 b is the deployment schematic diagram for the XML processing operation corresponding to embodiment ten that this specification embodiment provides.Such asShown in Figure 14 b, first, the instruction set for block chain virtual machine adds XML process instruction, meanwhile, in the middle part of block chain virtual machineIt affixes one's name to XML and handles logic.Second, the instruction set for intelligent contract compiler adds XML process instruction.Third, will be closed by intelligenceThe business intelligence contract (Contract ID comprising the intelligent contract of XML processing) of about compiler compiling is deployed in block chain network.
Embodiment 11
Figure 15 is a kind of transaction Hash acquisition methods based on block chain intelligence contract that this specification embodiment providesFlow diagram includes the following steps:
S1500: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S1502: for each node in the block chain network, the node when executing the business and initiating transaction,By block chain virtual machine, the business intelligence contract is called.
S1504: the node is referred to by block chain virtual machine according to the transaction Hash acquisition in the business intelligence contractIt enables, triggering executes the transaction Hash and obtains logic, to obtain the transaction Hash that the business initiates transaction.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include transaction Hash acquisition instruction in the instruction set of block chain virtual machine, also, disposed in block chain virtual machineThere is the transaction Hash for corresponding to the transaction Hash acquisition instruction to obtain logic.
2) include the transaction Hash acquisition instruction in the instruction set of intelligent contract compiler, compiled through the intelligent contractIt include the transaction Hash acquisition instruction in the business intelligence contract of device compiling.
3) it is disposed in block chain network and is stated business intelligence contract.
The business intelligence contract is to need that transaction Hash is called to obtain intelligent contract corresponding to the business of function.
In embodiment 11, after business intelligence contract described in block chain virtual machine call, the business intelligence can readIt bytecode in contract or binary code and can execute, when reading the transaction Hash acquisition instruction in the business intelligence contractWhen, it is equivalent to and specifies that carrying out transaction Hash at this time obtains operation, therefore, it is pre- that block chain virtual machine can trigger execution at this timeIt is first deployed in local transaction Hash and obtains logic, obtain operation to carry out transaction Hash to pending data.
In practical applications, for each node in the block chain network, which is calling the business intelligenceBefore contract, the context of block chain virtual machine is initialized, and the transaction Hash that the business initiates transaction is written on describedHereinafter.
In this way, specifically, the node is by block chain virtual machine, according to the business intelligence contract in step S1504In transaction Hash acquisition instruction, triggering executes transaction Hash acquisition logic, to obtain the industry from the contextThe transaction Hash of transaction is initiated in business.
It is further to note that if block chain virtual machine is obtained according to the transaction Hash in the business intelligence contractInstruction triggers execute transaction Hash and obtain logic, then, used data transfer mode is usually that stack passes in the process of implementationIt passs.Embodiment 12 below provides another transaction Hash acquisition methods based on block chain intelligence contract, and (precompile is closedMode about).
Embodiment 12
Figure 16 is a kind of transaction Hash acquisition methods based on block chain intelligence contract that this specification embodiment providesFlow diagram includes the following steps:
S1600: the node in block chain network obtains business and initiates to trade and be broadcast to other nodes.
S1602: for each node in the block chain network, the node when executing the business and initiating transaction,By block chain virtual machine, the business intelligence contract is called.
S1604: the node is obtained by block chain virtual machine according to the transaction Hash in the business intelligence contractThe Contract ID of intelligent contract calls the transaction Hash to obtain intelligent contract.
S1606: the node obtains the transaction Hash in intelligent contract according to the transaction Hash by block chain virtual machineAcquisition instruction, triggering execute the transaction Hash and obtain logic, to obtain the transaction Hash that the business initiates transaction.
In the present embodiment, it needs to be pre-configured with for block chain network, so that:
1) include transaction Hash acquisition instruction in the instruction set of block chain virtual machine, also, disposed in block chain virtual machineThere is the transaction Hash for corresponding to the transaction Hash acquisition instruction to obtain logic.
2) include the transaction Hash acquisition instruction in the instruction set of intelligent contract compiler, compiled through the intelligent contractThe Contract ID of intelligent contract is obtained in the business intelligence contract of device compiling comprising transaction Hash, the transaction Hash obtains intelligenceContract is the intelligent contract being deployed in the block chain network in advance.
3) the business intelligence contract is disposed in block chain network.
Embodiment 12 and the difference of embodiment 11 essentially consist in, in embodiment 12, block chain virtual machine callAfter the business intelligence contract, when reading the Contract ID of the intelligent contract of transaction Hash acquisition, it is equivalent to clearIt needs that the transaction Hash is further called to obtain intelligent contract at this time.Transaction Hash described in block chain virtual machine call obtainsIntelligent contract also can read the transaction Hash and obtain bytecode or binary code in intelligent contract, when reading the friendshipWhen easy Hash acquisition instruction, be equivalent to and specify that needing to be implemented transaction Hash at this time obtains operation, therefore, block chain virtual machine thisWhen can trigger to execute and be deployed in local transaction Hash in advance and obtain logic, initiate the transaction of transaction to obtain the business and breathe outIt is uncommon.
That is, intelligent contract compiler is when compiling business intelligence contract, if it find that industry in embodiment 12It is engaged in stating that transaction Hash is called to obtain operation in intelligent contract, then this section will not be stated be compiled as transaction Hash acquisition instruction,But it is compiled into the Contract ID that the transaction Hash obtains intelligent contract.In this way, block chain virtual machine is calling business intelligenceWhen contract, the transaction Hash can further be called to obtain intelligent contract.
In practical applications, for each node in the block chain network, which is calling the business intelligenceBefore contract, the context of block chain virtual machine is initialized, and the transaction Hash that the business initiates transaction is written on describedHereinafter.
In this way, specifically, which is obtained by block chain virtual machine according to the transaction Hash in step S1606Transaction Hash acquisition instruction in intelligent contract, triggering executes the transaction Hash and obtains logic, to obtain from the contextThe business is taken to initiate the transaction Hash of transaction.
Figure 17 a is that the deployment for the transaction Hash acquisition operation corresponding to embodiment 11 that this specification embodiment provides is shownIt is intended to.As illustrated in fig 17 a, first, the instruction set for block chain virtual machine adds transaction Hash acquisition instruction, meanwhile, in blockDeployment transaction Hash obtains logic in chain virtual machine.Second, the instruction set addition transaction Hash for intelligent contract compiler obtainsInstruction.Third, the business intelligence contract (including transaction Hash acquisition instruction) by intelligent contract compiler compiling is deployed inIn block chain network.
Figure 17 b is that the deployment for the transaction Hash acquisition operation corresponding to embodiment 12 that this specification embodiment provides is shownIt is intended to.As illustrated in fig. 17b, first, the instruction set for block chain virtual machine adds transaction Hash acquisition instruction, meanwhile, in blockDeployment transaction Hash obtains logic in chain virtual machine.Second, the instruction set addition transaction Hash for intelligent contract compiler obtainsInstruction.Third, by (conjunction of intelligent contract is obtained comprising transaction Hash by the business intelligence contract of intelligent contract compiler compilingAbout identify) it is deployed in block chain network.
Embodiment 13
Figure 18 is a kind of process signal for transfer account method based on block chain intelligence contract that this specification embodiment providesFigure, includes the following steps:
S1800: the node in block chain network obtains money transfer transactions by external account of transferring accounts and is broadcast to other nodes.
I.e. node receives the money transfer transactions that client (having logged in external account of transferring accounts) constructs and send.
S1802: for each node in the block chain network, which passes through when executing the money transfer transactionsBlock chain virtual machine calls the business intelligence contract and according to the discrepancy checking command in the business intelligence contract, triggeringExecute the discrepancy check logic.
S1804: if check results be it is yes, which is executed in the business intelligence contract by block chain virtual machineUser's asset table modify logic.
In the framework of ether mill, each external account and each user are corresponded, the behavior reality of transferring accounts between two usersUpper is exactly the behavior of transferring accounts between two external accounts.
Assuming that external account A wants to transfer accounts to external account B, then, external account A can be constructed comprising transfer amounts firstWith the money transfer transactions of the account address of external account B, then, which can be broadcast to each section in block chain networkPoint.After each node is verified money transfer transactions, money transfer transactions are executed, external account B is written into transfer amounts.
It should be noted that the remaining sum that each node generally comprises verifying external account A to the verifying item of money transfer transactions isNo abundance, i.e., whether the remaining sum of external account A is greater than or equal to transfer amounts, if so, being verified.It means that existingIn the framework of some ether mills, if to transfer accounts, the account balance and transfer amounts for the people that transfers accounts can all be exposed to areaEach node in block chain network.
In embodiment 13, a kind of business demand is actually given, i.e., between the node in block chain networkA money transfer transactions, not expose transfer accounts user assets remaining sum and transfer amounts under the premise of, judgement transfer accounts user'sThe whether enough transfer of payment amount of money of assets remaining sum.
In order to meet this business demand, present invention employs a kind of new models of transferring accounts, and do not use block chain networkIn external account in remaining sum transferred accounts and receipt on account, but create business intelligence contract, in business intelligence contract againBuild the assets system of a user.In this assets system, there is no assets remaining sum concept, the assets that each user possessesIt is the equal of a kind of virtual object, user spends out an assets, this assets will disappear.
Specifically, the business intelligence contract is disposed in block chain network, the business intelligence contract is corresponding with userAsset table, user's asset table (correspond) corresponding assets for recording each external account with each user, forAny assets, the assets are the data comprising encrypting the amount of money, which obtained after encrypting to the amount of money of the assets's.
The following table 3 gives user's asset table with showing column.
External account 1Assets 1, assets 2
External account 2Assets 3, assets 4, assets 5
External account 3Assets 6
Table 3
For example, external account 1 is transferred accounts 120 yuan to external account 2, it is assumed that the amount of money of assets 1 is 100 yuan, the amount of money of assets 2It is 50 yuan, then external account 1 needs cost to fall oneself assets 1 and assets 2, then, assets 1 and assets 2 disappear, and produceAssets 7 (amount of money is 120 yuan) and assets 8 (amount of money is 30 yuan), external account 1 obtains assets 8, and external account 2 obtains assets 7.As it can be seen that assets 1+ assets 2 are actually this input transferred accounts, assets 7+ assets 8 are actually the output that this transfers accounts.ByAfter this pen is transferred accounts, table 3 will be updated the table 4 being as follows.
External account 1Assets 8
External account 2Assets 3, assets 4, assets 5, assets 7
External account 3Assets 6
Table 3
In this way, in the present invention, for the problem that a money transfer transactions, verifying remaining sum is converted into verifying input and outputThe problem of whether balancing.Since the amount of money of each assets is actually to encrypt, because being not exposed to block chain virtual machine, thisIt is meant that requiring block chain virtual machine when executing money transfer transactions, using homomorphic encryption algorithm (such as PedersenCommitment algorithm), whether the assets for verifying input are equal with the assets of output, if check results are yes, it is meant thatThis money transfer transactions is feasible (remaining sum for being equivalent to the people that illustrates to transfer accounts is sufficient).
For specifically embodiment, in the present embodiment 13, needs to be pre-configured with for block chain network, make:
It 1) include entering and leaving checking command, also, be deployed in block chain virtual machine pair in the instruction set of block chain virtual machineThe discrepancy check logic for Hash acquisition instruction of trading described in Ying Yu.
Wherein, the discrepancy check logic includes:, using homomorphic encryption algorithm, to verify this turn for any money transfer transactionsThe sum of the amount of money for the small change assets that the amount of money of the specified assets of transferring accounts of account transaction and the money transfer transactions are specified, if transfer accounts equal to thisThe sum of the amount of money of the specified each cost assets of transaction.
It should also be noted that, the money transfer transactions are actually that previously described business initiates transaction, only thisThe business at place is specially to encrypt transferred account service.
2) include the discrepancy checking command in the instruction set of intelligent contract compiler, compiled through the intelligent contract compilerIt include the discrepancy checking command in the business intelligence contract translated.
3) it is disposed in block chain network and is stated business intelligence contract.
The business intelligence contract is the intelligent contract of the function of transferring accounts for realizing hiding transfer amounts and assets remaining sum.
In step S1800, node actually refers to the corresponding node of the user that transfers accounts.External account of transferring accounts actually refers toThe external account that the user that transfers accounts is controlled.
Node obtains money transfer transactions by external account of transferring accounts, and the user that actually transfers accounts logs in client (or " moneyPacket "), it constructs money transfer transactions and is sent to node.
It include transfer accounts assets, small change assets and at least one cost assets in the money transfer transactions.Wherein, described at least oneA cost assets are actually to be input to this assets transferred accounts, and assets of transferring accounts are actually that this pen is transferred accounts with small change assetsThe assets of output.
In embodiment 13, after business intelligence contract described in block chain virtual machine call, the business intelligence can readIt bytecode in contract or binary code and can execute, when reading the discrepancy checking command in the business intelligence contract,It is equivalent to and specifies and need to carry out discrepancy verification operation at this time, therefore, block chain virtual machine can trigger execution deployment in advance at this timeIn local discrepancy check logic, to use homomorphic encryption algorithm, the amount of money and the small change of assets of transferring accounts described in verification are providedWhether the sum of amount of money of production is equal to the sum of the amount of money of each cost assets.
If check results be it is yes, illustrate that this money transfer transactions is feasible.In turn, block chain virtual machine needs to be implementedThis money transfer transactions modifies user's asset table according to money transfer transactions.The user's asset table for modifying user's asset table modifies logicIt is actually pre-written into business intelligence contract.It is external account of transferring accounts described in releasing that user's asset table, which modifies logic,With the corresponding relationship of each cost assets, the corresponding relationship of transfer accounts described in foundation external account and the small change assets, and receipts are establishedThe corresponding relationship of account external account and the assets of transferring accounts.
In addition, in practical applications, occurring following situation in order to prevent: certain malicious users when initiating money transfer transactions,Negative is set by the actual value for the assets of transferring accounts for including in money transfer transactions, other people assets are stolen in a manner of transferring accounts;WithAnd user is initiating money transfer transactions operation error, sets negative for the actual value for the small change assets for including in money transfer transactions,The amount of money of the practical assets produced of user is caused to be greater than the amount of money for assets of transferring accounts, the method that can use zero-knowledge proof is turningUnder the actual value of account assets and all sightless situation of the actual value of small change assets, verification transfer accounts assets actual value withWhether the actual value of small change assets falls within specified numberical range, and such as (0,264].If check results be it is yes, just eliminate withOn a possibility that happening.
Specifically, it in embodiment 13, can be pre-configured with further directed to block chain network, so that:
It 4) further include amount of money checking command in the instruction set of block chain virtual machine, also, also disposed in block chain virtual machineThere is the amount of money check logic corresponding to the amount of money checking command.
5) further include the amount of money checking command in the instruction set of the intelligent contract compiler, compiled through the intelligent contractIt translates in the business intelligence contract of device compiling also comprising the amount of money checking command.
It also needs to include the proof related data for realizing zero-knowledge proof based on this, in Client-initiated money transfer transactions(such as Bullet Proof, Borromean ring signatures).
Block chain virtual machine can trigger when reading the amount of money checking command in the business intelligence contract and execute localThe amount of money check logic disposed in advance, i.e., according to the proof related data, the amount of money for assets of transferring accounts described in verification is looked for describedWhether the amount of money of zero assets falls within specified numberical range.
In addition, can also include cost assets check logic in business intelligence contract, so that block in embodiment 13Chain virtual machine, can also be according to user's asset table when executing business intelligence contract, external account pair of transferring accounts described in verificationIt whether include each cost assets in the assets answered.If check results be it is yes, illustrate to transfer accounts user institute cost assets to be usedIt is one's own assets.
In addition, being directed to any assets, the data structure of the assets can also include characterizing the assets cost or non-costFirst state parameter.It can also include first state parameter interrelated logic in business intelligence contract, so as to block chain virtual machineWhen executing business intelligence contract, for each cost assets in money transfer transactions, the first state which includes is joinedNumber, verifies the whether non-cost of the cost assets.Also, the first state parameter interrelated logic further include: if be finally directed toThe result of the complete verification of the money transfer transactions is all, then, the first state parameter for including to the cost assets is repairedChange, so that modified first state parameter characterization cost assets cost.If finally for the money transfer transactionsHave in the result of complete verification any result be it is no, then money transfer transactions will fail, each cost assets not gone out by cost, fromIt need not so modify to first state parameter.
In addition, being directed to any assets, the data structure of the assets can also be present or absent including characterizing the assetsSecond state parameter.It can also include the second state parameter interrelated logic in business intelligence contract, so that block chain virtual machine existsWhen executing business intelligence contract, for each cost assets in the money transfer transactions, include according to the cost assets secondState parameter, verifying the cost assets whether there is.In this way, malicious user, which can be effectively prevented, fabricates not existing assets simultaneouslyIt is transferred accounts using imaginary assets.
It is further to note that if block chain virtual machine is according to the discrepancy checking command in the business intelligence contractIt is executed with the triggering of amount of money checking command and enters and leaves check logic and amount of money check logic, then, it is used in the process of implementation to countIt is usually stack transmitting according to transfer mode.Embodiment 14 below provides another side of transferring accounts based on block chain intelligence contractMethod (mode of precompile contract).
Embodiment 14
Figure 19 is a kind of transaction Hash acquisition methods based on block chain intelligence contract that this specification embodiment providesFlow diagram includes the following steps:
S1900: the node in block chain network obtains money transfer transactions by external account of transferring accounts and is broadcast to other nodes.
S1902: for each node in the block chain network, which passes through when executing the money transfer transactionsBlock chain virtual machine calls the business intelligence contract, and verifies intelligence according to the discrepancy in the business intelligence contractThe Contract ID of contract calls the discrepancy to verify intelligent contract.
S1904: the node executes the discrepancy according to the discrepancy checking command for entering and leaving and verifying in intelligent contract, triggeringCheck logic.
S1906: if check results be it is yes, which is executed in the business intelligence contract by block chain virtual machineUser's asset table modify logic.
In embodiment 14, need to be pre-configured with for block chain network, so that:
1) include transaction Hash acquisition instruction in the instruction set of block chain virtual machine, also, disposed in block chain virtual machineThere is the transaction Hash for corresponding to the transaction Hash acquisition instruction to obtain logic.
2) include the discrepancy checking command in the instruction set of intelligent contract compiler, compiled through the intelligent contract compilerThe Contract ID of intelligent contract is verified in the business intelligence contract translated comprising entering and leaving, it is preparatory portion that the discrepancy, which verifies intelligent contract,The intelligent contract being deployed in the block chain network.
3) it is disposed in block chain network and is stated business intelligence contract.
Embodiment 14 and the difference of embodiment 13 essentially consist in, in embodiment 12, block chain virtual machine callAfter the business intelligence contract, when reading the Contract ID for entering and leaving the intelligent contract of verification, it is equivalent to and specifies thisWhen need further to call the discrepancy to verify intelligent contract.Discrepancy described in block chain virtual machine call verifies intelligent contract,It can read the bytecode or binary code for entering and leaving and verifying in intelligent contract, when reading the discrepancy checking command, phaseWhen needing to be implemented discrepancy verification operation at this time in specifying, therefore, block chain virtual machine can trigger execution at this time and be deployed in advanceLocal discrepancy check logic.
That is, intelligent contract compiler is when compiling business intelligence contract, if it find that industry in embodiment 12Statement calling in intelligent contract of being engaged in enters and leaves verification operation, then will not be compiled as entering and leaving checking command for this section of statement, but compileAt the Contract ID for entering and leaving the intelligent contract of verification.In this way, block chain virtual machine is when calling business intelligence contract, meetingThe discrepancy is further called to verify intelligent contract.
Further, it in embodiment 14, needs to be pre-configured with for block chain network, so that:
It 4) further include amount of money checking command in the instruction set of block chain virtual machine, also, also disposed in block chain virtual machineThere is the amount of money check logic corresponding to the amount of money checking command.
5) further include the amount of money checking command in the instruction set of the intelligent contract compiler, compiled through the intelligent contractTranslate the Contract ID for also verifying intelligent contract in the business intelligence contract of device compiling comprising the amount of money, the amount of money verification intelligenceContract is the intelligent contract being deployed in the block chain network in advance.
In this way, for each node in the block chain network, the node is empty by block chain in embodiment 14Quasi- machine verifies the Contract ID of intelligent contract according to the amount of money in the business intelligence contract, the amount of money is called to verifyIntelligent contract;The node verifies the amount of money checking command in intelligent contract according to the amount of money, and triggering executes the amount of money verificationLogic, so as to according to the proof related data, whether the amount of money of the amount of money of assets of transferring accounts described in verification and the small change assetsFall within specified numberical range.
Furthermore it should be noted that in embodiment 14, the verification item of execution is consistent in embodiment 13, onlyBut, it is verified for entering and leaving verification with the amount of money, is (to enter and leave by calling precompile contract and verify intelligent contract and amount of money verificationIntelligent contract) mode carry out.
In embodiment 13 and embodiment 14, when having multiple for the verification item of money transfer transactions progress, work as wholeCheck results are all when being, block chain virtual machine can just execute user's asset table modification logic.
Figure 20 a is the associated check operation for the money transfer transactions corresponding to embodiment 13 that this specification embodiment providesDispose schematic diagram.As illustrated in fig. 20, first, the instruction set addition for block chain virtual machine enters and leaves checking command and the amount of money verifiesInstruction, meanwhile, deployment enters and leaves check logic and amount of money check logic in block chain virtual machine.Second, for intelligent contract compilingThe instruction set addition of device enters and leaves checking command and amount of money checking command.Third, by the business by intelligent contract compiler compilingIntelligent contract (comprising entering and leaving checking command and amount of money checking command) is deployed in block chain network.
Figure 20 b is the associated check operation for the money transfer transactions corresponding to embodiment 14 that this specification embodiment providesDispose schematic diagram.As shown in fig. 20b, first, the instruction set addition for block chain virtual machine enters and leaves checking command and the amount of money verifiesInstruction, meanwhile, deployment enters and leaves check logic and amount of money check logic in block chain virtual machine.Second, for intelligent contract compilingThe instruction set addition of device enters and leaves checking command and amount of money checking command.Third, by the business by intelligent contract compiler compilingIntelligent contract (Contract ID comprising entering and leaving the Contract ID and the intelligent contract of amount of money verification that verify intelligent contract) is deployed in areaIn block chain network.
More than, it is the explanation respectively to one~embodiment of embodiment 14.In fact, in practical applications, businessInitiating transaction specifically can be money transfer transactions, and in order to realize money transfer transactions, it may not only need to carry out associated check (as implementedThe every verification referred in example 13), it is also necessary to carry out BASE54 encoding operation, BASE54 decoding operate, RSA signature verifying behaviourWork, JSON processing operation, XML processing operation, transaction Hash obtain one of operation or a variety of.
That is, can by above-mentioned BASE64 coding method, BASE64 coding/decoding method, RSA signature verification method,JSON processing method, XML processing method and transaction one of Hash acquisition methods or it is a variety of be applied to embodiment 13 orIn transfer account method in embodiment 14, at this point, it is exactly money transfer transactions that business described previously, which initiates transaction,.
Furthermore it should be noted that in each embodiment of this specification, if business intelligence contract is not the blockUnique intelligence contract in chain network, then, business is initiated also to need to close comprising business intelligence in transaction (and money transfer transactions)Contract ID about, so that block chain virtual machine is according to the contract mark for including in business initiation transaction (and money transfer transactions)Know, calls corresponding business intelligence contract.
In addition, further including at least one in the instruction set of the block chain virtual machine to each embodiment in this manualA ether mill instruction, the instruction of ether mill are the instructions in the instruction set of ether mill virtual machine;For the block chain virtual machineThe each ether mill for including in instruction set instructs, and the correlation corresponding to ether mill instruction is deployed in the block chain virtual machineLogic.It further include the instruction of at least one ether mill in the instruction set of the intelligence contract compiler, the instruction of ether mill is ether millInstruction in the instruction set of virtual machine.That is, the block chain virtual machine in the present invention can be in ether mill virtual machineOn the basis of extension obtain, the intelligent contract compiler in the present invention can be on the basis of the intelligent contract compiler in ether millWhat upper extension obtained.
A kind of block catenary system that this specification provides, including block chain network;
It wherein, include entering and leaving checking command, also, be deployed in block chain virtual machine in the instruction set of block chain virtual machineCorresponding to the discrepancy check logic for entering and leaving checking command;It include that the discrepancy verifies in the instruction set of intelligent contract compilerIt instructs, includes the discrepancy checking command in the business intelligence contract through the intelligent contract compiler compiling;Block chain networkBusiness intelligence contract is stated in middle deployment, and the business intelligence contract is corresponding with user's asset table, and user's asset table is used forThe corresponding assets of each external account are recorded, for any assets, which is the data comprising encrypting the amount of money, the encryption amount of moneyIt is to be obtained after being encrypted to the amount of money of the assets;
Node in the block chain network obtains money transfer transactions by external account of transferring accounts and is broadcast to other nodes;The money transfer transactions include transfer accounts assets, small change assets and at least one cost assets;
Each node in the block chain network, by block chain virtual machine, is called when executing the money transfer transactionsThe business intelligence contract and according to the discrepancy checking command in the business intelligence contract, triggering, which executes discrepancys and verifies, patrolsVolume, transfer accounts to use homomorphic encryption algorithm, described in verification the sum of the amount of money of assets and the amount of money of the small change assets whether etc.In the sum of the amount of money of each cost assets;If check results be it is yes, by block chain virtual machine, execute the business intelligence contractIn user's asset table modify logic, to release the corresponding relationship of the transfer accounts external account and each cost assets, establish instituteThe corresponding relationship of transfer accounts external account and the small change assets is stated, and it is corresponding with the assets of transferring accounts to establish receipt on account external accountRelationship.
A kind of block catenary system that this specification provides, including block chain network;
It wherein, include entering and leaving checking command, also, be deployed in block chain virtual machine in the instruction set of block chain virtual machineCorresponding to the discrepancy check logic for entering and leaving checking command;It include that the discrepancy verifies in the instruction set of intelligent contract compilerIt instructs, the Contract ID comprising the intelligent contract of discrepancy verification in the business intelligence contract through the intelligent contract compiler compiling,It is the intelligent contract being deployed in the block chain network in advance that the discrepancy, which verifies intelligent contract,;It is deployed in block chain networkThe business intelligence contract, the business intelligence contract are corresponding with user's asset table, and user's asset table is each for recordingThe corresponding assets of external account, for any assets, which is the data comprising encrypting the amount of money, which is to the moneyWhat the amount of money of production obtained after being encrypted;
Node in the block chain network obtains money transfer transactions by external account of transferring accounts and is broadcast to other nodes;The money transfer transactions include transfer accounts assets, small change assets and at least one cost assets;
Each node in the block chain network, by block chain virtual machine, is called when executing the money transfer transactionsThe business intelligence contract, and according to the Contract ID of the intelligent contract of discrepancy verification in the business intelligence contract, it adjustsIntelligent contract is verified with the discrepancy;According to the discrepancy checking command for entering and leaving and verifying in intelligent contract, trigger described in executingCheck logic is entered and left, to use homomorphic encryption algorithm, transfer accounts described in the verification amount of money of assets and the amount of money of the small change assetsThe sum of whether be equal to each cost assets the sum of the amount of money;If check results be it is yes, by block chain virtual machine, execute the industryThe user's asset table being engaged in intelligent contract modifies logic, and to release, the external account of transferring accounts is corresponding with each cost assets to be closedSystem, the corresponding relationship of transfer accounts described in foundation external account and the small change assets, and establish receipt on account external account and transfer accounts with describedThe corresponding relationship of assets.
A kind of block catenary system that this specification provides, including block chain network;
Wherein, include BASE64 coded command in the instruction set of block chain virtual machine, also, disposed in block chain virtual machineThere is the BASE64 codimg logic corresponding to the BASE64 coded command;It include described in the instruction set of intelligent contract compilerBASE64 coded command refers to comprising BASE64 coding in the business intelligence contract through the intelligent contract compiler compilingIt enables;It is disposed in block chain network and is stated business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, according to the BASE64 coded command in the business intelligence contract,Triggering executes the BASE64 codimg logic, to perform the encoding operation to data to be encoded.
A kind of block catenary system that this specification provides, including block chain network;
Wherein, include BASE64 coded command in the instruction set of block chain virtual machine, also, disposed in block chain virtual machineThere is the BASE64 codimg logic corresponding to the BASE64 coded command;It include described in the instruction set of intelligent contract compilerBASE64 coded command includes the intellectual coded contract of BASE64 in the business intelligence contract through the intelligent contract compiler compilingContract ID, the intellectual coded contract of BASE64 is the intelligent contract being deployed in the block chain network in advance;It is describedIt is disposed in block chain network and is stated business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, encoded according to the BASE64 in the business intelligence contractThe Contract ID of intelligent contract calls the intellectual coded contract of the BASE64;By block chain virtual machine, according to the BASE64In intellectual coded contract, BASE64 coded command, triggering executes the BASE64 codimg logic, to carry out to data to be encodedEncoding operation.
A kind of block catenary system that this specification provides, including block chain network;
It wherein, include that BASE64 solves code instruction, also, disposes in block chain virtual machine in the instruction set of block chain virtual machineThere is the BASE64 decode logic for corresponding to BASE64 solution code instruction;It include described in the instruction set of intelligent contract compilerBASE64 solves code instruction, refers in the business intelligence contract through the intelligent contract compiler compiling comprising BASE64 decodingIt enables;It is disposed in block chain network and is stated business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, code instruction is solved according to the BASE64 in the business intelligence contract,Triggering executes the BASE64 decode logic, is decoded operation to treat decoding data.
A kind of block catenary system that this specification provides, including block chain network;
It wherein, include that BASE64 solves code instruction, also, disposes in block chain virtual machine in the instruction set of block chain virtual machineThere is the BASE64 decode logic for corresponding to BASE64 solution code instruction;It include described in the instruction set of intelligent contract compilerBASE64 solves code instruction, decodes intelligent contract comprising BASE64 in the business intelligence contract through the intelligent contract compiler compilingContract ID, it is the intelligent contract being deployed in the block chain network in advance that the BASE64, which decodes intelligent contract,;It is describedIt is disposed in block chain network and is stated business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, the node pass through block chain when executing the business initiation transactionVirtual machine calls the business intelligence contract;Through block chain virtual machine, according in the business intelligence contractBASE64 decodes the Contract ID of intelligent contract, and the BASE64 is called to decode intelligent contract;By block chain virtual machine, according toThe BASE64 is decoded in intelligent contract, and BASE64 solves code instruction, and triggering executes the BASE64 decode logic, to treat solutionCode data are decoded operation.
A kind of block catenary system that this specification provides, including block chain network;
It wherein, include RSA signature verifying instruction in the instruction set of block chain virtual machine, also, in the middle part of block chain virtual machineThere is the RSA signature verifying logic corresponding to RSA signature verifying instruction in administration;It include institute in the instruction set of intelligent contract compilerRSA signature verifying instruction is stated, is verified in the business intelligence contract through the intelligent contract compiler compiling comprising the RSA signatureInstruction;It is disposed in block chain network and is stated business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, referred to according to the RSA signature verifying in the business intelligence contractEnable, triggering executes the RSA signature verifying logic, carry out RSA signature verification operation to sign to business, with to business sign intoRow RSA signature verification operation.
A kind of block catenary system that this specification provides, including block chain network;
It wherein, include RSA signature verifying instruction in the instruction set of block chain virtual machine, also, in the middle part of block chain virtual machineThere is the RSA signature verifying logic corresponding to RSA signature verifying instruction in administration;It include institute in the instruction set of intelligent contract compilerRSA signature verifying instruction is stated, is verified in the business intelligence contract through the intelligent contract compiler compiling comprising the RSA signatureThe Contract ID of intelligent contract, it is the intelligence being deployed in the block chain network in advance that the RSA signature, which verifies intelligent contract,Contract;It is disposed in block chain network and is stated business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, verified according to the RSA signature in the business intelligence contractThe Contract ID of intelligent contract calls the RSA signature to verify intelligent contract;By block chain virtual machine, signed according to the RSAName verifies the RSA signature in intelligent contract and verifies instruction, and triggering executes the RSA signature verifying logic, with to business sign intoRow RSA signature verification operation carries out RSA signature verification operation to sign to business.
A kind of block catenary system that this specification provides, including block chain network;
Wherein, include JSON process instruction in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machineJSON corresponding to the JSON process instruction handles logic;It include that the JSON is handled in the instruction set of intelligent contract compilerIt instructs, includes the JSON process instruction in the business intelligence contract through the intelligent contract compiler compiling;Block chain networkBusiness intelligence contract is stated in middle deployment;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, according to the JSON process instruction in the business intelligence contract, touchingHair executes the JSON and handles logic, to carry out JSON processing operation to pending data.
A kind of block catenary system that this specification provides, including block chain network;
Wherein, include JSON process instruction in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machineJSON corresponding to the JSON process instruction handles logic;It include that the JSON is handled in the instruction set of intelligent contract compilerIt instructs, handles the Contract ID of intelligence contract in the business intelligence contract through the intelligent contract compiler compiling comprising JSON,It is the intelligent contract being deployed in the block chain network in advance that the JSON, which handles intelligent contract,;It is deployed in block chain networkThe JSON handles intelligent contract and the business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, intelligence is handled according to the JSON in the business intelligence contractThe Contract ID of energy contract calls the JSON to handle intelligent contract;By block chain virtual machine, intelligence is handled according to the JSONJSON process instruction in energy contract, triggering execute the JSON and handle logic, handle behaviour to carry out JSON to pending dataMake.
A kind of block catenary system that this specification provides, including block chain network;
Wherein, include XML process instruction in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machineXML corresponding to the XML process instruction handles logic;It include that XML processing refers in the instruction set of intelligent contract compilerIt enables, includes the XML process instruction in the business intelligence contract through the intelligent contract compiler compiling;In the middle part of block chain networkThere is the business intelligence contract in administration;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, according to the XML process instruction in the business intelligence contract, touchingHair executes the XML and handles logic, to carry out XML processing operation to pending data.
A kind of block catenary system that this specification provides, including block chain network;
Wherein, include XML process instruction in the instruction set of block chain virtual machine, also, be deployed in block chain virtual machineXML corresponding to the XML process instruction handles logic;It include that XML processing refers in the instruction set of intelligent contract compilerIt enables, handles the Contract ID of intelligent contract in the business intelligence contract through the intelligent contract compiler compiling comprising XML, it is describedThe intelligent contract of XML processing is the intelligent contract being deployed in the block chain network in advance;It disposes and is stated in block chain networkThe intelligent contract of XML processing and the business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, intelligence is handled according to the XML in the business intelligence contractThe Contract ID of contract calls the XML to handle intelligent contract;By block chain virtual machine, intelligence is handled according to the XML and is closedXML process instruction in about, triggering execute the XML and handle logic, to carry out XML processing operation to pending data.
A kind of block catenary system that this specification provides, including block chain network;
It wherein, include transaction Hash acquisition instruction in the instruction set of block chain virtual machine, also, in the middle part of block chain virtual machineAdministration has the transaction Hash corresponding to the transaction Hash acquisition instruction to obtain logic;Include in the instruction set of intelligent contract compilerThe transaction Hash acquisition instruction includes the transaction Hash in the business intelligence contract through the intelligent contract compiler compilingAcquisition instruction;It is disposed in block chain network and is stated business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, referred to according to the transaction Hash acquisition in the business intelligence contractIt enables, triggering executes the transaction Hash and obtains logic, to obtain the transaction Hash that the business initiates transaction.
A kind of block catenary system that this specification provides, including block chain network;
It wherein, include transaction Hash acquisition instruction in the instruction set of block chain virtual machine, also, in the middle part of block chain virtual machineAdministration has the transaction Hash corresponding to the transaction Hash acquisition instruction to obtain logic;Include in the instruction set of intelligent contract compilerThe transaction Hash acquisition instruction is obtained comprising transaction Hash in the business intelligence contract through the intelligent contract compiler compilingThe Contract ID of intelligent contract, it is the intelligence being deployed in the block chain network in advance that the transaction Hash, which obtains intelligent contract,Contract;It is disposed in block chain network and is stated the transaction intelligent contract of Hash acquisition and the business intelligence contract;
Node in the block chain network, acquisition business are initiated to trade and are broadcast to other nodes;
Each node in the block chain network, when executing the business and initiating transaction, by block chain virtual machine,Call the business intelligence contract;By block chain virtual machine, obtained according to the transaction Hash in the business intelligence contractThe Contract ID of intelligent contract is taken, the transaction Hash is called to obtain intelligent contract;By block chain virtual machine, according to the friendshipEasy Hash obtains the transaction Hash acquisition instruction in intelligent contract, and triggering executes the transaction Hash and obtains logic, to obtainState the transaction Hash that business initiates transaction.
Figure 21 shows a kind of structural schematic diagram of block catenary system provided by this specification embodiment.
This specification also provides a kind of computer equipment, includes at least memory, processor and storage on a memoryAnd the computer program that can be run on a processor, wherein processor realizes the side of embodiments herein when executing described programThe function of method in method and each embodiment after the combination of at least two embodiments.
Figure 22 shows one kind provided by this specification embodiment and more specifically calculates device hardware structural schematic diagram,The equipment may include: processor 2210, memory 2220, input/output interface 2230, communication interface 2240 and bus2250.Wherein processor 2210, memory 2220, input/output interface 2230 and communication interface 2240 are real by bus 2250The now communication connection inside equipment each other.
Processor 2210 can use general CPU (Central Processing Unit, central processing unit), micro- placeReason device, application specific integrated circuit (Application Specific Integrated Circuit, ASIC) or oneOr the modes such as multiple integrated circuits are realized, for executing relative program, to realize technical side provided by this specification embodimentCase.
Memory 2220 can use ROM (Read Only Memory, read-only memory), RAM (Random AccessMemory, random access memory), static storage device, the forms such as dynamic memory realize.Memory 2220 can storeOperating system and other applications are realizing technical solution provided by this specification embodiment by software or firmwareWhen, relevant program code is stored in memory 2220, and execution is called by processor 2210.
Input/output interface 2230 is for connecting input/output module, to realize information input and output.Input and output/Module can be used as component Configuration (not shown) in a device, can also be external in equipment to provide corresponding function.WhereinInput equipment may include keyboard, mouse, touch screen, microphone, various kinds of sensors etc., output equipment may include display,Loudspeaker, vibrator, indicator light etc..
Communication interface 2240 is used for connection communication module (not shown), to realize the communication of this equipment and other equipmentInteraction.Wherein communication module can be realized by wired mode (such as USB, cable etc.) and be communicated, can also be wirelessly(such as mobile network, WIFI, bluetooth etc.) realizes communication.
Bus 2250 include an access, equipment various components (such as 2210 memory 2220 of processor, input/it is defeatedOutgoing interface 2230 and communication interface 2240) between transmit information.
It should be noted that although above equipment illustrates only processor 2210, memory 2220, input/output interface2230, communication interface 2240 and bus 2250, but in the specific implementation process, which can also include realizing normal fortuneOther assemblies necessary to row.In addition, it will be appreciated by those skilled in the art that, it can also be only comprising real in above equipmentComponent necessary to existing this specification example scheme, without including all components shown in figure.
This specification embodiment also provides a kind of computer readable storage medium, is stored thereon with computer program, the journeyThe side in the method and each embodiment of embodiments herein after the combination of at least two embodiments is realized when sequence is executed by processorThe function of method.
Computer-readable medium includes permanent and non-permanent, removable and non-removable media can be by any methodOr technology come realize information store.Information can be computer readable instructions, data structure, the module of program or other data.The example of the storage medium of computer includes, but are not limited to phase change memory (PRAM), static random access memory (SRAM), movesState random access memory (DRAM), other kinds of random access memory (RAM), read-only memory (ROM), electric erasableProgrammable read only memory (EEPROM), flash memory or other memory techniques, read-only disc read only memory (CD-ROM) (CD-ROM),Digital versatile disc (DVD) or other optical storage, magnetic cassettes, tape magnetic disk storage or other magnetic storage devicesOr any other non-transmission medium, can be used for storage can be accessed by a computing device information.As defined in this article, it calculatesMachine readable medium does not include temporary computer readable media (transitory media), such as the data-signal and carrier wave of modulation.
As seen through the above description of the embodiments, those skilled in the art can be understood that this specificationEmbodiment can be realized by means of software and necessary general hardware platform.Based on this understanding, this specification is implementedSubstantially the part that contributes to existing technology can be embodied in the form of software products the technical solution of example in other words,The computer software product can store in storage medium, such as ROM/RAM, magnetic disk, CD, including some instructions are to makeIt is each to obtain computer equipment (can be personal computer, server or the network equipment etc.) execution this specification embodimentMethod described in certain parts of a embodiment or embodiment.
System, method, module or the unit that above-described embodiment illustrates can specifically realize by computer chip or entity,Or it is realized by the product with certain function.A kind of typically to realize that equipment is computer, the concrete form of computer canTo be personal computer, laptop computer, cellular phone, camera phone, smart phone, personal digital assistant, media playIn device, navigation equipment, E-mail receiver/send equipment, game console, tablet computer, wearable device or these equipmentThe combination of any several equipment.
All the embodiments in this specification are described in a progressive manner, same and similar portion between each embodimentDividing may refer to each other, and each embodiment focuses on the differences from other embodiments.Especially for device andFor apparatus embodiments, since it is substantially similar to the method embodiment, so describing fairly simple, related place is referring to methodThe part of embodiment illustrates.Embodiment of the method described above is only schematical, wherein described be used as separation unitThe module that part illustrates may or may not be physically separated, can be when implementing this specification example schemeThe function of each module is realized in the same or multiple software and or hardware.It can also select according to the actual needs thereinSome or all of the modules achieves the purpose of the solution of this embodiment.Those of ordinary skill in the art are not making the creative laborIn the case where, it can it understands and implements.
The above is only the specific embodiment of this specification embodiment, it is noted that for the general of the artFor logical technical staff, under the premise of not departing from this specification embodiment principle, several improvements and modifications can also be made, thisA little improvements and modifications also should be regarded as the protection scope of this specification embodiment.

Claims (21)

  1. It wherein, include entering and leaving checking command, also, be deployed with correspondence in block chain virtual machine in the instruction set of block chain virtual machineIn the discrepancy check logic for entering and leaving checking command;It include that discrepancy verification refers in the instruction set of intelligent contract compilerIt enables, includes the discrepancy checking command in the business intelligence contract through the intelligent contract compiler compiling;In block chain networkIt is deployed with the business intelligence contract, the business intelligence contract is corresponding with user's asset table, and user's asset table is for rememberingThe corresponding assets of each external account are recorded, for any assets, which is the data comprising encrypting the amount of money, which isIt is obtained after being encrypted to the amount of money of the assets;
    Each node in the block chain network, when executing the money transfer transactions, by block chain virtual machine, described in callingBusiness intelligence contract and according to the discrepancy checking command in the business intelligence contract, triggering executes the discrepancy check logic,To use homomorphic encryption algorithm, it is each whether transfer accounts described in verification the sum of the amount of money of assets and the amount of money of the small change assets are equal toThe sum of the amount of money of cost assets;If check results be it is yes, by block chain virtual machine, execute in the business intelligence contractUser's asset table modifies logic, to release the corresponding relationship of the transfer accounts external account and each cost assets, establishes described turnThe corresponding relationship of account external account and the small change assets, and establish receipt on account external account pass corresponding with the assets of transferring accountsSystem.
  2. It wherein, include entering and leaving checking command, also, be deployed with correspondence in block chain virtual machine in the instruction set of block chain virtual machineIn the discrepancy check logic for entering and leaving checking command;It include that discrepancy verification refers in the instruction set of intelligent contract compilerIt enables, verifies the Contract ID of intelligent contract, institute in the business intelligence contract through the intelligent contract compiler compiling comprising entering and leavingStating discrepancy and verifying intelligent contract is the intelligent contract being deployed in the block chain network in advance;It is disposed in block chain networkBusiness intelligence contract is stated, the business intelligence contract is corresponding with user's asset table, and user's asset table is each outer for recordingThe corresponding assets of portion's account, for any assets, which is the data comprising encrypting the amount of money, which is to the assetsThe amount of money encrypted after obtain;
    Each node in the block chain network, when executing the money transfer transactions, by block chain virtual machine, described in callingBusiness intelligence contract, and according to the Contract ID of the intelligent contract of discrepancy verification in the business intelligence contract, call instituteIt states discrepancy and verifies intelligent contract;According to the discrepancy checking command for entering and leaving and verifying in intelligent contract, triggering executes the discrepancyCheck logic, to use homomorphic encryption algorithm, transfer accounts described in the verification amount of money of assets and the sum of the amount of money of the small change assetsWhether the amount of money the sum of of each cost assets is equal to;If check results be it is yes, by block chain virtual machine, execute the business intelligenceUser's asset table in energy contract modifies logic, to release the corresponding relationship of the transfer accounts external account and each cost assets,It transfers accounts described in foundation the corresponding relationship of external account and the small change assets, and establishes receipt on account external account and the assets of transferring accountsCorresponding relationship.
CN201811517585.9A2018-12-122018-12-12Transfer method and system based on block chain intelligent contractActiveCN110009321B (en)

Priority Applications (3)

Application NumberPriority DateFiling DateTitle
CN201811517585.9ACN110009321B (en)2018-12-122018-12-12Transfer method and system based on block chain intelligent contract
TW108134610ATWI719651B (en)2018-12-122019-09-25 Transfer method and system based on blockchain smart contract
PCT/CN2019/119086WO2020119393A1 (en)2018-12-122019-11-18Account transfer method and system based on blockchain smart contract

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201811517585.9ACN110009321B (en)2018-12-122018-12-12Transfer method and system based on block chain intelligent contract

Publications (2)

Publication NumberPublication Date
CN110009321Atrue CN110009321A (en)2019-07-12
CN110009321B CN110009321B (en)2020-08-11

Family

ID=67165144

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201811517585.9AActiveCN110009321B (en)2018-12-122018-12-12Transfer method and system based on block chain intelligent contract

Country Status (3)

CountryLink
CN (1)CN110009321B (en)
TW (1)TWI719651B (en)
WO (1)WO2020119393A1 (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN110597916A (en)*2019-09-212019-12-20腾讯科技(深圳)有限公司Data processing method and device based on block chain, storage medium and terminal
CN110992021A (en)*2019-11-192020-04-10支付宝(杭州)信息技术有限公司Intelligent contract-based fund management method, device and equipment
CN111222841A (en)*2019-11-262020-06-02腾讯科技(深圳)有限公司Block chain-based data distribution method and equipment and storage medium thereof
WO2020119393A1 (en)*2018-12-122020-06-18阿里巴巴集团控股有限公司Account transfer method and system based on blockchain smart contract
CN111381938A (en)*2020-05-292020-07-07支付宝(杭州)信息技术有限公司Method and system for executing intelligent contracts in block chain based on basic instruction set
CN111738724A (en)*2020-07-312020-10-02支付宝(杭州)信息技术有限公司Cross-border resource transfer authenticity auditing method and device, and electronic equipment
CN111800252A (en)*2020-07-222020-10-20深圳壹账通智能科技有限公司Information auditing method and device based on block chain and computer equipment
CN111835929A (en)*2020-07-142020-10-27中国联合网络通信集团有限公司 Blockchain-based call charge transaction method and system
CN112037062A (en)*2020-08-312020-12-04成都质数斯达克科技有限公司Transaction consensus method, device, electronic equipment and readable storage medium
CN114553515A (en)*2022-02-172022-05-27支付宝(杭州)信息技术有限公司Block chain based NFT asset inspection method, service processing method and hardware

Citations (6)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN103279358B (en)*2013-06-082016-04-27北京首钢自动化信息技术有限公司A kind of explanation type Service Component dynamic fixing method of Industry-oriented application
US20180197155A1 (en)*2016-12-122018-07-12Topl, LlcMethod and Apparatus for Processing Mobile Payment Using Blockchain Techniques
CN108282459A (en)*2017-12-182018-07-13中国银联股份有限公司Data transferring method based on intelligent contract and system
CN108694575A (en)*2018-06-132018-10-23深圳前海微众银行股份有限公司Verification method of transferring accounts, device and storage medium based on block chain
CN108711105A (en)*2018-05-162018-10-26四川吉鼎科技有限公司A kind of Secure Transaction verification method and system based on block chain
CN108764875A (en)*2018-05-172018-11-06深圳前海微众银行股份有限公司Transfer account method, device, system and the computer readable storage medium of block chain

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US10521775B2 (en)*2016-04-182019-12-31R3 Ltd.Secure processing of electronic transactions by a decentralized, distributed ledger system
CN107678865A (en)*2017-09-202018-02-09中国银行股份有限公司The verification method and system of block chain based on transaction packet
CN107833060B (en)*2017-11-132020-12-25中国银行股份有限公司Verification method and system for intelligent contract transaction in block chain
CN108694589A (en)*2018-05-082018-10-23杭州佑他科技有限公司A kind of asset monitoring method based on block chain
CN108664650B (en)*2018-05-172020-05-22百度在线网络技术(北京)有限公司Transaction processing method, device, equipment and storage medium of block chain network
CN110009321B (en)*2018-12-122020-08-11阿里巴巴集团控股有限公司Transfer method and system based on block chain intelligent contract

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN103279358B (en)*2013-06-082016-04-27北京首钢自动化信息技术有限公司A kind of explanation type Service Component dynamic fixing method of Industry-oriented application
US20180197155A1 (en)*2016-12-122018-07-12Topl, LlcMethod and Apparatus for Processing Mobile Payment Using Blockchain Techniques
CN108282459A (en)*2017-12-182018-07-13中国银联股份有限公司Data transferring method based on intelligent contract and system
CN108711105A (en)*2018-05-162018-10-26四川吉鼎科技有限公司A kind of Secure Transaction verification method and system based on block chain
CN108764875A (en)*2018-05-172018-11-06深圳前海微众银行股份有限公司Transfer account method, device, system and the computer readable storage medium of block chain
CN108694575A (en)*2018-06-132018-10-23深圳前海微众银行股份有限公司Verification method of transferring accounts, device and storage medium based on block chain

Cited By (15)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
WO2020119393A1 (en)*2018-12-122020-06-18阿里巴巴集团控股有限公司Account transfer method and system based on blockchain smart contract
CN110597916B (en)*2019-09-212021-03-26腾讯科技(深圳)有限公司Data processing method and device based on block chain, storage medium and terminal
CN110597916A (en)*2019-09-212019-12-20腾讯科技(深圳)有限公司Data processing method and device based on block chain, storage medium and terminal
CN110992021A (en)*2019-11-192020-04-10支付宝(杭州)信息技术有限公司Intelligent contract-based fund management method, device and equipment
CN111222841B (en)*2019-11-262024-04-12腾讯科技(深圳)有限公司Block chain-based data distribution method and equipment and storage medium thereof
CN111222841A (en)*2019-11-262020-06-02腾讯科技(深圳)有限公司Block chain-based data distribution method and equipment and storage medium thereof
CN111381938A (en)*2020-05-292020-07-07支付宝(杭州)信息技术有限公司Method and system for executing intelligent contracts in block chain based on basic instruction set
CN111835929A (en)*2020-07-142020-10-27中国联合网络通信集团有限公司 Blockchain-based call charge transaction method and system
CN111835929B (en)*2020-07-142022-02-25中国联合网络通信集团有限公司 Blockchain-based call charge transaction method and system
CN111800252A (en)*2020-07-222020-10-20深圳壹账通智能科技有限公司Information auditing method and device based on block chain and computer equipment
CN111738724A (en)*2020-07-312020-10-02支付宝(杭州)信息技术有限公司Cross-border resource transfer authenticity auditing method and device, and electronic equipment
CN112037062A (en)*2020-08-312020-12-04成都质数斯达克科技有限公司Transaction consensus method, device, electronic equipment and readable storage medium
CN112037062B (en)*2020-08-312023-08-25成都质数斯达克科技有限公司Transaction consensus method, device, electronic equipment and readable storage medium
CN114553515A (en)*2022-02-172022-05-27支付宝(杭州)信息技术有限公司Block chain based NFT asset inspection method, service processing method and hardware
CN114553515B (en)*2022-02-172024-05-17支付宝(杭州)信息技术有限公司Block chain-based NFT asset checking method, business processing method and hardware

Also Published As

Publication numberPublication date
WO2020119393A1 (en)2020-06-18
TW202027530A (en)2020-07-16
TWI719651B (en)2021-02-21
CN110009321B (en)2020-08-11

Similar Documents

PublicationPublication DateTitle
CN110009321A (en)A kind of transfer account method and system based on block chain intelligence contract
CN110048846A (en)A kind of signature verification method and system based on block chain intelligence contract
CN109933404A (en)A kind of decoding method and system based on block chain intelligence contract
CN110046023B (en) A data processing method and system based on blockchain smart contract
TWI716116B (en) Transaction hash acquisition method and system based on blockchain smart contract
CN109919586B (en)Multi-layer secure mobile transaction enabled platform
CN110046991A (en)A kind of data processing method and system based on block chain intelligence contract
CN112200569B (en)Digital seal using method and device based on block chain and electronic equipment
CN112101938B (en)Digital seal using method and device based on block chain and electronic equipment
CN109313685A (en) Encryption application of blockchain system
CN110162523A (en)Date storage method, system, device and equipment
CN108600250A (en)Authentication method
CN113221165A (en)User element authentication method and device based on block chain
CN109213468A (en)A kind of speech playing method and device
CN108737402A (en)Mobile terminal safety means of defence and device
CN109922216A (en)A kind of recharging service processing method and processing device, storage medium
HK40010685B (en)Account transfer method and system based on blockchain smart contract
HK40010685A (en)Account transfer method and system based on blockchain smart contract
HK40011373A (en)Signature verification method and system based on blockchain smart contract
HK40011373B (en)Signature verification method and system based on blockchain smart contract
CN109190352A (en)A kind of authorization text Accuracy Verification method and apparatus
Naresh et al.Metaverse-A Forthcoming Lifestyle
YoussefzadehFuture of Payment Platforms
Chaumette et al.Towards an interoperability evaluation process for mobile contactless city service
CN113205323A (en)Red packet circulation method and device based on block chain

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
REGReference to a national code

Ref country code:HK

Ref legal event code:DE

Ref document number:40010685

Country of ref document:HK

GR01Patent grant
GR01Patent grant
TR01Transfer of patent right
TR01Transfer of patent right

Effective date of registration:20201013

Address after:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Patentee after:Innovative advanced technology Co.,Ltd.

Address before:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Patentee before:Advanced innovation technology Co.,Ltd.

Effective date of registration:20201013

Address after:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Patentee after:Advanced innovation technology Co.,Ltd.

Address before:A four-storey 847 mailbox in Grand Cayman Capital Building, British Cayman Islands

Patentee before:Alibaba Group Holding Ltd.

TR01Transfer of patent right
TR01Transfer of patent right

Effective date of registration:20240925

Address after:Guohao Times City # 20-01, 128 Meizhi Road, Singapore

Patentee after:Ant Chain Technology Co.,Ltd.

Country or region after:Singapore

Address before:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Patentee before:Innovative advanced technology Co.,Ltd.

Country or region before:Cayman Islands


[8]ページ先頭

©2009-2025 Movatter.jp