Malformed user regex crashes the entire scan
|
|
| Severity |
high |
| Kind |
edge-case |
| Location |
src/frameworks/synthetic-callers.ts → compileUserRules |
| Module |
src/frameworks |
| Finding ID |
f-4449ec |
Failure scenario
Lines 344-345 pass configuration strings directly to new RegExp. A .codemaprc rule containing an invalid pattern such as "[" throws SyntaxError during Orchestrator.run, aborting codemap generation instead of producing a configuration error or safely rejecting the rule.
Suggested test
Call compileUserRules([{ caller: 'custom', name_patterns: ['['] }]) and assert the invalid rule is handled without an uncaught native SyntaxError.
How to work this issue
Open a Claude Code session in this repo and say
"work the dev-cli finding f-4449ec in src/frameworks/synthetic-callers.ts".
If this is not a real defect, close the issue with the false-positive label — dev-cli
records the fingerprint and will never raise it again. Closing it without that label marks the
finding fixed instead.
Raised by dev-cli · repo codemap-cli · scan 2026-08-15T05-14-42 · fingerprint 4449ec3af416
Malformed user regex crashes the entire scan
highedge-casesrc/frameworks/synthetic-callers.ts→compileUserRulessrc/frameworksf-4449ecFailure scenario
Lines 344-345 pass configuration strings directly to new RegExp. A .codemaprc rule containing an invalid pattern such as "[" throws SyntaxError during Orchestrator.run, aborting codemap generation instead of producing a configuration error or safely rejecting the rule.
Suggested test
Call compileUserRules([{ caller: 'custom', name_patterns: ['['] }]) and assert the invalid rule is handled without an uncaught native SyntaxError.
How to work this issue
Open a Claude Code session in this repo and say
"work the dev-cli finding
f-4449ecinsrc/frameworks/synthetic-callers.ts".If this is not a real defect, close the issue with the
false-positivelabel — dev-clirecords the fingerprint and will never raise it again. Closing it without that label marks the
finding fixed instead.
Raised by dev-cli · repo
codemap-cli· scan2026-08-15T05-14-42· fingerprint4449ec3af416