Skip to content

fix(decoder): validate high bits for first field element in blob decoder#1533

Open
lavidaloca26 wants to merge 1 commit intobase:mainfrom
lavidaloca26:fix/blob-decoder-first-field-element-validation
Open

fix(decoder): validate high bits for first field element in blob decoder#1533
lavidaloca26 wants to merge 1 commit intobase:mainfrom
lavidaloca26:fix/blob-decoder-first-field-element-validation

Conversation

@lavidaloca26
Copy link

Summary

Fixes a blob decoding validation gap in BlobDecoder::decode.

Problem

The decoder validated high-order bits for field elements 1..3 (and subsequent rounds), but did not validate field element 0 in the first round (data[0]).

Changes

  • Added explicit high-bit validation for the first field element at offset 0.
  • Added a regression unit test to ensure malformed blobs with invalid high bits in data[0] return InvalidFieldElement { offset: 0 }.

Impact

Strengthens input validation and prevents malformed blobs from being accepted by the decoder.

@cb-heimdall
Copy link
Collaborator

🟡 Heimdall Review Status

Requirement Status More Info
Reviews 🟡 0/1
Denominator calculation
Show calculation
1 if user is bot 0
1 if user is external 0
2 if repo is sensitive 0
From .codeflow.yml 1
Additional review requirements
Show calculation
Max 0
0
From CODEOWNERS 0
Global minimum 0
Max 1
1
1 if commit is unverified 1
Sum 2

@vercel
Copy link

vercel bot commented Mar 20, 2026

Someone is attempting to deploy a commit to the Coinbase Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants