Method and system for securing computer software using a distributed hash table and a blockchain
A computer-implemented method ( 100 ) and system ( 1 ) for determining a metadata M for securing a controlled digital resource such as computer software using a distributed hash table ( 13 ) and a peer-to-peer distributed ledger ( 14 ). This is a blockchain such as the Bitcoin blockchain. The method includes determining ( 110 ) a data associated with the computer software and determining ( 120 ) a first hash value based on the computer software. A second hash value based on the data and the computer software may be determined ( 130 ). The method further includes sending 140 , over a communications network ( 5 ), the data, the first hash value and the second hash value to an entry for storage in a distributed hash table ( 13 ). The second hash value may be a key of a key-value pair. The data and the first hash value may be a value in the key-value pair. A metadata (M) that is based on the second hash value may be determined ( 150 ) for storage on the peer-to-peer distributed ledger ( 14 ).
1. A computer-implemented method ( 100 ) for authorizing access to computer software for a first user (U 1 ), the method comprising:
determining a data (D 1 ) associated with the computer software, wherein the data (D 1 ) comprises a licence associated with the computer software, and the licence is associated with the first user (U 1 ) or a second user (U 2 ) and further comprises a first user public key (PU 1 ) associated with the first user (U 1 ) or a second user public key (PU 2 ) associated with the second user (U 2 );
determining a first hash value (H 1 ) of the computer software;
determining a second hash value (H 2 ) based on the data (D 1 ) and the computer software;
sending, over a communications network, the data (D 1 ), the first hash value (H 1 ) and the second hash value (H 2 ) to an entry for storage in a distributed hash table as a key-value pair, wherein the second hash value (H 2 ) is a key of a key-value pair and the data (D 1 ) and the first hash value (H 1 ) are a value in the key-value pair;
determining a metadata (M) comprising the second hash value (H 2 ) for storage on a peer-to-peer distributed ledger; and
determining a second redeem script (RS 2 ), wherein the second redeem script (RS 2 ) is based on:
the metadata (M),
an agent public key (PA) associated with an agent (A), and
the first user public key (PU 1 ) associated with the first user (U 1 ); and
sending, over a second communications network, a second data output (O 2 ) to the peer-to-peer distributed ledger based on:
an indication that a first quantity of cryptocurrency (C 1 ) from a first data output (O 1 ) is to be transferred, and
the second redeem script (RS 2 ).
2. The method of claim 1 , further comprising:
determining a first redeem script (RS 1 ), wherein the first redeem script is based on:
the metadata (M); and
an agent public key (PA) associated with an agent (A).
3. The method of claim 2 , further comprising:
sending, over the communications network, a first data output (O 1 ) for storage on the peer-to-peer distributed ledger based on:
an indication of a first quantity of cryptocurrency (C 1 ) to be transferred, wherein the first quantity of cryptocurrency (C 1 ) is associated with the first redeem script (RS 1 ); and
the first redeem script (RS 1 ).
4. The method of claim 1 wherein the licence further comprises a hash value associated with at least one electronic device of the first user (U 1 ) or the second user (U 2 ).
5. The method of claim 1 wherein the licence further comprises the first hash value (H 1 ).
6. The method of claim 1 wherein the licence comprises a top hash value of a Merkle tree.
7. The method of claim 1 , further comprising:
determining an identifier indicative of a location of the computer software or the licence;
assigning the identifier to the value in the key-value pair; and
sending, over the communications network, the identifier to the entry on the distributed hash table.
8. The method of claim 1 , further comprising:
determining an identifier indicative of a location of the computer software or the licence;
assigning the identifier to the value in the key-value pair;
sending, over the communications network, the identifier to the entry on the distributed hash table;
determining the metadata (M) from a first redeem script (RS 1 );
retrieving the second hash value (H 2 ) from the metadata (M);
sending over the communications network, the second hash value (H 2 ) to a processor associated with a participating node of the distributed hash table; and
determining, from the processor of the participating node, the identifier indicative of the location of the computer software or licence.
9. The method of claim 3 wherein the cryptocurrency is Bitcoin.
10. The method of claim 1 wherein the peer-to-peer distributed ledger is a blockchain.
11. A non-transitory computer readable medium comprising machine-readable instructions, that when executed by a processing device comprising a processor and memory, cause the processing device to:
determine a data (D 1 ) associated with computer software, wherein the data (D 1 ) comprises a licence associated with the computer software, and the licence is associated with a first user (U 1 ) or a second user (U 2 ) and further comprises a first user public key (PU 1 ) associated with the first user (U 1 ) or a second user public key (PU 2 ) associated with the second user (U 2 );
determine a first hash value (H 1 ) of the computer software;
determine a second hash value (H 2 ) based on the data (D 1 ) and the computer software;
send, over a communications network, the data (D 1 ), the first hash value (H 1 ) and the second hash value (H 2 ) to an entry for storage in a distributed hash table as a key-value pair, wherein the second hash value (H 2 ) is a key of a key-value pair and the data (D 1 ) and the first hash value (H 1 ) are a value in the key-value pair;
determine ( 150 ) a metadata (M) comprising the second hash value (H 2 ) for storage on a peer-to-peer distributed ledger; and
determine a second redeem script (RS 2 ), wherein the second redeem script (RS 2 ) is based on:
the metadata (M),
an agent public key (PA) associated with an agent (A), and
the first user public key (PU 1 ) associated with the first user (U 1 ); and
sending, over a second communications network, a second data output (O 2 ) to the peer-to-peer distributed ledger based on:
an indication that a first quantity of cryptocurrency (C 1 ) from a first data output (O 1 ) is to be transferred, and
the second redeem script (RS 2 ).
12. A computer system operative authorize access to computer software for a first user (U 1 ), the computer system comprising a computing device associated with a node, configured to:
determine a data (D 1 ) associated with the computer software, wherein the data (D 1 ) comprises a licence associated with the computer software, and the licence is associated with the first user (U 1 ) or a second user (U 2 ) and further comprises a first user public key (PU 1 ) associated with the first user (U 1 ) or a second user public key (PU 2 ) associated with the second user (U 2 );
determine a first hash value (H 1 ) of the computer software;
determine a second hash value (H 2 ) based on the data (D 1 ) and the computer software;
send, over a communications network, the data (D 1 ), the first hash value (H 1 ) and the second hash value (H 2 ) to an entry for storage in a distributed hash table as a key-value pair, wherein the second hash value (H 2 ) is a key of a key-value pair and the data (D 1 ) and the first hash value (H 1 ) are a value in the key-value pair;
determine a metadata (M) comprising the second hash value (H 2 ) for storage on a peer-to-peer distributed ledger; and
determine a second redeem script (RS 2 ), wherein the second redeem script (RS 2 ) is based on:
the metadata (M),
an agent public key (PA) associated with an agent (A), and
the first user public key (PU 1 ) associated with the first user (U 1 ); and
sending, over a second communications network, a second data output (O 2 ) to the peer-to-peer distributed ledger based on:
an indication that a first quantity of cryptocurrency (C 1 ) from a first data output (O 1 ) is to be transferred, and
the second redeem script (RS 2 ).