opencode-api-security-testing 1.0.0 → 1.0.1
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/README.md +10 -39
- package/package.json +1 -1
- package/index.ts +0 -9
package/README.md
CHANGED
|
@@ -1,46 +1,27 @@
|
|
|
1
1
|
# API Security Testing Plugin
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
API 安全测试插件,为 OpenCode 提供自动化漏洞扫描和渗透测试能力。
|
|
4
4
|
|
|
5
|
-
##
|
|
6
|
-
|
|
7
|
-
如果您遇到 OpenCode 无法连接的问题,请先确保已从 `opencode.json` 中移除插件配置,然后按以下步骤安装。
|
|
8
|
-
|
|
9
|
-
## 安装步骤
|
|
10
|
-
|
|
11
|
-
### 步骤 1:复制 Agents
|
|
5
|
+
## 安装
|
|
12
6
|
|
|
13
7
|
```bash
|
|
14
|
-
|
|
15
|
-
mkdir -p ~/.config/opencode/agents
|
|
16
|
-
|
|
17
|
-
# 复制 agents 到全局配置目录
|
|
18
|
-
cp -r agents/* ~/.config/opencode/agents/
|
|
8
|
+
npm install opencode-api-security-testing
|
|
19
9
|
```
|
|
20
10
|
|
|
21
|
-
|
|
11
|
+
## 配置
|
|
22
12
|
|
|
23
|
-
|
|
24
|
-
# 创建全局 commands 目录(如果不存在)
|
|
25
|
-
mkdir -p ~/.config/opencode/commands
|
|
13
|
+
在 `opencode.json` 中添加:
|
|
26
14
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
### 步骤 3:复制 References(供参考)
|
|
32
|
-
|
|
33
|
-
```bash
|
|
34
|
-
# 复制漏洞测试参考文档
|
|
35
|
-
cp -r references ~/.config/opencode/
|
|
15
|
+
```json
|
|
16
|
+
{
|
|
17
|
+
"plugin": ["opencode-api-security-testing"]
|
|
18
|
+
}
|
|
36
19
|
```
|
|
37
20
|
|
|
38
21
|
## 使用方法
|
|
39
22
|
|
|
40
23
|
### 使用 Agents
|
|
41
24
|
|
|
42
|
-
在 OpenCode 中使用 `@` 提及 agents:
|
|
43
|
-
|
|
44
25
|
```
|
|
45
26
|
@cyber-supervisor 对 https://example.com 进行 API 安全测试
|
|
46
27
|
```
|
|
@@ -53,16 +34,6 @@ cp -r references ~/.config/opencode/
|
|
|
53
34
|
@resource-specialist 发现所有 API 端点
|
|
54
35
|
```
|
|
55
36
|
|
|
56
|
-
### 使用 Commands
|
|
57
|
-
|
|
58
|
-
```
|
|
59
|
-
/api-security-testing-scan https://example.com/api
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
```
|
|
63
|
-
/api-security-testing-test https://example.com/api/login sqli
|
|
64
|
-
```
|
|
65
|
-
|
|
66
37
|
## Agents
|
|
67
38
|
|
|
68
39
|
### cyber-supervisor
|
|
@@ -76,7 +47,7 @@ cp -r references ~/.config/opencode/
|
|
|
76
47
|
|
|
77
48
|
## 漏洞测试参考
|
|
78
49
|
|
|
79
|
-
|
|
50
|
+
详细测试指南位于 `references/vulnerabilities/` 目录:
|
|
80
51
|
|
|
81
52
|
| 文件 | 漏洞类型 |
|
|
82
53
|
|------|---------|
|
package/package.json
CHANGED