Login| Sign Up| Help| Contact|

Patent Searching and Data


Title:
SYSTEM, DEVICE AND METHOD FOR SECURELY TRANSFERRING INFORMATION FROM A HARDWARE TO A BLOCKCHAIN
Document Type and Number:
WIPO Patent Application WO/2020/121265
Kind Code:
A1
Abstract:
The present disclosure is directed to a system and a method for acquiring data related to a certain event from a source like a data network gateway or an industrial machine or a set of sensors, extract relevant information from the acquired data, encrypt the information by means of hardware powered security chips and then securely transfer the information to a single or multiple blockchain, or other kind of distributed ledgers, for validation, automatically and without any need of human intervention.

Inventors:
BALDI GIACOMO (IT)
FANTONI GUALTIERO (IT)
MAZZEI DANIELE (IT)
MONTELISCIANI GABRIELE (IT)
Application Number:
PCT/IB2019/060750
Publication Date:
June 18, 2020
Filing Date:
December 13, 2019
Export Citation:
Click for automatic bibliography generation   Help
Assignee:
TOI S R L (IT)
International Classes:
G06F21/34; G06F21/64; G06F21/71; H04L9/08
Foreign References:
EP2953290A12015-12-09
US20180034625A12018-02-01
EP3413507A12018-12-12
US20180101906A12018-04-12
Other References:
RELEASE: "Ledger Documentation Hub", 1 August 2017 (2017-08-01), XP055607219, Retrieved from the Internet
"Mastering bitcoin : [unlocking digital cryptocurrencies]", 20 December 2014, O'REILLY MEDIA, Beijing Cambridge Farnham Köln Sebastopol Tokyo, ISBN: 978-1-4493-7404-4, article ANDREAS M. ANTONOPOULOS: "Mastering Bitcoin - Unlocking Digital Cryptocurrencies", XP055306939
Download PDF:
Claims:
CLAIMS

1. A data communication system for transferring data from a hardware unit to a blockchain (12) or other distributed ledger, comprising:

a hardware interface (1 1 ) to connect to the hardware unit;

a device (10) in turn comprising

a microcontroller (80),

a secure element (82) connected to the microcontroller (80), first communication module (85),

a communication protocol for enabling the microcontroller (80) to communicate with the hardware interface (1 1 ) through the first communication module (85),

wherein the microcontroller (80) is adapted to: read data from the hardware unit through the hardware interface (1 1 ); generate a transaction corresponding to the data; securely generate a blockchain private key, dB, and store it into the secure element (82); digitally sign the transaction by means of the blockchain private key, dB; deliver the signed transaction, and then delete the blockchain private key, de, from the secure element (82) characterized in that the microcontroller (80) is adapted to generate a blockchain private key, de, from parameters contained part in the device (10) itself and part in the hardware interface (11 ).

2. The system according to one or more of the preceding claims, characterized in that it further comprises a second communication module (81 ) for connecting to a remote server where a blockchain (12) or a generic distributed ledger node is hosted and for directly delivering the signed transaction into the blockchain (12) or into the generic distributed ledger.

3. The system according to one or more of the preceding claims, characterized in that the communication protocol for enabling the microcontroller (80) to communicate with at least a hardware unit through the first communication means (85) is based on the Hayes command set.

4. The system according to one or more of the preceding claims, characterized in that the secure element (82) comprises means for secure storage (83) and a hardware cryptographic engine (84).

5. The system according to one or more of the preceding claims, characterized in that the hardware interface (1 1 ) comprises a computational unit, communication means adapted to connect to the device (10) to exchange data and memory means for storing the data.

6. The system according to the preceding claim, characterized in that the memory means are secure memory means.

7. Method for transferring data from a hardware unit to a blockchain (12) or other distributed ledger with the system according to one or more of the preceding claims, wherein an initial priming phase is performed comprising the following steps:

the hardware interface (1 1 ) generates and stores a Unique Identifier string, UIDH, a Private Key, dH, and a Public Key, QH;

the hardware interface (1 1 ) prompts the device (10) by sending a priming command and the Public Key, QH, through the first communication module (85);

the device (10) extracts (63) the public key QH of the hardware interface (11 ); the device (10) generates (64) a Private Key, dD, and a Public Key, QD and stores them in the secure element (82);

the device (10) sends (65) the Public Key QD to the hardware interface (1 1 ) and stores (66) the Public key QH in the secure element (82);

the device (10) generates (67) a Unique Identifier string UIDD and stores it (68) in the secure element (82).

8. Method according to the preceding claim wherein a first transaction phase is performed comprising the following steps:

the hardware interface (1 1 ) sends a command to initiate a blockchain transaction to the device (10) with a primed secure element that does not contain a dongle blockchain address, QB;

the hardware interface (1 1 ) and the device (10) cooperate in securely generating and exchanging (70) a secret key K, said secret key K being generated from the keys dD, QD, dH and QH; the device (10) decrypts (71 ) the command received using the secret key K and extracts (72) the hardware interface Unique Identifier, UIDH, and the message, M, to be sent to the blockchain (12);

the device (10) reads the Unique Identifier string, UIDD, from the secure storage (82) and generates (73) from UIDD and UIDH the blockchain private key dB;

the device (10) derives (74) the blockchain address, QB, from the blockchain private key de and then the blockchain address, QB, is stored (75) into the secure element (82);

the device (10) generates (76) the blockchain transaction and sends it to the blockchain;

the device (10) deletes UIDH, de, UIDD and QB.

9. Method according to one or more of the claims from 7 to 8 wherein the nth transaction phase, when n > 1 , is performed comprising the following steps: the hardware interface (1 1 ) sends a blockchain AT command to the device

(10) with a primed secure element that contains the dongle blockchain address QB;

the hardware interface (1 1 ) and the device (10) cooperate in securely generating and exchanging (1 10) a secret key K, said secret key K being generated from the keys dD, QD, dH and QH;

the device (10) decrypts (1 11 ) the command received using the secret key K and extracts (1 12) the hardware interface Unique Identifier, UIDH, and the message, M, to be sent to the blockchain (12);

the device (10) reads the Unique Identifier string, UIDD, from the secure storage (82) and generates (1 14), from UIDD and UIDH, the blockchain private key dB;

the device (10) derives (1 14) the blockchain address, QB, from de;

the device (10) compares (1 15) the blockchain address, QB, as calculated at the previous step, with the the blockchain address, QB, stored in the secure element (82);

if the blockchain addresses compared at the previous step differ, the transaction is not generated (116), if the blockchain addresses compared at the previous step match, then the device (10) generates (1 17) a blockchain transaction from the message M and the blockchain private key dB;

the device (1 0) deletes U I DH, dB, U I DD and QB.

10. Method according to one or more of the claims from 8 to 9 wherein the step of generating (76, 1 17) a blockchain transaction is carried out as follows: the device (10) extracts (120) from the message M the address, QT, of the blockchain receiving the transaction;

the device (10) extracts (121 ) from the message M additional data, D, to be embedded in the blockchain transaction;

the device (10) generates (122) a blockchain transaction, T, by signing the tuple (QT,D) with de.

1 1 . Method according to one or more of the claims from 8 to 10 wherein the step of generation of the blockchain private key, de, is carried out by the interaction of the device (10) with multiple hardware interfaces (1 1 ) each one carrying a different U IDH and dH.

12. Method according to one or more of the claims from 8 to 1 1 wherein the step of generation of the blockchain private key de is carried out only when a subset of at least m hardware interfaces (1 1 ) of the total n hardware interface (1 1 ) interacts with the device (10).

13. A device (10) for transferring data from a hardware unit to a blockchain (12) or other distributed ledger, comprising:

a microcontroller (80),

a secure element (82) connected to the microcontroller (80),

a first communication module (85),

a communication protocol for enabling the microcontroller (80) to communicate with an external hardware interface (1 1 ) through the first communication module (85), wherein the microcontroller (80) is adapted to: read data from the hardware unit through the hardware interface (1 1 ); generate a transaction corresponding to the data; securely generate a blockchain private key, de, and store it into the secure element (82); digitally sign the transaction by means of the blockchain private key, de; deliver the signed transaction, and then delete the blockchain private key, dB, from the secure element (82).

14. The device (10) according to claim 13, characterized in that the microcontroller (80) is adapted to generate a blockchain private key, dB, from parameters contained part in the device (10) itself and part in the hardware interface (1 1 ).

15. The device (10) according to one or more of the preceding claims, characterized in that it further comprises a second communication module (81 ) for connecting to a remote server where a blockchain (12) or a generic distributed ledger node is hosted and for directly delivering the signed transaction into the blockchain (12) or into the generic distributed ledger.

16. The device (10) according to one or more of the claims from 13 to 15, characterized in that it is manufactured in form of a dongle.

Description:
SYSTEM, DEVICE AND METHOD FOR SECURELY TRANSFERRING INFORMATION FROM A HARDWARE TO A BLOCKCHAIN

BACKGROUND OF THE INVENTION

The new frontier of cyber security attacks is rapidly shifting from single computers to companies, always finding new and more sophisticated ways for extorting money or disrupting businesses. This trend is demonstrated by the recent attacks to major companies worldwide in different fields like transportation, logistics, banking and even military facilities.

Companies very often have or are a part of supply chains wherein an integrated enterprise manages the entire logistic chain by sharing the information with its partners or the other components of the supply chain. Some of them have businesses that partially overlap and while they collaborate in a supply chain, they may be competitors in other markets or activities. Therefore, a possible cyber-attack to one of the companies of the supply chain can affect the supply chain but can also alter the competition outside the supply chain.

Warehouse goods are generally monitored by control systems based on sensors. Without an effective anti-tampering protection, a cyber-attacker can, for instance, tamper with said systems in order to decrease the stock of a component in the warehouse of a single supplier thus mimicking a close/incoming stock shortage. Thus, an immediate order (sometimes automatic orders are activated in case of stock shortages) to replenish the warehouse is generated, based on a wrong information. The cyber-attack to fake an imminent stock shortage can be launched when the raw material costs are higher, thus inducing extra costs and ultimately altering the fair competition within and outside the supply chain.

After the order is placed the cyber-attacker could even restore the correct value of the stock, thus virtually cancelling the trace of his/her tampering or at least making the detection of the tampering very difficult to be carried out.

Another typical cyber security attack scenario is when the cyber-attacker operates in the opposite direction by increasing the quantities of some or all the raw materials in the warehouse. Trusting on the warehouse automatic management system, no one detects the missing items and the production stops because one or more parts are out of stock. Penalties will then be charged to the supplier responsible for the out of stock items. In some cases, the supplier can be removed from the supply chain.

Cyber security attacks launched against enterprises which are part of a supply-chain of companies sharing sensitive information, can therefore cause unfair competition issues between the companies of the supply chain. A supplier A of a certain component within a supply chain SC1 can be a competitor of the supplier B in another supply chain SC2. Having access to sensitive information concerning the supplier B in supply chain SC1 (for example regarding machine failures, production rescheduling, etc.), the supplier A can decide to make an offer in supply chain SC2 knowing that supplier B is experiencing problems, thus gaining new market share in an unfair way.

The above sensitive information can regard certain type of goods that a company handles and deal with. In fact, certain goods have a value that varies during their lifetime: radioactive drugs decay according to a proper time function, perishables goods have to be maintained under certain temperature conditions, fragile goods must be kept under certain maximum acceleration stress (impacts). Therefore, the value of these goods changes according to the time of the transport, the temperature-time situation, the acceleration to which they are subjected, and other key parameters. Supply contracts can thus be signed envisaging different values and agreements according to a particular function depending on one or more monitored key parameters. It is apparent that the monitoring and the following transmission of such parameters (normally performed by control systems associated with a number of sensors) is a sensitive task that can be subjected to potentially disruptive cyber-attacks.

In other cyber security attack scenarios, the control parameters of some apparatus, managed by control systems associated with sensors, can be slightly altered and changed, day by day, while keeping the value reported on the apparatus control interface stable at the nominal level. This will bring the apparatus to work out of the correct working zone causing abnormal stress and premature failures and damages. It would be thus desirable to design and provide a method and a device for secure data communication, adapted to interface set of sensors and multiple industrial machines based on microcontrollers or on low-end microprocessors in a secure way, thus overcoming the aforementioned drawbacks.

BRIEF DESCRIPTION OF THE INVENTION

Microcontrollers are electronic devices integrated on a single chip. While their principle of operation is common to the microprocessors, microcontrollers are differentiated by the fact of carrying the memory elements and the interface devices required for the digital control of specific applications on board, mostly in embedded systems that include sensors and actuators for most varied purposes. Unfortunately, microcontrollers have a limited memory space and computational resources thus making complex the use of cryptographic primitives (e.g. https based on big integer arithmetic) for secure communications between them or with other machines, gateways, etc. Such lack of resources has limited also the adoption of other cryptography-based technologies as, for example, a blockchain or other distributed ledgers. Same drawbacks apply to low-end microprocessors.

The present disclosure is directed to methods and systems for acquiring data from a source (for instance a data network gateway or an industrial machine endowed with PLCs, Programmable Logic Controllers, or other types of controllers, microcontrollers, low-end microprocessors, or with a set of sensors) generate a transaction from the data, encrypt the transaction by means of hardware powered security chips and finally securely transfer the transaction to a blockchain using a device based on a microcontroller or a generic low computational power device.

An example of transaction can be, for instance, related to data concerning a warehouse movement where an item x has been scanned and transferred from one location to another. Thus, the data acquired by the system of the present invention may refer to the event of the warehouse movement and the transaction that is generated may comprise the code of the item x, the time and date of the transfer of the item x, the initial and the final location of the item x. With the system according to the present disclosure this transaction is generated, encrypted and transferred to a blockchain (or other distributed ledger) in order to securely certify the event, it refers to (in the above example, the warehouse movement of the item x).

The device according to the present invention is capable of interfacing, without human intervention, single or multiple industrial machines or set of sensors with single or multiple blockchain or other DLT (Distributed Ledger Technology) implementations. Thus, in the present disclosure, the term“blockchain” is to be considered referring to any distributed ledger.

Preferably, the device according to the present invention is implemented as a dongle, a small piece of hardware adapted to connect to another device to provide it with additional functionality.

According to a preferred embodiment, the device of the present invention is a dongle provided with communication capability: thus, the dongle generates and certifies the transactions and also writes them into the blockchain. The hardware to which the dongle is connected does not need to have communication capability and it can be also a RFID reader or a beacon or other similar piece of hardware (active or passive) that can be read by the dongle in order to acquire the information, e.g. identity, timestamp, or any other metadata stored in said hardware, metadata that the dongle will use to write a message in the blockchain.

According to another preferred embodiment, the device of the present invention is a dongle with no communication capability: thus, the dongle only generates and certifies the transactions, while the hardware to which the dongle is connected is responsible to write the certified transactions into the blockchain.

According to a further embodiment, the device of the present invention is a modular dongle adapted to be added or embedded as, for instance, a hardware part in the electronic control module of an industrial apparatus.

According to another embodiment, the device of the present invention is a multi input dongle adapted to receive and process input data from a plurality of sources. Further features and advantages of the present invention will be apparent in the following description of a non-limitative embodiment with reference to the figures in the accompanying drawings, which are diagrammatic and show functional blocks which are adapted to be implemented with a hardware structure according to different circuitry solutions in practice or with a software structure, for example coded into firmware and executed by a suitable hardware. In detail:

BRIEF DESCRIPTION OF THE DRAWINGS

Fig. 1 shows a schematic block diagram of preferred embodiments of the system according to the present disclosure in the cases where a) the device of the invention is provided with connecting means to write a transaction into a remote distributed ledger, b) the device of the invention is not provided with connecting means to write a transaction into a remote distributed ledger;

Fig. 2 shows a schematic block diagram of a preferred embodiment of the system according to the present disclosure wherein the data exchange during initial setup, “priming”, phase is illustrated;

Fig. 3 shows a schematic block diagram of a preferred embodiment of the system according to the present disclosure wherein a secure key K is exchanged between the device of the invention and a connected hardware interface;

Fig. 4 shows a schematic block diagram of a preferred embodiment of the system according to the present disclosure wherein a hardware monotonous counter is employed within the device of the invention to provide additional security;

Fig. 5 shows a schematic block diagram of a preferred embodiment of the system according to the present disclosure wherein a first transaction between the device of the invention and a connected hardware Interface, and the generation of the blockchain private key is illustrated;

Fig. 6 shows a schematic block diagram of a preferred embodiment of the priming process within the device of the invention;

Fig. 7 shows a schematic block diagram of a preferred embodiment of a first transaction within the device of the invention;

Fig. 8 shows a preferred embodiment of the device according to the present disclosure in the cases where a) the device of the invention is provided with connecting means to write a transaction into a remote distributed ledger, b) the device of the invention is not provided with connecting means to write a transaction into a remote distributed ledger;

Fig. 9 shows an additional schematic block diagram of a preferred embodiment of the priming process within the system of the invention with the steps performed by the device of the invention and by the hardware interface highlighted;

Fig. 10 shows an additional schematic block diagram of a preferred embodiment of a first transaction within the system of the invention with the steps performed by the device of the invention and by the hardware interface highlighted; Fig. 1 1 shows a schematic block diagram of a preferred embodiment of a n th transaction, when n >1 , within the device of the invention;

Fig. 12 shows a schematic block diagram of a preferred embodiment of blockchain transaction process between the device of the invention and a blockchain node, and Fig. 13 shows an additional schematic block diagram of a preferred embodiment of a n th transaction, when n >1 , within the system of the invention with the steps performed by the device of the invention and by the hardware interface highlighted. DETAILED DESCRIPTION OF THE INVENTION

The present disclosure is directed to methods, systems and devices for acquiring data from a source (for instance a data network gateway or an industrial machine endowed with PLCs - Programmable Logic Controllers -, or other types of controllers, microcontrollers, low-end microprocessors, or with a set of sensors) extract information from the data, encrypt the information by means of hardware powered security chips, generating a transaction corresponding to the information extracted from the data and finally securely transfer the information to a blockchain - or any other generic distributed ledger - using a device based on a microcontroller or a generic low computational power device.

The device according to the present invention is capable of interfacing single or multiple industrial machines or set of sensors with single or multiple blockchain or other DLT (Distributed Ledger Technology) implementations, without human intervention. Preferably, the device according to the present invention is implemented as a dongle, a small piece of hardware adapted to connect to another device or apparatus to provide it with additional functionality.

With reference to Fig. 8, a preferred embodiment of the device 10 according to the invention comprises a PLC, a microcontroller, a low-end microprocessor or a generic low computational power device 80, a first communication module 85 and a secure element 82 comprising secure storage means 83 and a hardware cryptographic engine 84. A secure element 82 is a chip which can store sensitive data and run secure applications for performing tasks such as, e.g. a payment. The secure element 82 acts as a vault, protecting what's inside the secure element 82 (both applications and data) from possible malware attacks that may happen, e.g., in the host system. An example of secure element 82 is the commercially available device ATECC608A by the company Microchip™.

The first communication module 85 is adapted to communicate with external digital systems, e.g. a machine interface 1 1 adapted to connect the device 10 with another external hardware unit, said machine interface 1 1 being hereinafter referred to as hardware interface 1 1 . The hardware interface 1 1 is provided with a computational unit that can be implemented on a microcontroller. A second device 10 according to this disclosure can also be configured to operate as a hardware interface 1 1 and to communicate with the first device 10. In other embodiments the hardware interface 1 1 may comprise a programmable machine interface that can be modified to interact with the device 10 of the invention and its protocol. In further embodiments the hardware interface 1 1 may be embedded into the external hardware unit to which the device 10 needs to connect.

Preferably, the features of a hardware interface 1 1 are: capability to compute basic cryptographic primitives (such as, e.g., Elliptic curve cryptography, RSA cryptography, SHA functions); communication capability (e.g. Ethernet, Wi-Fi, Bluetooth, serial, etc.); capability to store data in memory means, preferably in secure memory means.

In the following part of this disclosure the terms cryptographic keys and random strings are used. These terms are both defined as random sequences of bits generated on a FIPS-140 compliant hardware module by a random bit generator with features approved by security standards such as FIPS-186-3. The difference between the two terms is functional: a cryptographic key is a random string used as a key in a cryptographic algorithm whereas a random string is not. Cryptographic keys are used to encrypt messages by means of appropriate cryptographic algorithms; in such context a message is defined as a sequence of bits formatted according to a convention common to the sender and the receiver of the message. Encrypted messages, being sequences of bits, can be transmitted by means of different technologies over different mediums (electromagnetic fields, rays of light, electrical currents, etc.); abstracting away from the particular technology, a message is said to be transmitted over a channel; generally, sequences of bits transmitted over a channel can be intercepted by any actor (any attacker) having access to such channel, thus allowing the actor to read the transmitted information. Therefore, if the information to be transmitted is required to be known only by the sender and the intended receiver, such information is usually suitably modified by a cryptographic algorithm (i.e. encrypted) in such a way that even if the encrypted information being transmitted is read by an attacker, the attacker can't reverse the cryptographic algorithm in a computationally feasible manner to obtain the unencrypted information

Regarding the interaction with a blockchain or with a generic remote distributed ledger, a crucial issue regarding the device 10 according to the present invention is the storage of the private key that controls the blockchain address. It is a crucial issue because, if the storage of a key is not secure, then it exposes the key itself to advanced hacking techniques like thermography or direct hardware access.

Today there are two kind of hardware specialized in storing blockchain keys and adapted to generate transactions: hardware wallets and hardware security modules or HSMs.

Regarding hardware wallets, the generation of a transaction from these devices is consequent to a human decision, therefore the key can be stored in an encrypted form that can be decrypted by asking via a human interface for a pin, a password, a biometric or more generally a piece of data from which the original private key can be reconstructed and used to sign a transaction. While this approach is meaningful for hardware wallets designed for humans, it is not feasible for the device according to the present invention the purpose of which is to allow other connected hardware to participate in a blockchain platform.

Regarding HSMs, they can generate and store private keys and signing data with said private keys, adopting different levels of safeguards against tampering. However, their level of sophistication comes at a relatively high price and they are normally designed as a general-purpose secure storage for a huge number of private keys for banking, payment and certification applications.

Instead of storing the private key somewhere, the approach used in the blockchain device according to the present invention makes it possible to generate the private key from parameters contained part in the device itself and part in other hardware units, namely a hardware interface 1 1 , interacting with the device 10 over a communication channel. In such a way, any physical tampering with the device 10 will not disclose the private key since the private key is not entirely stored either in the device or in the connected hardware.

In further detail, the blockchain private key is built from two pieces of information coming from different sources. The first piece of information is initially generated and saved securely within the secure element 82 at the initialization of the device. This first piece of information is not known to the user who performs the initialization of the device, it is known to the device only and it never leaves the device itself. The second piece of information is provided by the single hardware interface 1 1 or by the multiple hardware interfaces 1 1 to which the device 10 is connected through the first communication module 85.

The device microcontroller, low-end microprocessor or generic low computational power device 80 is adapted to carry out an algorithm to generate (or reconstruct) the blockchain private key, digitally sign the transaction, deliver the transaction and then delete the blockchain private key from memory.

The blockchain device according to the present disclosure is adapted to interface multiple industrial machines or set of sensors with multiple blockchain and other DLT (Distributed Ledger Technology) implementations, without human intervention. With reference to enclosed Fig. 1 a) and Fig. 8 a), the device 10 according to the present disclosure can be provided with a second communication module 81 for connecting to a remote server where a blockchain or a generic distributed ledger node is hosted and for writing the transaction into a blockchain. Fig. 1 a) shows a device 10 according to the invention that is therefore adapted to generate and certify transactions and writing the transactions into the blockchain.

In this embodiment the device may be adapted to read from a RFID or from a beacon or from a similar - active or passive - piece of hardware. As a non-limiting example, the device 10 will be associated to an RFID reader. Every time that the reader reads an RFID (e.g. a warehouse movement regarding an item x that was sold at a certain time y), then the collected data - e.g. code and identity of the item, timestamp of the movement, operator ID and other metadata - will be sent by the RFID reader to the device 10 that will format the received data into a transaction, sign the transaction and send it to the blockchain, thus securely certifying that the item x was sold at the time y.

Fig 1 b) shows a device 10 according to the present disclosure with no communication capability, while the connected hardware interface 1 1 is provided with means of communication. In this embodiment, the device 10 only signs the transactions, while the hardware is responsible to write the signed transactions into the blockchain.

The communication protocol between the hardware interface 1 1 and the device 10 according to the present disclosure may take place - through the first communication module 85 - over a wired or wireless channel and is agnostic with respect to the platform on which it is performed and therefore compatible with existing standards regarding both cryptography and protocol format; one possible and convenient implementation of the protocol is based on the Hayes command set, a popular command set, used for decades in telecommunications and networking, also known as AT command set (with AT short for attention). The AT command set has been introduced and used extensively with modems and modulator/demodulator devices, adapted to read digital information, modulate it over analog channels, and return digital information demodulated from the analog format. During the years the term “modem” has broadened its original meaning, generally indicating communication devices used to link computers to other computers or networks. In this broader sense the AT commands set nicely fits the device 10 according to the present disclosure that can be seen as a sort of“blockchain modem”.

The Hayes command set is characterized by basic AT commands, command formats and result codes. It has been extended for custom solutions, the most popular of which is the one adopted for Global System for Mobile Communications (GSM) modems. Hence, the device 10 according to the invention can make use of a blockchain custom set of AT commands to standardize the blockchain functionalities exposed to the connected hardware.

A preferred example of a set of parameters, their generation and handling by the system according to the present disclosure is summarized in the following table:

With reference to Fig. 8, preferably the secure element 82 (sometimes referred to as crypto chip or secure storage) of the device 10 according to the present disclosure is an integrated circuit with the following features:

- the ability to generate a truly random (opposed to a pseudo random) private key (dD in the above table);

the ability to store data in a way that is physically very difficult to be accessed (i.e. safe from thermography or X-ray screening of the integrated circuit) with respect to standard non-volatile memories; the ability to execute cryptographic signature algorithm directly on the integrated circuit without exposing the private key plus the optional ability to have monotonically increasing non-volatile hardware counters.

With reference to enclosed Fig. 2 and Fig. 9, the device 10 according to the present disclosure (from now on preferably referred to as“dongle” according to one of the embodiments of the present disclosure) carries out an initial phase - referred to from now on as priming phase - of initial setup where the dongle 10 generates 90 a set of parameters. These parameters are, for instance, dD (Dongle Private Key), QD (Dongle Public key), U IDD (Dongle Unique Identifier), dH (FIWUnit Private Key), QH (FIWUnit Public Key) and U IDH (FIWUnit Unique Identifier). Said parameters can be generated by a cryptography certified random number generator that can be located within the microcontroller 80 or within the secure element 82. The initial priming phase starts with the generation, by the hardware interface 11 connected to the dongle 10, of the parameter QH - Public Key of the hardware interface 11 - and proceeds with the transfer of the parameter QH from the hardware interface 1 1 to the Dongle Secure Storage 83. Multiple public keys can also be transferred if more hardware interfaces are requested. Then the dongle 10 proceeds by generating 92 the parameters dD (the Dongle Private Key), QD (the dongle public key), and U IDD (the dongle 10 unique identifier), and then transferring 93 the parameter QD to the hardware interface 1 1 and saving securely in the secure storage 83 the parameters QH, dD and U IDD.

After the priming phase, an example of first transaction between dongle 10 and hardware interface 1 1 and generation of blockchain private key dB is depicted in Fig. 3 and in Fig. 10:

The hardware interface 1 1 and the dongle 10 cooperate in securely exchanging 100 a secret key K over an insecure channel by applying, for instance, the Diffie-FHellman key exchange algorithm (in one of its flavors DH, DHE, ECDH, ECDHE). The Diffie- Hellman algorithm requires 5 parameters: two pairs of private-public keys and the characteristics of domain over which the calculations are performed (generally elliptic curves or integer multiplicative groups). The keys dD, QD, dH and QH are used in this step as parameters of the Diffie-Hellman algorithm (dD and dH being the private keys, QD and QH the public keys; the domain is determined by the Diffie- Heilman flavor chosen) with CID and dH never leaving their respective secure storage, dH the secure storage of the hardware interface 11 and dD the secure storage 82 of the dongle 10.

The secret key K is used to encrypt any successive communication between hardware interface 1 1 and the dongle 10 over the insecure channel. The message M (having any format, and preferably having an interoperable format such as, e.g., JSON) to be transmitted from the hardware interface 1 1 to the blockchain (the message M comprising for instance the data of a RFID reading concerning a warehouse transaction, or the data concerning any other event of interest) and it is first encrypted together with the Dongle Unique Identifier UIDH using the key K, and then sent 101 to the dongle 10.

Timestamped messages or cryptographic nonce can be used to avoid replay attacks. With reference to Fig. 4, in a particular instance of the Dongle 10, a hardware monotonous counter N 40 can be used to always ensure that old messages are not resent by an attacker or by a malfunctioning hardware interface 1 1 over the channel. Additional security steps can be taken by periodically generating a different secret key K to encrypt the communication over the insecure channel.

Still with reference to Fig. 4, when a message is received, the dongle will reconstruct the blockchain private key dB by applying the following algorithm to the received message:

By means of some Password Based Key Derivation Function (i.e PBKDF2) applied to some juxtaposition of at least UIDH and UIDD (but dD can also be used in this process), the initial entropy S for the deterministic calculation of dB is generated; Once de is generated, it is used to sign blockchain transactions in the Dongle. The first time de is generated, the corresponding blockchain public address QB is derived and stored in Secure Storage.

Then de is immediately cancelled from the Dongle memory. Any subsequent generation of de will additionally check that the corresponding QB is the same as the one stored in the Secure Storage.

With reference to Fig. 5, once the message M is converted to the blockchain format, a transaction can be generated. Once the transaction is successfully signed with dB, it can be directly sent to the blockchain by the dongle 10 or can be transmitted back to the hardware interface 1 1 that will send it to the blockchain in case the dongle is not provided with connectivity.

With reference to Fig. 6 and Fig. 9, in further detail the priming process within the dongle 10 is carried out as follows. The hardware interface 1 1 prompts the dongle 10 sending a priming command - e.g. an AT priming command - over a non- encrypted channel and through the first communication module 85. The dongle 10 has an empty secure element 82. The dongle 10 interpret the command - for instance with an AT command parser - 61 , the command is recognized 62 and analyzed to extract 63 the public key QH of the hardware interface 1 1. Then the dongle 10 (e.g. the secure element 82 of the dongle 10) generates 64 a private / public key pair QD / dD in a way that dD never needs to leave the secure element 82; then the key QD is sent back 65 to the hardware interface 1 1 and the key QH is sent 66 to the secure element 82 to be stored. At this point the random string U IDD is generated 67 by the device 10 and sent 68 to the secure element 82 to be stored. Thus at the end of the priming process the secure element 82 now stores the parameters U IDD,QD,QH and dD.

After the priming initialization phase, and with reference to enclosed Fig. 7 and Fig. 10, the first transaction is carried out as follows:

The hardware interface 11 starts by sending a blockchain command to the dongle 10 wherein the secure element 82 contains U IDD,QD,QH and dD but not the dongle blockchain address, QB, yet. The hardware interface 1 1 and the dongle 10 cooperate in securely exchanging 70 a secret key K over an insecure channel by applying, for instance, the Diffie-Hellman key exchange algorithm (in one of its flavors DH, DFIE, ECDFI, ECDFIE). The Diffie-Hellman algorithm requires 5 parameters: two pairs of private-public keys and the characteristics of domain over which the calculations are performed (generally elliptic curves or integer multiplicative groups). The keys dD, QD, dH and QH are used in this step as parameters of the Diffie-Hellman algorithm (dD and dH being the private keys, QD and QH the public keys; the domain is determined by the Diffie-Hellman flavor chosen) with dD and dH never leaving the secure storage 82.; the secret key K is then used to decrypt 71 the AT command previously received, the hardware interface 1 1 Unique Identifier, UIDH, is extracted 72 from the AT command together with the message M and UIDH is stored in the RAM of the microcontroller of the dongle 10. The UIDD is then read from the secure storage 82 and from UIDD and UIDH (and, optionally, further additional information), dB is generated 73 and stored in the RAM of the microcontroller of the dongle 10. The blockchain address QB is derived 74 from de and then QB is sent 75 to the secure element 82 to be stored therein. Finally, the blockchain transaction is generated 76 and sent to the blockchain. UIDH, de, UIDD and QB are deleted from the RAM of the microcontroller of the dongle 10.

With reference to Fig. 1 1 an Fig. 13 the n th transaction (n >1 ) begins with the hardware interface 1 1 sending a blockchain AT command to the dongle 10 with a primed secure element that contains the dongle blockchain address QB. The hardware interface (11 ) and the device (10) cooperate in securely generating and exchanging (70) a secret key K, said secret key K being generated from the keys dD, QD, dH and QFI, e.g. executing a Diffie-Hellman algorithm. The secret key K is used to decrypt 1 1 1 the AT command; then UIDH is extracted from the AT command together with the message M and UIDH is stored 1 12 in the RAM of the microcontroller of the dongle 10; UIDD is then read from the secure storage 82 and from UIDD and UIDH (and, optionally, further additional information), dB is generated 113 and stored in the RAM of the microcontroller of the dongle 10. The blockchain address QB is derived 1 14 from de, and then QB is checked against the QB contained in the secure element 82: if they differ, the transaction is not generated and the command fails 1 16, otherwise a blockchain transaction is generated 117 from M and dB and finally UIDH, de, UIDD and QB are deleted from the RAM of the microcontroller of the dongle 10.

In further detail and with reference to Fig. 12, the step of generating 1 17 a blockchain transaction can be carried out as follows:

The address QT of the blockchain receiving the transaction is extracted 120 from the message M; additional data D to be embedded in the blockchain transaction is then extracted 121 from the message M. A blockchain transaction T is then generated 122 by signing the tuple (QT,D) with de; at this point T is sent 123 to a blockchain node for validation and storage. The communication channel to the blockchain is not necessarily encrypted. T is then received 124 by a blockchain node and it is broadcasted to all adjacent nodes; the blockchain node aggregates 125 T with other received transactions to form a block; said block is modified 126 accordingly to the particular blockchain to pass the consensus algorithm of the blockchain (for example by embedding a proof of work) and finally the block is stored 127 in the blockchain with the transaction T written inside.

A possible variant of the described algorithm for the reconstruction of dB (multi-agent variant) allows the reconstruction of dB only by the interaction of the dongle 10 with multiple hardware interfaces 1 1 each one carrying a different U IDH and dH. In such case, with reference to Fig. 4, S is generated from the juxtaposition of UIDm, UIDH2,...UIDHn and U IDD, therefore allowing signing a transaction only after the successful interaction of all hardware interface 1 1.

Another possible variant of the described algorithm for the reconstruction of dB (multi-agent thresholded variant) allows the reconstruction of de only when a subset of at least m hardware interfaces 1 1 of the total n hardware interface 1 1 send a message to the dongle. The process is akin to a voting system where a blockchain transaction is generated only if the majority (defined by the threshold m; the higher m, the higher the level of consensus between the HWUnits required by the dongle to create a transaction) of HWUnits agree on its content. In this variant the UIDm, UIDH2,...UIDHn are not random strings but they are string pre-generated and assigned to hardware interface 1 1 by means of a sharing secrete scheme (i.e. Shamir Secret Sharing Scheme). In sharing secret schemes, a secret P (generally a random string) is converted to n different strings; these strings share a useful property: if at least m of the n strings are known by an agent, it is possible for the agent to reconstruct the original secret P. In the multi-agent thresholded variant, a secret P is randomly generated and used as input for a sharing secret scheme. P is therefore transformed into UIDm, UIDH2,... and the secret P can be reconstructed in the dongle 10 as soon as the dongle 10 receives m different UIDm Still with reference to Fig. 4, the secret P is used to generate the string S by juxtaposition of P with UIDD. In the multi-agent thresholded variant, knowing all the UIDHI is not enough to reconstruct de since UIDD is missing.