Skip to content

feat(identity): migrate ssh surface to charm v2 (wish/v2 v2.0.6) — #17343 slice 1 - #17410

Merged
developing-today-fleet[bot] merged 1 commit into
mainfrom
xaltha/17343-identity-ssh-v2
Nov 30, 2026
Merged

developing-today-fleet[bot] merged 1 commit into
mainfrom
xaltha/17343-identity-ssh-v2

Conversation

@developing-today-fleet

@developing-today-fleet developing-today-fleet Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

Refs #17343 — slice 1 of the charm-v2 migration (AN's slicing, comment 7286833051): the pkgs/identity ssh surface, the only package that actually serves the vulnerable SCP handler.

What changes

  • pkgs/identity/cmd/ssh (+ auth, observability, whose signatures carry the ssh types) migrate from github.com/charmbracelet/wish v1.4.7 to charm.land/wish/v2 v2.0.6 — the release whose scp package confines resolved paths to the configured root via os.Root (the CVE-2026-41589 fix; no patched v1 exists and v1.4.8 is docs-only). charmbracelet/ssh → charm.land/ssh v0.4.3 throughout.
  • TUI ported to bubbletea v2 / bubbles v2 / lipgloss v2: View() returns tea.View (AltScreen declared on the view; tea.WithAltScreen no longer exists), tea.KeyPressMsg, viewport options API.
  • promwish has no published v2 module (checked @latest and @main: the repo contains no promwish/v2 package), so it is replaced in-package by cmd/ssh/metrics.go, mirroring promwish v0.8.0 exactly: same counters (wish_sessions_created_total, wish_sessions_finished_total, wish_sessions_duration_seconds), same const/command labels, and a metrics-server wrapper that swallows http.ErrServerClosed (load-bearing — the caller treats any ListenAndServe error as fatal).
  • treilik/bubbleboxer has no bubbletea v2 release, replaced by cmd/ssh/layout.go: a minimal layout tree with the same surface the TUI used (CreateLeaf / ModelMap / UpdateSize / View; vertical SizeFunc partition, horizontal even column split, lipgloss join rendering).

Verification

  • Remote dispatch run 46480759595 at head 8027f2a, conclusion success; log read firsthand: cmd/ssh 4/4 PASS (new layout + metrics oracles + pre-existing log-hygiene test), auth 1/1 PASS, web PASS. Local go vet on the touched packages clean.
  • Full diff read at head before merge.

Not in this slice

github.com/charmbracelet/wish v1.4.7 remains in pkgs/identity/go.mod as an indirect dependency of the charm fork replace — no first-party code imports it after this PR, and the live SCP path runs the patched v2 handler. Removing the fork stack is slice 2; pkgs/chat + pkgs/launcher are slice 3 (pkgs/tea already landed via PR #17389). Alert #331 clears when slice 2 lands; #17343 stays open.


Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

…) — #17343 slice 1

Moves the only live CVE-2026-41589 exposure (pkgs/identity's SCP file
handler) from wish v1.4.7 to charm.land/wish/v2 v2.0.6, whose scp package
confines resolved paths to the configured root via os.Root.

- cmd/ssh, auth, observability: charmbracelet/ssh -> charm.land/ssh;
  wish middleware (scp/bubbletea/comment/elapsed/logging) -> wish/v2.
- TUI ported to bubbletea v2: View() returns tea.View (AltScreen on the
  view; tea.WithAltScreen no longer exists), tea.KeyPressMsg, bubbles v2
  viewport options API.
- promwish has no published v2 module: replaced in-package by metrics.go
  mirroring promwish v0.8.0 exactly (wish_sessions_created_total,
  wish_sessions_finished_total, wish_sessions_duration_seconds; metrics
  server wrapper swallowing http.ErrServerClosed).
- treilik/bubbleboxer has no bubbletea v2 release: replaced by layout.go,
  a minimal layout tree (CreateLeaf/ModelMap/UpdateSize/View) preserving
  the vertical SizeFunc stack + horizontal column rendering.
- New tests: metrics counter/command oracles, layout render/allocation
  oracle. Existing ssh_logging_test still passes.

wish v1.4.7 remains in go.mod as an indirect dependency of the charm
fork replace; removing it is slice 2 (charm stack) on #17343. The live
SCP serving path no longer runs the vulnerable code.

Refs #17343
@coderabbitai

coderabbitai Bot commented Nov 30, 2026

Copy link
Copy Markdown

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: a16fc8ae-8a8b-4d54-8564-234b130617a8

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

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