torusguard 1.4.0 → 2.0.0-alpha
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/.torusguard/auth.json +5 -0
- package/.torusguard/rules_catalog.json +242 -518
- package/.torusguard/scripts/__pycache__/apply_runner.cpython-314.pyc +0 -0
- package/.torusguard/scripts/__pycache__/audit_runner.cpython-314.pyc +0 -0
- package/.torusguard/scripts/__pycache__/harden_runner.cpython-314.pyc +0 -0
- package/.torusguard/scripts/__pycache__/html_reporter.cpython-314.pyc +0 -0
- package/.torusguard/scripts/__pycache__/manifest_builder.cpython-314.pyc +0 -0
- package/.torusguard/scripts/__pycache__/recipes_runner.cpython-314.pyc +0 -0
- package/.torusguard/scripts/__pycache__/report_sync.cpython-314.pyc +0 -0
- package/.torusguard/snapshots/20260921-182638/go.mod.bak +11 -0
- package/.torusguard/snapshots/20260921-185213/file.go.bak +5 -0
- package/README.md +315 -393
- package/package.json +1 -1
- package/skills/torusguard/__pycache__/bootstrap.cpython-314.pyc +0 -0
- package/skills/torusguard/payload/TORUSGUARD.md +145 -145
- package/skills/torusguard/payload/agents/auditor.md +41 -41
- package/skills/torusguard/payload/agents/profiler.md +49 -49
- package/skills/torusguard/payload/agents/remediator.md +41 -41
- package/skills/torusguard/payload/agents/reviewer.md +39 -39
- package/skills/torusguard/payload/agents/validator.md +46 -46
- package/skills/torusguard/payload/config/scope.json +24 -24
- package/skills/torusguard/payload/references/csharp-security.md +41 -41
- package/skills/torusguard/payload/references/go-security.md +41 -41
- package/skills/torusguard/payload/references/java-security.md +40 -40
- package/skills/torusguard/payload/references/polyglot-security-matrix.md +25 -25
- package/skills/torusguard/payload/references/rust-security.md +40 -40
- package/skills/torusguard/payload/rules/custom/.gitkeep +1 -1
- package/skills/torusguard/payload/rules/custom/README.md +30 -30
- package/skills/torusguard/payload/scripts/rules_sync.py +321 -321
- package/skills/torusguard/payload/scripts/safety_gate.py +64 -64
- package/skills/torusguard/payload/skills/torusguard/references/csharp-security.md +41 -41
- package/skills/torusguard/payload/skills/torusguard/references/go-security.md +41 -41
- package/skills/torusguard/payload/skills/torusguard/references/java-security.md +40 -40
- package/skills/torusguard/payload/skills/torusguard/references/polyglot-security-matrix.md +25 -25
- package/skills/torusguard/payload/skills/torusguard/references/rust-security.md +40 -40
- package/skills/torusguard/payload/templates/audit-report.template.md +54 -54
- package/skills/torusguard/payload/templates/authorization.template.md +34 -34
- package/skills/torusguard/payload/templates/finding-card.template.md +32 -32
- package/skills/torusguard/payload/templates/remediation-bundle.template.md +35 -35
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
# TorusGuard Custom Rules Directory
|
|
2
|
-
|
|
3
|
-
Place your custom organization-specific, framework-specific, or proprietary library rules here.
|
|
4
|
-
Any markdown files (`*.md`) or JSON files (`*.json`) placed in this directory will be automatically indexed during `/torusguard-audit` and finding scoring.
|
|
5
|
-
|
|
6
|
-
---
|
|
7
|
-
|
|
8
|
-
## Example Custom Rule: `TG-CUSTOM-001.md`
|
|
9
|
-
|
|
10
|
-
```markdown
|
|
11
|
-
# TG-CUSTOM-001: Require Organization UUID on All Multi-Tenant Queries
|
|
12
|
-
|
|
13
|
-
**Rule ID:** TG-CUSTOM-001
|
|
14
|
-
**Severity:** High
|
|
15
|
-
**Category:** database-safety
|
|
16
|
-
**Confidence Base:** 85
|
|
17
|
-
|
|
18
|
-
### Description
|
|
19
|
-
Ensure all database operations on multi-tenant tables enforce explicit `org_id` or `tenant_id` boundaries.
|
|
20
|
-
|
|
21
|
-
### Unsafe Pattern
|
|
22
|
-
```python
|
|
23
|
-
db.execute("SELECT * FROM invoices WHERE status = 'paid'")
|
|
24
|
-
```
|
|
25
|
-
|
|
26
|
-
### Safe Remediation
|
|
27
|
-
```python
|
|
28
|
-
db.execute("SELECT * FROM invoices WHERE status = 'paid' AND org_id = %s", [current_org_id])
|
|
29
|
-
```
|
|
30
|
-
```
|
|
1
|
+
# TorusGuard Custom Rules Directory
|
|
2
|
+
|
|
3
|
+
Place your custom organization-specific, framework-specific, or proprietary library rules here.
|
|
4
|
+
Any markdown files (`*.md`) or JSON files (`*.json`) placed in this directory will be automatically indexed during `/torusguard-audit` and finding scoring.
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## Example Custom Rule: `TG-CUSTOM-001.md`
|
|
9
|
+
|
|
10
|
+
```markdown
|
|
11
|
+
# TG-CUSTOM-001: Require Organization UUID on All Multi-Tenant Queries
|
|
12
|
+
|
|
13
|
+
**Rule ID:** TG-CUSTOM-001
|
|
14
|
+
**Severity:** High
|
|
15
|
+
**Category:** database-safety
|
|
16
|
+
**Confidence Base:** 85
|
|
17
|
+
|
|
18
|
+
### Description
|
|
19
|
+
Ensure all database operations on multi-tenant tables enforce explicit `org_id` or `tenant_id` boundaries.
|
|
20
|
+
|
|
21
|
+
### Unsafe Pattern
|
|
22
|
+
```python
|
|
23
|
+
db.execute("SELECT * FROM invoices WHERE status = 'paid'")
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
### Safe Remediation
|
|
27
|
+
```python
|
|
28
|
+
db.execute("SELECT * FROM invoices WHERE status = 'paid' AND org_id = %s", [current_org_id])
|
|
29
|
+
```
|
|
30
|
+
```
|