@sk8metal/michi-cli 0.10.1 → 0.11.0
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 +77 -847
- package/dist/scripts/phase-runner.js +1 -1
- package/dist/scripts/phase-runner.js.map +1 -1
- package/dist/scripts/utils/multi-repo-validator.d.ts +18 -0
- package/dist/scripts/utils/multi-repo-validator.d.ts.map +1 -1
- package/dist/scripts/utils/multi-repo-validator.js +42 -0
- package/dist/scripts/utils/multi-repo-validator.js.map +1 -1
- package/dist/scripts/utils/tasks-format-validator.js +3 -3
- package/dist/scripts/utils/tasks-format-validator.js.map +1 -1
- package/docs/README.md +20 -83
- package/docs/getting-started/configuration.md +379 -0
- package/docs/getting-started/installation.md +59 -0
- package/docs/getting-started/quick-start.md +76 -0
- package/docs/guides/ai-tools.md +311 -0
- package/docs/guides/atlassian-integration.md +116 -0
- package/docs/guides/claude-code.md +155 -0
- package/docs/guides/multi-repo.md +117 -0
- package/docs/guides/workflow.md +382 -0
- package/docs/reference/ai-commands.md +92 -0
- package/docs/reference/cli.md +756 -0
- package/docs/reference/environment-variables.md +192 -0
- package/docs/troubleshooting.md +543 -0
- package/package.json +1 -1
- package/scripts/phase-runner.ts +1 -1
- package/scripts/utils/__tests__/multi-repo-validator.test.ts +159 -1
- package/scripts/utils/multi-repo-validator.ts +50 -0
- package/scripts/utils/tasks-format-validator.ts +3 -3
- package/templates/claude/agents/e2e-first-planner/AGENT.md +1 -1
- package/templates/claude/agents/pr-resolver/AGENT.md +15 -3
- package/templates/claude/commands/michi/e2e-plan.md +1 -1
- package/templates/claude/commands/michi/spec-design.md +2 -2
- package/templates/claude/commands/michi/spec-tasks.md +156 -0
- package/templates/claude/commands/michi/test-planning.md +1 -1
- package/templates/claude/commands/michi/validate-design.md +3 -3
- package/templates/claude/commands/michi-multi-repo/impl-all.md +30 -1
- package/templates/claude/commands/michi-multi-repo/propagate-specs.md +14 -1
- package/templates/claude/commands/michi-multi-repo/spec-review.md +16 -2
- package/templates/claude-agent/agents/repo-spec-executor.md +1 -1
- package/templates/claude-agent/commands/michi/spec-tasks.md +117 -0
- package/templates/claude-agent/rules/code-size-monitor.md +26 -0
- package/templates/claude-agent/rules/code-size-rules.md +32 -0
- package/templates/codex/AGENTS.override.md +1 -1
- package/templates/codex/rules/README.md +2 -2
- package/templates/cursor/commands/michi/spec-tasks.md +117 -0
- package/templates/michi/cc-sdd-overrides/settings/rules/design-review-michi.md +1 -1
- package/docs/context.md +0 -59
- package/docs/michi-development/contributing/development.md +0 -341
- package/docs/michi-development/contributing/release.md +0 -365
- package/docs/michi-development/design/config-unification.md +0 -733
- package/docs/michi-development/design/design-config-current-state.md +0 -330
- package/docs/michi-development/design/design-config-implementation.md +0 -628
- package/docs/michi-development/design/design-config-migration.md +0 -952
- package/docs/michi-development/design/design-config-security.md +0 -771
- package/docs/michi-development/design/design-config-solution.md +0 -583
- package/docs/michi-development/design/design-config-testing.md +0 -892
- package/docs/michi-development/testing/manual-verification-flow.md +0 -871
- package/docs/michi-development/testing/manual-verification-other-tools.md +0 -1279
- package/docs/michi-development/testing/manual-verification-troubleshooting.md +0 -122
- package/docs/michi-development/testing/pre-publish-checklist.md +0 -560
- package/docs/michi-development/testing-strategy.md +0 -87
- package/docs/plan.md +0 -275
- package/docs/user-guide/getting-started/github-token-setup.md +0 -510
- package/docs/user-guide/getting-started/new-repository-setup.md +0 -704
- package/docs/user-guide/getting-started/quick-start.md +0 -212
- package/docs/user-guide/getting-started/setup.md +0 -819
- package/docs/user-guide/guides/agent-skills-integration.md +0 -222
- package/docs/user-guide/guides/customization.md +0 -537
- package/docs/user-guide/guides/internationalization.md +0 -540
- package/docs/user-guide/guides/migration-guide.md +0 -138
- package/docs/user-guide/guides/multi-project.md +0 -368
- package/docs/user-guide/guides/multi-repo-guide.md +0 -1590
- package/docs/user-guide/guides/phase-automation.md +0 -419
- package/docs/user-guide/guides/workflow.md +0 -574
- package/docs/user-guide/hands-on/README.md +0 -142
- package/docs/user-guide/hands-on/claude-agent-setup.md +0 -597
- package/docs/user-guide/hands-on/claude-setup.md +0 -452
- package/docs/user-guide/hands-on/cursor-setup.md +0 -353
- package/docs/user-guide/hands-on/troubleshooting.md +0 -964
- package/docs/user-guide/hands-on/verification-checklist.md +0 -439
- package/docs/user-guide/hands-on/workflow-walkthrough.md +0 -1078
- package/docs/user-guide/reference/config.md +0 -589
- package/docs/user-guide/reference/multi-repo-api.md +0 -771
- package/docs/user-guide/reference/quick-reference.md +0 -297
- package/docs/user-guide/reference/security-test-payloads.md +0 -50
- package/docs/user-guide/reference/tasks-template.md +0 -550
- package/docs/user-guide/release/ci-setup-java.md +0 -114
- package/docs/user-guide/release/ci-setup-nodejs.md +0 -94
- package/docs/user-guide/release/ci-setup-php.md +0 -102
- package/docs/user-guide/release/ci-setup-troubleshooting.md +0 -94
- package/docs/user-guide/release/ci-setup.md +0 -188
- package/docs/user-guide/release/release-flow.md +0 -476
- package/docs/user-guide/templates/test-specs/README.md +0 -173
- package/docs/user-guide/templates/test-specs/e2e-test-spec-template.md +0 -553
- package/docs/user-guide/templates/test-specs/integration-test-spec-template.md +0 -435
- package/docs/user-guide/templates/test-specs/performance-test-spec-template.md +0 -454
- package/docs/user-guide/templates/test-specs/security-test-spec-template.md +0 -625
- package/docs/user-guide/templates/test-specs/unit-test-spec-template.md +0 -328
- package/docs/user-guide/testing/integration-tests.md +0 -312
- package/docs/user-guide/testing/tdd-cycle.md +0 -349
- package/docs/user-guide/testing/test-execution-flow.md +0 -396
- package/docs/user-guide/testing/test-failure-handling.md +0 -521
- package/docs/user-guide/testing/test-planning-flow.md +0 -185
- package/docs/user-guide/testing-strategy.md +0 -185
- package/docs/verification-guide.md +0 -518
|
@@ -1,625 +0,0 @@
|
|
|
1
|
-
# Security Test Specification: {{TEST_NAME}}
|
|
2
|
-
|
|
3
|
-
**Author**: {{AUTHOR}}
|
|
4
|
-
**Date**: {{DATE}}
|
|
5
|
-
**Version**: 1.0
|
|
6
|
-
|
|
7
|
-
## 1. Overview
|
|
8
|
-
|
|
9
|
-
### 1.1 Purpose
|
|
10
|
-
{{PURPOSE}}
|
|
11
|
-
|
|
12
|
-
Example: To identify security vulnerabilities in the {{SYSTEM_NAME}} system and verify that data protection and access control are properly implemented.
|
|
13
|
-
|
|
14
|
-
### 1.2 Scope
|
|
15
|
-
{{SCOPE}}
|
|
16
|
-
|
|
17
|
-
Example: This test specification covers security testing for user authentication, authorization, data encryption, and input validation.
|
|
18
|
-
|
|
19
|
-
### 1.3 Testing Tool
|
|
20
|
-
- **Tool**: {{TOOL_NAME}}
|
|
21
|
-
- **Version**: {{VERSION}}
|
|
22
|
-
|
|
23
|
-
Example:
|
|
24
|
-
- **Tool**: OWASP ZAP / Burp Suite / Snyk / SonarQube
|
|
25
|
-
- **Version**: 2.14.0 / Professional 2023.11 / 1.1000.0 / 10.3.0
|
|
26
|
-
|
|
27
|
-
## 2. Test Environment
|
|
28
|
-
|
|
29
|
-
### 2.1 Software Requirements
|
|
30
|
-
- Programming Language: {{LANGUAGE}} {{VERSION}}
|
|
31
|
-
- Web Server: {{SERVER}} {{VERSION}}
|
|
32
|
-
- Database: {{DATABASE}} {{VERSION}}
|
|
33
|
-
- Authentication System: {{AUTH_SYSTEM}}
|
|
34
|
-
|
|
35
|
-
### 2.2 Test Accounts
|
|
36
|
-
- Admin Account: {{ADMIN_ACCOUNT}}
|
|
37
|
-
- Regular User Account: {{USER_ACCOUNT}}
|
|
38
|
-
- Guest Account: {{GUEST_ACCOUNT}} (if applicable)
|
|
39
|
-
|
|
40
|
-
### 2.3 Test Scope
|
|
41
|
-
- Target URL: {{TARGET_URL}}
|
|
42
|
-
- Target APIs: {{API_ENDPOINTS}}
|
|
43
|
-
- Excluded Scope: {{EXCLUDED_SCOPE}} (production environment, external services, etc.)
|
|
44
|
-
|
|
45
|
-
## 3. Security Test Categories
|
|
46
|
-
|
|
47
|
-
### 3.1 OWASP Top 10 (2021) Coverage
|
|
48
|
-
|
|
49
|
-
| OWASP Category | Vulnerability Name | Testing Coverage |
|
|
50
|
-
|----------------|-------------------|------------------|
|
|
51
|
-
| A01:2021 | Broken Access Control | ✅ Included |
|
|
52
|
-
| A02:2021 | Cryptographic Failures | ✅ Included |
|
|
53
|
-
| A03:2021 | Injection | ✅ Included |
|
|
54
|
-
| A04:2021 | Insecure Design | ✅ Included |
|
|
55
|
-
| A05:2021 | Security Misconfiguration | ✅ Included |
|
|
56
|
-
| A06:2021 | Vulnerable and Outdated Components | ✅ Included |
|
|
57
|
-
| A07:2021 | Identification and Authentication Failures | ✅ Included |
|
|
58
|
-
| A08:2021 | Software and Data Integrity Failures | ✅ Included |
|
|
59
|
-
| A09:2021 | Security Logging and Monitoring Failures | ✅ Included |
|
|
60
|
-
| A10:2021 | Server-Side Request Forgery (SSRF) | ✅ Included |
|
|
61
|
-
|
|
62
|
-
## 4. Test Cases
|
|
63
|
-
|
|
64
|
-
### Test Case ST-001: SQL Injection
|
|
65
|
-
|
|
66
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
67
|
-
|
|
68
|
-
Example: Verify that the application properly sanitizes user input to prevent SQL injection attacks.
|
|
69
|
-
|
|
70
|
-
**Preconditions**:
|
|
71
|
-
- {{PRECONDITION_1}}
|
|
72
|
-
- {{PRECONDITION_2}}
|
|
73
|
-
|
|
74
|
-
Example:
|
|
75
|
-
- Application is running
|
|
76
|
-
- Database contains test data
|
|
77
|
-
- Test user account is available
|
|
78
|
-
|
|
79
|
-
**Test Steps**:
|
|
80
|
-
1. {{STEP_1}}
|
|
81
|
-
2. {{STEP_2}}
|
|
82
|
-
3. {{STEP_3}}
|
|
83
|
-
|
|
84
|
-
Example:
|
|
85
|
-
1. Navigate to login page
|
|
86
|
-
2. Enter malicious SQL in username field: `' OR '1'='1' --`
|
|
87
|
-
3. Enter any password
|
|
88
|
-
4. Click login button
|
|
89
|
-
5. Observe response
|
|
90
|
-
|
|
91
|
-
**Expected Results**:
|
|
92
|
-
{{EXPECTED_RESULTS}}
|
|
93
|
-
|
|
94
|
-
Example:
|
|
95
|
-
- Login should fail
|
|
96
|
-
- No database error messages exposed
|
|
97
|
-
- Application logs the suspicious attempt
|
|
98
|
-
- No unauthorized access granted
|
|
99
|
-
|
|
100
|
-
**Actual Results**:
|
|
101
|
-
[To be filled during test execution]
|
|
102
|
-
|
|
103
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
104
|
-
|
|
105
|
-
**Severity**: High
|
|
106
|
-
|
|
107
|
-
**Notes**:
|
|
108
|
-
{{NOTES}}
|
|
109
|
-
|
|
110
|
-
---
|
|
111
|
-
|
|
112
|
-
### Test Case ST-002: Cross-Site Scripting (XSS)
|
|
113
|
-
|
|
114
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
115
|
-
|
|
116
|
-
Example: Verify that user input is properly sanitized to prevent XSS attacks.
|
|
117
|
-
|
|
118
|
-
**Test Type**: Reflected XSS / Stored XSS / DOM-based XSS
|
|
119
|
-
|
|
120
|
-
**Preconditions**:
|
|
121
|
-
- {{PRECONDITION}}
|
|
122
|
-
|
|
123
|
-
Example:
|
|
124
|
-
- Application is running
|
|
125
|
-
- User can submit content to the application
|
|
126
|
-
|
|
127
|
-
**Test Steps**:
|
|
128
|
-
1. {{STEP_1}}
|
|
129
|
-
2. {{STEP_2}}
|
|
130
|
-
3. {{STEP_3}}
|
|
131
|
-
|
|
132
|
-
Example:
|
|
133
|
-
1. Navigate to user profile page
|
|
134
|
-
2. Enter malicious script in "Bio" field: `<script>alert('XSS')</script>`
|
|
135
|
-
3. Save profile
|
|
136
|
-
4. Reload page and check if script executes
|
|
137
|
-
|
|
138
|
-
**Expected Results**:
|
|
139
|
-
{{EXPECTED_RESULTS}}
|
|
140
|
-
|
|
141
|
-
Example:
|
|
142
|
-
- Script does not execute
|
|
143
|
-
- Input is properly escaped or sanitized
|
|
144
|
-
- Page displays the literal text instead of executing code
|
|
145
|
-
|
|
146
|
-
**Actual Results**:
|
|
147
|
-
[To be filled during test execution]
|
|
148
|
-
|
|
149
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
150
|
-
|
|
151
|
-
**Severity**: High
|
|
152
|
-
|
|
153
|
-
**Notes**:
|
|
154
|
-
{{NOTES}}
|
|
155
|
-
|
|
156
|
-
---
|
|
157
|
-
|
|
158
|
-
### Test Case ST-003: Authentication and Session Management
|
|
159
|
-
|
|
160
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
161
|
-
|
|
162
|
-
Example: Verify secure authentication and session handling.
|
|
163
|
-
|
|
164
|
-
**Preconditions**:
|
|
165
|
-
- {{PRECONDITION}}
|
|
166
|
-
|
|
167
|
-
Example:
|
|
168
|
-
- Test user account is available
|
|
169
|
-
- Browser with developer tools
|
|
170
|
-
|
|
171
|
-
**Test Steps**:
|
|
172
|
-
1. {{STEP_1}}
|
|
173
|
-
2. {{STEP_2}}
|
|
174
|
-
3. {{STEP_3}}
|
|
175
|
-
|
|
176
|
-
Example:
|
|
177
|
-
1. Log in with valid credentials
|
|
178
|
-
2. Capture session token
|
|
179
|
-
3. Log out
|
|
180
|
-
4. Attempt to reuse captured session token
|
|
181
|
-
5. Verify session is invalidated
|
|
182
|
-
|
|
183
|
-
**Expected Results**:
|
|
184
|
-
{{EXPECTED_RESULTS}}
|
|
185
|
-
|
|
186
|
-
Example:
|
|
187
|
-
- Session token is invalidated after logout
|
|
188
|
-
- Reused token returns 401 Unauthorized
|
|
189
|
-
- Session has appropriate timeout
|
|
190
|
-
- Tokens are not exposed in URL
|
|
191
|
-
|
|
192
|
-
**Actual Results**:
|
|
193
|
-
[To be filled during test execution]
|
|
194
|
-
|
|
195
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
196
|
-
|
|
197
|
-
**Severity**: High
|
|
198
|
-
|
|
199
|
-
**Notes**:
|
|
200
|
-
{{NOTES}}
|
|
201
|
-
|
|
202
|
-
---
|
|
203
|
-
|
|
204
|
-
### Test Case ST-004: Authorization and Access Control
|
|
205
|
-
|
|
206
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
207
|
-
|
|
208
|
-
Example: Verify that users can only access resources they are authorized to access.
|
|
209
|
-
|
|
210
|
-
**Preconditions**:
|
|
211
|
-
- {{PRECONDITION}}
|
|
212
|
-
|
|
213
|
-
Example:
|
|
214
|
-
- Regular user account is available
|
|
215
|
-
- Admin-only endpoints are identified
|
|
216
|
-
|
|
217
|
-
**Test Steps**:
|
|
218
|
-
1. {{STEP_1}}
|
|
219
|
-
2. {{STEP_2}}
|
|
220
|
-
3. {{STEP_3}}
|
|
221
|
-
|
|
222
|
-
Example:
|
|
223
|
-
1. Log in as regular user
|
|
224
|
-
2. Attempt to access admin endpoint: `GET /api/admin/users`
|
|
225
|
-
3. Verify access is denied
|
|
226
|
-
4. Attempt to modify another user's data: `PUT /api/users/999`
|
|
227
|
-
5. Verify access is denied
|
|
228
|
-
|
|
229
|
-
**Expected Results**:
|
|
230
|
-
{{EXPECTED_RESULTS}}
|
|
231
|
-
|
|
232
|
-
Example:
|
|
233
|
-
- Regular user receives 403 Forbidden
|
|
234
|
-
- Cannot access admin resources
|
|
235
|
-
- Cannot modify other users' data
|
|
236
|
-
- Proper role-based access control (RBAC) enforcement
|
|
237
|
-
|
|
238
|
-
**Actual Results**:
|
|
239
|
-
[To be filled during test execution]
|
|
240
|
-
|
|
241
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
242
|
-
|
|
243
|
-
**Severity**: Critical
|
|
244
|
-
|
|
245
|
-
**Notes**:
|
|
246
|
-
{{NOTES}}
|
|
247
|
-
|
|
248
|
-
---
|
|
249
|
-
|
|
250
|
-
### Test Case ST-005: Data Encryption in Transit
|
|
251
|
-
|
|
252
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
253
|
-
|
|
254
|
-
Example: Verify that all sensitive data is transmitted over encrypted channels.
|
|
255
|
-
|
|
256
|
-
**Preconditions**:
|
|
257
|
-
- {{PRECONDITION}}
|
|
258
|
-
|
|
259
|
-
Example:
|
|
260
|
-
- Application is accessible over HTTPS
|
|
261
|
-
|
|
262
|
-
**Test Steps**:
|
|
263
|
-
1. {{STEP_1}}
|
|
264
|
-
2. {{STEP_2}}
|
|
265
|
-
3. {{STEP_3}}
|
|
266
|
-
|
|
267
|
-
Example:
|
|
268
|
-
1. Inspect HTTP headers for HTTPS enforcement
|
|
269
|
-
2. Check for Strict-Transport-Security (HSTS) header
|
|
270
|
-
3. Verify TLS version (TLS 1.2 or higher)
|
|
271
|
-
4. Check SSL/TLS certificate validity
|
|
272
|
-
5. Attempt to access site over HTTP and verify redirect to HTTPS
|
|
273
|
-
|
|
274
|
-
**Expected Results**:
|
|
275
|
-
{{EXPECTED_RESULTS}}
|
|
276
|
-
|
|
277
|
-
Example:
|
|
278
|
-
- All traffic uses HTTPS
|
|
279
|
-
- HSTS header is present
|
|
280
|
-
- TLS 1.2+ is enforced
|
|
281
|
-
- Valid SSL certificate
|
|
282
|
-
- HTTP requests redirect to HTTPS
|
|
283
|
-
|
|
284
|
-
**Actual Results**:
|
|
285
|
-
[To be filled during test execution]
|
|
286
|
-
|
|
287
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
288
|
-
|
|
289
|
-
**Severity**: Critical
|
|
290
|
-
|
|
291
|
-
**Notes**:
|
|
292
|
-
{{NOTES}}
|
|
293
|
-
|
|
294
|
-
---
|
|
295
|
-
|
|
296
|
-
### Test Case ST-006: Data Encryption at Rest
|
|
297
|
-
|
|
298
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
299
|
-
|
|
300
|
-
Example: Verify that sensitive data is encrypted when stored in the database.
|
|
301
|
-
|
|
302
|
-
**Preconditions**:
|
|
303
|
-
- {{PRECONDITION}}
|
|
304
|
-
|
|
305
|
-
Example:
|
|
306
|
-
- Database access is available for verification
|
|
307
|
-
- Test data with sensitive fields
|
|
308
|
-
|
|
309
|
-
**Test Steps**:
|
|
310
|
-
1. {{STEP_1}}
|
|
311
|
-
2. {{STEP_2}}
|
|
312
|
-
3. {{STEP_3}}
|
|
313
|
-
|
|
314
|
-
Example:
|
|
315
|
-
1. Create user with password
|
|
316
|
-
2. Directly query database for user record
|
|
317
|
-
3. Verify password is hashed (not plain text)
|
|
318
|
-
4. Verify sensitive fields (SSN, credit card) are encrypted
|
|
319
|
-
5. Check encryption algorithm strength
|
|
320
|
-
|
|
321
|
-
**Expected Results**:
|
|
322
|
-
{{EXPECTED_RESULTS}}
|
|
323
|
-
|
|
324
|
-
Example:
|
|
325
|
-
- Passwords are hashed with strong algorithm (bcrypt, Argon2)
|
|
326
|
-
- Sensitive data is encrypted
|
|
327
|
-
- Encryption keys are not stored in database
|
|
328
|
-
- No plain text sensitive data visible
|
|
329
|
-
|
|
330
|
-
**Actual Results**:
|
|
331
|
-
[To be filled during test execution]
|
|
332
|
-
|
|
333
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
334
|
-
|
|
335
|
-
**Severity**: Critical
|
|
336
|
-
|
|
337
|
-
**Notes**:
|
|
338
|
-
{{NOTES}}
|
|
339
|
-
|
|
340
|
-
---
|
|
341
|
-
|
|
342
|
-
### Test Case ST-007: Cross-Site Request Forgery (CSRF)
|
|
343
|
-
|
|
344
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
345
|
-
|
|
346
|
-
Example: Verify protection against CSRF attacks.
|
|
347
|
-
|
|
348
|
-
**Preconditions**:
|
|
349
|
-
- {{PRECONDITION}}
|
|
350
|
-
|
|
351
|
-
Example:
|
|
352
|
-
- Application has state-changing operations
|
|
353
|
-
- User can perform actions via forms or APIs
|
|
354
|
-
|
|
355
|
-
**Test Steps**:
|
|
356
|
-
1. {{STEP_1}}
|
|
357
|
-
2. {{STEP_2}}
|
|
358
|
-
3. {{STEP_3}}
|
|
359
|
-
|
|
360
|
-
Example:
|
|
361
|
-
1. Log in as user
|
|
362
|
-
2. Inspect state-changing forms for CSRF token
|
|
363
|
-
3. Submit form without CSRF token
|
|
364
|
-
4. Verify request is rejected
|
|
365
|
-
5. Submit form with invalid CSRF token
|
|
366
|
-
6. Verify request is rejected
|
|
367
|
-
|
|
368
|
-
**Expected Results**:
|
|
369
|
-
{{EXPECTED_RESULTS}}
|
|
370
|
-
|
|
371
|
-
Example:
|
|
372
|
-
- All state-changing operations require CSRF token
|
|
373
|
-
- Requests without valid token are rejected
|
|
374
|
-
- CSRF tokens are unique per session
|
|
375
|
-
- Tokens expire appropriately
|
|
376
|
-
|
|
377
|
-
**Actual Results**:
|
|
378
|
-
[To be filled during test execution]
|
|
379
|
-
|
|
380
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
381
|
-
|
|
382
|
-
**Severity**: High
|
|
383
|
-
|
|
384
|
-
**Notes**:
|
|
385
|
-
{{NOTES}}
|
|
386
|
-
|
|
387
|
-
---
|
|
388
|
-
|
|
389
|
-
### Test Case ST-008: Security Headers
|
|
390
|
-
|
|
391
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
392
|
-
|
|
393
|
-
Example: Verify presence of security-related HTTP headers.
|
|
394
|
-
|
|
395
|
-
**Preconditions**:
|
|
396
|
-
- {{PRECONDITION}}
|
|
397
|
-
|
|
398
|
-
Example:
|
|
399
|
-
- Application is running and accessible
|
|
400
|
-
|
|
401
|
-
**Test Steps**:
|
|
402
|
-
1. {{STEP_1}}
|
|
403
|
-
2. {{STEP_2}}
|
|
404
|
-
|
|
405
|
-
Example:
|
|
406
|
-
1. Make HTTP request to application
|
|
407
|
-
2. Inspect response headers for security headers
|
|
408
|
-
|
|
409
|
-
**Expected Results**:
|
|
410
|
-
{{EXPECTED_RESULTS}}
|
|
411
|
-
|
|
412
|
-
Example:
|
|
413
|
-
The following headers should be present:
|
|
414
|
-
- `Content-Security-Policy`: Prevents XSS
|
|
415
|
-
- `X-Frame-Options: DENY`: Prevents clickjacking
|
|
416
|
-
- `X-Content-Type-Options: nosniff`: Prevents MIME sniffing
|
|
417
|
-
- `Strict-Transport-Security`: Enforces HTTPS
|
|
418
|
-
- `Referrer-Policy: no-referrer`: Controls referrer information
|
|
419
|
-
|
|
420
|
-
**Actual Results**:
|
|
421
|
-
[To be filled during test execution]
|
|
422
|
-
|
|
423
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
424
|
-
|
|
425
|
-
**Severity**: Medium
|
|
426
|
-
|
|
427
|
-
**Notes**:
|
|
428
|
-
{{NOTES}}
|
|
429
|
-
|
|
430
|
-
---
|
|
431
|
-
|
|
432
|
-
### Test Case ST-009: Sensitive Data Exposure in Logs
|
|
433
|
-
|
|
434
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
435
|
-
|
|
436
|
-
Example: Verify that sensitive information is not logged.
|
|
437
|
-
|
|
438
|
-
**Preconditions**:
|
|
439
|
-
- {{PRECONDITION}}
|
|
440
|
-
|
|
441
|
-
Example:
|
|
442
|
-
- Access to application logs
|
|
443
|
-
- Ability to perform operations that generate logs
|
|
444
|
-
|
|
445
|
-
**Test Steps**:
|
|
446
|
-
1. {{STEP_1}}
|
|
447
|
-
2. {{STEP_2}}
|
|
448
|
-
3. {{STEP_3}}
|
|
449
|
-
|
|
450
|
-
Example:
|
|
451
|
-
1. Perform various operations (login, registration, transactions)
|
|
452
|
-
2. Review application logs
|
|
453
|
-
3. Search for sensitive data (passwords, tokens, SSN, credit cards)
|
|
454
|
-
4. Verify no sensitive data is logged
|
|
455
|
-
|
|
456
|
-
**Expected Results**:
|
|
457
|
-
{{EXPECTED_RESULTS}}
|
|
458
|
-
|
|
459
|
-
Example:
|
|
460
|
-
- No passwords in logs
|
|
461
|
-
- No API tokens in logs
|
|
462
|
-
- No credit card numbers in logs
|
|
463
|
-
- No personal identifiable information (PII) in plain text
|
|
464
|
-
- Sensitive fields are masked or redacted
|
|
465
|
-
|
|
466
|
-
**Actual Results**:
|
|
467
|
-
[To be filled during test execution]
|
|
468
|
-
|
|
469
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
470
|
-
|
|
471
|
-
**Severity**: High
|
|
472
|
-
|
|
473
|
-
**Notes**:
|
|
474
|
-
{{NOTES}}
|
|
475
|
-
|
|
476
|
-
---
|
|
477
|
-
|
|
478
|
-
### Test Case ST-010: Dependency Vulnerability Scan
|
|
479
|
-
|
|
480
|
-
**Description**: {{TEST_CASE_DESCRIPTION}}
|
|
481
|
-
|
|
482
|
-
Example: Scan third-party dependencies for known vulnerabilities.
|
|
483
|
-
|
|
484
|
-
**Preconditions**:
|
|
485
|
-
- {{PRECONDITION}}
|
|
486
|
-
|
|
487
|
-
Example:
|
|
488
|
-
- Access to project source code
|
|
489
|
-
- Dependency scanning tool installed
|
|
490
|
-
|
|
491
|
-
**Test Steps**:
|
|
492
|
-
1. {{STEP_1}}
|
|
493
|
-
2. {{STEP_2}}
|
|
494
|
-
|
|
495
|
-
Example:
|
|
496
|
-
1. Run dependency scan tool (Snyk, npm audit, OWASP Dependency-Check)
|
|
497
|
-
2. Review scan results
|
|
498
|
-
3. Identify high/critical vulnerabilities
|
|
499
|
-
4. Verify no critical vulnerabilities exist
|
|
500
|
-
|
|
501
|
-
**Expected Results**:
|
|
502
|
-
{{EXPECTED_RESULTS}}
|
|
503
|
-
|
|
504
|
-
Example:
|
|
505
|
-
- Zero critical vulnerabilities
|
|
506
|
-
- Zero high vulnerabilities
|
|
507
|
-
- All dependencies are up-to-date
|
|
508
|
-
- No known CVEs in dependencies
|
|
509
|
-
|
|
510
|
-
**Actual Results**:
|
|
511
|
-
[To be filled during test execution]
|
|
512
|
-
|
|
513
|
-
**Status**: [ ] Pass / [ ] Fail / [ ] Blocked
|
|
514
|
-
|
|
515
|
-
**Severity**: High
|
|
516
|
-
|
|
517
|
-
**Notes**:
|
|
518
|
-
{{NOTES}}
|
|
519
|
-
|
|
520
|
-
---
|
|
521
|
-
|
|
522
|
-
## 5. Test Execution Summary
|
|
523
|
-
|
|
524
|
-
| ID | Test Name | Status | Executed By | Date | Severity | Notes |
|
|
525
|
-
|----|-----------|--------|-------------|------|----------|-------|
|
|
526
|
-
| ST-001 | SQL Injection | | | | High | |
|
|
527
|
-
| ST-002 | XSS | | | | High | |
|
|
528
|
-
| ST-003 | Authentication | | | | High | |
|
|
529
|
-
| ST-004 | Authorization | | | | Critical | |
|
|
530
|
-
| ST-005 | Encryption in Transit | | | | Critical | |
|
|
531
|
-
| ST-006 | Encryption at Rest | | | | Critical | |
|
|
532
|
-
| ST-007 | CSRF | | | | High | |
|
|
533
|
-
| ST-008 | Security Headers | | | | Medium | |
|
|
534
|
-
| ST-009 | Data Exposure in Logs | | | | High | |
|
|
535
|
-
| ST-010 | Dependency Vulnerabilities | | | | High | |
|
|
536
|
-
|
|
537
|
-
## 6. Vulnerabilities Found
|
|
538
|
-
|
|
539
|
-
| Vulnerability ID | CVE ID | Severity | Description | Affected Components | Remediation | Status |
|
|
540
|
-
|------------------|--------|----------|-------------|---------------------|-------------|--------|
|
|
541
|
-
| | | Critical/High/Medium/Low | | | | Open/In Progress/Fixed/Closed |
|
|
542
|
-
|
|
543
|
-
## 7. Sign-off
|
|
544
|
-
|
|
545
|
-
**Tested By**: _______________
|
|
546
|
-
**Date**: _______________
|
|
547
|
-
**Security Officer Approval**: _______________
|
|
548
|
-
**Date**: _______________
|
|
549
|
-
|
|
550
|
-
---
|
|
551
|
-
|
|
552
|
-
## Appendix A: Security Testing Tools Setup
|
|
553
|
-
|
|
554
|
-
### OWASP ZAP
|
|
555
|
-
|
|
556
|
-
```bash
|
|
557
|
-
# Download OWASP ZAP
|
|
558
|
-
wget https://github.com/zaproxy/zaproxy/releases/download/v2.14.0/ZAP_2.14.0_Linux.tar.gz
|
|
559
|
-
tar -xzf ZAP_2.14.0_Linux.tar.gz
|
|
560
|
-
cd ZAP_2.14.0
|
|
561
|
-
|
|
562
|
-
# Start ZAP
|
|
563
|
-
./zap.sh
|
|
564
|
-
```
|
|
565
|
-
|
|
566
|
-
### Snyk (Dependency Scanner)
|
|
567
|
-
|
|
568
|
-
```bash
|
|
569
|
-
# Install Snyk CLI
|
|
570
|
-
npm install -g snyk
|
|
571
|
-
|
|
572
|
-
# Authenticate
|
|
573
|
-
snyk auth
|
|
574
|
-
|
|
575
|
-
# Scan project
|
|
576
|
-
snyk test
|
|
577
|
-
|
|
578
|
-
# Monitor project
|
|
579
|
-
snyk monitor
|
|
580
|
-
```
|
|
581
|
-
|
|
582
|
-
### OWASP Dependency-Check
|
|
583
|
-
|
|
584
|
-
```bash
|
|
585
|
-
# Download Dependency-Check
|
|
586
|
-
wget https://github.com/jeremylong/DependencyCheck/releases/download/v8.4.0/dependency-check-8.4.0-release.zip
|
|
587
|
-
unzip dependency-check-8.4.0-release.zip
|
|
588
|
-
|
|
589
|
-
# Run scan
|
|
590
|
-
./dependency-check/bin/dependency-check.sh --project "MyApp" --scan ./src
|
|
591
|
-
```
|
|
592
|
-
|
|
593
|
-
### SonarQube (Static Analysis)
|
|
594
|
-
|
|
595
|
-
```bash
|
|
596
|
-
# Run SonarQube scanner
|
|
597
|
-
sonar-scanner \
|
|
598
|
-
-Dsonar.projectKey=myproject \
|
|
599
|
-
-Dsonar.sources=./src \
|
|
600
|
-
-Dsonar.host.url=http://localhost:9000 \
|
|
601
|
-
-Dsonar.login=your-token
|
|
602
|
-
```
|
|
603
|
-
|
|
604
|
-
---
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
## Appendix B: Common Attack Payloads
|
|
608
|
-
|
|
609
|
-
攻撃ペイロードの詳細なリストは、以下のリファレンスドキュメントを参照してください:
|
|
610
|
-
|
|
611
|
-
👉 **[一般的な攻撃ペイロード](../../reference/security-test-payloads.md)**
|
|
612
|
-
|
|
613
|
-
## Appendix C: Execution Timing
|
|
614
|
-
|
|
615
|
-
## Phase B (Before Release) - Manual Execution
|
|
616
|
-
|
|
617
|
-
Security tests are executed manually before creating a release tag:
|
|
618
|
-
|
|
619
|
-
1. After PR is merged to main branch
|
|
620
|
-
2. Before creating a release tag
|
|
621
|
-
3. Run all security tests in Phase B
|
|
622
|
-
4. All critical and high-severity vulnerabilities must be fixed before release
|
|
623
|
-
5. Medium/low vulnerabilities should be documented and scheduled for future fix
|
|
624
|
-
|
|
625
|
-
**Note**: All security tests, including static code analysis and dependency vulnerability scanning, are executed manually in Phase B. CI/CD during PR phase (Phase A) only runs unit tests, linting, and build checks.
|