chore: remove bigint-buffer dependency to fix security vulnerability #3
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Remove bigint-buffer dependency to fix security vulnerability
Summary
Removes the
bigint-bufferdependency to address a HIGH severity buffer overflow vulnerability (CVE affecting versions ≤ 1.1.5). This involves:@solana/web3.jsto 1.98.4+ (which no longer depends on bigint-buffer)@solana/[email protected]that replaces bigint-buffer usage with native JavaScript BigInt implementationsThe patch replaces four core conversion functions (
toBigIntLE,toBufferLE,toBigIntBE,toBufferBE) with native implementations that provide equivalent functionality without the security vulnerability.Review & Testing Checklist for Human
pnpm buildandpnpm devto ensure no runtime errors from the bigint-buffer removal.Test Plan
grep -r "bigint-buffer" node_modules/(should return no results)pnpm devNotes
@solana/buffer-layout-utilsis updatedmy-own-fintechrepository and was implemented identically acrossamazon-shopperandstellar-server-walletsLink to Devin run: https://app.devin.ai/sessions/65d3e8006fc94200836c2612732193ff
Requested by: Penelope (@soinclined)