Once the PoW invoice (work response) has been sent from the broker node, the web node calls the prepareTransfer method from the IOTA iota.lib.js library and assembles the following pieces into a tryte string:

an address

a message

a value of 0

a tag that can be any valid tryte value

a seed (required for the method used, but ignored)

Currently, only the address and the message matter for our purposes.

Once the tryte string has been prepared, PoW from the web node is performed via a PoW method available from the IOTA curl.lib.js library on the trytes, as well as the branch and trunk transaction initially sent over from the broker node. The curl.lib.js PoW method used allows the web node to perform the PoW without being a full IOTA node. The PoW performed calculates a nonce value and adds this value, as well as the trunk and branch transaction, into the tryte string.

With this modified tryte string, the transaction is ready to be attached to the Tangle. Using the hook node IP addresses that the broker node sent to the web node when it sent the PoW invoice, the web node iterates through these hook nodes, calling an API method that we have added to the hook nodes that broadcasts transactions done by other nodes. The trytes are sent to each of these hook nodes in the list, and subsequently, these hook nodes broadcast the trytes to the Tangle.

Future Improvements

The Oyster development team has done extraordinary work in completing the ‘A’ and ‘B’ sections of the Oyster Testnet. Listed below are a few improvements the development team plan to implement for the Oyster Mainnet.

The broker node’s backend will be rebuilt entirely using Golang. Once this change is completed, the broker node will be able to send real PoW invoices associated with ongoing file upload to web nodes. Currently, the broker nodes are sending dummy PoW for the web node to complete (the trunk and branch transactions associated with the dummy work are still authentic IOTA transactions, though).

Additionally, future iterations of the Oyster protocol will allow broker nodes to specify a “PoW magnitude,” meaning that for some items, the web node may have to do more than one PoW calculation. The web node will have the option to decline to do the PoW, but for now, web nodes just complete the PoW automatically.

Finally, subsequent iterations of the web node script will communicate to the broker node that the PoW has been completed, and the broker node will then confirm the transaction on the Tangle with the correct message and address. Currently, the broker node does not verify this, as Oyster owns all the nodes in the network.

Summary

The release of the web node PoW demo video showcases the constant improvements made to the Oyster protocol as well as the steady progress towards Oyster’s Mainnet release. If there are questions or comments regarding the web node PoW demo, or any other topic covered within this update, we encourage our community to post them in our reddit or our Telegram knowledge channel.

Author’s note: I would like to extend my gratitude to the Oyster development team for supplying technical clarification for many of the topics covered in this update.