-
Notifications
You must be signed in to change notification settings - Fork 25
Open
Description
Was working on something that involved ssz encoding ethereum consensus payloads that contained blobs and I get a stack overflow when i trying to decode them. Happens right at blobs > 90_795 bytes with an empty function
simple reproduce:
use ssz::Encode as _;
#[test]
fn test_ssz_blob() {
let blob = [0u8; 90_796];
let vec_of_blobs = vec![blob];
let decoded_bytes: Vec<[u8; 90_796]> =
ssz::Decode::from_ssz_bytes(&vec_of_blobs.as_ssz_bytes()).unwrap();
}
output:
running 1 test
thread 'block::test_ssz_blob' has overflowed its stack
fatal runtime error: stack overflow
I think i can fix this on my end by implementing encode and decode myself, since i think ethereum blobs are already ssz encoded. But im curious if there is a way to fix this limit or is the idea of ssz encoding a list of blobs that size just not a good idea
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels