LLMs have revolutionized automated enterprise workflows, but they introduce a catastrophic vector for data leakage. Employees frequently paste high-risk raw credentials, proprietary strings, and personally identifiable information (PII) directly into AI prompt windows. Traditional regex-based filters fail to differentiate between normal programmatic code block grammar and malicious patterns. We built OnyxGuard to serve as a smart, secure, on-device proxy gateway that sanitizes user text inputs dynamically before they ever hit an external API or server pipeline.

OnyxGuard is an intelligent, high-precision data loss prevention (DLP) proxy gateway designed for secure AI application integrations. It intercepts incoming text payloads, parses individual string blocks sequentially, and instantly converts sensitive content into standardized, safe placeholders (such as {{PERSON_1}}, {{LOCATION_1}}, or {{SECRET_1}}). The app features an advanced reverse-token restoration engine that securely maps these hidden variables on a local device dictionary, preserving full structural context for the underlying AI model while entirely masking sensitive data from the cloud.

The project was developed natively using a highly optimized stack designed to execute efficiently on entry-level hardware architectures with a minimal memory footprint. The backend infrastructure relies on a lightweight Node.js server environment running Express to handle application routing. The parsing algorithm uses rigid, multi-layered programmatic character-filtering rules. It scans text blocks sequentially to identify explicit tracking hooks, name-matching patterns, and complex, unusual alphanumeric string combinations containing mixed casing and embedded special characters.

Our primary technical challenge centered around instruction confusion and over-triggering inside smaller, localized language modules. Initial code iterations suffered from an inversion flaw where standard English dictionary words like "currently" or "set to" were aggressively misclassified as secrets, stripping the target prompt of all usable semantic context. We resolved this systemic behavior by implementing a strict whitespace-anchored, multi-pass filtering hierarchy that separates clean A-Z natural language strings from high-complexity credential layouts before passing them to the mapping table.

We are incredibly proud of achieving an ultra-precise, production-grade text sanitization architecture that preserves absolute conversational syntax. The engine handles complex multi-vector scenarios natively—including possessive name consolidation (e.g., mapping "Elena's" directly to {{PERSON_1}}'s without creating redundant entities) and full terminal command structures—all while keeping system RAM usage low.

We learned that handling variable data structures requires absolute step-by-step heuristic rule execution rather than reliance on loose pattern descriptions. By enforcing rigid boundaries based on character-type profiles (letters vs. symbols and integers) and word-by-word structural evaluations, even compact, on-device computing configurations can compete effectively against resource-heavy corporate security networks.

The next phase for OnyxGuard focuses on scaling its integration footprint. We plan to build out native extension adapters for popular web browsers and developer interfaces, and port our core JavaScript filtering rules into a real-time, hands-first interactive WebXR cyber security dashboard for spatial computing terminals.

Built With

  • ai
  • cyber
  • cybersecurity
  • data
  • math
  • protection
  • vs
Share this project:

Updates

Submission history