clean up binary_formats

This commit is contained in:
swrup 2025-10-17 20:05:48 +02:00
parent c992e1d402
commit 6220bbdae1
3 changed files with 224 additions and 261 deletions

View file

@ -30,13 +30,13 @@ let mk_future_denom denom_secmod_sign_f
let open Binary_formats in
let h_denom_pub =
(* TODO hash *)
let v = pub |> Types.RsaPublicKey.to_b32 in
DenominationHash.{ v= { v } }
let hash = pub |> Types.RsaPublicKey.to_b32 in
DenominationHash.{ hash }
in
let h_section_name =
(* TODO hash *)
let v = section_name in
HashCode.{ v }
let hash = section_name in
HashCode.{ hash }
in
let anchor_time =
TimeAbsoluteNBO.{ v= Util.ptime_to_int64_us stamp_start }
@ -75,9 +75,7 @@ let mk_future_sign_key signkey_secmod_sign_f
({ pub; sign= _; stamp_start; stamp_expire; stamp_end } : Secmod_keys.t) =
let signkey_secmod_sig =
let open Binary_formats in
let exchange_pub =
ExchangePublicKeyP.{ v= { v= EddsaPublicKey.to_octets pub } }
in
let exchange_pub = ExchangePublicKeyP.{ v= EddsaPublicKey.to_octets pub } in
let anchor_time =
TimeAbsoluteNBO.{ v= Util.ptime_to_int64_us stamp_start }
in