CN111861482A - Block chain account checking method and system - Google Patents

Block chain account checking method and system Download PDF

Info

Publication number
CN111861482A
CN111861482A CN202011003500.2A CN202011003500A CN111861482A CN 111861482 A CN111861482 A CN 111861482A CN 202011003500 A CN202011003500 A CN 202011003500A CN 111861482 A CN111861482 A CN 111861482A
Authority
CN
China
Prior art keywords
reconciliation
account
transaction
hash value
contract
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202011003500.2A
Other languages
Chinese (zh)
Other versions
CN111861482B (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.)
Alipay Hangzhou Information Technology Co Ltd
Original Assignee
Alipay Hangzhou Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alipay Hangzhou Information Technology Co Ltd filed Critical Alipay Hangzhou Information Technology Co Ltd
Priority to CN202011003500.2A priority Critical patent/CN111861482B/en
Publication of CN111861482A publication Critical patent/CN111861482A/en
Application granted granted Critical
Publication of CN111861482B publication Critical patent/CN111861482B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q20/00Payment architectures, schemes or protocols
    • G06Q20/38Payment protocols; Details thereof
    • G06Q20/389Keeping log of transactions for guaranteeing non-repudiation of a transaction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange

Landscapes

  • Business, Economics & Management (AREA)
  • Accounting & Taxation (AREA)
  • Finance (AREA)
  • Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • Physics & Mathematics (AREA)
  • Strategic Management (AREA)
  • Theoretical Computer Science (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Technology Law (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)

Abstract

The embodiment of the specification discloses a block chain reconciliation method and a system. The method is performed by a block link point, comprising: receiving a reconciliation transaction from a first reconciliation party, the reconciliation transaction comprising an account identification and a hash value of first account data of the first reconciliation party; inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification; if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data; and determining a reconciliation result based on the query result or the comparison result.

Description

Block chain account checking method and system
Technical Field
The present disclosure relates to the field of information technologies, and in particular, to a method and a system for checking account of a blockchain.
Background
The problems of low efficiency and untimely account checking exist in manual account checking. In addition, there is a risk that privacy is leaked in the transmission of account data, for example, the reconciliation File is transmitted by an FTP (File Transfer Protocol) method.
At present, it is desirable to provide an account checking scheme which is efficient, timely and capable of avoiding privacy disclosure.
Disclosure of Invention
One of the embodiments of the present disclosure provides a blockchain reconciliation method, where the method is performed by a blockchain link point, and includes: receiving a reconciliation transaction from a first reconciliation party, the reconciliation transaction comprising an account identification and a hash value of first account data of the first reconciliation party; inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification; if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data; and determining a reconciliation result based on the query result or the comparison result.
One of the embodiments of the present specification provides a blockchain reconciliation system, where the system is implemented on a blockchain node, and includes; the account checking system comprises a receiving module, a checking module and a processing module, wherein the receiving module is used for receiving a checking transaction from a first checking party, and the checking transaction comprises an account identification and a hash value of first account data of the first checking party; the account checking module is used for: inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification; if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data; and determining a reconciliation result based on the query result or the comparison result.
One of the embodiments of the present disclosure provides a blockchain reconciliation method, where the method is performed by a blockchain link point, and includes: receiving a reconciliation transaction from a first reconciliation party, the reconciliation transaction comprising an account identification and a hash value of first account data of the first reconciliation party; judging whether the account checking transaction meets an account checking constraint condition, if so, executing: inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification; if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data; and determining a reconciliation result based on the query result or the comparison result.
One of the embodiments of the present specification provides a blockchain reconciliation system, where the system is implemented on a blockchain node, and includes a receiving module and a reconciliation module; the receiving module is used for receiving a reconciliation transaction from a first reconciliation party, wherein the reconciliation transaction comprises an account identification and a hash value of first account data of the first reconciliation party; the account checking module is used for judging whether the account checking transaction meets an account checking constraint condition or not, and if so, executing: inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification; if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data; and determining a reconciliation result based on the query result or the comparison result.
One of the embodiments of the present specification provides a blockchain reconciliation apparatus, which includes a processor and a storage device, where the storage device is configured to store instructions, and when the processor executes the instructions, the blockchain reconciliation method according to any embodiment of the present specification is implemented.
Drawings
The present description will be further explained by way of exemplary embodiments, which will be described in detail by way of the accompanying drawings. These embodiments are not intended to be limiting, and in these embodiments like numerals are used to indicate like structures, wherein:
FIG. 1 is a schematic diagram of an application scenario of a blockchain system according to some embodiments of the present disclosure;
FIG. 2 is an interaction diagram of a reconciliation flow shown in accordance with some embodiments of the present description;
fig. 3 is an exemplary block diagram of a blockchain reconciliation system in accordance with some embodiments of the present description.
Detailed Description
In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings used in the description of the embodiments will be briefly described below. It is obvious that the drawings in the following description are only examples or embodiments of the present description, and that for a person skilled in the art, the present description can also be applied to other similar scenarios on the basis of these drawings without inventive effort. Unless otherwise apparent from the context, or otherwise indicated, like reference numbers in the figures refer to the same structure or operation.
It should be understood that "system", "device", "unit" and/or "module" as used herein is a method for distinguishing different components, elements, parts, portions or assemblies at different levels. However, other words may be substituted by other expressions if they accomplish the same purpose.
As used in this specification, the terms "a", "an" and/or "the" are not intended to be inclusive of the singular, but rather are intended to be inclusive of the plural, unless the context clearly dictates otherwise. In general, the terms "comprises" and "comprising" merely indicate that steps and elements are included which are explicitly identified, that the steps and elements do not form an exclusive list, and that a method or apparatus may include other steps or elements.
Flow charts are used in this description to illustrate operations performed by a system according to embodiments of the present description. It should be understood that the preceding or following operations are not necessarily performed in the exact order in which they are performed. Rather, the various steps may be processed in reverse order or simultaneously. Meanwhile, other operations may be added to the processes, or a certain step or several steps of operations may be removed from the processes.
Fig. 1 is a schematic diagram of an application scenario of a blockchain system according to some embodiments of the present disclosure. As shown in fig. 1, the blockchain system 100 may include a blockchain network 110, a user terminal 120, and a network 130.
Blockchain network 110 may include a plurality of blockchain nodes, such as node 110-1, node 110-2, node 110-3.
In the blockchain system 100, the desired code may be executed through transactional triggering. Any blockchain node (hereinafter referred to as a node) may generate a transaction that triggers execution of a specific code and broadcast the transaction in blockchain network 110, i.e., initiate a transaction, so that each node executes (invokes) the code after receiving the transaction (which may also be considered as execution of the transaction). For example, to solve the reconciliation problem, a code containing a reconciliation flow may be written in the blockchain system 100, and then a node of any reconciliation party may invoke the code containing the reconciliation flow after receiving the reconciliation transaction through broadcasting the reconciliation transaction, which is more efficient and timely compared with manual reconciliation. In some embodiments, nodes may process multiple transactions in parallel to further increase processing efficiency. It is understood that the reconciliation transaction may contain information required for reconciliation, such as an identification of the reconciliation party initiating the reconciliation transaction, a hash value of account data of the reconciliation party initiating the reconciliation transaction, an identification of the account data to be reconciled, and the like.
It is worth noting that the blockchain has a public transparency feature, so that any node can obtain the transaction broadcasted in the blockchain network 110, and if the account data of the account checking party is put into the account checking transaction in a clear text form, there may be a risk of disclosure. In view of this, the account data of the account checking party is put into the account checking transaction in a hash form, and the comparison of the account data (i.e. account checking) can be realized on the premise that the account data in a plaintext form is not exposed.
To prove the origin and integrity of the transaction, the transaction may include a digital signature generated over the transaction contents (as a signed message) using the private key of the transaction initiator. In this manner, a node receiving a transaction can confirm the origin of the transaction and whether the transaction has been tampered with by verifying the digital signature.
The consensus mechanism is an essential component of the normal operation of the blockchain system, and is used to ensure that the blockchain data stored in each node is consistent. A plurality of nodes may agree on operations to receive (input of corresponding code), generate (output of corresponding code or intermediate result), and/or perform by running a consensus protocol, and nodes participating in consensus may be referred to as consensus nodes. For example, multiple consensus nodes receiving a reconciliation transaction may agree on the resulting reconciliation result by running a consensus protocol. As another example, for multiple transactions involved in a new block, each consensus node may agree on an order of execution for the multiple transactions by running a consensus protocol.
Blockchain data (also referred to as on-chain data) may include writes of blockchain data, also referred to as uplinks, by common identification of blockchain data and state data (also referred to as global state or world state). Wherein the block data comprises continuously generated and time-sequentially linked blocks, and each common node can uplink a new block by running a common protocol. The consensus pass means that each consensus node can write the same new block into the block data. For example only, in some embodiments, the condition that the consensus passes includes that more than a predetermined percentage (e.g., 2/3) of the consensus nodes agree to uplink the new block. The status data may include status variables associated with each account, such as the balance of an external account controlled by an individual, organization, or, as another example, the contract status of a contract account.
In some embodiments, code that the transaction triggers execution may be deployed into the blockchain system 100 through intelligent contract techniques. A developer may write code that translates the code into a machine-executable form (e.g., bytecode), and the nodes may generate intelligent contract deployment (creation) transactions and initiate broadcasts in blockchain network 110 to enable the respective consensus nodes to chain up machine-executable code (i.e., intelligent contracts), i.e., deploy intelligent contracts. It will be appreciated that the smart contract deployment transaction may include a smart contract to be deployed.
After the intelligent contract is linked up, any (consensus) node may invoke the intelligent contract in the local blockchain data, and the invocation of the intelligent contract may be triggered by the intelligent contract invocation transaction, that is, the consensus node invokes the corresponding intelligent contract in the local blockchain data after receiving the intelligent contract invocation transaction broadcasted in the blockchain network 110. In some embodiments, each smart contract may correspond to an account (which may be referred to as a contract account), which may have its identity (i.e., account address) similar to an external account controlled by an individual, organization. For any intelligent contract, the consensus node may access a contract store of the intelligent contract through an address of a contract account, where the contract store includes contract code (machine executable form) and contract state. The contract state in the contract store includes state variables of the intelligent contract, such as the version number of the intelligent contract. For example, the intelligent contract invocation transaction may include the address of the intelligent contract to be invoked, so that the consensus node may invoke the corresponding intelligent contract according to the contract address in the transaction.
It is understood that reconciliation may also be achieved through intelligent contract techniques. First, an intelligent contract (hereinafter referred to as a tie-out contract) containing a tie-out procedure may be deployed in the blockchain system 100. Without exposing account data in plaintext form, the basic function of the reconciliation contract may include comparing hash values of account data of both reconciliation parties to obtain a reconciliation result.
In some embodiments, the reconciliation contract may include reconciliation contract information, and due to the transparent nature of blockchain disclosure, the reconciliation parties may obtain the reconciliation contract information in the reconciliation contract from blockchain data and may be consciously compliant with the contract.
For example, the reconciliation contract information may indicate a hash function used by both reconciling parties and/or a format and an order of attributes of the account data. Attributes of the account data may include, among other things, time, amount, item Identification (ID), and the like. Taking the date of 2020, 8, 6 as an example, the date may be recorded as any one of "2020-8-6", "2020-08-06", "2020/8/6", "2020/08/06", "8-6-2020", "08-06-2020", "8/6/2020", "08/06/2020", and the like, and both reconciling parties need to convert the date in the account data into the same format. In addition, formats and sequences of all attributes of the hash function and/or the account data which are commonly used can be agreed between the account checking parties in a manual communication mode.
It should be noted that even if the account data of the reconciliation parties are consistent, if the format and the sequence of the hash function and the attribute of the account data adopted by the reconciliation parties are different, the input of the hash function is different, and further the output of the hash function is different. Accordingly, originally, the account data of both reconciliation parties are consistent, but a collation result indicating that the account data of both reconciliation parties are inconsistent is produced.
In some embodiments, the Hash function employed by the two reconciling parties may be determined based on any one of MD (Message-Digest), SM3 (domestic Hash Algorithm), SHA (Secure Hash Algorithm), and the like.
In some embodiments, reconciliation constraint information (or, a reconciliation constraint) may be included in the reconciliation contract, i.e., the reconciliation may be performed only if the reconciliation constraint is invoked if the reconciliation constraint is satisfied, otherwise the reconciliation may be terminated. Based on this, the block chain can be deployed with at least two reconciliation contracts which have different reconciliation constraint conditions, so that reconciliation task balance is automatically realized to a certain extent, and the overall reconciliation efficiency of the block chain is improved.
For example, the tie-out constraint information in the tie-out contract may include a validity time for the tie-out. In some embodiments, reconciliation may be performed by code logic restricting the reconciliation contract from being invoked only within a preset time period, otherwise reconciliation may be terminated. Based on this, a multi-copy reconciliation contract for performing reconciliation at different time periods can be deployed, namely, by performing reconciliation at time batches, the situation that processing performance is reduced because nodes run too many reconciliation processes at the same time can be avoided. Specifically, one day may be divided into morning and afternoon, and a reconciliation contract for performing reconciliation in the morning and a reconciliation contract for performing reconciliation in the afternoon are deployed accordingly. In still other embodiments, the reconciliation may be restricted by code logic of the reconciliation contract to perform the reconciliation only if the generation time of the account data is within a preset time period, otherwise the reconciliation may be terminated. Based on this, at least two reconciliation contracts for reconciling account data generated at different time periods (similarly, am and pm) may be deployed.
As another example, the tie-out constraint information may include a set (list) of account addresses of legitimate tie-outs, i.e., the tie-out is performed when the tie-out contract is invoked, by code logic restriction of the tie-out contract only if a tie-out transaction is initiated with an account belonging to a preset set of account addresses, otherwise the tie-out may be terminated.
In some embodiments, other information may be included in the tie-out contract, such as an identification of the contract deployment (creation) party (account address), the contract name, contract description information, and so forth.
For more details on the reconciliation flow, reference may also be made to fig. 2 and its associated description.
The user terminal 120 may be a service terminal using blockchain services, which may have a communication connection with a certain node in the blockchain network 110 through the network 130. In some embodiments, the client 120 may initiate a transaction and transmit the transaction to the blockchain node via the network 130, and the node receiving the transaction may broadcast the transaction in the blockchain network so that the other nodes in the blockchain together complete the execution of the transaction. In some embodiments, the block node may also return the transaction execution result to the user side.
In some embodiments, the user terminal 120 may also be directly integrated on a blockchain node. In other words, the user terminal 120 can join the blockchain network 110 as a node. In some embodiments, the customer end 120 of the account checking party may join the blockchain network 110 as a normal node not participating in consensus, or join the blockchain network 110 as a consensus node. Whichever way the blockchain network 110 is joined, the customer end 120 of the reconciliation party can generate a reconciliation transaction and broadcast it in the blockchain network 110 so that each (consensus) node performs the reconciliation after receiving the reconciliation transaction.
In some embodiments, the user terminal 120/nodes in the blockchain network 110 may include various types of computing devices, such as laptop computers, desktop computers, servers, and the like. Wherein a server may be a stand-alone server or a group of servers, which may be centralized or distributed. In some embodiments, the server may be regional or remote. In some embodiments, the server may execute on a cloud platform. For example, the cloud platform may include one or any combination of a private cloud, a public cloud, a hybrid cloud, a community cloud, a decentralized cloud, an internal cloud, and the like.
The network 130 connects the various components of the system so that communication can occur between the various components. The network between the various parts in the system may include wired networks and/or wireless networks. For example, network 130 may include a cable network, a wired network, a fiber optic network, a telecommunications network, an intranet, the internet, a Local Area Network (LAN), a Wide Area Network (WAN), a Wireless Local Area Network (WLAN), a Metropolitan Area Network (MAN), a Public Switched Telephone Network (PSTN), a bluetooth network, a ZigBee network (ZigBee), Near Field Communication (NFC), an intra-device bus, an intra-device line, a cable connection, and the like, or any combination thereof. The network connection between each two parts may be in one of the above-mentioned ways, or in a plurality of ways. It is understood that the network 130 and the blockchain network 110 do not have to have a distinct boundary, and in a more general application scenario, the blockchain nodes and the common network nodes may be accessed into the same physical network together, wherein the blockchain nodes logically form the blockchain network.
FIG. 2 is an interaction diagram of a blockchain reconciliation flow in accordance with some embodiments of the present description. The reconciliation process involves a first reconciliation party, a second reconciliation party and any blockchain node (consensus node) that received the reconciliation transaction.
Referring to the related description in the foregoing embodiments, the first and second reconciliers may use the same hash function and generate hash values of the respective account data in the format and order of the attributes of the agreed account data. Further, as shown in fig. 2, the first and second reconciliers may submit the hash value of the account data to be reconciled, i.e. the hash value of the first account data and the hash value of the second account data, respectively, and the hash () in fig. 2 represents a hash function agreed by the reconciliers. It can be understood that to ensure that reconciliation is successful (consistency of submitted account data by both reconciling parties), the first account data and the second account data should have the same account identification. Specifically, taking the first tie-back party as an example, the first tie-back party may generate and broadcast a tie-back transaction in the blockchain network, which may include an account identification and a hash value of first account data of the first tie-back party. After any consensus node receives the reconciliation transaction from the first reconciliation party, the hash value of the account data of the second reconciliation party can be inquired in the blockchain data according to the account identifier in the reconciliation transaction. Wherein the hash value of the account data of the second reconcilier is associated with the account identification.
It will be appreciated that the second tie-back party may also generate and broadcast in the blockchain network a tie-back transaction, which may include the account identification and a hash value of the second account data of the second tie-back party. After any consensus node receives the reconciliation transaction from the first reconciliation party, the account identification in the reconciliation transaction and the hash value of the second account data can be associated and written into the blockchain data.
If the consensus node does not inquire the hash value of the second account data in the blockchain data, an account checking result is determined based on the inquiry result, and the account checking result can indicate that the account data is absent. In some embodiments, where the hash value of the second account data is not queried, the consensus node may repeatedly query the block chain data for the hash value of the second account data. If the query result within the preset number of times or the preset duration indicates that the hash value of the second account data is not queried, the consensus node may generate a check result indicating that the hash value of the account data is absent. Of course, if the hash value of the second account data is queried within the preset number of times or the preset duration, the consensus node may continue to perform reconciliation, that is, compare the hash values of both sides of the reconciliation.
If the consensus node inquires the hash value of the second account data in the blockchain data, that is, the consensus node obtains the hash value of the account data submitted by both reconciliation parties, the hash value of the first account data and the hash value of the second account data can be compared. Accordingly, the consensus node may determine an account checking result based on the comparison result, and the account checking result may indicate whether the account data submitted by the account checking parties are consistent.
In some scenarios, the consensus node may associate and write the account identification and the hash value of the account data in a reconciliation transaction from any one of the reconciliers to the blockchain data. In this way, no matter which one of the account data hash value of the two reconciliation parties is written into the blockchain data first, the consensus node receiving the reconciliation transaction of the other of the two reconciliation parties can inquire the previously written account data hash value in the blockchain data, and obtain a reconciliation result indicating whether the account data submitted by the two reconciliation parties are consistent. In some embodiments, the consensus node may associate the account identifier in the reconciliation transaction with the hash value of the account data and then write the result into the locally stored state data.
In some scenarios, the reconciliation parties may include a reconciliation active party who wishes to take the reconciliation result and a reconciliation passive party who only needs to submit own account data. The common identification node receiving the reconciliation transaction from the reconciliation passive party can associate the account identification in the reconciliation transaction with the hash value of the account data of the reconciliation passive party and write the hash value into the blockchain data, so that the common identification node receiving the reconciliation transaction from the reconciliation active party can inquire the hash value of the account data of the reconciliation passive party in the blockchain data according to the account identification in the reconciliation transaction. That is, the consensus node that receives the reconciliation transaction from the reconciliation master can only cache the account data of the reconciliation master in the reconciliation transaction, without writing the account data of the reconciliation master into the blockchain data.
In some embodiments, the consensus node may return the obtained checking result to the client of the account checking party. In some embodiments, the consensus node receiving the reconciliation transaction may associate and write the account identification in the reconciliation transaction and the obtained reconciliation result into blockchain data. In some embodiments, the consensus node may associate the account identifier in the reconciliation transaction with the obtained reconciliation result and write the result into the locally stored status data. Therefore, the user terminal of any account checking party can obtain the account checking result of the uplink according to the account identification. It can be understood that, if the user side of the reconciliation party joins the blockchain network as a common node not participating in the consensus, an inquiry transaction including the account identifier may be generated and broadcast in the blockchain network, so that the consensus node reads the associated reconciliation result in the local blockchain data according to the account identifier in the transaction after receiving the transaction and returns the reconciliation result to the user side of the reconciliation party. If the user side of the account checking party joins the blockchain network as a common node which does not participate in the consensus, the associated account checking result can be read in the local blockchain data according to the account identification.
In some embodiments, the consensus node may determine whether the reconciliation transaction satisfies a reconciliation constraint. If yes, the consensus node which receives the reconciliation transaction from either one of the two reconciliation parties can execute the reconciliation, namely, the hash value of the account data of the other one of the two reconciliation parties is obtained and compared with the hash value of the account data of the two reconciliation parties. Otherwise, the consensus node may terminate reconciliation.
In some embodiments, the reconciliation transaction may also include a timestamp of the account data. The consensus node receiving the reconciliation transaction can determine the account generation time based on the timestamp of the account data, further determine whether the account generation time is within a first preset time period (e.g., morning/afternoon), and if so, determine that the reconciliation transaction meets the reconciliation constraint condition.
In some embodiments, the tie-out transaction may also include a timestamp of the tie-out transaction. The consensus node receiving the reconciliation transaction can determine the reconciliation time based on the timestamp of the reconciliation transaction, further judge whether the reconciliation time is within a second preset time period (for example, morning/afternoon), and if so, determine that the reconciliation transaction meets the reconciliation constraint condition.
In some embodiments, the tie-out transaction may also include an account address of the tie-out party. The consensus node receiving the reconciliation transaction can judge whether the account address of the reconciliation party belongs to a preset account address set, and if so, the reconciliation transaction is determined to meet the reconciliation constraint condition.
In connection with the relevant content of the foregoing embodiments, a blockchain may be deployed with at least two tie-out contracts having different tie-out constraints. Accordingly, the tie-up transaction may further include an address of the target tie-up contract, and the consensus node may invoke the target tie-up contract according to the address of the target tie-up contract in the tie-up transaction. And the calling of the target account-checking contract comprises judging whether the account-checking transaction meets the account-checking constraint condition of the target account-checking contract. And if so, the consensus node can execute account checking, namely acquiring the hash value of the account data of the other party of the two account checking parties and comparing the hash values of the account data of the two account checking parties. Otherwise, the consensus node may terminate reconciliation. Therefore, balance of account checking tasks can be automatically realized to a certain extent, and the overall account checking efficiency of the block chain is improved.
It should be noted that the above description of the flow is for illustration and description only and does not limit the scope of the application of the present specification. Various modifications and alterations to the flow may occur to those skilled in the art, given the benefit of this description. However, such modifications and variations are intended to be within the scope of the present description.
Fig. 3 is an exemplary block diagram of a blockchain reconciliation system in accordance with some embodiments of the present description. The system 300 may be implemented on block link points (consensus nodes). As shown in fig. 3, the system 300 may include a receiving module 310 and a reconciliation module 320.
The receiving module 310 may be configured to receive a reconciliation transaction from a first reconcilier, the reconciliation transaction comprising an account identification and a hash value of first account data of the first reconcilier.
The reconciliation module 320 may be configured to: inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification; if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data; and determining a reconciliation result based on the query result or the comparison result.
In some embodiments, a blockchain may be deployed with at least two tie-up contracts having different tie-up constraints. Accordingly, the tie-out transaction may also include an address of the target tie-out contract, and the tie-out module 320 may invoke the target tie-out contract based on the address of the target tie-out contract in the tie-out transaction. And the calling of the target account-checking contract comprises judging whether the account-checking transaction meets the account-checking constraint condition of the target account-checking contract. If so, the reconciliation module 320 may perform reconciliation, that is, obtain the hash value of the account data of the other of the two reconciliation parties and compare the hash values of the account data of the two reconciliation parties. Otherwise, the reconciliation module 320 can terminate the reconciliation.
For more details of the system 300 and its modules, reference may be made to fig. 2 and its associated description.
It should be understood that the system and its modules shown in FIG. 3 may be implemented in a variety of ways. For example, in some embodiments, the system and its modules may be implemented in hardware, software, or a combination of software and hardware. Wherein the hardware portion may be implemented using dedicated logic; the software portions may be stored in a memory for execution by a suitable instruction execution system, such as a microprocessor or specially designed hardware. Those skilled in the art will appreciate that the methods and systems described above may be implemented using computer executable instructions and/or embodied in processor control code, such code being provided, for example, on a carrier medium such as a diskette, CD-or DVD-ROM, a programmable memory such as read-only memory (firmware), or a data carrier such as an optical or electronic signal carrier. The system and its modules in this specification may be implemented not only by hardware circuits such as very large scale integrated circuits or gate arrays, semiconductors such as logic chips, transistors, or programmable hardware devices such as field programmable gate arrays, programmable logic devices, etc., but also by software executed by various types of processors, for example, or by a combination of the above hardware circuits and software (e.g., firmware).
It should be noted that the above description of the system and its modules is for convenience only and should not limit the present disclosure to the illustrated embodiments. It will be appreciated by those skilled in the art that, given the teachings of the system, any combination of modules or sub-system configurations may be used to connect to other modules without departing from such teachings. For example, in some embodiments, the reconciliation module 320 can be one module, and the functions of this one module can also be implemented by multiple modules, such as a query module for obtaining a hash value of account data of the second counterparty, a comparison module for comparing the hash values, and a determination module for determining a reconciliation result. Such variations are within the scope of the present disclosure.
The beneficial effects that may be brought by the embodiments of the present description include, but are not limited to: (1) the hash values of the account data of the account checking parties are compared, so that the account checking can be realized on the premise of not exposing the plaintext of the account data; (2) compared with manual account checking, the method is more efficient and timely; (3) and deploying multiple intelligent contracts corresponding to different reconciliation constraint conditions, and executing reconciliation in batches to avoid the reduction of processing performance caused by the fact that multiple reconciliation processes are operated by nodes at the same time, or automatically realizing the balancing of reconciliation tasks to a certain extent, thereby improving the overall reconciliation efficiency of the block chain. It is to be noted that different embodiments may produce different advantages, and in different embodiments, any one or combination of the above advantages may be produced, or any other advantages may be obtained.
Having thus described the basic concept, it will be apparent to those skilled in the art that the foregoing detailed disclosure is to be considered merely illustrative and not restrictive of the embodiments herein. Various modifications, improvements and adaptations to the embodiments described herein may occur to those skilled in the art, although not explicitly described herein. Such modifications, improvements and adaptations are proposed in the embodiments of the present specification and thus fall within the spirit and scope of the exemplary embodiments of the present specification.
Also, the description uses specific words to describe embodiments of the description. Reference throughout this specification to "one embodiment," "an embodiment," and/or "some embodiments" means that a particular feature, structure, or characteristic described in connection with at least one embodiment of the specification is included. Therefore, it is emphasized and should be appreciated that two or more references to "an embodiment" or "one embodiment" or "an alternative embodiment" in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, some features, structures, or characteristics of one or more embodiments of the specification may be combined as appropriate.
Moreover, those skilled in the art will appreciate that aspects of the embodiments of the present description may be illustrated and described in terms of several patentable species or situations, including any new and useful combination of processes, machines, manufacture, or materials, or any new and useful improvement thereof. Accordingly, aspects of embodiments of the present description may be carried out entirely by hardware, entirely by software (including firmware, resident software, micro-code, etc.), or by a combination of hardware and software. The above hardware or software may be referred to as "data block," module, "" engine, "" unit, "" component, "or" system. Furthermore, aspects of the embodiments of the present specification may be represented as a computer product, including computer readable program code, embodied in one or more computer readable media.
The computer storage medium may comprise a propagated data signal with the computer program code embodied therewith, for example, on baseband or as part of a carrier wave. The propagated signal may take any of a variety of forms, including electromagnetic, optical, etc., or any suitable combination. A computer storage medium may be any computer-readable medium that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code located on a computer storage medium may be propagated over any suitable medium, including radio, cable, fiber optic cable, RF, or the like, or any combination of the preceding.
Computer program code required for operation of various portions of the embodiments of the present description may be written in any one or more programming languages, including an object oriented programming language such as Java, Scala, Smalltalk, Eiffel, JADE, Emerald, C + +, C #, VB.NET, Python, and the like, a conventional programming language such as C, VisualBasic, Fortran2003, Perl, COBOL2002, PHP, ABAP, a dynamic programming language such as Python, Ruby, and Groovy, or other programming languages, and the like. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or processing device. In the latter scenario, the remote computer may be connected to the user's computer through any network format, such as a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet), or in a cloud computing environment, or as a service, such as a software as a service (SaaS).
In addition, unless explicitly stated in the claims, the order of processing elements and sequences, use of numbers and letters, or use of other names in the embodiments of the present specification are not intended to limit the order of the processes and methods in the embodiments of the present specification. While various presently contemplated embodiments of the invention have been discussed in the foregoing disclosure by way of example, it is to be understood that such detail is solely for that purpose and that the appended claims are not limited to the disclosed embodiments, but, on the contrary, are intended to cover all modifications and equivalent arrangements that are within the spirit and scope of the embodiments herein. For example, although the system components described above may be implemented by hardware devices, they may also be implemented by software-only solutions, such as installing the described system on an existing processing device or mobile device.
Similarly, it should be noted that in the preceding description of embodiments of the specification, various features are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the disclosure and aiding in the understanding of one or more embodiments of the invention. This method of disclosure, however, is not intended to imply that more features are required than are expressly recited in the claims. Indeed, the embodiments may be characterized as having less than all of the features of a single embodiment disclosed above.
For each patent, patent application publication, and other material, such as articles, books, specifications, publications, documents, etc., cited in this specification, the entire contents of each are hereby incorporated by reference into this specification. Except where the application history document does not conform to or conflict with the contents of the present specification, it is to be understood that the application history document, as used herein in the present specification or appended claims, is intended to define the broadest scope of the present specification (whether presently or later in the specification) rather than the broadest scope of the present specification. It is to be understood that the descriptions, definitions and/or uses of terms in the accompanying materials of this specification shall control if they are inconsistent or contrary to the descriptions and/or uses of terms in this specification.
Finally, it should be understood that the embodiments described herein are merely illustrative of the principles of the embodiments of the present disclosure. Other variations are possible within the scope of the embodiments of the present description. Thus, by way of example, and not limitation, alternative configurations of the embodiments of the specification can be considered consistent with the teachings of the specification. Accordingly, the embodiments of the present description are not limited to only those embodiments explicitly described and depicted herein.

Claims (11)

1. A blockchain reconciliation method is implemented by blockchain link points, wherein at least two reconciliation contracts are deployed on a blockchain, the reconciliation contracts are intelligent contracts used for reconciliation, and the at least two reconciliation contracts have different reconciliation constraints; the method comprises the following steps:
receiving a reconciliation transaction from a first reconciliation party, the reconciliation transaction comprising an account identification, a hash value of first account data of the first reconciliation party, and an address of a target reconciliation contract;
calling the target reconciliation contract according to the address of the target reconciliation contract so as to realize the following steps through the target reconciliation contract: judging whether the reconciliation transaction meets the reconciliation constraint condition of the target reconciliation contract, and if so, executing:
inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification;
if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data;
and determining a reconciliation result based on the query result or the comparison result.
2. The method of claim 1, wherein the tie-out transaction further comprises a timestamp of the tie-out transaction; the judging whether the reconciliation transaction meets the reconciliation constraint condition of the target reconciliation contract comprises the following steps:
determining a reconciliation time based on a timestamp of the reconciliation transaction;
and judging whether the reconciliation time is within a first preset time period, and if so, determining that the reconciliation transaction meets the reconciliation constraint condition of the target reconciliation contract.
3. The method of claim 1, wherein the reconciliation transaction further comprises a timestamp of the first account data; the judging whether the reconciliation transaction meets the reconciliation constraint condition of the target reconciliation contract comprises the following steps:
determining an account generation time based on a timestamp of the first account data;
and judging whether the account generation time is within a second preset time period, and if so, determining that the reconciliation transaction meets the reconciliation constraint condition of the target reconciliation contract.
4. The method of claim 1, wherein the tie-out transaction further comprises an account address of the first tie-out party; the judging whether the reconciliation transaction meets the reconciliation constraint condition of the target reconciliation contract comprises the following steps:
and judging whether the account address of the first account checking party belongs to a preset account address set, if so, determining that the account checking transaction meets the account checking constraint condition of the target account checking contract.
5. The method of claim 1, further comprising:
and if the reconciliation transaction does not meet the reconciliation constraint condition of the target reconciliation contract, terminating the reconciliation.
6. The method of claim 1, further comprising:
and associating the account identification in the reconciliation transaction with the hash value of the first account data and writing the hash value into the blockchain data.
7. The method of claim 1, further comprising:
and returning the account checking result to the user side of the first account checking party.
8. The method of claim 1, further comprising:
and associating the account identification with the account checking result and writing the account checking result into block chain data.
9. A block chain reconciliation system is realized on a block chain node, wherein at least two reconciliation contracts are deployed on the block chain, the reconciliation contracts are intelligent contracts used for reconciliation, and the at least two reconciliation contracts have different reconciliation constraint conditions; the system comprises a receiving module and a reconciliation module;
the receiving module is used for receiving a reconciliation transaction from a first reconciliation party, wherein the reconciliation transaction comprises an account identification, a hash value of first account data of the first reconciliation party and an address of a target reconciliation contract;
the reconciliation module is used for calling the target reconciliation contract according to the address of the target reconciliation contract so as to realize the following steps through the target reconciliation contract: judging whether the reconciliation transaction meets the reconciliation constraint condition of the target reconciliation contract, and if so, executing:
inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification;
if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data;
and determining a reconciliation result based on the query result or the comparison result.
10. A blockchain tie-out apparatus comprising a processor and a storage device for storing instructions which, when executed by the processor, implement the method of any one of claims 1 to 8.
11. A blockchain reconciliation method, wherein the method is performed by a blockchain link point, comprising:
receiving a reconciliation transaction from a first reconciliation party, the reconciliation transaction comprising an account identification and a hash value of first account data of the first reconciliation party;
inquiring a hash value of second account data of a second account counterparty in block chain data according to the account identification, wherein the hash value of the second account data is associated with the account identification;
if the hash value of the second account data is inquired, comparing the hash value of the first account data with the hash value of the second account data;
and determining a reconciliation result based on the query result or the comparison result.
CN202011003500.2A 2020-09-22 2020-09-22 Block chain account checking method and system Active CN111861482B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011003500.2A CN111861482B (en) 2020-09-22 2020-09-22 Block chain account checking method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011003500.2A CN111861482B (en) 2020-09-22 2020-09-22 Block chain account checking method and system

Publications (2)

Publication Number Publication Date
CN111861482A true CN111861482A (en) 2020-10-30
CN111861482B CN111861482B (en) 2021-07-06

Family

ID=72968423

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011003500.2A Active CN111861482B (en) 2020-09-22 2020-09-22 Block chain account checking method and system

Country Status (1)

Country Link
CN (1) CN111861482B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112347494A (en) * 2020-11-10 2021-02-09 上海欧冶金融信息服务股份有限公司 Encryption reconciliation method and system based on block chain
CN112506940A (en) * 2020-12-16 2021-03-16 平安银行股份有限公司 Data reconciliation method and device, electronic equipment and storage medium
CN112767113A (en) * 2021-02-26 2021-05-07 中国工商银行股份有限公司 Account checking data processing method, device and system based on block chain
CN112785408A (en) * 2021-02-26 2021-05-11 中国工商银行股份有限公司 Account checking method and device based on Hash
CN113421163A (en) * 2021-07-13 2021-09-21 北京沃东天骏信息技术有限公司 Account checking method, account checking application cluster and related client
CN113708943A (en) * 2021-09-06 2021-11-26 中国联合网络通信集团有限公司 Internetwork settlement method, device, equipment and storage medium
WO2023109841A1 (en) * 2021-12-15 2023-06-22 中国人民银行数字货币研究所 Blockchain-based reconciliation method, apparatus, and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107491519A (en) * 2017-08-15 2017-12-19 中国联合网络通信集团有限公司 The querying method and device of block chain account book
CN109003175A (en) * 2018-07-06 2018-12-14 国网汇通金财(北京)信息科技有限公司 A kind of account checking method and system based on block chain
CN109493202A (en) * 2018-09-27 2019-03-19 深圳壹账通智能科技有限公司 Block chain account checking method, device, system, equipment and readable storage medium storing program for executing
KR20190076837A (en) * 2018-10-29 2019-07-02 주식회사 미탭스플러스 Distributed Ledger Device and Distributed Ledger Method for Sharing User Information using Blockchain
CN110008735A (en) * 2019-01-31 2019-07-12 阿里巴巴集团控股有限公司 The method and node, storage medium that contract calls are realized in block chain

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107491519A (en) * 2017-08-15 2017-12-19 中国联合网络通信集团有限公司 The querying method and device of block chain account book
CN109003175A (en) * 2018-07-06 2018-12-14 国网汇通金财(北京)信息科技有限公司 A kind of account checking method and system based on block chain
CN109493202A (en) * 2018-09-27 2019-03-19 深圳壹账通智能科技有限公司 Block chain account checking method, device, system, equipment and readable storage medium storing program for executing
KR20190076837A (en) * 2018-10-29 2019-07-02 주식회사 미탭스플러스 Distributed Ledger Device and Distributed Ledger Method for Sharing User Information using Blockchain
CN110008735A (en) * 2019-01-31 2019-07-12 阿里巴巴集团控股有限公司 The method and node, storage medium that contract calls are realized in block chain

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112347494A (en) * 2020-11-10 2021-02-09 上海欧冶金融信息服务股份有限公司 Encryption reconciliation method and system based on block chain
CN112506940A (en) * 2020-12-16 2021-03-16 平安银行股份有限公司 Data reconciliation method and device, electronic equipment and storage medium
CN112506940B (en) * 2020-12-16 2023-07-21 平安银行股份有限公司 Data checking method and device, electronic equipment and storage medium
CN112767113A (en) * 2021-02-26 2021-05-07 中国工商银行股份有限公司 Account checking data processing method, device and system based on block chain
CN112785408A (en) * 2021-02-26 2021-05-11 中国工商银行股份有限公司 Account checking method and device based on Hash
CN113421163A (en) * 2021-07-13 2021-09-21 北京沃东天骏信息技术有限公司 Account checking method, account checking application cluster and related client
CN113708943A (en) * 2021-09-06 2021-11-26 中国联合网络通信集团有限公司 Internetwork settlement method, device, equipment and storage medium
WO2023109841A1 (en) * 2021-12-15 2023-06-22 中国人民银行数字货币研究所 Blockchain-based reconciliation method, apparatus, and system

Also Published As

Publication number Publication date
CN111861482B (en) 2021-07-06

Similar Documents

Publication Publication Date Title
CN111861482B (en) Block chain account checking method and system
CN109191124B (en) Block chain network, deployment method and storage medium
CN109218079B (en) Block chain network, deployment method and storage medium
CN109325855B (en) Block chain network, deployment method and storage medium
CN111163129B (en) Resource processing method and device based on cross-link network
CN102291464B (en) System and method for dynamically generating Web Service by business flow in BPM (Business Process Management)
CN109241032B (en) Account book database component, operation method and storage medium
CN109547488B (en) Credible data computing and exchanging system based on alliance block chain
CN110838065A (en) Transaction data processing method and device
CN111861481A (en) Block chain account checking method and system
US8250185B2 (en) Semantic matching of federation intents and services capabilities in a planning system for automatic service federation
CN112417049B (en) Cross-chain interaction method and system based on block chain all-in-one machine
US20200201843A1 (en) Optimization of chaincode statements
CN112162768B (en) Block chain upgrading method and system
CN112866421B (en) Intelligent contract operation method and device based on distributed cache and NSQ
CN110581893B (en) Data transmission method and device, routing equipment, server and storage medium
CN111899008A (en) Resource transfer method, device, equipment and system
CN117522581A (en) Distributed resource transaction platform based on blockchain
CN113111125A (en) Business evidence storage method based on block chain
CN111949634A (en) Method for synchronously migrating block chain data
WO2023005500A1 (en) Cross-chain transaction processing method and apparatus, electronic device, and storage medium
CN115511595A (en) Service execution method and device based on block chain
CN112565340B (en) Service scheduling method, device, computer system and medium for distributed application
US20220311595A1 (en) Reducing transaction aborts in execute-order-validate blockchain models
CN117319412A (en) Management method of block chain network and related equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant