Disclosure of Invention
The invention solves the technical problems that: in view of the above, the embodiment of the invention provides a method and a system for dynamically generating and supervising digital currency crown word numbers, which can solve the problem that digital currency tracks the flow direction of funds layer by layer across banks, support the directional tracking of the flow direction of the currency, and ensure the currency authorities to penetratively supervise the issuing, circulation and return of the digital currency, thereby protecting the privacy of users.
The technical scheme is as follows: in order to solve the above technical problems, in a first aspect, the present invention provides a method for dynamically generating and supervising a digital currency crown word number, including:
constructing a alliance chain of blockchains with currency authorities and commercial banks;
the first digital currency issued by a currency authority is used as a source currency, the first digital currency signed by a commercial bank is used as a destination currency, an originating transaction block is generated, and a plurality of transaction blocks are generated in subsequent transactions of the currency;
the unique number of each digital currency is synthesized by the block hash, the time stamp and the transaction pointer of the block to which each digital currency belongs as the crown word number of the digital currency.
Further, the block hash, the time stamp and the transaction pointer are dynamically generated during the block chain transaction, and cannot be forged and tampered after the block chain record and the certification are carried out.
Further, the crown word number of the digital currency and the transaction list thereof can be queried and supervised through a blockchain browser.
Further, the transaction list comprises a crown word number transaction track and chain of digital currency and transaction information.
Further, the transaction information includes account name, ID, financial institution code, use, amount, transaction line number, source coin, and destination coin identification.
Further, the crown word number transaction track and chain of the digital currency comprise one or any combination of transaction time, transaction amount, source currency owner information, destination currency and destination currency owner information.
In a second aspect, the present invention also provides a system for dynamically generating and supervising digital currency crown word numbers, comprising:
a building module for building a coalition chain of blockchains with currency authorities and commercial banks;
a transaction block generation module; the method comprises the steps of generating an initial transaction block by taking a first piece of digital currency issued by a currency authority as a source currency and a first piece of digital currency signed by a commercial bank as a destination currency, and generating a plurality of transaction blocks by subsequent transactions of the currency;
the system comprises a crown word number generation module, a code generation module and a code generation module, wherein the crown word number generation module is used for synthesizing a unique number of each digital currency as a crown word number of the digital currency by using a block hash, a time stamp and a transaction pointer of a block to which each digital currency belongs;
and the blockchain browser is used for inquiring and supervising the crown word number and the transaction list of the digital currency.
Further, the block hash, the time stamp and the transaction pointer are dynamically generated during the block chain transaction, and cannot be forged and tampered after the block chain record and the certification are carried out.
Further, the transaction list comprises a crown word number transaction track and chain of digital currency and transaction information.
Further, the transaction information includes account name, ID, financial institution code, use, amount, transaction line number, source coin, and destination coin identification.
The beneficial effects are that: compared with the prior art, the invention has the following advantages:
the invention dynamically generates the digital currency crown word number based on the alliance chain, can play the autonomous and controllable advantages of the alliance chain, multiplexes the existing financial infrastructure, reduces the cash production and operation cost, safely and efficiently generates the digital currency crown word number in real time, is beneficial to the currency authorities to penetratingly supervise the full life cycle of the digital currency, regulate and control the currency policy, prevent and fight crimes, and protect the privacy of users.
Detailed Description
The invention will be further illustrated with reference to specific examples, which are carried out on the basis of the technical solutions of the invention, it being understood that these examples are only intended to illustrate the invention and are not intended to limit the scope thereof.
First, the related art related to the embodiment of the present invention includes: a block, a hash algorithm, a timestamp, and a transaction pointer.
The Block (Block) consists of a Block Header (Block Header) and a transaction list contained in the Block. A chunk is a data packet carrying transaction data on a blockchain network, and is a data structure marked with a timestamp and a hash value of a previous chunk, and the chunk verifies and confirms the transaction in the chunk through a consensus mechanism of the network.
A Parent Block (Parent Block) refers to a previous Block of a Block, and the blockchain is temporally ordered by recording the hash values of the Block and the Parent Block at the head of the Block.
The block header records meta-information of the current block, and includes data such as the current version number, hash value of the parent block, timestamp, random number, hash value of MerkleRoot, and the like. In addition, the data record of the zone block generates a unique Merkleroot record in the block head through the Hash process of MerkleTree.
The hash algorithm, also called one-way hash function, is to transform an input of arbitrary length (also called pre-mapped pre-image) into an output of fixed length, which is the hash value, through the hash algorithm. This conversion is a compressed mapping, i.e. the hash value is typically much smaller in space than the input, different inputs may be hashed to the same output, so it is not possible to determine a unique input value from the hash value. Simply stated, a function of compressing messages of arbitrary length to a message digest of a fixed length.
String a function, note message M, one-way hash function H (), hash value H, h=h (M). Normally output characters
The length of the string h is much shorter than the length of the input string M.
A secure one-way hash function should at least meet the following requirements:
1. the input length is arbitrary;
2. the length of the output is fixed;
3. h is easily calculated given M;
4. given H, calculating M from H (M) =h is difficult, i.e. inversion is not feasible;
5. given M, it is computationally infeasible to find another message M 'and to satisfy H (M) =h (M');
6. given H (), it is computationally infeasible to find two different M1 and M2 such that H (Ml) =h (M2).
The hash functions commonly used at present are SM3, SHA256, etc.
And the time stamp ensures that each block is sequentially connected through the time stamp. The time stamp time stamps each piece of data on the blockchain. In short, the timestamp demonstrates what happens on the blockchain and anyone cannot tamper with. The timestamp plays the role of notary in the blockchain.
The transaction pointer is a data structure, specifically a pointer to a data storage location, and is also a hash value of the location data. Compared with the common pointer, the transaction pointer can not only tell you the stored position, but also verify that the data has not been tampered with.
As shown in fig. 1, a method for dynamically generating and supervising digital currency crown word numbers according to an embodiment of the present invention includes:
the federation chain of blockchains is built with currency authorities and commercial banks.
The first digital currency issued by the currency authorities is used as a source currency, the first digital currency signed by the commercial bank is used as a destination currency, an originating transaction block is generated, and a plurality of transaction blocks are generated in subsequent transactions of the currency.
The unique number of each digital currency is synthesized by the block hash, the time stamp and the transaction pointer of the block to which each digital currency belongs as the crown word number of the digital currency. The block hash is the hash value of the block to which each transaction of the digital currency belongs. Because hash pointers are linked with causal links between blocks, the source currency, destination currency, transaction track and chain of the source currency and the destination currency can be known by inquiring the crown word number of the digital currency, and the privacy of a user is protected.
The block hash, the time stamp and the transaction pointer in the embodiment of the invention are dynamically generated during the block chain transaction, and cannot be forged and tampered after the block chain record and the certification are carried out.
The crown word number of the digital currency and its transaction list can be queried and supervised by a blockchain browser. Wherein the transaction list comprises the crown number transaction track and chain of digital currency and transaction information. The transaction information includes account name, ID, financial institution code, use, amount, transaction line number, source coin, and destination coin identification. Inquiring the digital currency crown word number on the blockchain browser, and then finding out the transaction information such as account name, ID, financial institution code, use, amount, transaction flow number, source currency, destination currency identification and the like; otherwise, the source currency and the crown word number of the destination currency associated with the transaction block can be rechecked through certain transaction information. The crown number transaction trace and chain of digital currency includes one or any combination of transaction time, transaction amount, source currency owner information, destination currency and destination currency owner information.
Based on the above embodiments, it can be appreciated by those skilled in the art that the present invention further provides a system for dynamically generating and supervising a digital currency crown word number, including:
a building module for building a coalition chain of blockchains with currency authorities and commercial banks.
A transaction block generation module; the method is used for generating an originating transaction block by taking a first piece of digital currency issued by a currency authority as a source currency and taking the first piece of digital currency signed by a commercial bank as a destination currency, and generating a plurality of transaction blocks by subsequent transactions of the currency.
And the crown word number generation module is used for synthesizing a unique number of each digital currency by using the block hash, the time stamp and the transaction pointer of the block to which the digital currency belongs in each transaction as the crown word number of the digital currency. The block hash is the hash value of the block to which each transaction of the digital currency belongs. Because hash pointers are linked with causal links between blocks, the source currency, destination currency, transaction track and chain of the source currency and the destination currency can be known by inquiring the crown word number of the digital currency, and the privacy of a user is protected. After each transaction, the block hash, the timestamp and the transaction pointer are changed, and a valid crown word number is generated according to the changed block hash, the changed timestamp and the changed transaction pointer, and the crown word number before the transaction is invalidated.
And the blockchain browser is used for inquiring and supervising the crown word number and the transaction list of the digital currency. The transaction list includes the crown number transaction track and chain of digital currency and transaction information. The transaction information includes account name, ID, financial institution code, use, amount, transaction line number, source coin, and destination coin identification. Inquiring the digital currency crown word number on the blockchain browser, and then finding out the transaction information such as account name, ID, financial institution code, use, amount, transaction flow number, source currency, destination currency identification and the like; otherwise, the source currency and the crown word number of the destination currency associated with the transaction block can be rechecked through certain transaction information. The crown number transaction trace and chain of digital currency includes one or any combination of transaction time, transaction amount, source currency owner information, destination currency and destination currency owner information.
The block hash, the time stamp and the transaction pointer in the embodiment of the invention are dynamically generated during the block chain transaction, and cannot be forged and tampered after the block chain record and the certification are carried out.
In the embodiment of the invention, the oriented tracking bank loan scene is taken as an example, and the dynamic generation and compliance supervision of the digital currency crown word number are realized. An enterprise applies 1000 ten thousand yuan to a bank for buying steel materials in 500 ten thousand yuan, buying cement in 300 ten thousand yuan and buying ceramic tiles in 200 ten thousand yuan. After the bank passes the examination before lending, the enterprise loan account is opened on the alliance chain, 1000 ten-thousand-element digital currency is stored in the loan account to be the source currency, the system dynamically generates the crown word number A++, and then when 500 ten-thousand-element, 300 ten-thousand-element and 200 ten-thousand-element digital currency are respectively collected, the system dynamically generates the crown word numbers X++, Y++, and Z++, respectively. The currency authorities and their supervising authorities input crown word numbers A++ on the blockchain browser, namely can know that the crown word numbers of their loan fund flows are X++, Y++, Z++ respectively, can know their account name, ID, financial institution code, use, amount, trade running number, source coin and trade information such as going to coin identification at the same time; otherwise, the source currency and the crown word number of the destination currency associated with the transaction block can be rechecked through certain transaction information.
In summary, the invention dynamically generates the digital currency crown word number based on the alliance chain, can play the autonomous and controllable advantages of the alliance chain, reuse the existing financial infrastructure, reduce the cash production and operation cost, safely and efficiently dynamically generate the digital currency crown word number in real time, is beneficial to the currency authorities to penetratingly supervise the whole life cycle of the digital currency, regulate and control the currency policy, prevent and fight crimes, and protect the privacy of users.
The foregoing is merely a preferred embodiment of the present invention and it should be noted that modifications and adaptations to those skilled in the art may be made without departing from the principles of the present invention, which are intended to be comprehended within the scope of the present invention.