dsh-redteam-model
SeaOf0
基于dsh web实现的多种模式,目的是服务于redteam进行授权的安全研究,覆盖渗透测试、红队评估、代码审计等范围领域,请勿用于非法行为。(允许二开,赋予模块各位自己的业务逻辑,方法论只有自己熟练的才好用,好的方法论=好的生态)
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:cengcengcai-creator/dsh-ruleset
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
Behavioral rule compliance for DSH — one policy file drives both prompt injection and evidence-backed three-value checks.
Audits agent behavior, not plugin quality. For plugin conformance, see
PerryLink/dsh-standards(ENTRY/FLOW/BOOST).
The four-tier enforcement model (interception / exit gate / detection / prompt-only) and the "detectable is not blocked" rule live in agent-rule-enforcement. This package is the detection tier: it measures behaviour against logs and never claims to block anything.
Interop: lib/export.js emits a generic JSONL event log (ts / session / tool / ok / checkpoint / outcome), which audit_events.py from that repo consumes directly. Verified: 1,138 events → 40 task segments → long_task_without_checkpoint 15/40.
Most rule plugins inject text. Most audit plugins measure tooling. Neither answers: did the agent follow the rules it was told?
dsh-ruleset keeps one source of truth (policy.yaml):
pass / violation / unknown, each pointing back to a seq or fileContract: unknown is never read as pass (no data source or too few samples stays unknown).
# from GitHub (works today)
dsh plugin --profile web add github:cengcengcai-creator/dsh-ruleset
# from npm (once published)
dsh plugin --profile web add dsh-ruleset
Functional, self-hosted, no npm account needed — install straight from GitHub.
What it does today:
/api/dsh-ruleset/parse, deterministic fallback included).tools/pre-execute guard returns ask for sudo, chmod 777, curl | sh, system-path writes, credential-shaped strings. Hits are logged to .ruleset/guard.log.open/fixed/accepted/false_positive/superseded), false positives subtract from hit counts and are never deleted.audit-verdict.py); |z| < 1.96 is reported as "no meaningful change" instead of red..ruleset/injected.log.AGENTS.md is read-only; policy.yaml is written only on explicit user action, always after a backup; one-click rollback and export are built in.Rule hygiene (/api/dsh-ruleset/hygiene): duplicates, conflicts, rules without predicates, token cost.
Tests: npm test — 20 cases (validation, predicates, extraction, dedupe, plugin-load smoke, guard behaviour).
Known limits: no hot reload (host restart required), client-side slot props are not inspectable, model judging is advisory only (not calibrated with kappa yet).
Listed:
Pending review:
Not on npm yet; install from GitHub until it is:
dsh plugin --profile web add github:cengcengcai-creator/dsh-ruleset CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: audit。