From 69570e5b54a614e732f05bdfd28ced77f22916fe Mon Sep 17 00:00:00 2001 From: Brandon Thomas Date: Sun, 11 Oct 2026 20:16:15 -0400 Subject: [PATCH] Cap session bundles at 1 GiB: 4 GiB is all of wasm32's address space Co-Authored-By: Claude Opus 5.5 --- crates/engine/src/io.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/engine/src/io.rs b/crates/engine/src/io.rs index 8c774d83..464740e5 100644 --- a/crates/engine/src/io.rs +++ b/crates/engine/src/io.rs @@ -578,7 +578,7 @@ pub const BUNDLE_EXTENSION: &str = "scraftz"; /// Most entries and bytes a bundle may unpack to (bundles are hostile input). const MAX_BUNDLE_ENTRIES: usize = 10_000; -const MAX_BUNDLE_BYTES: u64 = 4 << 30; +const MAX_BUNDLE_BYTES: u64 = 1 << 30; /// Hands a finished file (name, bytes) to the person on a host without a filesystem: the web app /// installs one that starts a download. Native builds write files and never install it.