Fix/review hardening - #17
Merged
Merged
Conversation
…(M1/M2) - ModeDefinitionToml in codesmith-config: app_mode, reasoning_effort, approval_policy, sandbox_mode, memory_level, max_subagents, model, provider, tools.include/exclude, features overrides; every field optional (delta semantics, composes with existing config) - built-in modes minimal/balanced/maximal/plan ship in the binary; ~/.codesmith/modes/ then <workspace>/.codesmith/modes/ override by name; broken files skip with a warning instead of blocking startup - enforce tool selection at the per-turn catalog build: apply_tool_selection (allow+deny, case-insensitive, dispatch machinery exempt) + blocked_tools threaded through Op::SendMessage into EngineConfig — allowed_tools was plumbed but never enforced - /mode list|<name>|off|export[!]; catalog modes take precedence over legacy agent/plan/yolo tokens so /mode plan applies the full delta; --mode CLI (tui + facade forwarding), config.toml mode key, settings persistence, footer chip; live dials switch next turn, provider/ features/memory honestly reported as restart-required - memory_level maps onto the existing memory + KOD layers: goldfish (off) / notebook (explicit-only) / elephant (auto+decay) - docs: README "One Binary, Many Modes" section, MODES.md/MODES_cn.md schema + semantics, config.example.toml mode key
- sandbox: bwrap die-with-parent + clean /dev//proc//sys + policy-driven --share-net; seatbelt outbound-only network; hardening before runtime boot; dead seccomp module removed - secrets: 0600 atomic store writes, no CWD/plaintext-config fallbacks, no DeepSeek-key reuse on NVIDIA endpoints; /v1/* auth header-only, mobile SSE via fetch with Authorization header - paths: shared is_safe_path_component + symlink re-canonicalization (agent memory, vision), task-id/extension-entry/session-id validation - correctness: CJK-aware token heuristic, shared estimator everywhere; LSP stderr drain, URI percent-encoding, initialize ordering, per-URI diagnostics cache; prompt-framing escape helpers at six injection sites - team: roster-based protocol authorization, explicit lead identity, empty-name/collision guards, broadcast partial-failure reporting - infra: verify_task.sh exit-code/REWARD/test.patch semantics; atomic writes unified on write_atomic; gh/prefetch/hook blocking I/O moved off tokio workers; web dedup-key/link/facts fixes; dead code and network- hitting tests cleaned
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Testing
cargo fmt --all -- --checkcargo clippy --workspace --all-targets --all-featurescargo test --workspace --all-featuresChecklist