Skip to content

Commit

Permalink
Now passing: test that checked that Mastic API matches VDAF spec one
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Rosenberg committed Nov 26, 2024
1 parent aacb3d9 commit b98624a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/vdaf/xof.rs
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,10 @@ impl Xof<16> for XofFixedKeyAes128 {
let mut fixed_key_deriver = TurboShake128::from_core(TurboShake128Core::new(2u8));
Update::update(
&mut fixed_key_deriver,
&[dst.len().try_into().expect("dst must be at most 255 bytes")],
u16::try_from(dst.len())
.expect("dst must be at most 65536 bytes")
.to_le_bytes()
.as_slice(),
);
Update::update(&mut fixed_key_deriver, dst);
Self {
Expand Down

0 comments on commit b98624a

Please sign in to comment.