dsh-content-trust: An External Content Trust Boundary Checker for DeepSeek Harness

feely0208/dsh-content-trust

Development & OperationsVerified
Listed on 2026-10-13
Page last updated 2026-10-13

A DSH plugin that audits the external-content trust boundary, checking whether an agent treats text from web pages, files, or emails as instructions, guarding against indirect prompt injection.

dsh-content-trust adds an input-side guardrail to DeepSeek Harness, checking whether an agent treated content from web pages, files, or email as instructions to follow. It targets indirect prompt injection: an attacker hides a line on their page, the agent fetches it, it gets concatenated into the prompt, and the model complies while the user has no idea. The plugin reports findings in severe, high, and medium tiers, can list its built-in rules for line-by-line review, scans fetched HTML files directly, and demonstrates the correct pattern of declaring external content as reference-only in the system prompt with actions restricted to a whitelist.

How to Install

install
npmdsh plugin --profile web add @deepwhale-cn/dsh-content-trust
Category
Development & Operations
Platform
DSH Plugin
Author
feely0208
Distribution
Plugin

dsh-content-trust Key Features

Detects external content run as instructionsFlags unisolated prompt concatenationLists violations by severity levelSupports HTML reports and rule listing
Listed on dsh-plugin.org

dsh-content-trust Repo Summary

What Does It Do?

External Content Trust Boundary (dsh-content-trust) is a DSH plugin for DeepSeek Harness that checks whether an agent has treated content from web pages, files, or email as instructions to follow. It targets indirect prompt injection, the Indirect branch of OWASP LLM01: an attacker hides a line on their page, the agent fetches it, it gets concatenated into the prompt, and the model complies while the user has no idea. The plugin reports findings in severe, high, and medium tiers and shows the correct isolation pattern. It is maintained by feely0208 under the MIT license and was last updated on 2026-10-13.

Core Features

  • Tiered findings: extracting and executing instructions found in external content is severe; external content entering the prompt without isolation, or user credentials injected into the agent browser, is high; concatenation without delimiters or source labels is medium.
  • Rule listing: a built-in rule set can be listed in full so you can check it against your own concatenation code.
  • Page and file scanning: run checks directly against fetched HTML files to locate where external content enters the prompt.
  • Demo mode: a demo run shows how it judges before you wire it into your own flow.
  • Correct-practice guidance: it demonstrates declaring external content as reference-only in the system prompt and restricting actions to a whitelist.
  • Split from output-side checks: this plugin inspects trusted input (external content), while dsh-ai-output-trust inspects trusted output (AI-generated).

How to Use This Plugin?

After enabling it in DSH, run the demo once to see how it judges, then list the rules to check coverage against your own setup, and finally scan the page files you actually fetch. Results come back in three severity tiers: severe means instructions inside external content were executed as commands, high means external content reached the prompt without isolation or credentials were injected into the agent browser, and medium means concatenation lacked delimiters and source labels. The fix is to add delimiters and source labels around external content, state in the system prompt that it is reference-only and its instructions must not be executed, and allow only whitelisted actions. Know the boundaries: file-level exclusion can miss cases where one file mixes compliant and violating usage, detection relies on variable naming, and there is no data-flow analysis. The real defense is architectural, splitting reading external content and executing actions into components with different trust levels.

How to Troubleshoot This Plugin?

Missed detections are the most common report: if one file contains both compliant and violating usage, it may be skipped entirely by file-level exclusion, a trade-off made to reduce false positives, so split the file and check the parts separately. When nothing is flagged, first confirm variable naming is consistent, since inconsistent names cause misses. If you suspect a cross-step data-flow issue, this plugin does not perform data-flow analysis, so move the fix to the architecture level and separate trust levels.

This page is an independent rewrite of the plugin's official README — for authoritative documentation and the latest changes, refer to the source: feely0208/dsh-content-trust. The plugin is third-party code that runs on your machine once installed; inclusion does not imply endorsement — please review the source before installing.

Install, update, and uninstall this plugin in the Plugin Market of DeepSeek Harness's DSH Plugin Hub

DSH Plugin FAQ