Add slot contribution to nonce (#67)

This commit is contained in:
Giacomo Pasini 2024-02-07 12:31:31 +01:00 committed by GitHub
parent 0c447881ca
commit 6f05392693
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 0 deletions

View File

@ -256,6 +256,7 @@ class LedgerState:
h.update("epoch-nonce".encode(encoding="utf-8"))
h.update(self.nonce)
h.update(block.leader_proof.nullifier)
h.update(block.slot.absolute_slot.to_bytes(8, byteorder="big"))
self.nonce = h.digest()
self.block = block.id()