maximiliancw [Fri, 9 Jan 2026 16:00:19 +0000 (17:00 +0100)]
Enhance request logging to conditionally include detected secret types based on configuration; ensuring sensitive information is only logged when explicitly allowed, improving security and compliance
maximiliancw [Fri, 9 Jan 2026 15:52:46 +0000 (16:52 +0100)]
Use OpenAI-compatible error format for secrets blocking:
- Use 400 status code instead of 422
- Use standard error format {message, type, param, code}
- Remove non-standard 'details' field (secret types already in headers)
- Update tests to match new format
maximiliancw [Fri, 9 Jan 2026 15:23:47 +0000 (16:23 +0100)]
Add database migration for secrets detection columns
Existing installations will fail with 'table request_logs has no column
named secrets_detected' since the new columns don't exist in their SQLite
database. This adds a migration check that adds the missing columns if they
don't exist.
maximiliancw [Fri, 9 Jan 2026 15:04:32 +0000 (16:04 +0100)]
Implement redact and route_local actions:
- Integrate redact action: redacts secrets before PII detection, unredacts in responses
- Implement route_local action: routes requests with secrets to local provider
- Update stream transformer to handle both PII and secrets contexts
- Add comprehensive tests for secrets routing logic
- Update config.example.yaml with new entity types and action documentation
- Update README.md with complete secrets detection features
maximiliancw [Fri, 9 Jan 2026 15:02:22 +0000 (16:02 +0100)]
Add reversible redaction module for secret masking:
- Create redact.ts with RedactionContext for tracking secret mappings
- Implement redactSecrets() with configurable placeholder format
- Implement unredactSecrets() for restoring original secrets in responses
- Add streaming helpers for unredacting SSE responses
- Add comprehensive tests covering roundtrip, multiple messages, and streaming
maximiliancw [Fri, 9 Jan 2026 14:52:56 +0000 (15:52 +0100)]
feat(secrets): add detection for API keys, JWT tokens, and Bearer tokens
- Add new secret entity types: API_KEY_OPENAI, API_KEY_AWS, API_KEY_GITHUB, JWT_TOKEN, BEARER_TOKEN
- Extract pattern detection into reusable helper function
- Add comprehensive tests for all new secret types with false positive checks
- Update config schema with typed entity enum
maximiliancw [Fri, 9 Jan 2026 13:44:59 +0000 (14:44 +0100)]
Enhance secrets detection functionality in proxy routes:
- Integrate secrets detection logic into the proxy request handling.
- Add configuration checks for enabling/disabling secrets detection.
- Implement logging for detected secrets and their types.
- Update the logger to accommodate new fields for secrets detection.
- Refactor related functions for improved clarity and maintainability
Stefan Gasser [Fri, 9 Jan 2026 12:57:21 +0000 (13:57 +0100)]
Rename project from LLM-Shield to PasteGuard (#5)
After positive community response (100+ GitHub stars), committing fully
to this project. The name PasteGuard better describes the core function:
"guard what you paste" before sending to LLMs.
Changes:
- Update all branding: package.json, README, CONTRIBUTING
- Rename response headers: X-LLM-Shield-* → X-PasteGuard-*
- Update dashboard UI and page title
- Update /info endpoint metadata
- Update startup banner
- Update config files and defaults
- Update CI workflow docker tag
- Regenerate bun.lock with new package name
Domain pasteguard.com secured. Old GitHub links redirect automatically.
Stefan Gasser [Thu, 8 Jan 2026 16:15:59 +0000 (17:15 +0100)]
Add PII accuracy benchmark with multi-language phone context (#1)
- Add benchmark framework with precision/recall/F1 metrics
- Add 30 test cases across 5 languages (DE, EN, ES, FR, IT)
- Add phone_context words for all 24 supported languages
- Each language has 5-7 native words for: phone, number, mobile, call
Stefan Gasser [Thu, 8 Jan 2026 10:14:12 +0000 (11:14 +0100)]
Initial release
OpenAI-compatible privacy proxy with two modes:
- Mask: Replace PII with placeholders before upstream, unmask in response
- Route: Send PII-containing requests to local LLM
Features:
- 24 language support for PII detection
- Real-time streaming with unmasking
- Dashboard for monitoring
- Microsoft Presidio integration