Skip to content

v2.0.6

Latest

Choose a tag to compare

@github-actions github-actions released this 25 Nov 13:51
v2.0.6
c030fa2

Security fixes 💂🏻

This is a security release. We recommend everyone upgrade, especially if you serve files with the scp middleware.

Security

  • SCP uploads could escape the root through dangling symlinks (GHSA-wvjj-wqvp-hxmj). If a symlink inside the served directory pointed to a path outside it that didn't exist yet, an SCP upload to that name followed the link and created the file outside the root. A symlink swapped in right after the path check could do the same. Uploads, directory creation and timestamp changes in scp.NewFileSystemHandler now go through Go's os.Root, so the kernel refuses to follow any link out of the root. Affects servers using scp.NewFileSystemHandler.

  • A malformed escape sequence could crash the server (GHSA-wvjj-wqvp-hxmj). An ANSI sequence with more than 32 parameters (e.g. \x1b[1;1;1;…m) made charmbracelet/x/ansi panic with an index-out-of-range error. In a Bubble Tea app served over Wish, one crafted string reaching the view could take down the session. Fixed by updating to Bubble Tea v2.1.3 and x/ansi v0.11.10 (charmbracelet/x#1012).

Also changed

  • Bumped Bubble Tea to v2.1.3, which also brings its own fixes for cleaner shutdowns over SSH. (#595)
  • Lowered the minimum Go version to 1.26.0.

Stay safe,
Charm 🌟

Changelog

Fixed

Other stuff


The Charm logo

Thoughts? Questions? We love hearing from you. Feel free to reach out on X, Discord, Slack, The Fediverse, Bluesky.