Skip to content

Release v0.8.1 — fix SSH reconnect terminal death#15

Merged
moreih29 merged 2 commits into
mainfrom
develop
Jun 26, 2026
Merged

Release v0.8.1 — fix SSH reconnect terminal death#15
moreih29 merged 2 commits into
mainfrom
develop

Conversation

@moreih29

Copy link
Copy Markdown
Owner

Summary

SSH 워크스페이스가 장시간 단절(슬립/네트워크 드롭) 후 재연결될 때 터미널이 죽은 채 복구되지 않던 문제(0.7.1/0.8.0)를 수정하고 0.8.1로 릴리스합니다.

Root cause

단절로 ControlMaster가 사망하면 매니저의 자동 재인증이 인터랙티브 비밀번호 프롬프트를 다시 띄웠고, 무인 상태에서 30초 타임아웃 → 워크스페이스가 영구 error 상태로 빠졌습니다(자격 재사용 부재).

Fix

auth prompt handler를 세션 한정(메모리) 자격 캐시로 감쌈 — host|user|port 키로 성공한 비밀번호를 재사용해 무인 재연결이 조용히 복구. retry=true(비밀번호 거부) 시 캐시 evict 후 재프롬프트, host-key는 비캐싱, 디스크 비영속.

Tests

  • unit: credential-cache 데코레이터 (hit / retry-invalidation / host-key / key isolation)
  • integration (opt-in, dockerised password sshd): 인증 → ControlMaster kill → 재인증이 캐시 비밀번호로 실 sshd 인증, 재프롬프트 없음. 캐시 없이 RED(프롬프트 2회) → 캐시로 GREEN 확인.
  • 회귀: bun test tests/unit/main/agent tests/unit/main/workspace 190 pass / 0 fail, typecheck 0 error.

Protocol & Remote 영향

없음 — main 프로세스 인증 계층 변경만, 원격 에이전트 바이너리 변동 없어 SSH 재업로드 불필요.

🤖 Generated with Claude Code

moreih29 and others added 2 commits June 26, 2026 14:45
…death

A long outage (laptop sleep / network drop) kills the persistent SSH
ControlMaster that holds the authenticated session. The manager's reauth
path then re-ran the interactive password prompt; unattended, that prompt
timed out after 30s and the workspace dropped into a permanent error state
with a dead terminal — the "SSH 재연결 시 터미널 끊김" report, still present
in 0.7.1/0.8.0.

Wrap the auth prompt handler with a session-scoped (in-memory only) cache
keyed by host|user|port: a successful password is reused on reauth without
re-prompting the renderer, so unattended reconnects recover silently. On a
retry=true prompt (SSH "Permission denied, please try again") the stale
entry is evicted and the real prompt is shown, then re-cached. Host-key
prompts are never cached. No disk/keychain persistence.

Tests:
- unit: credential-cache decorator (hit / retry-invalidation / host-key / key isolation)
- integration (opt-in, dockerised password sshd): authenticate → kill
  ControlMaster → reauth reuses cached password against real sshd with no
  re-prompt. Verified RED without the cache (prompt fires twice) → GREEN with it.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011UMujpw19d41anbVNrnus9
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011UMujpw19d41anbVNrnus9
@moreih29
moreih29 merged commit 3be4aa3 into main Jun 26, 2026
1 check passed
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