From 6f05392693ee29287d11766f75433ebb0a9f58f8 Mon Sep 17 00:00:00 2001 From: Giacomo Pasini <21265557+zeegomo@users.noreply.github.com> Date: Wed, 7 Feb 2024 12:31:31 +0100 Subject: [PATCH] Add slot contribution to nonce (#67) --- cryptarchia/cryptarchia.py | 1 + 1 file changed, 1 insertion(+) diff --git a/cryptarchia/cryptarchia.py b/cryptarchia/cryptarchia.py index ec4001c..1672bbc 100644 --- a/cryptarchia/cryptarchia.py +++ b/cryptarchia/cryptarchia.py @@ -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()