Commit Graph

17 Commits

Author SHA1 Message Date
eb8553ce0b security: lock down OpenCode containers to read-only legal research
Add defense-in-depth restrictions via agent config and global permissions:
- Global permission layer denies bash, edit, webfetch, lsp
- Build agent tools restricted to read-only (grep/glob/list/read/todo)
- General/explore subagents locked to read-only
- Plan agent disabled to prevent mode switching
- Custom system prompt for legal research context (temp=0.2)
2026-02-08 20:22:57 +01:00
7dae8faf62 security: fix timing attack vulnerability and incorrect method call
- Use secrets.compare_digest() for token comparison instead of == to
  prevent timing-based attacks that could leak token information
- Fix rotate_session_auth_token() to call the correct method
  rotate_session_token() instead of non-existent rotate_session_auth_token()
2026-02-05 00:36:07 +01:00
2cb5263d9e feat: add comprehensive OpenCode API endpoint proxies
Added proxy routes for all OpenCode internal API endpoints to support
full application functionality when accessed via session manager:
- project, agent, config, model endpoints
- thread, chat, conversation endpoints
- command, mcp, lsp, vcs endpoints
- permission, question, event, status endpoints
- internal session endpoint (distinct from container sessions)

Also updated Caddyfile for routing configuration.
2026-02-05 00:33:58 +01:00
d6f2ea90a8 fix: add missing _get_container_info method to AsyncDockerClient
docker_service.get_container_info() was calling self._docker_client._get_container_info()
but AsyncDockerClient didn't have this method, causing silent AttributeError and
returning None, which triggered false health check failures.

Added _get_container_info() using aiodocker's container.show() to properly retrieve
container state information for health monitoring.
2026-02-04 22:04:29 +01:00
69d18cc494 fix: session stability improvements
- Fix docker client initialization bug in app.py (context manager was closing client)
- Add restart_session() method to preserve session IDs during container restarts
- Add 60-second startup grace period before health checking new sessions
- Fix _stop_container and _get_container_info to use docker_service API consistently
- Disable mDNS in Dockerfile to prevent Bonjour service name conflicts
- Remove old container before restart to free port bindings
2026-02-04 19:10:03 +01:00
05aa70c4af connected zen 2026-02-03 00:36:22 +01:00
9281c0e02a refactored the big main.py file 2026-02-03 00:17:26 +01:00
5e1cb64a81 wp on webui 2026-02-02 23:37:11 +01:00
ce24e0caa0 claude.md 2026-02-01 19:40:55 +01:00
0ff43b1a9c gitignore 2026-01-18 23:29:12 +01:00
7a9b4b751e docker related 2026-01-18 23:29:04 +01:00
2f5464e1d2 fixed all remaining issues with the session manager 2026-01-18 23:28:49 +01:00
0243cfc250 work with session manager etc 2026-01-18 22:10:03 +01:00
165d87899d debuged python docker client issue 2026-01-18 20:01:23 +01:00
fa2d278c79 fixed findings from review 2026-01-18 19:15:33 +01:00
f76328b621 phase 1 2026-01-18 19:07:20 +01:00
93da0b117e first attempts 2026-01-18 19:03:38 +01:00