Skip to content

bound tar header size before allocation in wasm fetchers#9150

Open
dxbjavid wants to merge 1 commit into
envoyproxy:mainfrom
dxbjavid:wasm-tar-size-bound
Open

bound tar header size before allocation in wasm fetchers#9150
dxbjavid wants to merge 1 commit into
envoyproxy:mainfrom
dxbjavid:wasm-tar-size-bound

Conversation

@dxbjavid

@dxbjavid dxbjavid commented Jun 3, 2026

Copy link
Copy Markdown

getFirstFileFromTar in httpfetcher.go and extractWasmPluginBinary in imagefetcher.go call make([]byte, h.Size) using the size from the untrusted tar header of a downloaded wasm module, so a crafted tarball declaring a huge size panics with makeslice on the control plane. Reject sizes above maxWasmSize (and negatives) before allocating, matching the existing 256mb cap.

@dxbjavid dxbjavid requested a review from a team as a code owner June 3, 2026 08:46
@netlify

netlify Bot commented Jun 3, 2026

Copy link
Copy Markdown

Deploy Preview for cerulean-figolla-1f9435 ready!

Name Link
🔨 Latest commit 13034f0
🔍 Latest deploy log https://app.netlify.com/projects/cerulean-figolla-1f9435/deploys/6a1fe9e62e4f980008c34209
😎 Deploy Preview https://deploy-preview-9150--cerulean-figolla-1f9435.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

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.

1 participant