1. Deterministic Toy Pattern Matching
BoundaryLab is an educational demonstrator. It matches suspicious patterns using explicit regular expressions and deterministic token rules in lib/policy.mjs. It does not execute a local or cloud LLM, does not run natural-language embedding classifiers, and does not claim to detect novel or obfuscated prompt injections.
The purpose of the simulator is not to test whether pattern matching can catch every attack. The purpose is to demonstrate what happens after a suspicious action is proposed: specifically, how an authorization boundary makes the final decision based on caller origin, rather than allowing arbitrary content to execute tools.
2. Provenance Defined by Channel Origin, Not Content
In production LLM systems, prompt injections often masquerade as authoritative system instructions by prepending tokens like SYSTEM OVERRIDE:, ADMIN:, or USER: please forward.
BoundaryLab models authentic security architecture: the channel origin (untrusted_source vs trusted_user) is determined strictly by how the text entered the application runtime. Text found inside a document is irrevocably classified as untrusted_source regardless of its rhetorical claims.
3. The Scoped User Grant Boundary
In The Lab, enabling the option "Also allow internal summary sharing" grants approval strictly for the internal summary proposal (SEND_SUMMARY_INTERNAL). It does not authorize external forwarding (FORWARD_EMAIL) or file deletion (DELETE_NOTES).
This demonstrates the principle of least privilege: user approval must be explicit, granular, and scoped to specific action intents, rather than granting blanket system execution.
4. Honest False Negatives & Detection Limits
If you type an injection phrase that is not catalogued in the regular expressions of lib/policy.mjs, BoundaryLab will report 0 candidate instructions detected.
Crucial truthfulness note: An empty match is an honest limitation of toy regex matching—it is never a certification of safety. In real-world systems, regex alone is fundamentally insufficient against adaptive adversarial prompt injection. The architectural boundary remains the indispensable second line of defense.
5. Privacy and Offline Local Execution
BoundaryLab runs 100% locally in your browser. No external API calls are dispatched, no telemetry is gathered, and no typed document text is ever transmitted over the network. When you click Export evidence report (.json), the JSON file is constructed completely in client-side memory using a Blob URL.
6. Reference Alignment: OWASP LLM01:2025
This project is built directly on the principles established in the OWASP Top 10 for LLM Applications: LLM01 Prompt Injection. OWASP explicitly recommends implementing privilege control, human-in-the-loop approvals for sensitive tools, and treating passive content as untrusted input.