mirror of
https://github.com/binaricat/Netcatty.git
synced 2026-11-24 00:50:44 +00:00
4db44e2ede1996cd52f48c422fd78a34322f0d13
11
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
5c5fa4f27e |
fix(ai): make the command blocklist shell-aware
Select default command-safety rules from the live session shell so legal PowerShell subexpressions are allowed and PowerShell-native dangerous commands are blocked. Untouched pre-shell-aware lists gain the new defaults on read. Closes #3256 |
||
|
|
29c4d12e82 | feat(ai): harden Catty terminal context handling | ||
|
|
c3224d30c6 |
feat: network device mode for SSH + serial charset encoding support (#540)
* feat: add deviceType field to Host model for network device support Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * feat: pass deviceType through session metadata pipeline Thread deviceType from Host model through AITerminalSessionInfo, IPC types, and mcpServerBridge so AI agents can inspect device type per session. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * feat: route network device SSH sessions to raw PTY execution When deviceType === 'network', handleExec now uses execViaRawPty instead of execViaPty so vendor CLIs (Huawei VRP, Cisco IOS, etc.) receive commands as-is without POSIX shell wrapping or markers. The command blocklist is also skipped for network devices, consistent with the existing serial session bypass. AI context description updated to document the raw-execution behaviour for network device sessions. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * feat: add network device mode toggle to host settings UI Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * feat: add network device awareness to Catty Agent system prompt Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: extend network device mode to Catty Agent exec path and host context - Add network device detection and raw execution routing to aiBridge.cjs (the primary Catty Agent command path), not just the MCP bridge - Export getSessionMeta from mcpServerBridge for reuse in aiBridge - Surface deviceType in Catty Agent system prompt host list so the AI can identify which sessions are network devices - Pass deviceType through buildSystemPrompt context Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: exempt network device sessions from client-side blocklist and update ACP context - Add deviceType to ExecutorContext sessions type - Skip renderer-side command blocklist for deviceType=network sessions in shared toolExecutors.ts (not just main-process side) - Update ACP agent context hint to mention network device sessions Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: only show network device mode toggle for SSH hosts Telnet and local hosts don't support the network device execution path, so hiding the toggle prevents users from enabling a broken configuration. Serial hosts already use raw mode by default. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: exclude Mosh sessions from network device raw execution path Mosh uses a shell-backed PTY and cannot connect to vendor CLIs, so network device mode should only apply to SSH and serial sessions. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: prefer session.protocol over metadata for Mosh detection Mosh tabs report protocol:"ssh" in renderer metadata but "mosh" in the main-process session object. Prioritize session.protocol (runtime truth) to correctly exclude Mosh from network device raw execution. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: suppress deviceType metadata for Mosh sessions Mosh requires a shell-backed PTY and cannot connect to vendor CLIs, so omit deviceType from AI-facing metadata when session is Mosh-backed. This prevents the AI from being told to use vendor CLI syntax when the actual execution path uses normal shell wrapping. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: use exit code 0 for network device sessions and hide toggle for Mosh - Network device / serial sessions return exitCode: null from vendor CLIs. Default to 0 instead of -1 so the AI doesn't misinterpret successful commands as failures. - Hide the network device mode toggle when Mosh is enabled, since the setting is suppressed at runtime for Mosh sessions anyway. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: preserve null exit codes and restrict raw mode to SSH/serial - Preserve exitCode: null for network device sessions instead of coercing to 0, so the AI knows exit status is unavailable rather than seeing a misleading success code. - Explicitly whitelist SSH/serial protocols for network device mode instead of just excluding mosh, preventing local/telnet sessions from accidentally entering raw execution. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: use UTF-8 encoding for SSH network device raw execution execViaRawPty hardcodes latin1 for serial port data decoding. Add an encoding option (default: latin1) and pass utf8 from SSH network device call sites so multi-byte characters aren't corrupted. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: use host charset for serial port decoding instead of hardcoded latin1 - Extract charsetToNodeEncoding() to module scope in terminalBridge - Serial sessions now read options.charset (from Host.charset) for both terminal display decoding and AI command output - Store serialEncoding on session object so exec paths can use it - Pass encoding through all execViaRawPty call sites - Default encoding changed from latin1 to utf8 (matches most modern network equipment and is the safer default for CJK environments) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: move serialEncoding declaration before session object creation serialEncoding was referenced in the session object literal before its const declaration, causing a TDZ ReferenceError that would crash every serial connection. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: tighten isNetworkDevice logic and clean up edge cases - Align toolExecutors isNetworkDevice check with bridge logic: require explicit SSH/serial protocol match instead of trusting deviceType alone - Remove empty-string protocol match from isSshOrSerial in both bridges to prevent local/unknown sessions from being treated as network devices - Widen exitCode return type to `number | null` to match actual behavior - Clear deviceType when enabling Mosh (incompatible combination) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: update MCP server tool descriptions for network device sessions The get_environment and terminal_execute tool descriptions only mentioned serial/raw sessions for network devices. Updated to also reference deviceType: network SSH sessions so external AI agents (Claude, Codex) know about the new execution mode. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: include deviceType in get_environment and guard execViaChannel fallback - Add deviceType to executeWorkspaceGetInfo session mapping and return type so Catty Agent's get_environment tool matches MCP bridge output - Guard both aiBridge and mcpServerBridge against falling through to execViaChannel for network device sessions — network devices require an interactive PTY and exec channels would produce broken behavior Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * feat: add charset setting to serial host configuration UI Serial hosts now have a charset input in the Advanced section, defaulting to UTF-8. The value is saved to Host.charset and used by the serial decoder in terminalBridge. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * feat: add charset to serial quick-connect modal with full pipeline - Add charset input to SerialConnectModal (Advanced section) - Thread charset through onConnect callback → handleConnectSerial → createSerialSession → TerminalSession.charset - Add charset field to TerminalSession interface - Include charset in fallback host builder for quick-connect sessions so createTerminalSessionStarters can pass it to startSerialSession - Saved hosts also store charset via onSaveHost Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: constrain serial connect modal height with scrollable content Modal content could overflow the viewport when Advanced section was expanded. Add max-h-[85vh] to DialogContent with flex layout so the content area scrolls while header and footer buttons stay visible. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: propagate charset through all serial session creation paths - Add charset to startSerialSession type in global.d.ts - Copy host.charset to TerminalSession in connectToHost serial path - Copy host.charset in createWorkspaceWithHosts serial path - Propagate session.charset in splitSession (both workspace and standalone) - Propagate session.charset in copySession Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: propagate charset in remaining session creation paths Add host.charset to connectToHost (non-serial), createWorkspaceWithHosts (non-serial), and runSnippet session creation for consistency. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|
|
7a5b6f506e |
feat: Catty Agent 支持串口会话命令执行 (#520)
* feat: Catty Agent 支持串口会话命令执行 (#520) 串口连接的网络设备(华为交换机、Cisco 路由器等)使用厂商自有 CLI, 无法识别 Agent 原有的 shell 包裹语法(__NCMCP_ markers、eval、trap)。 新增 execViaRawPty 函数,直接发送原始命令到串口,通过 idle timeout 检测命令完成,无 shell 语法包裹。 - 新增 execViaRawPty:原始命令执行,2s idle timeout 检测完成 - terminalBridge: 串口 session 添加 protocol/shellKind 字段 - mcpServerBridge: handleGetContext 发现串口会话,handleExec/handleTerminalWrite 支持串口 - aiBridge: ai:exec 和 ai:terminal:write 增加 serialPort 分支 - systemPrompt: Agent 提示词增加串口会话使用指南 Closes #520 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: review 问题全量修复 P1: - handleExec 移除死代码(内层 if 条件永远为 true) - 串口会话跳过 shell 安全黑名单(shutdown 在 Cisco 是正常接口命令) - MCP tool 描述更新:terminal_execute/get_environment/multi_host_execute 不再只说 "shell command" - 串口检查增加 protocol === "serial" guard,不再纯靠 duck typing P2: - execViaRawPty 编码改为 latin1,与 terminalBridge 终端解码一致 - exitCode 改为 null(而非 -1),MCP 响应中 null 时不输出 exit code 行 - idle timer 改为收到第一个数据后才启动,避免慢设备超时返回空输出 - idle timeout 默认从 2s 调为 3s,适配低速串口 - serialPort.write 统一用 safeWrite 包裹 try-catch - echo 剥离仅在 lines.length > 1 时执行,避免误删唯一输出行 P3: - cancelKey 用简单自增序列替代 crypto.randomBytes - serialPort.on 前增加 typeof 检查 - finish 函数签名差异增加注释说明 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: 第二轮 review 问题修复 P2: - MCP server terminal 类工具 (terminal_execute/terminal_send_input/multi_host_execute) 跳过 blocklist,由 bridge 层做 session-aware 检查,解决串口 shutdown 等命令 在 MCP 层就被拦截的问题 - handleTerminalWrite (mcpServerBridge + aiBridge) 串口会话跳过 blocklist, 与 handleExec 保持一致 - handleMultiExec 移除外层 blocklist,每个 session 由 handleExec 独立检查 - 移除 execViaRawPty 中的死代码 receivedFirstChunk 变量 - handleGetContext 返回的 description 补充 serial 会话说明 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: Codex review 问题修复 - [P2] toolExecutors.ts executeTerminalExecute 也需要跳过串口 blocklist, 否则 Catty Agent renderer 侧的 checkCommandSafety 会在命令到达 bridge 之前拦截 shutdown 等合法设备命令 - [P2] execViaRawPty 增加 noResponseTimer,无输出命令(enable、 configure terminal 等)不再等满 60s 整体超时,而是 2×idleMs 后正常返回 - [P1] 串口 blocklist skip 设计决策加注释:serial 协议由用户主动选择, 如果串口连的是 Linux shell 应使用 local 协议 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: Codex 第二轮 review 修复 - [P2] noResponseTimer 从 2×idleMs 调整为 min(idleMs*4, timeoutMs/4), 默认 12s,避免截断慢速网络设备操作 - [P1] 串口 blocklist skip 设计说明扩充:serial 协议由用户主动选择, 且 execViaRawPty 不做 shell 解释,blocklist 中的 shell 元字符 即使发到串口连接的 Linux shell 也不会被解释执行 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: execViaRawPty echo 阶段使用更长的 idle timeout ping/traceroute/copy 等命令在回显后可能沉默数秒才产出真正输出。 引入 chunkCount 区分 echo 阶段(前 2 个 chunk)和正式输出阶段: echo 阶段使用 2×idleMs(默认 6s),正式输出阶段使用 idleMs(3s)。 避免在回显后就误判命令已完成导致输出截断。 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: noResponseTimer 增加无输出提示 设备无响应时返回提示信息 "(no output received — command may have completed silently or may still be running)",让 AI 知道命令可能 仍在执行,避免误认为命令已成功完成后立即发送下一条命令。 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: Codex 第 5 轮 review 修复 - [P2] terminal_send_input 串口写入时将 \n 转换为 \r, 网络设备期望 CR 作为回车而非 LF - [P2] execViaRawPty 增加 512KB 输出上限,达到上限后停止 重置 idle timer,避免 noisy session(持续发日志的设备) 导致命令永远无法完成 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|
|
4971f18bbe | Fix AI terminal execution completion and tool UI | ||
|
|
17e98090ad |
Add AI support for local terminal sessions (#419)
* Add AI support for local terminal sessions * Fix local AI session metadata and shell safety * Fix local session cloning and multi-exec errors * Refactor local shell detection helpers * Fix local shell helper import path * Fix CJS imports in renderer * Use ESM local shell helpers in renderer * Normalize local shell paths and platform metadata |
||
|
|
3d4fbf8763 |
fix: keep workspace MCP scope in sync (#385)
* fix: keep workspace MCP scope in sync * fix: refresh catty workspace tool context * fix: preserve AI stream state across tab switches * fix: align ACP stop and resume with 1code semantics * fix: harden ACP resume fallback for unsupported agents |
||
|
|
ccfa2d4dd0 |
fix: non-zero exit code is not a failure, include output on real errors (#377)
* fix: treat non-zero exit code as success and include output on failure - Non-zero exit codes (e.g. grep returning 1, ls on missing file) are valid command results, not execution failures. Changed execViaPty and execViaChannel to always return ok:true when the command actually ran. - ok:false is now reserved for real failures: timeout, session gone, stream not writable, etc. - When ok:false, include any partial stdout/stderr in the error message so the user and LLM can see what happened before the failure. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: return stdout+exitCode for all completed commands, clean up dead code - ptyExec: preserve original ok semantics (non-zero = ok:false) so MCP server bridge callers (handleMultiExec, stopOnError) still work - execViaChannel: null exit code (SSH disconnect) returns ok:false - toolExecutors: Catty Agent always returns stdout+exitCode to the LLM regardless of exit code, only treats real failures (timeout, disconnect) as errors — with partial output included - Remove dead code: executeTerminalSendInput, executeSftp*, executeMultiHost - Clean up unused imports, bridge interface, ExecutorContext Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|
|
6727248924 |
feat: add web search & URL fetch tools for AI agent (#365)
* feat: add web search and URL fetch tools for AI agent Add web_search and url_fetch tools to Catty Agent, allowing the AI to search the internet for current information and fetch webpage content. - Support 5 search providers: Tavily, Exa, Bocha, Zhipu, SearXNG - Settings UI with provider selection, API key encryption, and config - web_search is conditional on config; url_fetch is always available - Both tools are read-only and work in all permission modes (incl. observer) - aiFetch skipHostCheck for AI tool requests to arbitrary URLs - System prompt guidelines for when to use search/fetch - i18n support (en + zh-CN) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address code review findings (SSRF, key exposure, state race) - P1: Restore SSRF protection when skipHostCheck is true — still block localhost, RFC1918, link-local, and cloud metadata endpoints; only skip the domain allowlist for public HTTPS hosts - P2: Move web search API key decryption to main process via dedicated IPC handler, matching the existing provider key security model - P2: Use configRef to avoid stale closure in async settings callbacks that could overwrite newer user changes Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address second review — DNS rebinding, url_fetch approval, maxResults - P1: url_fetch now requires approval in confirm mode (outbound GET is a side effect that could exfiltrate data via query strings) - P1: Add DNS resolution check when skipHostCheck is set — resolve hostname and reject if any IP is private/loopback/link-local, blocking DNS rebinding attacks against internal services - P2: Slice search results after provider call to enforce maxResults consistently (Zhipu and SearXNG ignore the limit parameter) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address third review — localhost/IPv6 SSRF, API key blur race - P1: Block localhost/loopback when skipHostCheck is enabled — restructure isAllowedFetchUrl to check private hosts first in the skipHostCheck path, preventing access to local services on allowlisted ports - P1: Handle IPv6 private ranges (fc00::/7, fe80::/10, ::ffff: mapped), strip brackets from URL.hostname, block [::1] and fd00:: addresses - P2: Guard handleApiKeyBlur against provider change during async encryption — skip stale write if provider switched while encrypting Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address fourth review — main-process key isolation, SearXNG compat - P1: Replace aiWebSearchDecryptKey IPC with __WEB_SEARCH_KEY__ placeholder pattern — renderer never sees plaintext keys; main process replaces placeholder in headers before HTTP request, matching provider key flow - P1: Search API requests use normal allowlist path (not skipHostCheck), so SearXNG on localhost/HTTP/private networks works via aiSyncWebSearch; only url_fetch uses skipHostCheck for arbitrary public HTTPS URLs - P2: Remove needsApproval from url_fetch — treat as read-only like sftp_read_file, consistent with observer mode allowlist Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address fifth review — private LAN providers, maxResults default - P1: Allow private-IP hosts that are explicitly in the provider/search allowlist (e.g. https://192.168.x.x model providers or SearXNG) - P2: Remove .default(5) from web_search maxResults schema so the user's configured maxResults setting is used when the model omits the param Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address sixth review — HTTPS scope, config gate, redirects - P2: Scope HTTP exception to private/LAN IPs only — remote allowlisted hosts still require HTTPS to protect API keys in transit - P2: Gate web_search tool on complete config (API key for providers that require it, apiHost for SearXNG) to avoid advertising a broken tool - P2: Add redirect following (up to 5 hops) to aiFetch for url_fetch — handles 301/302/307 for short links, www canonicalization, etc. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address seventh review — redirect SSRF, decrypt race, HTTPS-only - P1: Revalidate each redirect hop against SSRF guards (allowlist check + DNS resolution) before following, preventing open-redirect SSRF - P2: Add sequence counter to API key decryption effect — stale promise results from a previous provider are discarded on provider switch - P3: Restrict url_fetch to HTTPS-only URLs, matching the skipHostCheck policy that already rejects HTTP in the bridge Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address eighth review — OS resolver, allowlisted HTTP hosts - P1: Use dns.lookup (OS resolver) instead of dns.resolve4/6 for private IP checks — matches what http.request actually connects to, respects /etc/hosts, mDNS, and other local resolver sources - P2: Allow HTTP for any explicitly allowlisted host (not just literal private IPs), so self-hosted SearXNG at http://searxng.lan works Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address ninth review — HTTP scope, blur ordering, decrypt flag - P1: Narrow HTTP exception to web search apiHost only — AI provider endpoints remain HTTPS-only to protect credentials in transit - P2: Add blur sequence counter to prevent out-of-order encryption results from overwriting newer API key saves - P2: Reset isDecrypting flag when cancelling decrypt on provider switch, preventing permanently disabled API key input Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address tenth review — DNS pinning, prompt/tool alignment - P1: Pin validated DNS result to the HTTP request via custom lookup function, preventing TOCTOU/DNS-rebinding between validation and actual connection - P2: Extract isWebSearchReady() helper and use it consistently in both tool registration and system prompt, so the model isn't told web search is available when config is incomplete Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address eleventh review — single DNS lookup, redirect pinning, CGNAT - P1: Combine DNS validation and pinning into a single lookup call, eliminating the TOCTOU window between hasPrivateResolution and pinnedLookup - P1: Pin DNS for redirect targets too — resolve/validate/pin in one step before following each redirect hop - P2: Add 100.64.0.0/10 (CGNAT) to private IP ranges for Tailscale and similar CGNAT-addressed internal services Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: address twelfth review — apiHost validation, sync on enable - P2: Validate apiHost is a well-formed URL in isWebSearchReady(), preventing tool exposure when user enters a malformed host - P2: Add webSearchConfig.enabled to sync effect deps so the main process gets updated immediately when the toggle changes Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: remove DNS-level SSRF checks that break fakedns/proxy environments DNS resolution validation (dns.lookup + IP pinning) breaks in proxy environments where fakedns resolves all domains to LAN addresses. Revert to hostname-level checks only (blocking localhost, 127.0.0.1, metadata endpoints, etc.) which are sufficient without false positives. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * fix: resolve empty catch block lint warning Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|
|
be36ccd167 |
fix: address security, correctness, and performance issues from code review
Security: add validateSender to agent IPC handlers, remove CODEX_API_KEY and NODE_PATH from SAFE_ENV_KEYS, validate URL scheme before openExternal, add backtick substitution to command blocklist, add 10MB buffer limits. Bugs: fix runExternalAgentTurn timeout hang, fix limitConcurrency undefined entries on error, treat null exitCode as failure, enforce maxBytes for SFTP reads. Performance: debounce addMessageToSession persistence, cache compiled blocklist regexes, add QuotaExceededError handling for localStorage writes. UI: use local onKeyDown for PermissionDialog, move CRITICAL_PATHS to module level. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |
||
|
|
71b13a77a3 |
fix: address security, correctness, and performance issues from code review
Security: validate agent spawn commands against allowlist, replace execSync with execFileSync in agent discovery, restrict localhost SSRF to known ports, add observer mode enforcement at IPC layer, add IPC sender validation, expand dangerous env key blocklist, add pending approval timeout. Correctness: replace updateLastMessage with ID-based updateMessageById to fix race condition during streaming, include tool-call/tool-result messages in SDK context, flush debounced persist on unmount, fix ACP client break placement, use proper AI SDK message types. Performance: pre-compile command blocklist regexps, extract shared tool executors to deduplicate executor.ts and tools.ts (~50% reduction each). Also: i18n for hardcoded English strings, remove dead detectDoomLoop code, add bypass-resistant blocklist patterns, include permissionMode in ACP provider reuse fingerprint. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> |