|
December 21, 2020, 12:19:52 AM |
|
Light Wallet Service and LWS-Client
The light wallet service, abbreviated as LWS. It is a bridge between the blockchain of the BigBang Core network and the data acquisition sensor of IoT device. BigBang Core Wallet's block and transaction data are updated and cached on time in LWS's own high-speed memory database and local database via LWS.
It calculates the latest UTXO collection of public key addresses for which different IoT devices hold keys based on this bunch of data. And sends (publish) the data to Amazon's cloud facility via a MQTT connection provided by AWS IoT Core. Broker forwards to the IoT device where the corresponding subscription (subscribe) has this information. Accordingly, the IoT device will package the collected data into the transaction based on these list of UTXO related to itself and publish it to Amazon IoT Core via MQTT. Then, the Message Broker of the Amazon service is pushed to LWS, which subscribes to the sending transaction topic sending these devices, and LWS verifies these transactions and, if the result of verification is successful, the LWS forwards this transaction to the BigBang Core Wallet via the Socket API. After received the transaction, the core program broadcasts the transaction to the BigBang Core network by the P2P network interface, and the node that generate block will collect these transactions, which are eventually completed the process of packaging these transactions into blocks and permanently stored on the blockchain.
The LWS client program, as part of the IoT device Firmware, it uses the CPU and secure computing coprocessor of the IoT device to process BigBang Core transaction-related calculations including transaction construction/deconstruction, HASH, ED25519 signature/check, etc. The device private key is stored in a secure area of the chip and cannot be read directly.
|