Files
Nexus/docs/audit/2026-06-08-webssh-xterm-ansi-output-fix.md
T
Nexus Agent 8312a6cf81 fix(terminal): WebSSH xterm SSH 交互区 ANSI 彩色输出
PTY 环境变量注入 TERM=xterm-256color,DATA 帧 base64 保 ESC;前端解码写入 xterm;命令栏 Shell 高亮 CSS 与黑屏分离。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-08 12:35:27 +08:00

1.0 KiB
Raw Blame History

审计 — WebSSH xterm SSH 交互区 ANSI 彩色输出(2026-06-08

Changelog: docs/changelog/2026-06-08-webssh-xterm-ansi-output-fix.md

审计范围

模块 文件
WebSocket relay server/api/webssh.py
前端解码 frontend/src/utils/terminalPayload.ts
会话 frontend/src/composables/terminal/useTerminalSessions.ts
样式分离 frontend/src/pages/TerminalPage.vue, frontend/src/components/terminal/TerminalCmdBar.vue
单测 tests/test_webssh_terminal_payload.py

Step 3

H 规则 结论
H1 ANSI 在 xterm 输出区,非命令栏冒充 PASS — PTY env + data_b64 + CSS 分离
H2 无静默吞错 PASS — relay 异常仍走现有 teardown
H3 向后兼容 PASS — 前端仍可读 legacy data 字段

Closure

H 判定
H1H3 PASS

DoD

  • pytest 3/3
  • local_verify 26/26
  • frontend build
  • pre_deploy_check 7/7
  • 生产浏览器 xterm 内 printf/ls(部署后终验)