dsh-secret-scrub
Run the following command in DeepSeek Harness:
dsh plugin install jwilson411/dsh-secret-scrub
Paste the following prompt into your AI chat to install this plugin:
Run `dsh plugin install jwilson411/dsh-secret-scrub` inside DeepSeek Harness to install the plugin; source code is available at https://github.com/jwilson411/dsh-secret-scrub
About this plugin
In tool-augmented LLM pipelines, credentials and API tokens are routinely carried into tool arguments and echoed back in results, ending up in both the model context and the transcript. The leak is already done the moment the model sees the bytes. dsh-secret-scrub sits at the narrowest seam in that chain: it pattern-matches tool arguments before execution and tool results after, so the raw bytes are replaced before the model or the log ever touch them.
Each matched secret is swapped for a session-stable placeholder. Identical bytes within the same session always map to the same placeholder, so the model can still reason about which argument produced which result. Across sessions an independent per-session salt guarantees no cross-session correlation. The append-only JSONL incident log records exactly five fields per event: timestamp, session, tool, pattern name, and placeholder. It never stores the preimage, any prefix, any length, or any other fragment.
It is not a vault, not a DLP engine, and not an ML classifier. It matches six predefined credential shapes (GitHub PATs, AWS access keys, Slack bot tokens, PEM private keys, and generic sk- prefixed tokens) and redacts on sight or passes through silently. Teams that route credentials through LLM tool calls will find this a practical last-line scrub: if a known secret shape crosses the wire, it is gone from the transcript before anyone can read it.
Use Cases
- Tool arguments containing API keys are scrubbed to placeholders before execution
- Tool results carrying credentials are redacted before the model sees them in the next turn
- Post-session audit of which secret shapes were intercepted and how many times, via the append-only JSONL log
Best For
- Developers who route credentials and tokens through LLM tool calls
- AI application teams preventing secret leakage into transcripts or model context
- Platform engineers focused on tool-execution security boundaries and post-hoc auditability
Related Plugins
A network security red-team benchmark plugin for DeepSeek-V4.1/Flash featuring dual-layer kernel injection and zero-tool architecture for controlled model safety assessment.
A security red-team prompt plugin for DeepSeek-V4 that uses code-formal mapping and zero-trigger system prompts to enable unconditional output, intended for authorized testing and research only.
Adds an Auto approval mode on the official workspace-write sandbox, classifying semantic risks, asking when ambiguous, and denying destructive operations.
Undo/rollback system for DSH: config & plugin snapshots, one-click undo/redo/restore, message-level revert, secret masking, safe mode, and offline WebUI/GUI/CLI rescue tools for when DSH won't start.