Files
Nexus/docs/changelog/2026-06-10-rdp-ws-instruction-relay-fix.md
T

30 lines
1.1 KiB
Markdown
Raw Normal View History

# 2026-06-10 — RDP WebSocket 按指令边界转发
## 摘要
修复浏览器 RDP 黑屏/连不上:guacd→WebSocket 原先按 TCP 块转发,会截断 Guacamole 指令;改为按 `;` 完整指令转发。
## 动机
生产验证可见 WS 消息在 `4.blob,` 等处被截断,guacamole-common-js 无法解析图像流。微软 RDP 客户端直连正常,说明目标机与凭据无问题。
## 涉及文件
- `server/infrastructure/guacamole/protocol.py``read_raw_instruction` / `read_raw_batch`
- `server/infrastructure/guacamole/ws_tunnel.py` — guacd→WS 按指令转发;内部 ping 全部回显
- `server/api/rdp_hosts.py` — connect 接口不再返回 password
- `frontend/src/composables/rdp/useRdpSession.ts` — connect 查询串不含密码
- `tests/test_guacamole_protocol.py` — 跨 TCP 块指令重组单测
## 迁移 / 重启
无 DB 迁移;需重建 API 镜像并同步前端。
## 验证
```bash
bash scripts/local_verify.sh
```
生产:3389 页连接 → 应显示 Windows 桌面画布;guacd 日志无 Instruction parse error。