Use SHA3-256 hash of transaction header as transactionID


Dear community,

With this email, I would like to kickoff the discussion for a LIP regarding the roadmap objective “Replace transaction ID system”.

The IDs for transactions in Lisk, namely transactionIDs, should be computed in a way such that collisions have a negligible probability. Although a collision does not pose a security risk, it is inconvenient as it corrupts their intended usage: being a unique identifier for a transaction.

The length of the currently used transactionIDs, 64 bits, does not provide a negligible probability considering the potential number of transactions that could get included in the Lisk blockchain in the next years. The expected value for the number of transactions after which there is a collision of transactionIDs is ~2^32. The proposed change regarding the block size (LIP 0002) will allow up to 128 transactions per block (assuming the current size of transaction objects). If every block contains 128 transactions, a collision is expected after approximately 11 years. Hence, 64 bits is obviously too short.

We propose to use a length of 256 bits. Assuming that each block contains 128 transaction, the probability of having a collision within the next 50 years is below 10^(-56). Moreover, we propose to use SHA3-256 as the hash function in order to use the same hash function family as proposed for the blockIDs and the network identifier (see LIP 0009).

I’m looking forward to your responses and feedback.


-- Andreas Kendziorra
Cryptographer, Lightcurve