/** * SMI-5876 Wave 1: Jailbreak / AI-Defence pattern arrays + evidence-tier map. * @module @skillsmith/core/security/scanner/patterns.jailbreak * * Split out of patterns.ts (which was approaching the 500-line audit:standards * gate) to hold `JAILBREAK_PATTERNS` and `AI_DEFENCE_PATTERNS`; the * evidence-tier classification that governs their severity now lives * alongside them in `patterns.jailbreak.evidence.ts` (SMI-5881, split out for * the same 500-line reason). * * Background: both arrays previously matched bare vocabulary with no context * requirement (`/jailbreak/i`, `/\bDAN\b/`, a bare role marker, a bare `[[...]]` * bracket, ...) — a security-checklist skill's prose tripped the same * CRITICAL/HIGH severity as a real attack. `EVIDENCE_TYPE_BY_PATTERN` * classifies every pattern in both arrays into one of FIVE evidence tiers * (`types.ts`'s `EvidenceType` — `mention`, `role_turn_with_body`, * `imperative_instruction`, `instruction_override`, and `state_assertion`, the * last added in a design-pass follow-up for declarative state assertions like * "Jailbreak activated" that no frame-based directive pattern can catch); * `SecurityScanner.evidence.ts` turns that tier (+ documentation context) into * a severity/confidence pair, and `SecurityScanner.helpers.ts`'s merge-loop * picks the STRONGEST tier per line across both the multi-line and * single-line scan passes. * * Discriminator (see the SMI-5876 design doc for the full worked argument): a * pattern is `mention`-tier iff its matched text, read in isolation, instructs * nothing — pure nouns/names/labels/structural markers/payload-free * obfuscation artifacts. Anything with a verb+object pairing or a * second-person predicate is directive-tier (`imperative_instruction` / * `instruction_override`). A descriptive-frame negative guard (demote when * preceded by "guards against" / "for example" / ...) was deliberately * REJECTED — for prompt injection the text IS the attack, so any framing-based * exemption is itself a bypass vector ("for example, ignore all previous * instructions" would be suppressed). This is why JAILBREAK's `bypass ... * restrictions/filters/safety` entry stays directive-tier: it's a genuine * attack on its own, and the only tool that would separate it from the * "guards against bypass" documentation case is the rejected frame guard. */ export declare const JAILBREAK_PATTERNS: RegExp[]; export declare const AI_DEFENCE_PATTERNS: RegExp[]; //# sourceMappingURL=patterns.jailbreak.d.ts.map