CN112116346A - Block chain for quickly confirming transaction and method for quickly confirming transaction on block chain - Google Patents

Block chain for quickly confirming transaction and method for quickly confirming transaction on block chain Download PDF

Info

Publication number
CN112116346A
CN112116346A CN201910546180.6A CN201910546180A CN112116346A CN 112116346 A CN112116346 A CN 112116346A CN 201910546180 A CN201910546180 A CN 201910546180A CN 112116346 A CN112116346 A CN 112116346A
Authority
CN
China
Prior art keywords
transaction
block
change number
node
block change
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.)
Withdrawn
Application number
CN201910546180.6A
Other languages
Chinese (zh)
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.)
Beijing Weining Technology Co ltd
Original Assignee
Beijing Weining 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 Beijing Weining Technology Co ltd filed Critical Beijing Weining Technology Co ltd
Priority to CN201910546180.6A priority Critical patent/CN112116346A/en
Publication of CN112116346A publication Critical patent/CN112116346A/en
Withdrawn legal-status Critical Current

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/382Payment protocols; Details thereof insuring higher security of 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
    • 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)
  • Engineering & Computer Science (AREA)
  • Finance (AREA)
  • Physics & Mathematics (AREA)
  • Strategic Management (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Technology Law (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)

Abstract

The invention provides a block chain for quickly confirming transaction and a method for quickly confirming transaction on the block chain. The blockchain for rapid validation transactions includes: an originating transaction node and a billing node. The originating transaction node extracts a first block change number from an unused transaction output (UTXO), the first block change number corresponding to a last transaction block number of a user, broadcasts a transaction order for a transaction, the transaction order including the first block change number. After receiving the said trade list, the accounting node extracts a second block change number from the unused trade output, the second block change number is the last trade block number corresponding to the user, and checks whether the second block change number is the same as the first block change number recorded in the trade list, if so, the accounting node accounts the trade.

Description

Block chain for quickly confirming transaction and method for quickly confirming transaction on block chain
Technical Field
The invention relates to the technical field of block chains, in particular to a block chain for quickly confirming transactions and a method for quickly confirming transactions on the block chain.
Background
Blockchain technology has been increasingly popular with digital cryptocurrency, such as bitcoin, which records all transactions and historical data by building a commonly maintained and non-tampered database. However, before recording the transaction, it is necessary to confirm that the transaction is not recorded on the blockchain, so as to avoid repeated recording.
Disclosure of Invention
In view of the above problems, the present invention provides a block chain for fast transaction verification and a fast transaction verification method on the block chain, so as to solve the problems in the prior art.
In one embodiment, a blockchain for fast validation transactions includes: an originating transaction node and a billing node. The originating transaction node extracts a first block change number from an unused transaction output (UTXO), the first block change number corresponding to a last transaction block number of a user, broadcasts a transaction order for a transaction, the transaction order including the first block change number. After receiving the said trade list, the accounting node extracts a second block change number from the unused trade output, the second block change number is the last trade block number of the corresponding user, and checks whether the second block change number is the same as the first block change number recorded in the trade list, if so, the accounting node accounts the trade.
In one embodiment, a method for quickly confirming a transaction on a blockchain includes: extracting a first block change number from an unused transaction output (UTXO) by an originating transaction node, the first block change number corresponding to a last transaction block number of a user; initiating a transaction by the transaction initiating node to generate a transaction order, wherein the transaction order comprises a first block change number; acquiring billing rights from a billing node according to a consensus algorithm; and after receiving the transaction order, the accounting node extracts a second block change number from the unused transaction output, checks whether the second block change number is the same as the first block change number recorded in the transaction order, and accounts the transaction if the second block change number is the same as the first block change number recorded in the transaction order.
According to some embodiments, the transaction order further comprises a valid block number designation, and the accounting node checks whether the block height of the block chain is within a valid block range corresponding to the valid block number designation, and if so, does not account for the transaction.
According to some embodiments, the transaction list further includes a valid time, and the billing node further determines whether a timestamp of the block matches the valid time when the transaction list is packaged as a block, and only bills the transaction when the timestamp matches the valid time.
According to some embodiments, the transaction order is signed by the originating transaction node, and the billing node also verifies a signature on the transaction order.
In summary, the invention provides a blockchain for quickly confirming a transaction and a method for quickly confirming a transaction on a blockchain, which can simply confirm whether a transaction is recorded on the blockchain through a block number, omit the traditional complicated way of one-to-one comparison, and make the complexity of check time be O (log)2n) is reduced to O (1), thereby greatly improving the calculation efficiency.
Drawings
Fig. 1 is a block diagram of a block chain according to an embodiment of the invention.
Fig. 2 is a flow chart of a method for quickly confirming a transaction on a blockchain according to an embodiment of the invention.
Fig. 3 is a flow chart of a method for quickly confirming a transaction on a blockchain according to another embodiment of the invention.
Detailed Description
In order to make the objects, features and effects of the present invention easier to understand, embodiments for describing the present invention in detail and the accompanying drawings are provided below.
Referring to fig. 1, fig. 1 is a block diagram illustrating a block chain 100 according to an embodiment of the invention. Blockchain 100 includes a plurality of nodes 110. Such nodes 110 are connected via a point-to-point technique. The nodes 110 may be any electronic device with computing and networking capabilities, such as desktop computers, mobile phones, tablet computers, servers, embedded devices, and the like.
Included among these nodes 110 are an originating transaction node 111 and a billing node 112. Accounting node 112 is determined by a consensus algorithm, not necessarily the same node 110 as accounting node 112 each time. The consensus algorithm may employ, for example, a Proof Of workload (PoW) mechanism, a Proof Of rights (PoS) mechanism, a Proof Of rights delegation (DPoS) mechanism, or a distributed consistency algorithm, among others.
Each node 110 stores an unused transaction output (UTXO) that records the unused output of each user, as well as the last transaction block number of each user. The last transaction block number is the block height of the corresponding user during the previous uplink transaction. After the next corresponding user completes one transaction again, the last transaction block number is updated to the block height of the current transaction uplink. For the sake of differentiation, the last transaction block number for the originating transaction node 111, which is extracted from the unused transaction outputs for the corresponding user, is referred to as "first block change number". The originating transaction node 111 will broadcast a transaction order for a transaction, which records the first block change number.
After determining the billing node 112 by the consensus algorithm, the billing node 112 extracts the last transaction block number (hereinafter referred to as "second block change number") corresponding to the same subscriber from the unused transaction output, and if the last transaction block number of the same subscriber has not changed during the period from issuing the transaction order to preparing for billing, the transaction is not packaged and therefore the billing node 112 can bill the transaction. In other words, the billing node 112 checks whether the second block change number is the same as the first block change number, and if so, the transaction is packed and linked. On the contrary, if the second block change number is different from the first block change number, it indicates that the transaction is packed and linked, i.e. the transaction order is an expired transaction, so the accounting node 112 will not pack and link the transaction, and avoid repeated transactions.
In some embodiments, the transaction order further includes a validity time, and when the billing node 112 packages the transaction order into a block, it also determines whether a timestamp of the block matches the validity time (i.e., within the validity period). E.g., a valid time of 2 minutes, the accounting node 112 will determine whether the time difference between the block's timestamp and the transaction order's timestamp is within 2 minutes. The transaction is only billed when the validity time is met. If not, this indicates that the transaction is out of date and therefore is not billed.
In some embodiments, the transaction order further includes a valid block number designation. The valid block number designation limits a block growing range. For example, the block number when the transaction order is issued is 10, if the valid block number indicates that the valid block growth range is limited to three blocks, the block number is still valid when it grows to 13, and the transaction is considered to be obsolete when it grows to 14. That is, the billing node 112 checks whether the block height of the block chain is within the valid block range corresponding to the valid block number, and if so, does not bill the transaction. Thus, the issue of time asynchronism between nodes can be avoided, and the block number is used to determine the validity period, because the growth rate of each block chain is generally stable.
In some embodiments, the transaction order is also signed via originating transaction node 111, and billing node 112 also verifies the signature on the transaction order to determine that the received transaction order was sent by originating transaction node 111.
Referring to fig. 2, fig. 2 is a flowchart illustrating a method for quickly confirming a transaction on a block chain 100 according to an embodiment of the present invention. The method for quickly confirming the transaction on the blockchain 100 comprises the following steps: extracting the first block change number from the unused transaction output by the originating transaction node 111 (step S01), and then originating a transaction by the originating transaction node 111 to generate a transaction order, wherein the transaction order includes the first block change number (step S02); after obtaining the billing right from a billing node 112 according to a consensus algorithm (step S03), the billing node 112 extracts a second block change number from the unused transaction output after receiving the transaction order, checks whether the second block change number is the same as the first block change number recorded in the transaction order (step S04), and if so, bills the transaction (step S05).
In some embodiments, as shown in fig. 3, before step S02, a step S11 is further included: a valid block number designation is recorded in the transaction ticket by originating transaction node 111. In step S04, if the second block change number is different from the first block change number recorded in the transaction ticket, the process proceeds to step S06: the transaction is not billed. If it is determined in step S04 that the first tile change number is the same as the second tile change number, the process proceeds to step S07. In step S07, the accounting node 112 checks whether the block height of the block chain is within the valid block range corresponding to the valid block number, so as to further confirm whether the transaction is over time, if so, the transaction is not accounted (step S06), otherwise, the transaction is accounted (step S05).
In some embodiments, step S07 may instead confirm whether the timestamp of the tile corresponds to the validity time of the transaction order record. If yes, go to step S05; if not, the process proceeds to step S06.
In some embodiments, the order of step S04 and step S07 may be interchanged.
In summary, the invention provides a blockchain for quickly confirming a transaction and a method for quickly confirming a transaction on the blockchain, which can simply confirm whether a transaction is recorded on the blockchain through a block number, and omit a complicated way of comparing the transactions one by one.
Although the present invention has been described with reference to the preferred embodiments, it should be understood that various changes and modifications can be made without departing from the spirit and scope of the invention as defined by the appended claims.

Claims (8)

1. A blockchain for quickly validating transactions, comprising:
an originating transaction node extracting a first block change number from an unused transaction output (UTXO), the first block change number corresponding to a last transaction block number of a user, broadcasting a transaction order for a transaction, the transaction order including the first block change number; and
and the accounting node extracts a second block change number from the unused transaction output after receiving the transaction list, wherein the second block change number corresponds to the last transaction block number of the user, checks whether the second block change number is the same as the first block change number recorded in the transaction list, and accounts the transaction if the second block change number is the same as the first block change number recorded in the transaction list.
2. A blockchain for rapid acknowledgment transactions according to claim 1 wherein said transaction ticket further includes a valid block number designation, said billing node checking whether a block height of said blockchain is within a valid block range corresponding to said valid block number designation, and if so, not billing said transaction.
3. The blockchain of claim 1 wherein the transaction order further includes a validity time, and wherein when the billing node packages the transaction order into a block, the billing node further determines whether a timestamp of the block matches the validity time, and when the validity time is met, the transaction is only billed.
4. A blockchain for rapid acknowledgment transactions according to claim 1 wherein said transaction order is signed by said initiating transaction node and said billing node also verifies a signature on said transaction order.
5. A method for quickly confirming transaction on block chain is characterized by comprising the following steps:
extracting a first block change number from an unused transaction output (UTXO) by an originating transaction node, the first block change number corresponding to a last transaction block number of a user;
initiating a transaction by the transaction initiating node to generate a transaction order, wherein the transaction order comprises the first block change number;
acquiring billing rights from a billing node according to a consensus algorithm; and
after receiving the transaction order, the accounting node extracts a second block change number from the unused transaction output, wherein the second block change number is the last transaction block number corresponding to the user, checks whether the second block change number is the same as the first block change number recorded in the transaction order, and accounts the transaction if the second block change number is the same as the first block change number recorded in the transaction order.
6. The method of claim 5, further comprising:
recording a valid block number mark in the transaction sheet by the transaction initiating node; and
checking by the accounting node whether a block height of the block chain is within a valid block range corresponding to the valid block number designation, and if so, not accounting for the transaction.
7. The method as claimed in claim 5, wherein the transaction order further includes a valid time, the billing node further determines whether a timestamp of the block corresponds to the valid time when the transaction order is packaged as a block, and only bills the transaction when the timestamp corresponds to the valid time.
8. The blockchain rapid acknowledgment transaction method of claim 5 wherein said transaction order is signed by said originating transaction node, said billing node further verifying a signature on said transaction order.
CN201910546180.6A 2019-06-20 2019-06-20 Block chain for quickly confirming transaction and method for quickly confirming transaction on block chain Withdrawn CN112116346A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910546180.6A CN112116346A (en) 2019-06-20 2019-06-20 Block chain for quickly confirming transaction and method for quickly confirming transaction on block chain

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910546180.6A CN112116346A (en) 2019-06-20 2019-06-20 Block chain for quickly confirming transaction and method for quickly confirming transaction on block chain

Publications (1)

Publication Number Publication Date
CN112116346A true CN112116346A (en) 2020-12-22

Family

ID=73795342

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910546180.6A Withdrawn CN112116346A (en) 2019-06-20 2019-06-20 Block chain for quickly confirming transaction and method for quickly confirming transaction on block chain

Country Status (1)

Country Link
CN (1) CN112116346A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107396360A (en) * 2017-08-15 2017-11-24 中国联合网络通信集团有限公司 Block verification method and device
CN108848055A (en) * 2018-05-03 2018-11-20 中国银联股份有限公司 A kind of block chain common recognition method, accounting nodes and node
CN108876377A (en) * 2018-07-06 2018-11-23 杭州复杂美科技有限公司 A kind of method and system for preventing from repeating to pay
CN109255713A (en) * 2018-11-12 2019-01-22 裴若含 In a kind of block chain network in certain time period book keeping operation power acquisition methods
US20200162550A1 (en) * 2017-06-20 2020-05-21 nChain Holdings Limited Fast propagation of recent transactions over a blockchain network

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20200162550A1 (en) * 2017-06-20 2020-05-21 nChain Holdings Limited Fast propagation of recent transactions over a blockchain network
CN107396360A (en) * 2017-08-15 2017-11-24 中国联合网络通信集团有限公司 Block verification method and device
CN108848055A (en) * 2018-05-03 2018-11-20 中国银联股份有限公司 A kind of block chain common recognition method, accounting nodes and node
CN108876377A (en) * 2018-07-06 2018-11-23 杭州复杂美科技有限公司 A kind of method and system for preventing from repeating to pay
CN109255713A (en) * 2018-11-12 2019-01-22 裴若含 In a kind of block chain network in certain time period book keeping operation power acquisition methods

Similar Documents

Publication Publication Date Title
CN112446785B (en) Cross-chain transaction method, system, device, equipment and storage medium
CN110121727B (en) Method and system for providing authenticated, auditable and immutable input for intelligent contracts
KR102050129B1 (en) Block chain supporting multiple one-way functions used for verification of blocks
CN107239954B (en) Method and device for increasing block generation speed
CN110851870B (en) Block chain privacy protection method, system and medium based on trusted execution environment
EP4050542A1 (en) Blockchain-based data processing method and apparatus, and device and readable storage medium
CN111444211A (en) Block chain consensus node checking method, device, equipment and storage medium
CN111556115B (en) Block chain-based data processing method, device, equipment and storage medium
CN111343212B (en) Message processing method, device, equipment and storage medium
LU102556B1 (en) Blockchain-enhanced open internet of things access architecture
KR102139551B1 (en) Method and server for managing testament
CN111339141B (en) Data transmission method, block chain node equipment and medium
JP2022539283A (en) A method and system for validating blockchain data stored in a storage format different from the blockchain
CN111008251B (en) Data processing method and device
CN112184436A (en) Data synchronization method, electronic device and readable storage medium
US20220245634A1 (en) Blockchain-enhanced open internet of things access architecture
CN113761064A (en) Block chain based daily cutting account checking method, device, equipment and readable storage medium
CN111198763B (en) Method for detecting reuse of resources, terminal and computer-readable storage medium
CN112788555B (en) Cross-operator telephone charge transfer settlement method, device and computing equipment
CN112116346A (en) Block chain for quickly confirming transaction and method for quickly confirming transaction on block chain
CN110163606B (en) Refund method and device based on blockchain and electronic equipment
CN111524011B (en) Parallel link consensus validation method, apparatus, and storage medium
CN111144958B (en) Electronic invoice issuing method, device and system based on block chain
CN109739515B (en) Basic data reporting method applied to Internet mobile application
CN113222744A (en) Method and device for trusted processing of data, storage medium and electronic 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
WW01 Invention patent application withdrawn after publication

Application publication date: 20201222

WW01 Invention patent application withdrawn after publication