Skip to main content

MAX_RECEIVED_PACK_SIZE

Constant MAX_RECEIVED_PACK_SIZE 

Source
pub const MAX_RECEIVED_PACK_SIZE: u64 = _; // 2_147_483_648u64
Expand description

Maximum hosted native-pack body accepted by the receive primitive.

Native sync packs are produced from bounded state-closure wants and each decoded pack object is separately capped at 1 GiB in the pack reader. A 2 GiB compressed pack is materially above normal hosted sync use while still preventing an untrusted server from growing the in-memory receive buffer without limit. The receive path can now move to temp-file spooling plus install_pack_streaming — that install API reports the installed ids the receiver needs, so only the spooling of the receive buffer itself remains.