Commit b0c5241
committed
feat(config,tui): confirmed opt-out for model-bound key redaction
The model boundary masks credential-shaped tool output before it reaches an
upstream model (configured secrets plus a CredentialShaped structural pass).
Editing files that contain real credentials has always been awkward because
the model cannot quote those bytes back. This adds a deliberate, documented
opt-out that treats lowering the boundary as a security decision:
- config.toml gains [redaction] model_bound = "enabled" (default) | "disabled";
"disabled" only records a request.
- After a restart the interactive TUI shows a full-screen startup gate (same
explicit-key discipline as workspace trust: 1/Y confirm, 2/U keep, 3/N/Esc
quit; Enter never confirms by reflex).
- Confirming persists a receipt to ~/.codewhale/redaction-state.json and
rebuilds the engine so its client applies the opt-out. Until a receipt
exists every process - including headless/exec runs - stays masked.
- The client opt-out covers structured ToolResult blocks only; routing/
classification summaries and durable goal-state text keep always-on
redaction.
- Gate copy is localized across all 15 shipped locale packs; enum, JSON, and
ALL_MESSAGE_IDS stay in sync.1 parent aedb88b commit b0c5241
28 files changed
Lines changed: 1417 additions & 4 deletions
File tree
- crates
- config/src
- tui
- locales
- src
- tui
- app
- ui
- docs
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
206 | 206 | | |
207 | 207 | | |
208 | 208 | | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
209 | 236 | | |
210 | 237 | | |
211 | 238 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
| |||
920 | 921 | | |
921 | 922 | | |
922 | 923 | | |
| 924 | + | |
| 925 | + | |
| 926 | + | |
| 927 | + | |
923 | 928 | | |
924 | 929 | | |
925 | 930 | | |
926 | 931 | | |
| 932 | + | |
| 933 | + | |
| 934 | + | |
| 935 | + | |
| 936 | + | |
| 937 | + | |
| 938 | + | |
| 939 | + | |
| 940 | + | |
| 941 | + | |
| 942 | + | |
| 943 | + | |
| 944 | + | |
| 945 | + | |
| 946 | + | |
927 | 947 | | |
928 | 948 | | |
929 | 949 | | |
| |||
0 commit comments