Commit 4c1c128
fix(assail): close CryptoMisuse self-reference FP (use code_only not content)
Self-scan of panic-attack found 1 Critical CryptoMisuse finding in
src/assail/analyzer.rs itself — the detector's own source code.
Cause: the dangerous_insecure_decode detector was using raw `content`
instead of `code_only` (the string-, comment-, and test-mod-stripped
variant that every other check in analyze_rust uses). The old code
carried a comment claiming "this identifier never appears inside a
string literal" — but that was immediately falsified by the format!
macro right below, and by the #[test] fixture at line 5802.
Fix: one-line change to use `code_only`. Comment updated to reflect
the real reason (strip self-references, test fixtures, doc mentions).
Dogfood pass: self-scan Critical count 15 -> 14 (remaining 14 are
UnboundedAllocation from unbounded read_to_string calls in panic-
attack's own src/ — triage pending, all are TPs by detector semantics
and need .take(LIMIT) bounds the same way 007-lang got them).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 24b91b4 commit 4c1c128
1 file changed
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1034 | 1034 | | |
1035 | 1035 | | |
1036 | 1036 | | |
1037 | | - | |
1038 | | - | |
1039 | | - | |
| 1037 | + | |
| 1038 | + | |
| 1039 | + | |
1040 | 1040 | | |
1041 | 1041 | | |
1042 | 1042 | | |
| |||
0 commit comments