Epic: Security & Safety Hardening #362
Labels
No labels
auto/needs-reevaluation
controller-managed
auto/blocked-by-deps
auto/ci-timeout
auto/claimed-implementer
auto/claimed-merge
auto/claimed-reviewer
auto/driver-down
auto/invariant-violation
auto/last-attempt-tier-0
auto/last-attempt-tier-1
auto/last-attempt-tier-2
auto/last-attempt-tier-min
Automation Tracking
auto/needs-conflict-resolution
auto/needs-implementer
auto/postmortem
auto/ready-to-merge
auto/restart-throttled
auto/revert
auto/sentinel
auto/stale-inactivity
auto/unstable
Blocked
Bounty
$100
Bounty
$1000
Bounty
$10000
Bounty
$20
Bounty
$2000
Bounty
$250
Bounty
$50
Bounty
$500
Bounty
$5000
Bounty
$750
MoSCoW
Could have
MoSCoW
Must have
MoSCoW
Should have
Needs Feedback
Points
1
Points
13
Points
2
Points
21
Points
3
Points
34
Points
5
Points
55
Points
8
Points
88
Priority
Backlog
Priority
CI Blocker
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Signed-off: Owner
Signed-off: Scrum Master
Signed-off: Tech Lead
Spike
State
Completed
State
Duplicate
State
In Progress
State
In Review
State
Paused
State
Unverified
State
Verified
State
Wont Do
Type
Automation
Type
Bug
Type
Discussion
Type
Documentation
Type
Epic
Type
Feature
Type
Legendary
Type
Refactor
Type
Support
Type
Task
Type
Testing
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Blocks
Depends on
#376 Legendary: Hardening, Testing & Security
cleveragents/cleveragents-core
#2064 UAT:
agents automation-profile list JSON/YAML output missing spec-required profiles wrapper and summary field
cleveragents/cleveragents-core
#2078 UAT:
agents automation-profile show rich output uses single combined panel instead of spec-required 5 separate panels
cleveragents/cleveragents-core
#318 fix(security): remove eval-based config parsing
cleveragents/cleveragents-core
#319 fix(security): harden template rendering
cleveragents/cleveragents-core
#321 fix(security): close async resources and leaks
cleveragents/cleveragents-core
#320 fix(security): enforce explicit exception handling
cleveragents/cleveragents-core
#322 feat(security): enforce read-only actions
cleveragents/cleveragents-core
#387 Fix flaky database_integration robot suite on CI
cleveragents/cleveragents-core
#573 feat(security): implement Secret Masking in LLM Context Construction
cleveragents/cleveragents-core
#1610 BUG-HUNT: [error-handling] Graph continues execution after a node fails
cleveragents/cleveragents-core
#1688 BUG-HUNT: [concurrency] Race condition in StateManager
cleveragents/cleveragents-core
#1749 UAT: JWT, GitHub PAT, and GitLab PAT patterns missing from base redaction.py — tokens leak in logs when error_handling not imported
cleveragents/cleveragents-core
#1799 BUG-HUNT: [resource] Potential resource leak in Agent class due to manual disposal
cleveragents/cleveragents-core
#1832 UAT: AuthHeader and ClientAccount auth models accept empty/whitespace-only token, orgId, and hash — no minimum length validation
cleveragents/cleveragents-core
#1907 UAT:
agents diagnostics does not check config file permissions — spec requires warning when config.toml is world-readable
cleveragents/cleveragents-core
#2056 UAT:
AutomationProfileService hardcodes "manual" as global default profile — spec requires "supervised"
cleveragents/cleveragents-core
#2081 UAT:
agents automation-profile add JSON output uses wrong data structure — spec requires thresholds/flags grouping, not phase_transitions/decision_automation/self_repair/execution_controls
cleveragents/cleveragents-core
#2085 UAT:
agents automation-profile remove JSON output returns full profile dict with removed: true instead of spec-required {"name": "..."} only
cleveragents/cleveragents-core
#2091 UAT: All 8 built-in automation profile descriptions don't match spec-required values
cleveragents/cleveragents-core
#2097 UAT:
AutomationProfileService missing switch() method required by spec for A2A session/set_mode operation
cleveragents/cleveragents-core
#2154 UAT:
core.namespace config key accepts reserved and provider namespace values without validation — setting core.namespace to openai or system is not rejected
cleveragents/cleveragents-core
#2160 UAT:
NamespacedName.parse() in plan.py silently accepts leading-slash names (e.g., "/my-action") and maps them to local/my-action instead of raising a validation error
cleveragents/cleveragents-core
#2228 TEST-INFRA: [dependency-security] aiohttp@3.13.3 - 8 untracked CVEs (CVE-2026-34514, 34516, 34517, 34518, 34519, 34520, 34525, CVE-2026-22815)
cleveragents/cleveragents-core
#2379 UAT:
DEFAULT_AUTOMATION_PROFILE = "balanced" in database models uses a non-existent built-in profile name
cleveragents/cleveragents-core
#2395 UAT: 31
# type: ignore[misc] comments on SQLAlchemy ORM model classes in infrastructure/database/models.py violate the no-type-ignore rule
cleveragents/cleveragents-core
#2461 UAT:
CheckpointManager.create_checkpoint does not store sandbox_path in checkpoint metadata — rollback_to silently returns False
cleveragents/cleveragents-core
#2466 UAT:
CheckpointService.selective_rollback always re-raises original exception — should raise BusinessRuleViolation when recovery also fails
cleveragents/cleveragents-core
#2472 UAT:
snapshot sandbox strategy raises NotImplementedError — tools with checkpoint: "snapshot" (e.g., shell_execute) cannot be properly checkpointed
cleveragents/cleveragents-core
#2559 BUG-HUNT: [concurrency] Race condition in Settings singleton initialization
cleveragents/cleveragents-core
#2604 BUG-HUNT: [error-handling] Incomplete subcommand registration on error
cleveragents/cleveragents-core
#2758 TEST-INFRA: [dependency-security] Medium severity vulnerability in behave
cleveragents/cleveragents-core
#2763 TEST-INFRA: [dependency-security] High severity vulnerability in robotframework
cleveragents/cleveragents-core
#2811 fix(error-handling): handle json.JSONDecodeError in robot.json_helper.parse_json
cleveragents/cleveragents-core
#2813 BUG-HUNT: [error-handling] Missing input validation in
create_template_db.py can lead to unhandled exceptions
cleveragents/cleveragents-core
#2814 BUG-HUNT: [error-handling] Unhandled exceptions in robot.json_helper.load_json_file
cleveragents/cleveragents-core
#2817 BUG: [error-handling] Incomplete traceback in
wrap_unexpected may leak sensitive data
cleveragents/cleveragents-core
#2822 BUG-HUNT: [error-handling] Potential AttributeError in robot.json_helper.get_dict_keys
cleveragents/cleveragents-core
#2828 UAT:
# type: ignore[assignment] in SandboxManager.get_or_create_sandbox_for_resource violates coding standards
cleveragents/cleveragents-core
#2829 BUG-HUNT: [error-handling] Unhandled FileNotFoundError in robot.helper_actor_config
cleveragents/cleveragents-core
#2832 BUG-HUNT: [error-handling] Unhelpful error message in find_fixture
cleveragents/cleveragents-core
#2835 fix(error-handling): handle parsing errors in robot.helper_actor_config
cleveragents/cleveragents-core
#2839 UAT:
CheckpointManager.rollback_to silently returns False when sandbox_path not in checkpoint metadata
cleveragents/cleveragents-core
#2851 UAT:
Settings.data_dir default is 'data' (relative path) — spec requires ~/.cleveragents
cleveragents/cleveragents-core
#2863 UAT:
configure_structlog() rejects 'TRACE' log level — spec requires TRACE support
cleveragents/cleveragents-core
#2865 TEST-INFRA: [dependency-security] Outdated test dependencies
cleveragents/cleveragents-core
#2867 TEST-INFRA: [dependency-security] Outdated pre-commit dependency
cleveragents/cleveragents-core
#2868 TEST-INFRA: [dependency-security] Outdated bandit dependency
cleveragents/cleveragents-core
#2869 UAT: Config security scanner flags Jinja2
{{ template syntax as MEDIUM violation — false positive for spec-required actor YAML templating
cleveragents/cleveragents-core
#2871 UAT: Database URL default inconsistency —
Settings uses sqlite:///cleveragents.db, alembic/env.py uses .cleveragents/db.sqlite, spec requires ~/.cleveragents/cleveragents.db
cleveragents/cleveragents-core
#2900 UAT:
AutomationProfile name validator rejects server:namespace/name format — spec requires full three-part namespacing
cleveragents/cleveragents-core
#2910 UAT:
agents automation-profile show rich output uses single panel instead of spec-required 4 separate panels
cleveragents/cleveragents-core
#2912 UAT:
agents validation attach does not reject plain Tools — spec requires type discriminator check
cleveragents/cleveragents-core
#2923 UAT:
agents automation-profile add rich output title is "Profile Added" instead of spec-required "Profile Registered", missing "Created:" timestamp and separate "Confidence Thresholds" panel
cleveragents/cleveragents-core
#2942 UAT:
agents automation-profile list rich table columns differ from spec — shows Decompose/Create Tool/Select Tool instead of spec-required "Auto-Apply" column
cleveragents/cleveragents-core
#2948 UAT:
agents validation attach rich output missing spec-required panel — shows single line instead of structured panel with Attachment ID, Validation, Mode, Resource, Scope
cleveragents/cleveragents-core
#2951 UAT:
SandboxFactory.create_sandbox never uses the custom strategy registry — custom sandbox strategies registered via SandboxStrategyRegistry can never be instantiated
cleveragents/cleveragents-core
#2953 UAT:
BuiltInSandboxStrategyAdapter.restore_checkpoint does not delete files added after the checkpoint — sandbox state is not fully restored
cleveragents/cleveragents-core
#2960 UAT:
agents automation-profile add JSON output uses wrong structure — phase_transitions/decision_automation/self_repair/execution_controls instead of spec-required thresholds/flags
cleveragents/cleveragents-core
#2964 UAT:
agents plan rollback has undocumented --to-checkpoint option not in spec — spec only defines <PLAN_ID> <CHECKPOINT_ID> positional arguments
cleveragents/cleveragents-core
#2966 UAT:
agents automation-profile remove rich output missing spec-required "Profile Removed" panel — only prints plain checkmark message
cleveragents/cleveragents-core
#2970 UAT:
ValidationAttachmentRepository.attach() silently swaps validation_name and resource_id arguments — violates fail-fast principle
cleveragents/cleveragents-core
#2977 BUG-HUNT: [error-handling] Unsafe Datetime Parsing in LegacyDataMigrator Can Lead to Data Loss
cleveragents/cleveragents-core
#2979 UAT:
CheckpointService.rollback_to_checkpoint is hardcoded to git operations — fails for non-git sandbox strategies (copy_on_write, overlay, transaction_rollback)
cleveragents/cleveragents-core
#2980 UAT: Built-in automation profile descriptions don't match spec —
review, supervised, cautious, and trusted have incorrect description strings
cleveragents/cleveragents-core
#2988 BUG-HUNT: [error-handling] Missing Argument Validation in LLMTraceRepository Constructor
cleveragents/cleveragents-core
#2990 UAT:
CheckpointService.rollback_to_checkpoint only rolls back the first sandbox (sandbox_refs[0]) — multi-resource plans with multiple sandboxes are only partially reverted
cleveragents/cleveragents-core
#2995 BUG-HUNT: [security] Default server host binds to all interfaces — change default to
localhost
cleveragents/cleveragents-core
#2996 BUG-HUNT: [consistency] Inconsistent exception type in
retry_auto_debug
cleveragents/cleveragents-core
#3003 UAT:
CheckpointService.create_workspace_snapshot diff metadata (diff_paths, diff_based, diff_hash) is added after database persistence — metadata is lost on restart
cleveragents/cleveragents-core
#3006 BUG-HUNT: [consistency] Manual dependency injection in
_get_tool_registry_service
cleveragents/cleveragents-core
#3009 BUG-HUNT: [error-handling] Missing Argument Validation in Changeset Repositories
cleveragents/cleveragents-core
#3018 BUG-HUNT: [spec-alignment] Missing Hugging Face provider
cleveragents/cleveragents-core
#3020 BUG-HUNT: [error-handling] Potential busy loop in
retry_auto_debug
cleveragents/cleveragents-core
#3023 UAT:
automation-profile add only accepts schema_version: "1.0" but spec defines cleveragents.version: "3.0" as the schema version field — field name mismatch
cleveragents/cleveragents-core
#3025 BUG-HUNT: [concurrency] Shared Mutable State in SqliteChangeSetStore
cleveragents/cleveragents-core
#3037 BUG-HUNT: [security] Path Traversal Vulnerability in LegacyDataMigrator
cleveragents/cleveragents-core
#3046 BUG-HUNT: [consistency] Duplicated session list summary logic
cleveragents/cleveragents-core
#3047 BUG-HUNT: [consistency] Inefficient Use of get_all_for_project in LegacyDataMigrator
cleveragents/cleveragents-core
#3084 BUG-HUNT: [error-handling] Broad exception handling in auto_debug.py
cleveragents/cleveragents-core
#3085 BUG-HUNT: [error-handling] Silent error suppression in
_build_facade can hide critical startup failures
cleveragents/cleveragents-core
#3088 BUG-HUNT: [error-handling] Broad exception handling in
_cleanup_session_devcontainers can mask cleanup failures
cleveragents/cleveragents-core
#3089 BUG-HUNT: [security] Path traversal vulnerability in plan_generation.py
cleveragents/cleveragents-core
#3100 BUG-HUNT: [error-handling] Broad exception clause in _load_static_base
cleveragents/cleveragents-core
#3130 UAT:
AutomationProfileService.get_effective_profile() maps default_profile parameter to project-level precedence — callers expecting global-level fallback get wrong precedence tier
cleveragents/cleveragents-core
#3133 BUG-HUNT: [error-handling] Silent error suppression in facade construction
cleveragents/cleveragents-core
#3137 BUG-HUNT: [error-handling] Overly broad exception handling in devcontainer cleanup
cleveragents/cleveragents-core
#3140 BUG-HUNT: [error-handling] Overly broad exception handling in event callback
cleveragents/cleveragents-core
#3175 BUG-HUNT: [security] Incomplete sanitization in
_actor_name could lead to path traversal
cleveragents/cleveragents-core
#3181 Refactor: Improper exception handling in PlanLifecycleService
cleveragents/cleveragents-core
#3192 UAT:
agents invariant add rich output does not match spec — missing panel, wrong field labels, and no "✓ OK" confirmation line
cleveragents/cleveragents-core
#3213 BUG-HUNT: [concurrency] Potential race condition in
ActorRegistry
cleveragents/cleveragents-core
#3236 BUG: [security] Potential prompt injection vulnerability in agent graphs
cleveragents/cleveragents-core
#3242 UAT: Invariant IDs missing
inv_ prefix — spec requires inv_<ULID> format but implementation uses raw ULIDs
cleveragents/cleveragents-core
#3253 BUG-HUNT: [error-handling] Generic exception handling in
add method
cleveragents/cleveragents-core
#3276 UAT:
agents safety-profile CLI command missing — SafetyProfile domain model exists but has no CLI management interface
cleveragents/cleveragents-core
#3403 UAT: Core domain model classes do not inherit from spec-required DomainBaseModel base class
cleveragents/cleveragents-core
#3407 UAT:
audit.* config keys (audit.retention-days, audit.async, audit.queue-maxsize) are not registered in ConfigService registry — cannot be managed via agents config CLI
cleveragents/cleveragents-core
#3411 UAT: Prohibited
# type: ignore suppression comments found in domain model files
cleveragents/cleveragents-core
#3447 fix(error-handling): replace broad
except Exception clauses in agents module with specific exception handlers
cleveragents/cleveragents-core
#3448 Fix race condition in BoundedMemorySaver._prune causing data corruption under concurrent access
cleveragents/cleveragents-core
#3452 BUG-HUNT: [error-handling] Suppressed exceptions in facade wiring and cleanup
cleveragents/cleveragents-core
#3621 TEST-INFRA: [dependency-security] Perform a comprehensive dependency security audit
cleveragents/cleveragents-core
#3628 UAT:
_store_project_extras() builds SQL UPDATE with f-string column interpolation — SQL injection risk pattern
cleveragents/cleveragents-core
#3630 Bug:
enforce_permission decorator defined but never applied at any CLI or service call site — authorization entirely unenforced
cleveragents/cleveragents-core
#3646 UAT: Config security scanner (
security_scanner.py) does not scan for YAML-specific injection patterns — !!python/object and !!python/exec constructors not detected
cleveragents/cleveragents-core
#3649 UAT:
validate_config_safety() never called when loading actor, skill, action, or resource YAML — malicious configs bypass security scan
cleveragents/cleveragents-core
#3653 UAT:
PlanGenerationGraph passes plan.prompt directly to LLM without calling sanitize_user_input() — prompt injection mechanism 1 bypassed in plan generation path
cleveragents/cleveragents-core
#3679 fix(repositories): standardize all timestamp generation to timezone-aware UTC in repositories.py
cleveragents/cleveragents-core
#3690 BUG: [error-handling] Inconsistent Error Handling in
use_action function in plan.py
cleveragents/cleveragents-core
#3697 fix(cli): handle unhandled exceptions in
_get_plan_executor DI container wiring
cleveragents/cleveragents-core
#3702 UAT:
PlanApplyService.apply_with_validation_gate silently swallows complete_apply failure, reporting false APPLIED status
cleveragents/cleveragents-core
#3714 BUG: [boundary-condition] Missing Validation for
--project in use_action
cleveragents/cleveragents-core
#3716 UAT:
agents plan rollback restores sandbox but does NOT reset plan phase/state, leaving plan in inconsistent state
cleveragents/cleveragents-core
#3726 BUG-HUNT: [security] Configuration security scanner can be bypassed by YAML tags
cleveragents/cleveragents-core
#3728 UAT:
PlanResumeService.resume_plan directly mutates processing_state bypassing lifecycle service methods, skipping pre-flight guardrails and invariant reconciliation
cleveragents/cleveragents-core
#3736 UAT:
_perform_reversion in PlanLifecycleService does not emit domain events for plan phase reversion, breaking audit log completeness
cleveragents/cleveragents-core
#3744 UAT: InlineToolExecutor._validate_paths() uses heuristic key-name matching — paths under non-standard keys bypass sandbox restriction
cleveragents/cleveragents-core
#3748 fix(cli): Use
yaml.safe_load exclusively in _load_config_text to prevent unsafe deserialization
cleveragents/cleveragents-core
#3769 UAT:
agents plan missing spec-required subcommands: tree, explain, correct, prompt, rollback
cleveragents/cleveragents-core
#3781 BUG-HUNT: [resource] Temporary file leak in M3ValidationAddSuite benchmark
cleveragents/cleveragents-core
#3797 UAT: 329 prohibited
# type: ignore comments in infrastructure/database/repositories.py violate CONTRIBUTING.md type safety policy
cleveragents/cleveragents-core
#3840 UAT:
BoundedMemorySaver._prune() accesses private LangGraph MemorySaver internals via cast(Any, self), creating fragile coupling to LangGraph implementation details
cleveragents/cleveragents-core
#3863 UAT: Silent exception suppression in session create command hides actor detail errors
cleveragents/cleveragents-core
#3864 UAT: Silent exception suppression in _notify_facade() violates exception propagation rules
cleveragents/cleveragents-core
#3873 UAT: Silent exception suppression in use_action() hides config service lookup failures
cleveragents/cleveragents-core
#3874 UAT: Silent exception suppression in plan use command hides project context propagation errors
cleveragents/cleveragents-core
#3876 UAT:
agents session list --format json returns inconsistent structure for empty vs non-empty session lists
cleveragents/cleveragents-core
#3885 UAT: Missing fail-fast validation for required string arguments in create_action() public method
cleveragents/cleveragents-core
#3891 UAT: Missing fail-fast empty-string validation for plan_id in plan lifecycle service public methods
cleveragents/cleveragents-core
#3960 UAT:
validate_path() and validate_sandbox_path() use str.startswith() without os.sep suffix — path traversal prefix-collision bypass in file_tools.py, file_ops.py, and inline_executor.py
cleveragents/cleveragents-core
#3995 UAT: LockService not integrated into PlanLifecycleService or SubplanService — lock enforcement missing during plan transitions
cleveragents/cleveragents-core
#3997 UAT: LockService.count_stale_locks() and is_locked() lack exception handling and session cleanup
cleveragents/cleveragents-core
#4002 UAT: LockService not exported from application/services __init__.py — inconsistent with PermissionService
cleveragents/cleveragents-core
#4003 UAT: LockModel.acquired_at and expires_at use String(30) but ISO datetime with timezone is 32 characters — potential truncation in PostgreSQL
cleveragents/cleveragents-core
#4033 UAT: Security - validate_path() vulnerable to path prefix collision allowing sandbox escape
cleveragents/cleveragents-core
#4054 UAT:
_ThreadLocalStream.flush() raises ValueError when original stream is closed
cleveragents/cleveragents-core
#4142 UAT:
snapshot sandbox strategy raises NotImplementedError — spec-defined strategy is unimplemented
cleveragents/cleveragents-core
#4155 BUG-HUNT: [security] Potential SQL Injection in repository
get_by_name methods via implicit filter_by
cleveragents/cleveragents-core
#5358 BUG-HUNT: [validation] Namespace validator allows whitespace-only namespaces
cleveragents/cleveragents-core
#6067 TEST-INFRA: [dependency-security] Vulnerabilities in Jinja2 3.1.0
cleveragents/cleveragents-core
#7916 BUG: [Security] Command Injection Vulnerability in validate_remediation.sh due to
eval usage
cleveragents/cleveragents-core
#7935 BUG-HUNT: [Security/Error-Handling] Insecure Temporary File Handling in update_tracking_agents.sh
cleveragents/cleveragents-core
Reference
cleveragents/cleveragents-core#362
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Background
Covers security audit findings: template rendering hardening, explicit exception handling, async resource leak closure, and read-only action enforcement.
Expected Behavior
Security audit findings are resolved: template rendering is hardened against injection, exception handling is explicit and safe, async resource leaks are closed, and read-only action enforcement prevents unintended mutations.
Child Issues
Definition of Done
This Epic is complete when all child issues are closed and merged. Security audit findings resolved.
Implementation Notes — Advanced Security Scans Alignment
2026-02-13: Task Q0-adv-security In Progress - Align Security Scans with Nox
security_scansession (between Bandit and Vulture).(Migrated from
docs/implementation-notes.md)freemo referenced this issue2026-03-04 04:57:04 +00:00
PM Status (Day 31):
Epic #362 (Security & Safety Hardening) status review:
M4 milestone (v3.3.0): This epic is assigned to M4. M4 is now feature-complete. Safety profile enforcement (#345) merged Day 23. Secret masking (#573) has PR #656 submitted by @CoreRasurae (merge conflict, no reviews).
Child issue status: Please verify which child issues under this epic are still open vs closed. If all security-related child features are merged, this epic may be ready for closure.
@freemo — can you confirm whether the remaining child issues under this epic are resolved? If so, we can close this epic and unblock M4 milestone closure.
New child issue added: #1273 — BUG: [error-handling] Silent exception swallowing in
MigrationRunner._find_alembic_iniThis issue covers the silent
except Exception: passin_find_alembic_inithat suppresses import errors without logging them. The fix replacespasswith a_logger.debug(...)call, consistent with the explicit exception handling theme of this Epic.Issue #1273 blocks this Epic.
effective_profile_snapshotviolates spec intent #1275New child issue added to this Epic: #1275 — BUG-HUNT: [spec-alignment] Default value of
effective_profile_snapshotviolates spec intentThis issue covers the
Plandomain model'seffective_profile_snapshotfield defaulting to"{}", which violates the specification's auditability and reproducibility requirements. It is a low-priority spec-alignment bug that fits within the Security & Safety Hardening scope.New child issue added: #1283 — Fix silent exception swallowing in
LegacyDataMigrator.migrate_project_dataThis issue addresses the explicit exception handling audit finding (silent swallowing of
json.JSONDecodeErrorandOSErrorin the legacy data migration path). It depends on #1283.try_auto_run#1285try_auto_run#1285Child issue added: #1288 — BUG-HUNT: [spec-alignment] Default database location deviates from specification
This issue fixes the
database_urldefault inSettingsto use~/.cleveragents/cleveragents.dbas required by the specification, rather than the current working directory.Child issue #1289 (BUG-HUNT: [spec-alignment] Database schema documentation in specification is outdated) has been created and blocks this Epic.
New child issue added to this Epic: #1291 — fix: [error-handling] Propagate exception when sandbox backup restore fails during commit
This issue addresses the swallowed exception in
CopyOnWriteSandbox.commitandOverlaySandbox.commitwhensafe_restorefails during rollback. It is a direct child of this Epic (Security & Safety Hardening) as it falls under the "explicit exception handling" audit finding.Dependency: #1291 is independent of the current open work in this Epic and does not block any existing child issues.
robot/cli_core.robotlocal${PYTHON}variable overrides pabot-provided variable, causing test failures #1309robot/cli_core.robotlocal${PYTHON}variable overrides pabot-provided variable, causing test failures #1309agents diagnosticsdoes not check config file permissions — spec requires warning when config.toml is world-readable #1907agents diagnosticsdoes not check config file permissions — spec requires warning when config.toml is world-readableAutomationProfileServicehardcodes"manual"as global default profile — spec requires"supervised"#2056AutomationProfileServicehardcodes"manual"as global default profile — spec requires"supervised"agents automation-profile listJSON/YAML output missing spec-requiredprofileswrapper andsummaryfield #2064agents automation-profile listJSON/YAML output missing spec-requiredprofileswrapper andsummaryfieldagents automation-profile showrich output uses single combined panel instead of spec-required 5 separate panels #2078agents automation-profile showrich output uses single combined panel instead of spec-required 5 separate panelsagents automation-profile showrich output uses single combined panel instead of spec-required 5 separate panels #2078agents automation-profile addJSON output uses wrong data structure — spec requiresthresholds/flagsgrouping, notphase_transitions/decision_automation/self_repair/execution_controls#2081agents automation-profile addJSON output uses wrong data structure — spec requiresthresholds/flagsgrouping, notphase_transitions/decision_automation/self_repair/execution_controlsagents automation-profile removeJSON output returns full profile dict withremoved: trueinstead of spec-required{"name": "..."}only #2085agents automation-profile removeJSON output returns full profile dict withremoved: trueinstead of spec-required{"name": "..."}onlyagents automation-profile removeJSON output returns full profile dict withremoved: trueinstead of spec-required{"name": "..."}only #2085AutomationProfileServicemissingswitch()method required by spec for A2Asession/set_modeoperation #2097AutomationProfileServicemissingswitch()method required by spec for A2Asession/set_modeoperationNamespacedNameinplan.pydoes not validate reserved or provider namespaces — actions and plans can be created withsystem/,admin/,openai/,anthropic/etc. #2143NamespacedNameinplan.pydoes not validate reserved or provider namespaces — actions and plans can be created withsystem/,admin/,openai/,anthropic/etc.core.namespaceconfig key accepts reserved and provider namespace values without validation — settingcore.namespacetoopenaiorsystemis not rejected #2154core.namespaceconfig key accepts reserved and provider namespace values without validation — settingcore.namespacetoopenaiorsystemis not rejectedNamespacedName.parse()inplan.pysilently accepts leading-slash names (e.g.,"/my-action") and maps them tolocal/my-actioninstead of raising a validation error #2160NamespacedName.parse()inplan.pysilently accepts leading-slash names (e.g.,"/my-action") and maps them tolocal/my-actioninstead of raising a validation errorDEFAULT_AUTOMATION_PROFILE = "balanced"in database models uses a non-existent built-in profile name #2379DEFAULT_AUTOMATION_PROFILE = "balanced"in database models uses a non-existent built-in profile name# type: ignore[misc]comments on SQLAlchemy ORM model classes ininfrastructure/database/models.pyviolate the no-type-ignore rule #2395# type: ignore[misc]comments on SQLAlchemy ORM model classes ininfrastructure/database/models.pyviolate the no-type-ignore ruleDEFAULT_AUTOMATION_PROFILE = "balanced"in database models uses a non-existent built-in profile name #2379# type: ignore[misc]comments on SQLAlchemy ORM model classes ininfrastructure/database/models.pyviolate the no-type-ignore rule #2395IndexErrorin_collect_adr_inventory#2381CheckpointManager.create_checkpointdoes not storesandbox_pathin checkpoint metadata —rollback_tosilently returnsFalse#2461CheckpointManager.create_checkpointdoes not storesandbox_pathin checkpoint metadata —rollback_tosilently returnsFalseCheckpointService.selective_rollbackalways re-raises original exception — should raiseBusinessRuleViolationwhen recovery also fails #2466CheckpointService.selective_rollbackalways re-raises original exception — should raiseBusinessRuleViolationwhen recovery also failssnapshotsandbox strategy raisesNotImplementedError— tools withcheckpoint: "snapshot"(e.g.,shell_execute) cannot be properly checkpointed #2472snapshotsandbox strategy raisesNotImplementedError— tools withcheckpoint: "snapshot"(e.g.,shell_execute) cannot be properly checkpointedfreemo referenced this issue2026-04-03 19:20:34 +00:00
create_template_db.pycan lead to unhandled exceptions #2813create_template_db.pycan lead to unhandled exceptionswrap_unexpectedmay leak sensitive data #2817wrap_unexpectedmay leak sensitive data# type: ignore[assignment]inSandboxManager.get_or_create_sandbox_for_resourceviolates coding standards #2828# type: ignore[assignment]inSandboxManager.get_or_create_sandbox_for_resourceviolates coding standardsCheckpointManager.rollback_tosilently returnsFalsewhensandbox_pathnot in checkpoint metadata #2839CheckpointManager.rollback_tosilently returnsFalsewhensandbox_pathnot in checkpoint metadataSettings.data_dirdefault is'data'(relative path) — spec requires~/.cleveragents#2851Settings.data_dirdefault is'data'(relative path) — spec requires~/.cleveragentsconfigure_structlog()rejects'TRACE'log level — spec requires TRACE support #2863configure_structlog()rejects'TRACE'log level — spec requires TRACE supportSettingsusessqlite:///cleveragents.db,alembic/env.pyuses.cleveragents/db.sqlite, spec requires~/.cleveragents/cleveragents.db#2871Settingsusessqlite:///cleveragents.db,alembic/env.pyuses.cleveragents/db.sqlite, spec requires~/.cleveragents/cleveragents.dbSettingsusessqlite:///cleveragents.db,alembic/env.pyuses.cleveragents/db.sqlite, spec requires~/.cleveragents/cleveragents.db#2871{{template syntax as MEDIUM violation — false positive for spec-required actor YAML templating #2869{{template syntax as MEDIUM violation — false positive for spec-required actor YAML templatingAutomationProfilename validator rejectsserver:namespace/nameformat — spec requires full three-part namespacing #2900AutomationProfilename validator rejectsserver:namespace/nameformat — spec requires full three-part namespacingagents automation-profile showrich output uses single panel instead of spec-required 4 separate panels #2910agents validation attachdoes not reject plain Tools — spec requires type discriminator check #2912agents automation-profile showrich output uses single panel instead of spec-required 4 separate panelsagents validation attachdoes not reject plain Tools — spec requires type discriminator checkagents automation-profile addrich output title is "Profile Added" instead of spec-required "Profile Registered", missing "Created:" timestamp and separate "Confidence Thresholds" panel #2923agents automation-profile addrich output title is "Profile Added" instead of spec-required "Profile Registered", missing "Created:" timestamp and separate "Confidence Thresholds" panelagents automation-profile listrich table columns differ from spec — shows Decompose/Create Tool/Select Tool instead of spec-required "Auto-Apply" column #2942agents automation-profile listrich table columns differ from spec — shows Decompose/Create Tool/Select Tool instead of spec-required "Auto-Apply" columnagents validation attachrich output missing spec-required panel — shows single line instead of structured panel with Attachment ID, Validation, Mode, Resource, Scope #2948agents validation attachrich output missing spec-required panel — shows single line instead of structured panel with Attachment ID, Validation, Mode, Resource, ScopeSandboxFactory.create_sandboxnever uses the custom strategy registry — custom sandbox strategies registered viaSandboxStrategyRegistrycan never be instantiated #2951BuiltInSandboxStrategyAdapter.restore_checkpointdoes not delete files added after the checkpoint — sandbox state is not fully restored #2953BuiltInSandboxStrategyAdapter.restore_checkpointdoes not delete files added after the checkpoint — sandbox state is not fully restoredSandboxFactory.create_sandboxnever uses the custom strategy registry — custom sandbox strategies registered viaSandboxStrategyRegistrycan never be instantiatedagents automation-profile addJSON output uses wrong structure —phase_transitions/decision_automation/self_repair/execution_controlsinstead of spec-requiredthresholds/flags#2960agents automation-profile addJSON output uses wrong structure —phase_transitions/decision_automation/self_repair/execution_controlsinstead of spec-requiredthresholds/flagsagents plan rollbackhas undocumented--to-checkpointoption not in spec — spec only defines<PLAN_ID> <CHECKPOINT_ID>positional arguments #2964agents plan rollbackhas undocumented--to-checkpointoption not in spec — spec only defines<PLAN_ID> <CHECKPOINT_ID>positional argumentsagents automation-profile removerich output missing spec-required "Profile Removed" panel — only prints plain checkmark message #2966ValidationAttachmentRepository.attach()silently swapsvalidation_nameandresource_idarguments — violates fail-fast principle #2970agents automation-profile removerich output missing spec-required "Profile Removed" panel — only prints plain checkmark messageValidationAttachmentRepository.attach()silently swapsvalidation_nameandresource_idarguments — violates fail-fast principleCheckpointService.rollback_to_checkpointis hardcoded to git operations — fails for non-git sandbox strategies (copy_on_write,overlay,transaction_rollback) #2979review,supervised,cautious, andtrustedhave incorrect description strings #2980CheckpointService.rollback_to_checkpointis hardcoded to git operations — fails for non-git sandbox strategies (copy_on_write,overlay,transaction_rollback)review,supervised,cautious, andtrustedhave incorrect description stringsCheckpointService.rollback_to_checkpointonly rolls back the first sandbox (sandbox_refs[0]) — multi-resource plans with multiple sandboxes are only partially reverted #2990CheckpointService.rollback_to_checkpointonly rolls back the first sandbox (sandbox_refs[0]) — multi-resource plans with multiple sandboxes are only partially revertedlocalhost#2995retry_auto_debug#2996localhostretry_auto_debugCheckpointService.create_workspace_snapshotdiff metadata (diff_paths,diff_based,diff_hash) is added after database persistence — metadata is lost on restart #3003freemo referenced this issue2026-04-05 03:34:44 +00:00
_get_tool_registry_service#3006CheckpointService.create_workspace_snapshotdiff metadata (diff_paths,diff_based,diff_hash) is added after database persistence — metadata is lost on restart_get_tool_registry_serviceretry_auto_debug#3020retry_auto_debugautomation-profile addonly acceptsschema_version: "1.0"but spec definescleveragents.version: "3.0"as the schema version field — field name mismatch #3023automation-profile addonly acceptsschema_version: "1.0"but spec definescleveragents.version: "3.0"as the schema version field — field name mismatch_build_facadecan hide critical startup failures #3085_build_facadecan hide critical startup failures_cleanup_session_devcontainerscan mask cleanup failures #3088_cleanup_session_devcontainerscan mask cleanup failures_build_facadecan hide critical startup failures #3085_cleanup_session_devcontainerscan mask cleanup failures #3088AutomationProfileService.get_effective_profile()mapsdefault_profileparameter to project-level precedence — callers expecting global-level fallback get wrong precedence tier #3130AutomationProfileService.get_effective_profile()mapsdefault_profileparameter to project-level precedence — callers expecting global-level fallback get wrong precedence tier_actor_namecould lead to path traversal #3175_actor_namecould lead to path traversal_actor_namecould lead to path traversal #3175agents invariant addrich output does not match spec — missing panel, wrong field labels, and no "✓ OK" confirmation line #3192agents invariant addrich output does not match spec — missing panel, wrong field labels, and no "✓ OK" confirmation lineActorRegistry#3213ActorRegistryagents invariant addrich output does not match spec — missing panel, wrong field labels, and no "✓ OK" confirmation line #3192inv_prefix — spec requiresinv_<ULID>format but implementation uses raw ULIDs #3242inv_prefix — spec requiresinv_<ULID>format but implementation uses raw ULIDsaddmethod #3253addmethodinv_prefix — spec requiresinv_<ULID>format but implementation uses raw ULIDs #3242inv_prefix — spec requiresinv_<ULID>format but implementation uses raw ULIDs #3242agents safety-profileCLI command missing — SafetyProfile domain model exists but has no CLI management interface #3276agents safety-profileCLI command missing — SafetyProfile domain model exists but has no CLI management interface_get_tool_registry_service#3006audit.*config keys (audit.retention-days,audit.async,audit.queue-maxsize) are not registered in ConfigService registry — cannot be managed viaagents configCLI #3407audit.*config keys (audit.retention-days,audit.async,audit.queue-maxsize) are not registered in ConfigService registry — cannot be managed viaagents configCLI# type: ignoresuppression comments found in domain model files #3411# type: ignoresuppression comments found in domain model filesexcept Exceptionclauses in agents module with specific exception handlers #3447except Exceptionclauses in agents module with specific exception handlersexcept Exceptionclauses in agents module with specific exception handlers #3447_store_project_extras()builds SQL UPDATE with f-string column interpolation — SQL injection risk pattern #3628_store_project_extras()builds SQL UPDATE with f-string column interpolation — SQL injection risk patternenforce_permissiondecorator defined but never applied at any CLI or service call site — authorization entirely unenforced #3630enforce_permissiondecorator defined but never applied at any CLI or service call site — authorization entirely unenforcedsecurity_scanner.py) does not scan for YAML-specific injection patterns —!!python/objectand!!python/execconstructors not detected #3646security_scanner.py) does not scan for YAML-specific injection patterns —!!python/objectand!!python/execconstructors not detectedvalidate_config_safety()never called when loading actor, skill, action, or resource YAML — malicious configs bypass security scan #3649validate_config_safety()never called when loading actor, skill, action, or resource YAML — malicious configs bypass security scanPlanGenerationGraphpassesplan.promptdirectly to LLM without callingsanitize_user_input()— prompt injection mechanism 1 bypassed in plan generation path #3653PlanGenerationGraphpassesplan.promptdirectly to LLM without callingsanitize_user_input()— prompt injection mechanism 1 bypassed in plan generation pathloggingmodule instead of requiredstructlog— secrets masking processor bypassed in 100+ source files #3687use_actionfunction inplan.py#3690use_actionfunction inplan.py_get_plan_executorDI container wiring #3697_get_plan_executorDI container wiringPlanApplyService.apply_with_validation_gatesilently swallowscomplete_applyfailure, reporting false APPLIED status #3702PlanApplyService.apply_with_validation_gatesilently swallowscomplete_applyfailure, reporting false APPLIED status--projectinuse_action#3714agents plan rollbackrestores sandbox but does NOT reset plan phase/state, leaving plan in inconsistent state #3716--projectinuse_actionagents plan rollbackrestores sandbox but does NOT reset plan phase/state, leaving plan in inconsistent statePlanResumeService.resume_plandirectly mutatesprocessing_statebypassing lifecycle service methods, skipping pre-flight guardrails and invariant reconciliation #3728PlanResumeService.resume_plandirectly mutatesprocessing_statebypassing lifecycle service methods, skipping pre-flight guardrails and invariant reconciliation_perform_reversioninPlanLifecycleServicedoes not emit domain events for plan phase reversion, breaking audit log completeness #3736_perform_reversioninPlanLifecycleServicedoes not emit domain events for plan phase reversion, breaking audit log completenessyaml.safe_loadexclusively in_load_config_textto prevent unsafe deserialization #3748yaml.safe_loadexclusively in_load_config_textto prevent unsafe deserializationagents planmissing spec-required subcommands:tree,explain,correct,prompt,rollback#3769agents planmissing spec-required subcommands:tree,explain,correct,prompt,rollbackagents planmissing spec-required subcommands:tree,explain,correct,prompt,rollback#3769PlanResumeService.resume_plandirectly mutatesprocessing_statebypassing lifecycle service methods, skipping pre-flight guardrails and invariant reconciliation #3728agents plan executeuses wrong JSON output format —_execute_output_dictis defined but never called #3792# type: ignorecomments in infrastructure/database/repositories.py violate CONTRIBUTING.md type safety policy #3797# type: ignorecomments in infrastructure/database/repositories.py violate CONTRIBUTING.md type safety policyBoundedMemorySaver._prune()accesses private LangGraphMemorySaverinternals viacast(Any, self), creating fragile coupling to LangGraph implementation details #3840BoundedMemorySaver._prune()accesses private LangGraphMemorySaverinternals viacast(Any, self), creating fragile coupling to LangGraph implementation detailsagents session list --format jsonreturns inconsistent structure for empty vs non-empty session lists #3876agents session list --format jsonreturns inconsistent structure for empty vs non-empty session listsvalidate_path()andvalidate_sandbox_path()usestr.startswith()withoutos.sepsuffix — path traversal prefix-collision bypass in file_tools.py, file_ops.py, and inline_executor.py #3960validate_path()andvalidate_sandbox_path()usestr.startswith()withoutos.sepsuffix — path traversal prefix-collision bypass in file_tools.py, file_ops.py, and inline_executor.pyUKOIndexerinstantiated withoutcontent_readerin DI container —LocationContentReaderdefaults to nobase_dir, allowing unrestricted filesystem access #3962ReactiveStreamRouter._route_to_llm()applies prompt boundary markers (mechanism 2) but skipssanitize_user_input()(mechanism 1) — prompt injection mechanism 1 bypassed in reactive routing path #3965_ThreadLocalStream.flush()raisesValueErrorwhen original stream is closed #4054_ThreadLocalStream.flush()raisesValueErrorwhen original stream is closedbuiltin/file-searchcompiles user-controlled regex without timeout or validation — ReDoS (Denial of Service) vulnerability #4116InlineToolExecutor._validate_paths()uses heuristic key-name matching — sandbox path restriction bypassed via non-standard input key names #4120langchain-anthropicdependency in pyproject.toml [project.dependencies] #4123nox(primary task runner) is missing from pyproject.toml dev/tests optional dependencies #4126commitizenis configured in pyproject.toml but missing from dev optional dependencies #4130src/cleveragents.egg-info/contains completely wrong package metadata (version 0.1.0, Apache license, Python 3.9) #4131major_version_zero = truein commitizen config contradicts project version 1.0.0+ #4133snapshotsandbox strategy raisesNotImplementedError— spec-defined strategy is unimplemented #4142snapshotsandbox strategy raisesNotImplementedError— spec-defined strategy is unimplementedget_by_namemethods via implicitfilter_by#4155get_by_namemethods via implicitfilter_byevalusage #7916evalusage #7916evalusage