CyberStrikeAI/internal
Sycun 470eb5ead1
feat: add runtime storage cleanup with per-category retention (#310) (#313)
Runtime artifacts (agent workspaces, tool-output spill, C2 payloads, chat
uploads, workflow checkpoints, diagnostic logs) previously accumulated
without bound: most were only removed when a conversation or project was
deleted, and tmp/c2 plus workflow checkpoints were never removed at all.

Add a storage cleaner with named per-category tasks (Gitea-style), a
settings page tab, and a background sweep that is off by default so
upgrading never deletes existing data.

Safety properties, since mis-deleting live task data costs far more than
the disk saved:
- dry-run is the default; a real cleanup requires dry_run=false together
  with confirm=true at the API layer, not just a frontend dialog
- sessions active within active_grace_hours are always skipped, and a
  failed activity lookup skips conservatively (fail closed)
- directories whose conversation/project no longer exists are reclaimed
  as orphans after orphan_grace_days
- scanners never follow symlinks and every candidate path is confined to
  its category root; deletion renames to a .tmp-for-deletion marker first
  so a crash leaves recoverable residue instead of a half-deleted dir
- storage:* permissions are admin-only; without the grantSystemRolePermissions
  skip the default branch would have given operators an irreversible
  file-deletion right

Also fix two confirmed leaks: DeleteConversation left chat_uploads files
on disk (their rows already vanished via ON DELETE CASCADE), and workflow
checkpoints had no deletion path at all.

Co-authored-by: Parallels <parallels@kali-linux-2025-2.localdomain>
2026-09-25 14:46:23 +08:00
..
agent feat: add configurable tool call blocking and monitoring 2026-09-08 09:44:32 +08:00
agentfinalizer Fix finalization cleanup for pending tool executions 2026-08-23 19:57:17 +08:00
agents Add files via upload 2026-08-18 20:31:48 +08:00
app feat: add runtime storage cleanup with per-category retention (#310) (#313) 2026-09-25 14:46:23 +08:00
attackchain Add files via upload 2026-08-18 20:36:34 +08:00
audit Add files via upload 2026-08-18 20:36:34 +08:00
authctx Add files via upload 2026-08-18 20:17:38 +08:00
c2 Add files via upload 2026-08-18 20:22:40 +08:00
config feat: add runtime storage cleanup with per-category retention (#310) (#313) 2026-09-25 14:46:23 +08:00
database feat: add runtime storage cleanup with per-category retention (#310) (#313) 2026-09-25 14:46:23 +08:00
einomcp Add files via upload 2026-08-18 20:36:34 +08:00
einoobserve Add files via upload 2026-08-18 20:36:34 +08:00
handler feat: add runtime storage cleanup with per-category retention (#310) (#313) 2026-09-25 14:46:23 +08:00
hitl feat: add TypeSafe Jev as HITL audit backend 2026-09-22 21:15:53 +08:00
knowledge Add files via upload 2026-08-18 20:31:48 +08:00
llm Add files via upload 2026-08-18 20:34:53 +08:00
logger feat: persist diagnostic logs with daily rotation and retention 2026-09-08 14:41:46 +08:00
mcp feat: manage task process lifetimes and preserve turn history 2026-09-16 17:52:58 +08:00
monitor Add files via upload 2026-08-18 20:17:38 +08:00
multiagent fix: avoid duplicate summarization token limits 2026-09-23 18:02:00 +08:00
openai fix: normalize SSE error responses for Eino models 2026-09-14 16:34:22 +08:00
processguard feat: manage task process lifetimes and preserve turn history 2026-09-16 17:52:58 +08:00
project Add files via upload 2026-08-18 20:34:53 +08:00
projectprompt Add files via upload 2026-08-18 20:36:34 +08:00
reasoning Respect OpenAI reasoning profile for DeepSeek-named models 2026-08-24 13:55:07 +08:00
robot Add files via upload 2026-08-18 20:17:38 +08:00
runlease feat: manage task process lifetimes and preserve turn history 2026-09-16 17:52:58 +08:00
security feat: add runtime storage cleanup with per-category retention (#310) (#313) 2026-09-25 14:46:23 +08:00
skillpackage Add files via upload 2026-08-18 20:31:48 +08:00
storage feat: add runtime storage cleanup with per-category retention (#310) (#313) 2026-09-25 14:46:23 +08:00
termout fix: startup banner hardcodes 127.0.0.1 regardless of server.host (#307) 2026-09-13 15:27:38 +08:00
toolguard feat: add configurable tool call blocking and monitoring 2026-09-08 09:44:32 +08:00
tooloutput Add files via upload 2026-08-18 20:36:34 +08:00
typesafe feat: add TypeSafe Jev as HITL audit backend 2026-09-22 21:15:53 +08:00
vision Add files via upload 2026-08-18 20:36:34 +08:00
workflow Add files via upload 2026-08-18 20:17:38 +08:00