dsh-pentester 0.0.1 → 0.1.0-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,15 +1,44 @@
1
1
  {
2
2
  "name": "dsh-pentester",
3
- "version": "0.0.1",
3
+ "version": "0.1.0-alpha.2",
4
4
  "description": "Pentesting agent plugin for DeepSeek Harness",
5
+ "license": "MIT",
5
6
  "type": "module",
6
- "main": "./index.js",
7
+ "main": "lib/index.js",
8
+ "types": "lib/index.d.ts",
7
9
  "files": [
8
- "index.js",
10
+ "lib",
11
+ "presets",
9
12
  "cordis.patch.yml",
13
+ "cordis.dev.patch.yml",
10
14
  "README.md",
11
15
  "LICENSE"
12
16
  ],
17
+ "engines": {
18
+ "node": "^22.19 || >=24",
19
+ "dsh": ">=0.1.0-rc.6"
20
+ },
21
+ "dsh": {
22
+ "bundle": {
23
+ "patch": "./cordis.patch.yml"
24
+ },
25
+ "client": {
26
+ "inject": [
27
+ "@deepseek-ai/dsh-client-runtime",
28
+ "@deepseek-ai/dsh-client-locale",
29
+ "@deepseek-ai/dsh-client-ui-conversation",
30
+ "@deepseek-ai/dsh-client-ui-primitives"
31
+ ],
32
+ "platform": "web"
33
+ }
34
+ },
35
+ "scripts": {
36
+ "build": "tsdown && node scripts/build-client.mjs",
37
+ "typecheck": "tsc --noEmit",
38
+ "check": "pnpm run typecheck && pnpm run build",
39
+ "test": "node --import ./test/resolve-ts.mjs --test test/config/*.test.ts test/ptap/*.test.ts test/state/*.test.ts test/workflow/*.test.ts test/orchestrator/*.test.ts test/context/*.test.ts test/harness/*.test.ts test/runtime/*.test.ts test/ptes-core/*.test.ts test/tools/*.test.ts test/projection/*.test.ts test/reporting/*.test.ts test/client/*.test.ts test/host/*.test.ts test/integration/*.test.ts",
40
+ "prepare": "pnpm run build"
41
+ },
13
42
  "keywords": [
14
43
  "dsh",
15
44
  "deepseek",
@@ -19,10 +48,53 @@
19
48
  "pentesting",
20
49
  "security"
21
50
  ],
22
- "license": "MIT",
23
- "dsh": {
24
- "bundle": {
25
- "patch": "./cordis.patch.yml"
26
- }
51
+ "repository": {
52
+ "type": "git",
53
+ "url": "git+https://github.com/fb0sh/dsh-pentester.git"
54
+ },
55
+ "bugs": {
56
+ "url": "https://github.com/fb0sh/dsh-pentester/issues"
57
+ },
58
+ "homepage": "https://github.com/fb0sh/dsh-pentester",
59
+ "peerDependencies": {
60
+ "@deepseek-ai/cordis": "^4.0.0",
61
+ "@deepseek-ai/dsh-client-runtime": "*",
62
+ "@deepseek-ai/dsh-client-ui-primitives": "*",
63
+ "@deepseek-ai/dsh-session-projection": "*",
64
+ "@deepseek-ai/dsh-typert-protocol": "*",
65
+ "@deepseek-ai/schemastery": "^3.18.0"
66
+ },
67
+ "devDependencies": {
68
+ "@deepseek-ai/cordis": "^4.0.1",
69
+ "@deepseek-ai/dsh-client-runtime": "0.1.0-rc.7",
70
+ "@deepseek-ai/dsh-client-ui-primitives": "0.1.0-rc.7",
71
+ "@deepseek-ai/dsh-session-projection": "0.1.0-rc.7",
72
+ "@deepseek-ai/dsh-typert-protocol": "0.1.0-rc.7",
73
+ "@deepseek-ai/schemastery": "^3.18.1",
74
+ "@types/node": "^22.20.1",
75
+ "@types/react": "18.3.12",
76
+ "@types/react-dom": "18.3.1",
77
+ "esbuild": "0.25.0",
78
+ "tsdown": "^0.22.14",
79
+ "typescript": "~5.9.2"
80
+ },
81
+ "exports": {
82
+ ".": {
83
+ "types": "./lib/index.d.ts",
84
+ "default": "./lib/index.js"
85
+ },
86
+ "./client": {
87
+ "types": "./lib/client/plugin.d.ts",
88
+ "default": "./lib/client.js"
89
+ },
90
+ "./cordis.patch.yml": "./cordis.patch.yml",
91
+ "./package.json": "./package.json"
92
+ },
93
+ "dependencies": {
94
+ "@modelcontextprotocol/sdk": "1.30.0",
95
+ "@xyflow/react": "12.8.2",
96
+ "react": "18.3.1",
97
+ "react-dom": "18.3.1",
98
+ "zod": "^4.4.3"
27
99
  }
28
100
  }
@@ -0,0 +1,60 @@
1
+ # PentesterMode: a named Agent Preset so DSH sessions can select
2
+ # `pentester-mode` and show the Pentester conversation.view.
3
+ # This is composition identity + persona, not a second Agent runtime.
4
+
5
+ - id: persona
6
+ name: '@deepseek-ai/dsh-persona'
7
+ config:
8
+ text: >-
9
+ You are the Pentester Orchestrator for an authorized PTES engagement.
10
+ Stay inside Scope and Rules of Engagement. Do not invent Host, Docker,
11
+ or MCP capabilities. Coordinate Tasks; do not rewrite the Harness
12
+ Conversation or Session manager. Never call Broker tools
13
+ (http_probe, sqlmap_check, container_exec, mcp_lookup) — those are
14
+ worker-only.
15
+
16
+ PTES STAGE ORDER: 1 Pre-engagement, 2 Intelligence Gathering,
17
+ 3 Threat Modeling, 4 Vulnerability Analysis, 5 Exploitation,
18
+ 6 Post Exploitation, 7 Reporting. A Stage changes only when
19
+ pentester_request_stage_transition is accepted — never announce a
20
+ Stage change in prose. Create Tasks only after the transition to the
21
+ correct Stage is accepted.
22
+
23
+ BOOTSTRAP FIRST: at the start of a Pentester session, call
24
+ pentester_ensure_engagement with no arguments.
25
+ If it returns an existing bound Engagement, continue it.
26
+ If it returns engagement_selection_required, use the native
27
+ ask_user_question tool to ask the user whether to continue one
28
+ of the existing Engagements in this Workspace or start a new one.
29
+ Never attach an Engagement without explicit user choice.
30
+ If the user chooses an existing Engagement, call
31
+ pentester_ensure_engagement with its existingEngagementId.
32
+ If the user chooses a new Engagement, collect the required
33
+ pre-engagement information (objectives, authorized scope, targets,
34
+ Rules of Engagement, credentials when applicable) and call
35
+ pentester_ensure_engagement with { objectives, scopeSummary, targets }
36
+ to create it. Never ask the user to create an Engagement through the
37
+ host CLI or Web. Never invent or type a UUID manually.
38
+
39
+ PRE-ENGAGEMENT CONFIRMATION GATE: before starting any assessment work
40
+ you MUST NOT call any tool (no task creation, no agent spawn, no broker
41
+ execution, no scanning, no ping). First ensure the Engagement exists and
42
+ confirm every required input with the user; wait for the user to confirm
43
+ ALL information before proposing the first Task or advancing the Stage.
44
+ Do not proceed on assumed defaults.
45
+
46
+ HUMAN INTERACTION: every user-facing question throughout the engagement
47
+ (missing information, choice between strategies, product or workflow
48
+ decisions, a value the user must provide) MUST use the native
49
+ ask_user_question tool — never present a numbered/lettered choice list
50
+ in plain text and wait for the user to type an answer. After the
51
+ pre-engagement confirmation, ordinary task splitting, template
52
+ selection, safe recon strategy, prioritization, and deterministic
53
+ workflow choices are yours to decide; do not interrupt the user for
54
+ every small decision.
55
+
56
+ # Native DSH human interaction: ask_user_question (official tool plugin).
57
+ # Rendered by the DSH Web native Question UI. Only this preset exposes it;
58
+ # worker Subagents restrict their tool catalog to PTAP tools.
59
+ - id: tool-ask-user
60
+ name: '@deepseek-ai/dsh-tool-ask-user'
@@ -0,0 +1,3 @@
1
+ name: PentesterMode
2
+ description: PTES Pentester Orchestrator — authorized engagement workspace in the native Conversation view.
3
+ order: 20
package/index.js DELETED
@@ -1,5 +0,0 @@
1
- export const name = "dsh-pentester";
2
-
3
- export function apply() {
4
- console.log("[dsh-pentester] loaded");
5
- }