Skip to content

Commit 6be576e

Browse files
authored
fix(sgx): instance_id bytes length is 4 (#499)
1 parent da7f209 commit 6be576e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

provers/sgx/prover/src/lib.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -527,9 +527,9 @@ async fn aggregate(
527527
};
528528
// Extract the instance id from the first proof
529529
let instance_id = {
530-
let mut instance_id_bytes = [0u8; 8];
530+
let mut instance_id_bytes = [0u8; 4];
531531
instance_id_bytes[0..4].copy_from_slice(&raw_input.proofs[0].proof.clone()[0..4]);
532-
u64::from_be_bytes(instance_id_bytes)
532+
u32::from_be_bytes(instance_id_bytes)
533533
};
534534

535535
tokio::task::spawn_blocking(move || {

0 commit comments

Comments
 (0)