JP6467540B1 - Method for verifying transactions in a blockchain network and nodes for configuring the network - Google Patents

Method for verifying transactions in a blockchain network and nodes for configuring the network Download PDF

Info

Publication number
JP6467540B1
JP6467540B1 JP2018043666A JP2018043666A JP6467540B1 JP 6467540 B1 JP6467540 B1 JP 6467540B1 JP 2018043666 A JP2018043666 A JP 2018043666A JP 2018043666 A JP2018043666 A JP 2018043666A JP 6467540 B1 JP6467540 B1 JP 6467540B1
Authority
JP
Japan
Prior art keywords
transaction
bloom filter
block
txid
dictionary
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2018043666A
Other languages
Japanese (ja)
Other versions
JP2019146137A (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.)
BitFlyer Inc
Original Assignee
BitFlyer Inc
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 BitFlyer Inc filed Critical BitFlyer Inc
Priority to JP2018043666A priority Critical patent/JP6467540B1/en
Application granted granted Critical
Publication of JP6467540B1 publication Critical patent/JP6467540B1/en
Publication of JP2019146137A publication Critical patent/JP2019146137A/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

【課題】トランザクションを検証するための方法において、検証速度の高速化を図る。
【解決手段】ブロックチェーン・ネットワークにおいて、第1のノードは、トランザクション(tx)を受け取るS201。第1のノードは、受け取ったtxをブルームフィルターに対する入力として与えるS202。ブルームフィルターは、ブロックチェーンに含まれる過去の1又は複数のtxに基づいて生成される。ブルームフィルターが真を返す場合S202T、第1のノードは、検証対象となるtxのtxidをキーにディクショナリを検索して、その有無を判定するS203。ディクショナリは、過去に合意されたブロックに含まれる1又は複数のtxに基づいて生成される。ディクショナリの検索結果が偽であるときはS203F、検証対象のトランザクションを有効と判定し、ブルームフィルターが偽を返すときS202Fも検証対象のtxを同様に有効と判定するS204。
【選択図】図2
In a method for verifying a transaction, a verification speed is increased.
In a blockchain network, a first node receives a transaction (tx) S201. The first node gives the received tx as an input to the Bloom filter S202. The Bloom filter is generated based on one or more past tx included in the block chain. When the Bloom filter returns true S202T, the first node searches the dictionary with the txid of tx to be verified as a key and determines whether or not there is S203T. The dictionary is generated based on one or more tx included in a previously agreed block. If the dictionary search result is false, S203F determines that the transaction to be verified is valid, and if the Bloom filter returns false, S202F also determines that tx to be verified is also valid S204.
[Selection] Figure 2

Description

本発明は、ブロックチェーン・ネットワークにおいてトランザクションを検証するための方法及び当該ネットワークを構成するためのノードに関する。   The present invention relates to a method for verifying transactions in a blockchain network and nodes for configuring the network.

複数のノードを備えるブロックチェーン・ネットワークにおいて、各ノードは、採択について合意が形成されたブロックが連なったブロックチェーンを有する。各ブロックは、ヘッダと、1又は複数のトランザクションを含むボディとを有する。   In a blockchain network comprising a plurality of nodes, each node has a blockchain with a series of blocks that have been agreed upon for adoption. Each block has a header and a body containing one or more transactions.

各トランザクションは、当該トランザクションのハッシュ値をその識別子とすることができ、当該識別子は「トランザクションid(txid)」と呼ばれることがある。txidは、過去のトランザクションを参照する際に用いられ、そのディクショナリが必要に応じて、1若しくは複数又はすべてのノードにおいて保持されることがある。   Each transaction can have a hash value of the transaction as an identifier, and the identifier may be referred to as “transaction id (txid)”. The txid is used when referring to a past transaction, and the dictionary may be held in one, a plurality, or all nodes as necessary.

txidが用いられる場面の1つとして、同一のトランザクションの二重実行の防止が挙げられる。採択についての合意形成が図られるブロックは、いずれかのノードが、メモリプールに蓄積したトランザクションの中から1又は複数のトランザクションを選んで生成するものであるが、トランザクションをメモリプールに記憶する際に、過去に合意されたブロックに含まれるトランザクションではないかについての検証(vaildation)がなされることがある。また、他のノードにおいて生成されたブロックに含まれるトランザクションに対する検証がなされることがある。   One of the situations where txid is used is prevention of double execution of the same transaction. The block for which consensus is reached regarding the adoption is one in which one or more transactions are selected from the transactions accumulated in the memory pool, and when the transaction is stored in the memory pool. In some cases, a verification is made as to whether the transaction is included in a block agreed upon in the past. In addition, a transaction included in a block generated in another node may be verified.

しかしながら、検証を行うためには、過去に合意されたブロックに含まれるすべてのトランザクションに対するtxidのディクショナリを保持しておき、新たなトランザクションを受け取るたびに当該ディクショナリを参照して、過去に存在していないことの確認を行わなければならず、これは、ブロック高の増大とともに時間又は記憶領域を要する処理となっていく。   However, in order to perform verification, a dictionary of txids for all transactions included in a block agreed in the past is maintained, and each time a new transaction is received, the dictionary is referred to and exists in the past. It must be confirmed that there is no data, and this becomes a process that requires time or a storage area as the block height increases.

本発明は、このような問題点に鑑みてなされたものであり、その目的は、ブロックチェーン・ネットワークにおいてトランザクションを検証するための方法及び当該ネットワークを構成するためのノードにおいて、検証速度の高速化又は記憶領域増大の抑制を図ることにある。   The present invention has been made in view of such problems, and an object of the present invention is to increase the verification speed in a method for verifying a transaction in a blockchain network and a node for configuring the network. Alternatively, it is intended to suppress an increase in storage area.

このような目的を達成するために、本発明の第1の態様は、ブロックチェーン・ネットワークにおいてトランザクションを検証するための方法であって、検証対象となるトランザクションを受け取るステップと、前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたブルームフィルターに対して前記トランザクションを入力するステップと、前記ブルームフィルターの出力が偽である場合、前記トランザクションを有効と判定するステップとを含むことを特徴とする。   In order to achieve such an object, a first aspect of the present invention is a method for verifying a transaction in a blockchain network, the step of receiving a transaction to be verified, and the blockchain network. And entering the transaction to a Bloom filter generated based on one or more transactions included in a block agreed upon in the past, and validating the transaction if the output of the Bloom filter is false. And determining.

また、本発明の第2の態様は、第1の態様において、前記ブルームフィルターの出力が真である場合、前記トランザクションのtxidをキーに、前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたディクショナリを検索するステップと、前記ディクショナリの検索結果が偽である場合、前記トランザクションを有効と判定するステップとを含むことを特徴とする。   The second aspect of the present invention includes, in the first aspect, when the output of the Bloom filter is true, the txid of the transaction as a key, and the block agreed upon in the blockchain network in the past. And a step of searching a dictionary generated based on one or a plurality of transactions, and a step of determining that the transaction is valid when a search result of the dictionary is false.

また、本発明の第3の態様は、第2の態様において、前記ディクショナリの検索結果が真である場合、前記トランザクションを無効と判定するステップをさらに含むことを特徴とする。   According to a third aspect of the present invention, in the second aspect, the method further includes the step of determining that the transaction is invalid when the dictionary search result is true.

また、本発明の第4の態様は、第1から第3のいずれかの態様において、前記ブルームフィルターを構成するためのデータは、メモリに記憶されていることを特徴とする。   According to a fourth aspect of the present invention, in any one of the first to third aspects, data for configuring the Bloom filter is stored in a memory.

また、本発明の第5の態様は、第4の態様において、前記データは、前記過去に合意されたブロックに含まれる1又は複数のトランザクションに対応する1又は複数のtxidから生成されたデータ列であることを特徴とする。   According to a fifth aspect of the present invention, in the fourth aspect, the data is a data string generated from one or more txids corresponding to one or more transactions included in the block agreed in the past. It is characterized by being.

また、本発明の第6の態様は、第5の態様において、前記データ列は、前記トランザクションのtxidよりもビット長が長いことを特徴とする。   According to a sixth aspect of the present invention, in the fifth aspect, the data string has a bit length longer than txid of the transaction.

また、本発明の第7の態様は、第1から第6のいずれかの態様において、前記検証対象となるトランザクションは、合意形成の対象となるブロックに含まれる1又は複数のトランザクションのうちのいずれかであることを特徴とする。   In addition, according to a seventh aspect of the present invention, in any one of the first to sixth aspects, the transaction to be verified is any one of one or more transactions included in a block to be a consensus formation target. It is characterized by.

また、本発明の第8の態様は、第7の態様において、前記検証対象となるトランザクションのtxidをキーに、前記ブロックに含まれる1又は複数のトランザクションに対応する1又は複数のtxidを保持するテンポラリーディクショナリを検索するステップをさらに含むことを特徴とする。   In addition, in an eighth aspect of the present invention, in the seventh aspect, one or more txids corresponding to one or more transactions included in the block are held using the txid of the transaction to be verified as a key. The method further includes searching the temporary dictionary.

また、本発明の第9の態様は、コンピュータに、ブロックチェーン・ネットワークにおいてトランザクションを検証するための方法を実行させるためのプログラムであって、前記方法は、検証対象となるトランザクションを受け取るステップと、前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたブルームフィルターに対して前記トランザクションを入力するステップと、前記ブルームフィルターの出力が偽である場合、前記トランザクションを有効と判定するステップとを含むことを特徴とする。   According to a ninth aspect of the present invention, there is provided a program for causing a computer to execute a method for verifying a transaction in a blockchain network, the method receiving a transaction to be verified; Inputting the transaction to a Bloom filter generated based on one or more transactions included in a block previously agreed in the blockchain network; and if the output of the Bloom filter is false, And determining that the transaction is valid.

また、本発明の第10の態様は、ブロックチェーン・ネットワークにおいてトランザクションを検証するための前記ブロックチェーン・ネットワークを構成するノードであって、検証対象となるトランザクションを受け取り、前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたブルームフィルターに対して前記トランザクションを入力し、前記ブルームフィルターの出力が偽である場合、前記トランザクションを有効と判定することを特徴とする。   According to a tenth aspect of the present invention, there is provided a node constituting the blockchain network for verifying a transaction in the blockchain network, the node receiving the transaction to be verified, and the past in the blockchain network. The transaction is input to a Bloom filter generated based on one or more transactions included in a block agreed to, and if the output of the Bloom filter is false, determining that the transaction is valid Features.

本発明の一態様によれば、ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたブルームフィルターに対して、検証対象となるトランザクションを入力し、真が出力として得られた場合にのみディクショナリへのアクセスを行うことによって、時間を要するディクショナリへのアクセスを抑制してトランザクションの検証を高速化することができる。   According to one aspect of the present invention, a transaction to be verified is input to a Bloom filter generated based on one or a plurality of transactions included in a block agreed in the past in the blockchain network. By accessing the dictionary only when is obtained as an output, access to the dictionary that requires time can be suppressed and transaction verification can be speeded up.

本発明の第1の実施形態にかかるブロックチェーン・ネットワークを示す図である。It is a figure which shows the block chain network concerning the 1st Embodiment of this invention. 本発明の第1の実施形態にかかるトランザクションの検証方法の流れ図である。It is a flowchart of the verification method of the transaction concerning the 1st Embodiment of this invention.

以下、図面を参照して本発明の実施形態を詳細に説明する。   Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings.

(第1の実施形態)
図1に、本発明の第1の実施形態にかかるブロックチェーン・ネットワークを示す。ネットワーク100は、第1のノード101と、第2のノード102と、第3のノード103と、第4のノード104とを備える。これらのノードは、それぞれブロックチェーンを有し、新たなブロックの採択にかかる合意形成に参加する。図1では、4個の例を示しているが、これはあくまで例示である。また、合意形成に参加しないノードがネットワーク100に含まれることもある。以下では、第1のノード101に着目して説明する。その他のノードについても、以下に述べる構成を有することが出来る。
(First embodiment)
FIG. 1 shows a block chain network according to a first embodiment of the present invention. The network 100 includes a first node 101, a second node 102, a third node 103, and a fourth node 104. Each of these nodes has a block chain and participates in consensus building for the adoption of a new block. Although four examples are shown in FIG. 1, this is merely an example. In addition, the network 100 may include nodes that do not participate in consensus building. Hereinafter, the description will be given focusing on the first node 101. Other nodes can also have the configuration described below.

第1のノード101は、通信インターフェースなどの通信部101−1と、プロセッサ、CPU等の処理部101−2と、メモリ等の主記憶装置101−3と、ハードディスク等の補助記憶装置101−4とを備え、各処理を行うためのプログラムを実行することによって構成することができる。第1のノード101は、1又は複数の装置ないしサーバを含むことがあり、また当該プログラムは、1又は複数のプログラムを含むことがあり、また、コンピュータ読み取り可能な記憶媒体に記録して非一過性のプログラムプロダクトとすることができる。   The first node 101 includes a communication unit 101-1 such as a communication interface, a processing unit 101-2 such as a processor and a CPU, a main storage device 101-3 such as a memory, and an auxiliary storage device 101-4 such as a hard disk. And can be configured by executing a program for performing each process. The first node 101 may include one or a plurality of devices or servers, and the program may include one or a plurality of programs. The first node 101 may be recorded on a computer-readable storage medium and stored in a non-unique manner. Can be a transient program product.

また、主記憶装置101−3と補助記憶装置101−4とを分けて説明するものの、これらを同一の記憶装置又は記憶媒体とし、又はこれらを包含する記憶装置又は記憶媒体を記憶部とみることも考えられる。また、主記憶装置101−3及び補助記憶装置101−4は、それぞれ複数の記憶装置又は記憶媒体を含むことも考えられる。また、主記憶装置101−3に記憶されるものとして以下で説明するデータは、CPU等の処理部101−2が有するL1、L2、L3等のキャッシュメモリに記憶されることもあることを付言する。この場合、主記憶装置101−3と処理部101−2が有するキャッシュメモリとを包含して「第1の記憶装置」と呼び、補助記憶装置101−4を包含して「第2の記憶装置」と呼ぶこともできる。   Further, although the main storage device 101-3 and the auxiliary storage device 101-4 will be described separately, they are regarded as the same storage device or storage medium, or the storage device or storage medium including them is regarded as a storage unit. Is also possible. The main storage device 101-3 and the auxiliary storage device 101-4 may each include a plurality of storage devices or storage media. Further, it is noted that the data described below as being stored in the main storage device 101-3 may be stored in a cache memory such as L1, L2, or L3 of the processing unit 101-2 such as a CPU. To do. In this case, the main storage device 101-3 and the cache memory included in the processing unit 101-2 are included to be referred to as a “first storage device”, and the auxiliary storage device 101-4 is included to indicate the “second storage device”. Can also be called.

第1のノード101は、まずブロックチェーン・ネットワーク100内又は外で生成されたトランザクション(tx)を受け取る(S201)。ここで、ネットワーク100においてトランザクションが生成され、自ら受け取ることもある。図1の例では、ネットワーク100の外で生成されたトランザクションが第1のノードによって受け取られている。   The first node 101 first receives a transaction (tx) generated within or outside the blockchain network 100 (S201). Here, a transaction is generated in the network 100 and may be received by itself. In the example of FIG. 1, a transaction generated outside the network 100 has been received by a first node.

検証の対象となるトランザクションの受け取りは、1又は複数のトランザクションを直接受け取る場合のほか、他のノードにおいて生成されたブロックを受信することによって、当該ブロックに含まれる1又は複数のトランザクションを受け取る場合がある。   In addition to receiving one or more transactions directly, receiving a transaction to be verified may receive one or more transactions included in the block by receiving a block generated in another node. is there.

第1のノード101は、受け取ったトランザクションをブルームフィルターに対する入力として与える(S202)。ブルームフィルターは、当該フィルターを構成するためのプログラム及びデータを有するモジュールを主記憶装置101−3又は第1の記憶装置に記憶しておき、当該プログラムを実行することによって動作させることができる。   The first node 101 gives the received transaction as an input to the Bloom filter (S202). The Bloom filter can be operated by storing a module having a program and data for configuring the filter in the main storage device 101-3 or the first storage device and executing the program.

当該データは、ネットワーク100を構成する各ノードが有するブロックチェーンに含まれる過去の1又は複数のトランザクションに基づいて生成されるものであり、より具体的には、当該過去の1又は複数のトランザクションに対応する1又は複数のtxidに基づいて生成することができる。   The data is generated on the basis of one or more past transactions included in the block chain of each node constituting the network 100. More specifically, the data is stored in the past one or more transactions. It can be generated based on the corresponding one or more txids.

txidは、32バイトのハッシュ値とすることができるが、一例として、4ビットの場合について説明する。第1のtxidとして0101、第2のtxidとして1001が過去のトランザクションに対応するtxidとして存在するものとする。これらの2つのtxidの各ビットを重ね合わせて、1101という4ビットのデータ列を生成し、上記ブルームフィルターを構成するためのデータとすることができる。換言すれば、過去の1又は複数のトランザクションに対応する1又は複数のtxidに基づいて、値が1であるビットを重ね合わせて生成したデータ列を当該フィルターを構成するためのデータとすることができる。   Although txid can be a hash value of 32 bytes, a case of 4 bits will be described as an example. It is assumed that 0101 as the first txid and 1001 as the second txid exist as txid corresponding to the past transaction. By superposing these two bits of txid, a 4-bit data string 1101 can be generated and used as data for constituting the Bloom filter. In other words, based on one or a plurality of txids corresponding to one or a plurality of past transactions, a data string generated by superposing bits having a value of 1 may be used as data for configuring the filter. it can.

実際には、txidの長さとデータ列の長さを同一とする必要はなく、過去の1又は複数のトランザクションに対応する1又は複数のtxidになんらかの変換を行ってデータ列をtxidよりも長く生成することもできる。たとえば、txidのビット長よりも10万倍、より好ましくは50万倍、100万倍以上長いのが望ましい。32バイトのtxidに対して100万倍とすると32MBとなり、このようにしても一般的な主記憶装置101−3又は第1の記憶装置に格納することができる。   Actually, it is not necessary to make the length of txid and the length of the data string the same, but some conversion to one or more txid corresponding to one or more past transactions is performed to generate a data string longer than txid. You can also For example, it is desirable that it is 100,000 times longer than the bit length of txid, more preferably 500,000 times and 1 million times or more. If it is 1 million times the txid of 32 bytes, it becomes 32 MB, and in this way, it can be stored in the general main storage device 101-3 or the first storage device.

上記ブルームフィルターは、検証対象として入力されたトランザクションが過去に合意されたブロックに含まれないトランザクションである場合には、出力として必ず偽(False)を返し、出力として真(True)を返すときは、過去に存在したトランザクションであるときとそうでないときがある。過去に存在しないにも関わらず真を返すことを偽陽性と呼ぶ。   When the above-mentioned Bloom filter is a transaction that is not included in a block that has been agreed in the past, the Bloom filter always returns false as an output and returns true as an output. , There are times when it is a transaction that existed in the past and when it is not. Returning true even though it does not exist in the past is called false positive.

実際にはより複雑な処理も可能であるが、上述の4ビットの例で説明すれば、検証対象として4ビットのハッシュ値1001が第1のノード101において新たにブルームフィルターに与えられると、当該フィルターを構成するためのプログラムが、検証対象のトランザクションの値が1であるビットが当該データ列においても1であるか否かを判定する。検証対象のトランザクションの値が1であるビットのすべてにおいて肯定的に判定された場合、ブルームフィルフィルターは真を返す。過去のtxidに1001は存在しないものの、1101との対比において、偽陽性となる。   Actually, more complicated processing is possible. However, in the case of the 4-bit example described above, when a 4-bit hash value 1001 is newly given to the Bloom filter in the first node 101 as a verification target, A program for configuring the filter determines whether or not a bit whose transaction target value is 1 is also 1 in the data string. The Bloomfill filter returns true if all of the bits for which the value of the transaction to be verified is affirmatively determined. Although 1001 does not exist in the past txid, it becomes a false positive in comparison with 1101.

上記ブルームフィルターが真を返す場合、第1のノード101は、検証対象となるトランザクションのtxidをキーに又は当該txidに基づいてディクショナリを検索して、その有無を判定する(S203)。ディクショナリは、過去に合意されたブロックに含まれる1若しくは複数又はすべてのトランザクションに対するtxidを順序付けて保持したものであり、補助記憶装置101−4又は第2の記憶装置に記憶しておくことができる。   When the Bloom filter returns true, the first node 101 searches the dictionary using the txid of the transaction to be verified as a key or based on the txid, and determines the presence or absence (S203). The dictionary holds txid for one or more or all transactions included in a previously agreed block in order, and can be stored in the auxiliary storage device 101-4 or the second storage device. .

ディクショナリの検索結果が偽、すなわち、検証対象のトランザクションのtxidが当該ディクショナリに含まれないときは、検証対象のトランザクションを有効と判定する(S204)。   If the dictionary search result is false, that is, the txid of the transaction to be verified is not included in the dictionary, it is determined that the transaction to be verified is valid (S204).

上記ブルームフィルターが偽を返す場合、検証対象のトランザクションを同様に有効と判定する(S204)。   If the Bloom filter returns false, the transaction to be verified is similarly determined to be valid (S204).

ディクショナリの検索結果が真、すなわち、検証対象のトランザクションのtxidが当該ディクショナリに含まれるときは、検証対象のトランザクションを無効と判定する(S205)。   When the dictionary search result is true, that is, when the txid of the transaction to be verified is included in the dictionary, it is determined that the transaction to be verified is invalid (S205).

以上のように、過去に合意されたブロックに含まれる1又は複数のトランザクション又はそのtxidに基づき、ディクショナリに加えてブルームフィルターを生成し、記憶しておくことによって、時間を要するディクショナリへのアクセスを抑制してトランザクションの検証を高速化することができる。特に、ブルームフィルターモジュールをメモリ等の主記憶装置101−3又は第1の記憶装置に記憶しておくことによって、一層の高速化が図られる。   As described above, a Bloom filter is generated and stored in addition to a dictionary based on one or a plurality of transactions included in a block agreed upon in the past or its txid, thereby allowing access to a time-consuming dictionary. It can be suppressed to speed up transaction verification. In particular, by storing the Bloom filter module in the main storage device 101-3 such as a memory or the first storage device, the speed can be further increased.

ブルームフィルター及びディクショナリは、新たなブロックについて合意形成がなされた後であって次の検証対象のトランザクションを受け取る前に、当該ブロックに含まれる1又は複数のトランザクションについて更新を行うのが望ましい。   It is desirable that the Bloom filter and the dictionary update one or more transactions included in the block after the consensus is reached for the new block and before the next transaction to be verified is received.

上述のブルームフィルターの変形形態として、当該フィルターを構成するためのデータ列の各値をビットではなくバイトの単位として、txidの値が1であるビットに対応する位置のバイトの値を当該位置の値が1であるtxidの数に応じてインクリメントしていくようにしてもよい。第1のtxidとして0101、第2のtxidとして1001が過去のトランザクションに対応するtxidとして存在するものとした場合、生成されるデータ列は、4バイトの1102となる。第3のtxidとして0001をさらに考えると、データ列は、1103となる。このようにすることによって、過去に反映されたtxidの削除が可能となる。この形態においては、一例として、検証対象のトランザクションの値が1であるビットに対応するバイトが当該データ列において1以上の値であるか否かの判定を行うことで真又は偽が定めることができる。ブルームフィルターとして本明細書において説明したフィルターは、説明した所要の動作を行うフィルターであればよい。   As a variation of the above-mentioned Bloom filter, each value of the data string for constituting the filter is a unit of bytes instead of bits, and the byte value at the position corresponding to the bit whose txid value is 1 is You may make it increment according to the number of txid whose value is 1. Assuming that 0101 as the first txid and 1001 as the second txid exist as txid corresponding to the past transaction, the data string to be generated is 1102 of 4 bytes. If 0001 is further considered as the third txid, the data string is 1103. In this way, txid reflected in the past can be deleted. In this form, as an example, true or false may be determined by determining whether or not the byte corresponding to the bit whose transaction value to be verified is 1 is 1 or more in the data string. it can. The filter described in this specification as the Bloom filter may be a filter that performs the required operation described above.

なお、「××のみに基づいて」、「××のみに応じて」、「××のみの場合」というように「のみ」との記載がなければ、本明細書においては、付加的な情報も考慮し得ることが想定されていることに留意されたい。   In addition, in the present specification, additional information is provided unless there is a description of “only”, such as “based only on XX”, “according to XX only”, and “only XX”. Note that it is also assumed that

また、念のため、なんらかの方法、プログラム、端末、装置、サーバ又はシステム(以下「方法等」)において、本明細書で記述された動作と異なる動作を行う側面があるとしても、本発明の各態様は、本明細書で記述された動作のいずれかと同一の動作を対象とするものであり、本明細書で記述された動作と異なる動作が存在することは、当該方法等を本発明の各態様の範囲外とするものではないことを付言する。   Also, just in case, even if there is an aspect of performing an operation different from the operation described in this specification in any method, program, terminal, device, server, or system (hereinafter “method etc.”), each of the present invention The aspect is directed to the same operation as any of the operations described in this specification, and there is an operation different from the operation described in this specification. It is added that it is not outside the scope of the embodiment.

(第2の実施形態)
第1の実施形態においては、検証対象のトランザクションが過去に合意されたブロックに含まれるトランザクションであるか否かの検証について記述したところ、合意対象のブロックに複数の同一のトランザクションが含まれることを防止することはできない。
(Second Embodiment)
In the first embodiment, the verification of whether or not the transaction to be verified is a transaction included in a block that has been agreed in the past has been described. As a result, a plurality of identical transactions are included in the block to be agreed. It cannot be prevented.

そこで、本発明の第2の実施形態においては、第1のノード101は、自ら生成したブロック又は他のノードから受け取ったブロックについて、当該ブロックに含まれる1又は複数のトランザクションに対応する1又は複数のtxidを保持する一時的なテンポラリーディクショナリを生成する。   Therefore, in the second embodiment of the present invention, the first node 101 has, for a block generated by itself or a block received from another node, one or more corresponding to one or more transactions included in the block. Generate a temporary temporary dictionary holding the txid of

たとえば、第1の実施形態において説明した検証方法において、ブルームフィルターが偽を返したとしても(S202)、当該テンポラリーディクショナリを検索して同一のtxidが検出される可能性がある。この場合、検証対象のトランザクションを無効と判定されなければならない。ディクショナリが偽を返したとき(S203)も同様である。また、一律にブルームフィルターを適用する前にすべてのトランザクションについてテンポラリーディクショナリの検索を検証対象のトランザクションのtxidをキーとして行うようにすることもできる。テンポラリーディクショナリの検索時点をランダムに又は所定の規則に従い可変としたり、図2に示すループとは並列な処理として実行することもできる。   For example, in the verification method described in the first embodiment, even if the Bloom filter returns false (S202), there is a possibility that the same txid is detected by searching the temporary dictionary. In this case, it is necessary to determine that the transaction to be verified is invalid. The same applies when the dictionary returns false (S203). It is also possible to search the temporary dictionary for all transactions using the txid of the transaction to be verified as a key before uniformly applying the Bloom filter. The temporary dictionary search time can be changed randomly or in accordance with a predetermined rule, or can be executed in parallel with the loop shown in FIG.

100 ブロックチェーン・ネットワーク
101 第1のノード
101−1 通信部
101−2 処理部
101−3 主記憶装置
101−4 補助記憶装置
102 第2のノード
103 第3のノード
104 第4のノード
100 block chain network 101 first node 101-1 communication unit 101-2 processing unit 101-3 main storage device 101-4 auxiliary storage device 102 second node 103 third node 104 fourth node

Claims (5)

ブロックチェーン・ネットワークにおいてトランザクションを検証するための方法であって、
検証対象となるトランザクションを受け取るステップと、
前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたブルームフィルターに対して前記トランザクション又は前記トランザクションに対応するtxidを入力するステップと、
前記ブルームフィルターの出力が偽である場合、前記トランザクションを有効と判定するステップと、
前記ブルームフィルターの出力が真である場合、前記トランザクションのtxidをキーに、前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたディクショナリを検索するステップと、
前記ディクショナリの検索結果が偽である場合、前記トランザクションを有効と判定するステップと、
前記ディクショナリの検索結果が真である場合、前記トランザクションを無効と判定するステップと
を含むことを特徴とする方法。
A method for validating a transaction in a blockchain network, comprising:
Receiving a transaction to be verified;
Inputting a txid corresponding to the transaction or the transaction to Bloom filter is generated based on one or more transactions included in the block agreed in the past in the block chain network,
Determining that the transaction is valid if the output of the Bloom filter is false;
If the output of the Bloom filter is true, searching a dictionary generated based on one or a plurality of transactions included in a block that has been agreed in the blockchain network using the txid of the transaction as a key When,
Determining that the transaction is valid if the dictionary search result is false;
Determining that the transaction is invalid if the dictionary search result is true.
前記ブルームフィルターを構成するためのデータは、前記過去に合意されたブロックに含まれる1又は複数のトランザクションに対応する1又は複数のtxidから生成されたデータ列であることを特徴とする請求項1に記載の方法。The data for configuring the Bloom filter is a data string generated from one or more txids corresponding to one or more transactions included in the block agreed in the past. The method described in 1. 前記検証対象となるトランザクションは、合意形成の対象となるブロックに含まれる1又は複数のトランザクションのうちのいずれかであることを特徴とする請求項1又は2に記載の方法。 The verification subject to transaction method according to claim 1 or 2, characterized in that any of the one or more transactions included in the block to be consensus. コンピュータに、ブロックチェーン・ネットワークにおいてトランザクションを検証するための方法を実行させるためのプログラムであって、前記方法は、
検証対象となるトランザクションを受け取るステップと、
前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたブルームフィルターに対して前記トランザクション又は前記トランザクションに対応するtxidを入力するステップと、
前記ブルームフィルターの出力が偽である場合、前記トランザクションを有効と判定するステップと、
前記ブルームフィルターの出力が真である場合、前記トランザクションのtxidをキーに、前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたディクショナリを検索するステップと、
前記ディクショナリの検索結果が偽である場合、前記トランザクションを有効と判定するステップと、
前記ディクショナリの検索結果が真である場合、前記トランザクションを無効と判定するステップと
を含むことを特徴とするプログラム。
A program for causing a computer to execute a method for validating a transaction in a blockchain network, the method comprising:
Receiving a transaction to be verified;
Inputting a txid corresponding to the transaction or the transaction to Bloom filter is generated based on one or more transactions included in the block agreed in the past in the block chain network,
Determining that the transaction is valid if the output of the Bloom filter is false;
If the output of the Bloom filter is true, searching a dictionary generated based on one or a plurality of transactions included in a block that has been agreed in the blockchain network using the txid of the transaction as a key When,
Determining that the transaction is valid if the dictionary search result is false;
And determining that the transaction is invalid if the dictionary search result is true.
ブロックチェーン・ネットワークにおいてトランザクションを検証するための前記ブロックチェーン・ネットワークを構成するノードであって、
検証対象となるトランザクションを受け取り、
前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたブルームフィルターに対して前記トランザクション又は前記トランザクションに対応するtxidを入力し、
前記ブルームフィルターの出力が偽である場合、前記トランザクションを有効と判定し、
前記ブルームフィルターの出力が真である場合、前記トランザクションのtxidをキーに、前記ブロックチェーン・ネットワークにおいて過去に合意されたブロックに含まれる1又は複数のトランザクションに基づいて生成されたディクショナリを検索し、
前記ディクショナリの検索結果が偽である場合、前記トランザクションを有効と判定し、
前記ディクショナリの検索結果が真である場合、前記トランザクションを無効と判定することを特徴とするノード。
Nodes constituting the blockchain network for verifying transactions in the blockchain network,
Receive the transaction to be verified,
Enter the txid corresponding to the transaction or the transaction to Bloom filter is generated based on one or more transactions included in the block agreed in the past in the block chain network,
If the output of the Bloom filter is false, determine that the transaction is valid,
If the output of the Bloom filter is true, using the txid of the transaction as a key, search a dictionary generated based on one or more transactions included in a block agreed in the blockchain network in the past,
If the dictionary search result is false, the transaction is determined to be valid,
A node that determines that the transaction is invalid when a search result of the dictionary is true.
JP2018043666A 2018-03-10 2018-03-10 Method for verifying transactions in a blockchain network and nodes for configuring the network Active JP6467540B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2018043666A JP6467540B1 (en) 2018-03-10 2018-03-10 Method for verifying transactions in a blockchain network and nodes for configuring the network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018043666A JP6467540B1 (en) 2018-03-10 2018-03-10 Method for verifying transactions in a blockchain network and nodes for configuring the network

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2018026529A Division JP2019145925A (en) 2018-02-16 2018-02-16 Method for verifying transaction in blockchain network, and node for constituting the network

Publications (2)

Publication Number Publication Date
JP6467540B1 true JP6467540B1 (en) 2019-02-13
JP2019146137A JP2019146137A (en) 2019-08-29

Family

ID=65355994

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018043666A Active JP6467540B1 (en) 2018-03-10 2018-03-10 Method for verifying transactions in a blockchain network and nodes for configuring the network

Country Status (1)

Country Link
JP (1) JP6467540B1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20200092362A1 (en) * 2018-09-13 2020-03-19 International Business Machines Corporation A sparse peer with transient participation
WO2020242190A1 (en) * 2019-05-31 2020-12-03 주식회사 엠티에스컴퍼니 Method for verifying activity information by means of blockchain

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110427432A (en) * 2019-08-08 2019-11-08 英华达(上海)科技有限公司 Violation event processing method, system, equipment and storage medium based on block chain
GB2595489A (en) * 2020-05-28 2021-12-01 Nchain Holdings Ltd Probabilistic membership test for blockchain transaction outputs

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016151802A (en) * 2015-02-16 2016-08-22 科韻動力有限公司 Management method for virtual currency, virtual currency system, advertisement method in virtual currency system, and application program
WO2017042890A1 (en) * 2015-09-08 2017-03-16 株式会社東芝 Database system, server device, program, and information processing method
WO2017079652A1 (en) * 2015-11-05 2017-05-11 Pulsifer Allen Cryptographic transactions system
US20170228731A1 (en) * 2016-02-09 2017-08-10 Fmr Llc Computationally Efficient Transfer Processing and Auditing Apparatuses, Methods and Systems
JP2017200196A (en) * 2017-06-01 2017-11-02 株式会社bitFlyer Private node, processing method in private node, and program therefor
US20170344987A1 (en) * 2016-05-24 2017-11-30 Mastercard International Incorporated Method and system for an efficient consensus mechanism for permssioned blockchains using bloom filters and audit guarantees

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016151802A (en) * 2015-02-16 2016-08-22 科韻動力有限公司 Management method for virtual currency, virtual currency system, advertisement method in virtual currency system, and application program
WO2017042890A1 (en) * 2015-09-08 2017-03-16 株式会社東芝 Database system, server device, program, and information processing method
WO2017079652A1 (en) * 2015-11-05 2017-05-11 Pulsifer Allen Cryptographic transactions system
US20170228731A1 (en) * 2016-02-09 2017-08-10 Fmr Llc Computationally Efficient Transfer Processing and Auditing Apparatuses, Methods and Systems
US20170344987A1 (en) * 2016-05-24 2017-11-30 Mastercard International Incorporated Method and system for an efficient consensus mechanism for permssioned blockchains using bloom filters and audit guarantees
JP2017200196A (en) * 2017-06-01 2017-11-02 株式会社bitFlyer Private node, processing method in private node, and program therefor

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20200092362A1 (en) * 2018-09-13 2020-03-19 International Business Machines Corporation A sparse peer with transient participation
WO2020242190A1 (en) * 2019-05-31 2020-12-03 주식회사 엠티에스컴퍼니 Method for verifying activity information by means of blockchain
KR20200137654A (en) * 2019-05-31 2020-12-09 주식회사 엠티에스컴퍼니 Behavior information proof method by block chain
KR102191803B1 (en) 2019-05-31 2020-12-16 주식회사 엠티에스컴퍼니 Behavior information proof method by block chain

Also Published As

Publication number Publication date
JP2019146137A (en) 2019-08-29

Similar Documents

Publication Publication Date Title
WO2019160128A1 (en) Method for validating transaction in blockchain network and node for configuring same network
JP6467540B1 (en) Method for verifying transactions in a blockchain network and nodes for configuring the network
US10698885B2 (en) Method and device for writing service data in block chain system
JP6626211B2 (en) Method and apparatus for processing short link and short link server
JP6435398B2 (en) Method and system for facilitating terminal identifiers
JP2020513176A5 (en)
JP6362805B1 (en) Method for enabling access to past transactions in a blockchain network and nodes for configuring the network
US11182365B2 (en) Systems and methods for distributed storage of data across multiple hash tables
US10191998B1 (en) Methods of data reduction for parallel breadth-first search over graphs of connected data elements
US20180198819A1 (en) Method and apparatus for generating incident graph database
CN111553670B (en) Transaction processing method and device and computer readable storage medium
CN102880628A (en) Hash data storage method and device
US20170091271A1 (en) Technology to reduce cost of concatenation for hash array
CN109145053B (en) Data processing method and device, client and server
WO2014079282A1 (en) Method and apparatus for storing and verifying redeem code
CN111107181B (en) NAT rule matching method and device, electronic equipment and storage medium
KR20190130933A (en) Method and apparatus for constructing data based blockchain
CN107391033B (en) Data migration method and device, computing equipment and computer storage medium
JP6951846B2 (en) Computer system and task allocation method
JP6233846B2 (en) Variable-length nonce generation
CN107085681B (en) Robust computing device identification framework
KR102416336B1 (en) Device, method, system and computer readable storage medium for managing blockchain
CN113342275B (en) Method, apparatus and computer readable storage medium for accessing data at block link points
CN111506658B (en) Data processing method and device, first equipment and storage medium
KR102248991B1 (en) Apparatus, method and program for controlling connection of neighbor node in block-chain network

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20180310

A871 Explanation of circumstances concerning accelerated examination

Free format text: JAPANESE INTERMEDIATE CODE: A871

Effective date: 20180310

A975 Report on accelerated examination

Free format text: JAPANESE INTERMEDIATE CODE: A971005

Effective date: 20180322

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20180608

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20180717

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20180914

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20181002

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20181213

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20190111

R150 Certificate of patent or registration of utility model

Ref document number: 6467540

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313113

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250