protect-mcp 0.3.2 → 0.3.3

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/LICENSE ADDED
@@ -0,0 +1,68 @@
1
+ SPDX-License-Identifier: LicenseRef-FSL-1.1-MIT
2
+
3
+ # Functional Source License, Version 1.1, MIT Future License
4
+
5
+ ## Abbreviation
6
+
7
+ FSL-1.1-MIT
8
+
9
+ ## Notice
10
+
11
+ Copyright 2026 Tom Farley
12
+
13
+ ## Terms and Conditions
14
+
15
+ ### Licensor ("We")
16
+
17
+ The party offering the Software under these Terms and Conditions.
18
+
19
+ ### The Software
20
+
21
+ The "Software" is each version of the software that we make available under these Terms and Conditions, as indicated by our inclusion of these Terms and Conditions with the Software.
22
+
23
+ ### License Grant
24
+
25
+ Subject to your compliance with this License Grant and the Patents, Redistribution and Trademark clauses below, we hereby grant you the right to use, copy, modify, create derivative works, publicly perform, publicly display and redistribute the Software for any Permitted Purpose identified below.
26
+
27
+ ### Permitted Purpose
28
+
29
+ A Permitted Purpose is any purpose other than a Competing Use. A Competing Use means making the Software available to others in a commercial product or service that:
30
+
31
+ 1. substitutes for the Software;
32
+ 2. substitutes for any other product or service we offer using the Software that exists as of the date we make the Software available; or
33
+ 3. offers the same or substantially similar functionality as the Software.
34
+
35
+ Permitted Purposes specifically include using the Software:
36
+
37
+ 1. for your internal use and access;
38
+ 2. for non-commercial education;
39
+ 3. for non-commercial research; and
40
+ 4. in connection with professional services that you provide to a licensee using the Software in accordance with these Terms and Conditions.
41
+
42
+ ### Patents
43
+
44
+ To the extent your use for a Permitted Purpose would necessarily infringe our patents, the license grant above includes a license under our patents. If you make a claim against any party that the Software infringes or contributes to the infringement of any patent, then your patent license to the Software ends immediately.
45
+
46
+ ### Redistribution
47
+
48
+ The Terms and Conditions apply to all copies, modifications and derivatives of the Software. If you redistribute any copies, modifications or derivatives of the Software, you must include a copy of or a link to these Terms and Conditions and not remove any copyright notices provided in or with the Software.
49
+
50
+ ### Disclaimer
51
+
52
+ THE SOFTWARE IS PROVIDED "AS IS" AND WITHOUT WARRANTIES OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, TITLE OR NON-INFRINGEMENT. IN NO EVENT WILL WE HAVE ANY LIABILITY TO YOU ARISING OUT OF OR RELATED TO THE SOFTWARE, INCLUDING INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES, EVEN IF WE HAVE BEEN INFORMED OF THEIR POSSIBILITY IN ADVANCE.
53
+
54
+ ### Trademarks
55
+
56
+ Except for displaying the License Details and identifying us as the origin of the Software, you have no right under these Terms and Conditions to use our trademarks, trade names, service marks or product names.
57
+
58
+ ## Grant of Future License
59
+
60
+ We hereby irrevocably grant you an additional license to use the Software under the MIT license that is effective on the second anniversary of the date we make the Software available.
61
+
62
+ On or after that date, you may use the Software under the MIT license, in which case the following will apply:
63
+
64
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
65
+
66
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
67
+
68
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
package/README.md CHANGED
@@ -210,8 +210,48 @@ Use `createAuditBundle()` around your own collected signed receipts.
210
210
  - **Keep the claims tight.** The default CLI path does not yet do everything the long-term architecture will support.
211
211
  - **Layer on top of existing auth.** Don't rip out your stack just to add control and evidence.
212
212
 
213
+ ## Incident-Anchored Policy Packs
214
+
215
+ Ship with protect-mcp — each prevents a real attack:
216
+
217
+ | Policy | Incident | OWASP Categories |
218
+ |--------|----------|-----------------|
219
+ | `clinejection.json` | CVE-2025-6514: MCP OAuth proxy hijack (437K environments) | A01, A03 |
220
+ | `terraform-destroy.json` | Autonomous Terraform agent destroys production | A05, A06 |
221
+ | `github-mcp-hijack.json` | Prompt injection via crafted GitHub issue | A01, A02, A03 |
222
+ | `data-exfiltration.json` | Agent data theft via outbound tool abuse | A02, A04 |
223
+ | `financial-safe.json` | Unauthorized financial transaction | A05, A06 |
224
+
225
+ ```bash
226
+ npx protect-mcp --policy node_modules/protect-mcp/policies/clinejection.json -- node server.js
227
+ ```
228
+
229
+ Full OWASP Agentic Top 10 mapping: [scopeblind.com/docs/owasp](https://scopeblind.com/docs/owasp)
230
+
231
+ ## BYOPE: External Policy Engines
232
+
233
+ Supports OPA, Cerbos, Cedar (AWS AgentCore), and generic HTTP endpoints:
234
+
235
+ ```json
236
+ {
237
+ "policy_engine": "hybrid",
238
+ "external": {
239
+ "endpoint": "http://localhost:8181/v1/data/mcp/allow",
240
+ "format": "cedar",
241
+ "timeout_ms": 200,
242
+ "fallback": "deny"
243
+ }
244
+ }
245
+ ```
246
+
247
+ ## Standards & IP
248
+
249
+ - **IETF Internet-Draft**: [draft-farley-acta-signed-receipts-00](https://datatracker.ietf.org/doc/draft-farley-acta-signed-receipts/) — Signed Decision Receipts for Machine-to-Machine Access Control
250
+ - **Patent Status**: 4 Australian provisional patents pending (2025-2026) covering decision receipts with configurable disclosure, tool-calling gateway, agent manifests, and portable identity
251
+ - **Verification**: MIT-licensed — `npx @veritasacta/verify --self-test`
252
+
213
253
  ## License
214
254
 
215
- FSL-1.1-MIT — free to use, converts to full MIT after 2 years.
255
+ FSL-1.1-MIT — free to use, modify, and self-host. Cannot be offered as a competing hosted service. Converts to full MIT after 2 years per version.
216
256
 
217
- [scopeblind.com](https://scopeblind.com) · [npm](https://www.npmjs.com/package/protect-mcp) · [GitHub](https://github.com/tomjwxf/scopeblind-gateway)
257
+ [scopeblind.com](https://scopeblind.com) · [npm](https://www.npmjs.com/package/protect-mcp) · [GitHub](https://github.com/tomjwxf/scopeblind-gateway) · [IETF Draft](https://datatracker.ietf.org/doc/draft-farley-acta-signed-receipts/)
@@ -460,6 +460,28 @@ function formatRequest(context, format) {
460
460
  },
461
461
  actions: [context.action.operation || "call"]
462
462
  };
463
+ case "cedar":
464
+ return {
465
+ principal: {
466
+ type: "Agent",
467
+ id: context.actor.id || "unknown"
468
+ },
469
+ action: {
470
+ type: "Action",
471
+ id: `MCP::Tool::${context.action.operation || "call"}`
472
+ },
473
+ resource: {
474
+ type: "Tool",
475
+ id: context.action.tool
476
+ },
477
+ context: {
478
+ tier: context.actor.tier,
479
+ manifest_hash: context.actor.manifest_hash || null,
480
+ service: context.target.service || "default",
481
+ mode: context.mode,
482
+ credential_ref: context.credential_ref || null
483
+ }
484
+ };
463
485
  case "generic":
464
486
  default:
465
487
  return context;
@@ -489,6 +511,22 @@ function parseResponse(result, format) {
489
511
  }
490
512
  }
491
513
  return { allowed: false, reason: "unrecognized Cerbos response" };
514
+ case "cedar":
515
+ if (typeof result.decision === "string") {
516
+ return {
517
+ allowed: result.decision === "Allow",
518
+ reason: result.decision === "Deny" ? `cedar_deny${result.diagnostics ? ": " + JSON.stringify(result.diagnostics) : ""}` : void 0,
519
+ metadata: result.diagnostics
520
+ };
521
+ }
522
+ if (Array.isArray(result.results) && result.results.length > 0) {
523
+ const first = result.results[0];
524
+ return {
525
+ allowed: first.decision === "Allow",
526
+ reason: first.decision === "Deny" ? "cedar_deny" : void 0
527
+ };
528
+ }
529
+ return { allowed: false, reason: "unrecognized Cedar response" };
492
530
  case "generic":
493
531
  default:
494
532
  return {
package/dist/cli.js CHANGED
@@ -3326,6 +3326,28 @@ function formatRequest(context, format) {
3326
3326
  },
3327
3327
  actions: [context.action.operation || "call"]
3328
3328
  };
3329
+ case "cedar":
3330
+ return {
3331
+ principal: {
3332
+ type: "Agent",
3333
+ id: context.actor.id || "unknown"
3334
+ },
3335
+ action: {
3336
+ type: "Action",
3337
+ id: `MCP::Tool::${context.action.operation || "call"}`
3338
+ },
3339
+ resource: {
3340
+ type: "Tool",
3341
+ id: context.action.tool
3342
+ },
3343
+ context: {
3344
+ tier: context.actor.tier,
3345
+ manifest_hash: context.actor.manifest_hash || null,
3346
+ service: context.target.service || "default",
3347
+ mode: context.mode,
3348
+ credential_ref: context.credential_ref || null
3349
+ }
3350
+ };
3329
3351
  case "generic":
3330
3352
  default:
3331
3353
  return context;
@@ -3355,6 +3377,22 @@ function parseResponse(result, format) {
3355
3377
  }
3356
3378
  }
3357
3379
  return { allowed: false, reason: "unrecognized Cerbos response" };
3380
+ case "cedar":
3381
+ if (typeof result.decision === "string") {
3382
+ return {
3383
+ allowed: result.decision === "Allow",
3384
+ reason: result.decision === "Deny" ? `cedar_deny${result.diagnostics ? ": " + JSON.stringify(result.diagnostics) : ""}` : void 0,
3385
+ metadata: result.diagnostics
3386
+ };
3387
+ }
3388
+ if (Array.isArray(result.results) && result.results.length > 0) {
3389
+ const first = result.results[0];
3390
+ return {
3391
+ allowed: first.decision === "Allow",
3392
+ reason: first.decision === "Deny" ? "cedar_deny" : void 0
3393
+ };
3394
+ }
3395
+ return { allowed: false, reason: "unrecognized Cedar response" };
3358
3396
  case "generic":
3359
3397
  default:
3360
3398
  return {
package/dist/cli.mjs CHANGED
@@ -7,7 +7,7 @@ import {
7
7
  parseLogFile,
8
8
  simulate,
9
9
  validateCredentials
10
- } from "./chunk-GV7N53QE.mjs";
10
+ } from "./chunk-WDCPUM2O.mjs";
11
11
 
12
12
  // src/cli.ts
13
13
  function printHelp() {
package/dist/index.d.mts CHANGED
@@ -36,8 +36,8 @@ type PolicyEngineMode = 'built-in' | 'external' | 'hybrid';
36
36
  interface ExternalPDPConfig {
37
37
  /** HTTP endpoint for the external policy decision point */
38
38
  endpoint: string;
39
- /** Response format: 'opa' | 'cerbos' | 'generic' */
40
- format?: 'opa' | 'cerbos' | 'generic';
39
+ /** Response format: 'opa' | 'cerbos' | 'cedar' | 'generic' */
40
+ format?: 'opa' | 'cerbos' | 'cedar' | 'generic';
41
41
  /** Timeout in milliseconds (default: 500) */
42
42
  timeout_ms?: number;
43
43
  /** Fallback decision when external PDP is unreachable */
@@ -480,7 +480,7 @@ declare function isSigningEnabled(): boolean;
480
480
  * BYOPE (Bring Your Own Policy Engine) — sends decision context
481
481
  * to an external Policy Decision Point via HTTP webhook.
482
482
  *
483
- * Supports OPA, Cerbos, and generic JSON formats.
483
+ * Supports OPA, Cerbos, Cedar (AWS), and generic JSON formats.
484
484
  * ScopeBlind always signs the receipt regardless of who made the decision.
485
485
  *
486
486
  * Sprint 2: One HTTP webhook adapter. More adapters later.
package/dist/index.d.ts CHANGED
@@ -36,8 +36,8 @@ type PolicyEngineMode = 'built-in' | 'external' | 'hybrid';
36
36
  interface ExternalPDPConfig {
37
37
  /** HTTP endpoint for the external policy decision point */
38
38
  endpoint: string;
39
- /** Response format: 'opa' | 'cerbos' | 'generic' */
40
- format?: 'opa' | 'cerbos' | 'generic';
39
+ /** Response format: 'opa' | 'cerbos' | 'cedar' | 'generic' */
40
+ format?: 'opa' | 'cerbos' | 'cedar' | 'generic';
41
41
  /** Timeout in milliseconds (default: 500) */
42
42
  timeout_ms?: number;
43
43
  /** Fallback decision when external PDP is unreachable */
@@ -480,7 +480,7 @@ declare function isSigningEnabled(): boolean;
480
480
  * BYOPE (Bring Your Own Policy Engine) — sends decision context
481
481
  * to an external Policy Decision Point via HTTP webhook.
482
482
  *
483
- * Supports OPA, Cerbos, and generic JSON formats.
483
+ * Supports OPA, Cerbos, Cedar (AWS), and generic JSON formats.
484
484
  * ScopeBlind always signs the receipt regardless of who made the decision.
485
485
  *
486
486
  * Sprint 2: One HTTP webhook adapter. More adapters later.
package/dist/index.js CHANGED
@@ -521,6 +521,28 @@ function formatRequest(context, format) {
521
521
  },
522
522
  actions: [context.action.operation || "call"]
523
523
  };
524
+ case "cedar":
525
+ return {
526
+ principal: {
527
+ type: "Agent",
528
+ id: context.actor.id || "unknown"
529
+ },
530
+ action: {
531
+ type: "Action",
532
+ id: `MCP::Tool::${context.action.operation || "call"}`
533
+ },
534
+ resource: {
535
+ type: "Tool",
536
+ id: context.action.tool
537
+ },
538
+ context: {
539
+ tier: context.actor.tier,
540
+ manifest_hash: context.actor.manifest_hash || null,
541
+ service: context.target.service || "default",
542
+ mode: context.mode,
543
+ credential_ref: context.credential_ref || null
544
+ }
545
+ };
524
546
  case "generic":
525
547
  default:
526
548
  return context;
@@ -550,6 +572,22 @@ function parseResponse(result, format) {
550
572
  }
551
573
  }
552
574
  return { allowed: false, reason: "unrecognized Cerbos response" };
575
+ case "cedar":
576
+ if (typeof result.decision === "string") {
577
+ return {
578
+ allowed: result.decision === "Allow",
579
+ reason: result.decision === "Deny" ? `cedar_deny${result.diagnostics ? ": " + JSON.stringify(result.diagnostics) : ""}` : void 0,
580
+ metadata: result.diagnostics
581
+ };
582
+ }
583
+ if (Array.isArray(result.results) && result.results.length > 0) {
584
+ const first = result.results[0];
585
+ return {
586
+ allowed: first.decision === "Allow",
587
+ reason: first.decision === "Deny" ? "cedar_deny" : void 0
588
+ };
589
+ }
590
+ return { allowed: false, reason: "unrecognized Cedar response" };
553
591
  case "generic":
554
592
  default:
555
593
  return {
package/dist/index.mjs CHANGED
@@ -18,7 +18,7 @@ import {
18
18
  signDecision,
19
19
  simulate,
20
20
  validateCredentials
21
- } from "./chunk-GV7N53QE.mjs";
21
+ } from "./chunk-WDCPUM2O.mjs";
22
22
  import {
23
23
  collectSignedReceipts,
24
24
  createAuditBundle
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "protect-mcp",
3
- "version": "0.3.2",
3
+ "version": "0.3.3",
4
+ "mcpName": "io.github.tomjwxf/protect-mcp",
4
5
  "description": "Security gateway for MCP servers. Shadow-mode logs, per-tool policies, optional local Ed25519-signed receipts. Programmatic hooks for trust tiers, credential config, and external policy engines.",
5
6
  "main": "dist/index.js",
6
7
  "types": "dist/index.d.ts",
@@ -22,6 +23,7 @@
22
23
  },
23
24
  "files": [
24
25
  "dist",
26
+ "policies",
25
27
  "README.md"
26
28
  ],
27
29
  "keywords": [
@@ -36,7 +38,15 @@
36
38
  "decision-log",
37
39
  "tool-protection",
38
40
  "ai-agent",
39
- "llm-gateway"
41
+ "llm-gateway",
42
+ "owasp",
43
+ "cedar",
44
+ "opa",
45
+ "ed25519",
46
+ "receipts",
47
+ "trust-tiers",
48
+ "agent-governance",
49
+ "claude-code"
40
50
  ],
41
51
  "author": "Tom Farley <tommy@scopeblind.com>",
42
52
  "license": "FSL-1.1-MIT",
@@ -0,0 +1,18 @@
1
+ {
2
+ "$comment": "Claude Code hooks configuration. Add this to your .claude/settings.json to integrate protect-mcp as a pre-tool-use hook for Claude Code. Every tool call will be evaluated against your protect-mcp policy and produce a signed receipt.",
3
+ "hooks": {
4
+ "PreToolUse": [
5
+ {
6
+ "matcher": ".*",
7
+ "hooks": [
8
+ {
9
+ "type": "command",
10
+ "command": "npx protect-mcp hook-eval --tool \"$TOOL_NAME\" --input \"$TOOL_INPUT\"",
11
+ "timeout": 5000,
12
+ "on_failure": "allow"
13
+ }
14
+ ]
15
+ }
16
+ ]
17
+ }
18
+ }
@@ -0,0 +1,45 @@
1
+ {
2
+ "$comment": "CVE-2025-6514: Clinejection — Malicious MCP OAuth proxy hijacked 437,000+ developer environments. Blocks shell execution, restricts file access to non-sensitive paths, requires approval for any write operation.",
3
+ "incident": "CVE-2025-6514",
4
+ "incident_name": "Clinejection MCP OAuth Proxy Hijack",
5
+ "incident_date": "2025-07-15",
6
+ "owasp_categories": ["A01-Prompt-Injection", "A03-Supply-Chain"],
7
+ "tools": {
8
+ "*": {
9
+ "rate_limit": "30/minute"
10
+ },
11
+ "execute_command": {
12
+ "block": true
13
+ },
14
+ "run_command": {
15
+ "block": true
16
+ },
17
+ "shell": {
18
+ "block": true
19
+ },
20
+ "bash": {
21
+ "block": true
22
+ },
23
+ "terminal": {
24
+ "block": true
25
+ },
26
+ "write_file": {
27
+ "require_approval": true,
28
+ "rate_limit": "10/minute"
29
+ },
30
+ "edit_file": {
31
+ "require_approval": true,
32
+ "rate_limit": "10/minute"
33
+ },
34
+ "read_file": {
35
+ "rate_limit": "30/minute",
36
+ "min_tier": "signed-known"
37
+ },
38
+ "list_files": {
39
+ "rate_limit": "60/minute"
40
+ }
41
+ },
42
+ "signing": {
43
+ "enabled": true
44
+ }
45
+ }
@@ -0,0 +1,52 @@
1
+ {
2
+ "$comment": "Prevents data exfiltration via AI agents. Blocks all outbound data channels (email, webhooks, uploads, HTTP). Restricts file reads. Requires approval for any external communication.",
3
+ "incident": "agent-data-exfiltration-pattern",
4
+ "incident_name": "AI Agent Data Exfiltration via Tool Abuse",
5
+ "owasp_categories": ["A02-Sensitive-Data-Exposure", "A04-Tool-Call-Injection"],
6
+ "tools": {
7
+ "*": {
8
+ "rate_limit": "60/minute"
9
+ },
10
+ "send_email": {
11
+ "block": true
12
+ },
13
+ "send_message": {
14
+ "block": true
15
+ },
16
+ "upload_file": {
17
+ "block": true
18
+ },
19
+ "http_request": {
20
+ "block": true
21
+ },
22
+ "http_post": {
23
+ "block": true
24
+ },
25
+ "webhook": {
26
+ "block": true
27
+ },
28
+ "publish": {
29
+ "block": true
30
+ },
31
+ "post_to_api": {
32
+ "block": true
33
+ },
34
+ "execute_command": {
35
+ "block": true
36
+ },
37
+ "read_file": {
38
+ "rate_limit": "20/minute",
39
+ "min_tier": "signed-known"
40
+ },
41
+ "search": {
42
+ "rate_limit": "30/minute"
43
+ },
44
+ "database_query": {
45
+ "rate_limit": "10/minute",
46
+ "min_tier": "signed-known"
47
+ }
48
+ },
49
+ "signing": {
50
+ "enabled": true
51
+ }
52
+ }
@@ -0,0 +1,49 @@
1
+ {
2
+ "$comment": "Financial services safety policy. Every financial action requires human approval with evidenced trust tier. All reads are rate-limited. Destructive operations blocked entirely.",
3
+ "incident": "agent-unauthorized-transaction-pattern",
4
+ "incident_name": "Unauthorized Financial Transaction via AI Agent",
5
+ "owasp_categories": ["A05-Insufficient-Access-Control", "A06-Excessive-Autonomy"],
6
+ "tools": {
7
+ "*": {
8
+ "rate_limit": "30/minute",
9
+ "min_tier": "signed-known"
10
+ },
11
+ "transfer_funds": {
12
+ "require_approval": true,
13
+ "min_tier": "privileged"
14
+ },
15
+ "create_payment": {
16
+ "require_approval": true,
17
+ "min_tier": "privileged"
18
+ },
19
+ "approve_transaction": {
20
+ "require_approval": true,
21
+ "min_tier": "privileged"
22
+ },
23
+ "modify_account": {
24
+ "require_approval": true,
25
+ "min_tier": "evidenced"
26
+ },
27
+ "delete_account": {
28
+ "block": true
29
+ },
30
+ "close_account": {
31
+ "block": true
32
+ },
33
+ "read_balance": {
34
+ "rate_limit": "10/minute",
35
+ "min_tier": "evidenced"
36
+ },
37
+ "read_transactions": {
38
+ "rate_limit": "10/minute",
39
+ "min_tier": "evidenced"
40
+ },
41
+ "generate_report": {
42
+ "rate_limit": "5/hour",
43
+ "min_tier": "signed-known"
44
+ }
45
+ },
46
+ "signing": {
47
+ "enabled": true
48
+ }
49
+ }
@@ -0,0 +1,54 @@
1
+ {
2
+ "$comment": "GitHub MCP server hijacked via crafted issue containing prompt injection (2025). Agent exfiltrated private repo data. Blocks outbound data tools, restricts git operations, requires approval for any push/publish.",
3
+ "incident": "github-mcp-issue-hijack-2025",
4
+ "incident_name": "GitHub MCP Server Prompt Injection via Crafted Issue",
5
+ "incident_date": "2025-08-20",
6
+ "owasp_categories": ["A01-Prompt-Injection", "A02-Sensitive-Data-Exposure", "A03-Supply-Chain"],
7
+ "tools": {
8
+ "*": {
9
+ "rate_limit": "30/minute"
10
+ },
11
+ "git_push": {
12
+ "require_approval": true,
13
+ "min_tier": "evidenced"
14
+ },
15
+ "git_commit": {
16
+ "rate_limit": "10/minute"
17
+ },
18
+ "create_pull_request": {
19
+ "require_approval": true
20
+ },
21
+ "publish": {
22
+ "block": true
23
+ },
24
+ "npm_publish": {
25
+ "block": true
26
+ },
27
+ "send_email": {
28
+ "block": true
29
+ },
30
+ "send_message": {
31
+ "block": true
32
+ },
33
+ "upload_file": {
34
+ "require_approval": true,
35
+ "min_tier": "signed-known"
36
+ },
37
+ "http_request": {
38
+ "require_approval": true,
39
+ "rate_limit": "5/minute"
40
+ },
41
+ "webhook": {
42
+ "block": true
43
+ },
44
+ "read_file": {
45
+ "rate_limit": "30/minute"
46
+ },
47
+ "search_code": {
48
+ "rate_limit": "20/minute"
49
+ }
50
+ },
51
+ "signing": {
52
+ "enabled": true
53
+ }
54
+ }
@@ -0,0 +1,50 @@
1
+ {
2
+ "$comment": "Terraform agent destroyed production infrastructure (2025). Blocks all destructive infrastructure operations, requires human approval for any apply/deploy, rate-limits plan operations.",
3
+ "incident": "terraform-prod-destroy-2025",
4
+ "incident_name": "Autonomous Terraform Agent Destroys Production",
5
+ "incident_date": "2025-09-01",
6
+ "owasp_categories": ["A06-Excessive-Autonomy", "A05-Insufficient-Access-Control"],
7
+ "tools": {
8
+ "*": {
9
+ "rate_limit": "30/minute"
10
+ },
11
+ "terraform_apply": {
12
+ "require_approval": true,
13
+ "min_tier": "evidenced"
14
+ },
15
+ "terraform_destroy": {
16
+ "block": true
17
+ },
18
+ "terraform_plan": {
19
+ "rate_limit": "10/minute",
20
+ "min_tier": "signed-known"
21
+ },
22
+ "deploy": {
23
+ "require_approval": true,
24
+ "min_tier": "evidenced"
25
+ },
26
+ "kubectl_apply": {
27
+ "require_approval": true,
28
+ "min_tier": "evidenced"
29
+ },
30
+ "kubectl_delete": {
31
+ "block": true
32
+ },
33
+ "aws_cli": {
34
+ "require_approval": true,
35
+ "rate_limit": "5/minute"
36
+ },
37
+ "delete_resource": {
38
+ "block": true
39
+ },
40
+ "drop_database": {
41
+ "block": true
42
+ },
43
+ "truncate_table": {
44
+ "block": true
45
+ }
46
+ },
47
+ "signing": {
48
+ "enabled": true
49
+ }
50
+ }