Changelog

oven-sh/bun · · 44 commits

Huge ownership sweep across Bun runtime

Major refactors and fixes hardened ownership, removed UAF risks, and tightened safety across bundler, HTTP, DNS, tests, and AOT.

Runtime and bundler ownership was overhauled across the stack (dylan-conwayd85aed4, dylan-conway862278d, dylan-conwaybbd0017, dylan-conway8a0ea60, dylan-conway6f8424e, dylan-conwayd401db7, dylan-conwayc5e0bbb)

Bun spent the day turning raw pointers, shared counters, and hand-freed resources into explicit owners. The biggest moves touched the watcher, bundler parse/link flow, VM/dev server lifetimes, HTTP request ownership, DNS/HTTP3 callbacks, and a wide swath of runtime helpers, cutting a large amount of unsafe code and eliminating several classes of leaks/UAFs.

Security and correctness fixes landed in low-level wrappers (dylan-conway7bd08b9, dylan-conwayd4796b2, dylan-conway44ed28a, dylan-conway24ec418, dylan-conwayab9b2eb)

Safe wrappers around simdutf/Highway/picohttpparser now validate lengths, closing out-of-bounds risks from short slices. Separate fixes tightened HTTP/2 stream borrowing, DNS keepalive timing, SQL message lifetimes, and BoringSSL handle ownership.

AOT and bundler behavior got notable feature-level updates (Jarred-Sumner9dfd5e3, Jarred-Sumner812575d, Jarred-Sumner20e881a, dylan-conway861960d, dylan-conway3a133b5)

The AOT compiler picked up broader support for built-ins, frames, async error handling, and more realistic test-run behavior, with fresh fixtures and documentation. Bundler CSS chunk printing and npm-mode tar behavior also got substantial correctness improvements.

Other misc changes

  • Refactors and renames across AST, bundler, CLI, and runtime internals.
  • Build/CI fixes, including missing headers and Windows sysroot bump.
  • Test updates and new regression coverage.
  • Dependency/config churn and small cleanup commits.