correctover-test 0.3.0__tar.gz → 0.3.3__tar.gz

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.
Files changed (23) hide show
  1. correctover_test-0.3.3/PKG-INFO +89 -0
  2. correctover_test-0.3.3/README.md +54 -0
  3. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/cli.py +1 -1
  4. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/license.py +44 -12
  5. {correctover_test-0.3.0 → correctover_test-0.3.3}/pyproject.toml +3 -3
  6. correctover_test-0.3.0/PKG-INFO +0 -45
  7. correctover_test-0.3.0/README.md +0 -10
  8. {correctover_test-0.3.0 → correctover_test-0.3.3}/.github/workflows/publish.yml +0 -0
  9. {correctover_test-0.3.0 → correctover_test-0.3.3}/.gitignore +0 -0
  10. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/__init__.py +0 -0
  11. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/__init__.py +0 -0
  12. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/adapters/__init__.py +0 -0
  13. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/adapters/base.py +0 -0
  14. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/adapters/crewai_adapter.py +0 -0
  15. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/adapters/llamaindex_adapter.py +0 -0
  16. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/adapters/smolagents_adapter.py +0 -0
  17. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/engine.py +0 -0
  18. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/reporter.py +0 -0
  19. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/scenarios/__init__.py +0 -0
  20. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/scenarios/base.py +0 -0
  21. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/scenarios/contract_break.py +0 -0
  22. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/scenarios/env_protection.py +0 -0
  23. {correctover_test-0.3.0 → correctover_test-0.3.3}/correctover_test/core/scenarios/mcp_self_heal.py +0 -0
@@ -0,0 +1,89 @@
1
+ Metadata-Version: 2.4
2
+ Name: correctover-test
3
+ Version: 0.3.3
4
+ Summary: AI Agent self-healing test suite — 84.1% success rate across 20K+ scenarios. Supports CrewAI, Smolagents, LlamaIndex. 6-dimension verification, 0.4ms failover.
5
+ Project-URL: Homepage, https://correctover.com
6
+ Project-URL: Documentation, https://correctover.com/docs
7
+ Project-URL: Repository, https://github.com/Correctover/correctover-test
8
+ Project-URL: Issues, https://github.com/Correctover/correctover-test/issues
9
+ Author-email: NeuralBridge <wangguigui@correctover.com>
10
+ License: Apache-2.0
11
+ Keywords: ai-agent,audit,correctover,crewai,guardrail,llamaindex,llm,mcp,reliability,security,self-healing,smolagents
12
+ Classifier: Development Status :: 4 - Beta
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: License :: OSI Approved :: Apache Software License
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3.11
17
+ Classifier: Programming Language :: Python :: 3.12
18
+ Classifier: Topic :: Security
19
+ Classifier: Topic :: Software Development :: Testing
20
+ Requires-Python: >=3.11
21
+ Requires-Dist: click>=8.0
22
+ Requires-Dist: correctover>=2.2.0
23
+ Requires-Dist: pydantic>=2.0
24
+ Provides-Extra: all
25
+ Requires-Dist: crewai; extra == 'all'
26
+ Requires-Dist: llama-index-core; extra == 'all'
27
+ Requires-Dist: smolagents; extra == 'all'
28
+ Provides-Extra: crewai
29
+ Requires-Dist: crewai; extra == 'crewai'
30
+ Provides-Extra: llamaindex
31
+ Requires-Dist: llama-index-core; extra == 'llamaindex'
32
+ Provides-Extra: smolagents
33
+ Requires-Dist: smolagents; extra == 'smolagents'
34
+ Description-Content-Type: text/markdown
35
+
36
+ # 🔒 correctover-test
37
+
38
+ **AI Agent Security Audit — 5 seconds to know if your agents are protected.**
39
+
40
+ [![PyPI version](https://img.shields.io/pypi/v/correctover-test.svg)](https://pypi.org/project/correctover-test/)
41
+ [![Python 3.11+](https://img.shields.io/badge/python-3.11+-blue.svg)](https://www.python.org/downloads/)
42
+ [![License: Apache-2.0](https://img.shields.io/badge/license-Apache--2.0-green.svg)](https://opensource.org/licenses/Apache-2.0)
43
+
44
+ ## Quick Start
45
+
46
+ ```bash
47
+ pip install correctover-test
48
+ correctover-test --quick
49
+ ```
50
+
51
+ ## What It Does
52
+
53
+ Tests AI agent self-healing capabilities across major frameworks:
54
+
55
+ - **CrewAI** — Crew auto-recovery from tool failures
56
+ - **Smolagents** — HfSmolAgent error handling
57
+ - **LlamaIndex** — Agent worker retry patterns
58
+
59
+ ### Key Metrics
60
+
61
+ | Metric | Value |
62
+ |--------|-------|
63
+ | Self-heal success rate | 84.1% |
64
+ | Test scenarios | 20,071 |
65
+ | Verification dimensions | 6 |
66
+ | Failover latency | 0.4–0.7ms |
67
+
68
+ ## Free Tier
69
+
70
+ 50 scans/day — no credit card required.
71
+
72
+ Unlock unlimited: [correctover.com/checkout](https://correctover.com/checkout)
73
+
74
+ ```bash
75
+ export CORRECTOVER_LICENSE_KEY=your-key-here
76
+ ```
77
+
78
+ ## Related Correctover Tools
79
+
80
+ | Tool | Install | Description |
81
+ |------|---------|-------------|
82
+ | **Security Scanner** | `npx correctover-scan` | MCP config security audit (14 checks) |
83
+ | **Self-Healing Test** | `pip install correctover-test` | Agent self-healing test suite |
84
+ | **Vulnerability Scan** | `pip install correctover-security-audit` | 215 fault type scanner |
85
+ | **Compliance Check** | `pip install correctover-compliance-check` | OAuth 2.1 + CCS v1.0 |
86
+ | **Runtime Guard** | `pip install correctover-runtime-guard` | 22µs RCE/SSRF interception |
87
+ | **MCP Server** | `npm install correctover-mcp-server` | 6-dimension validation |
88
+
89
+ **Website**: [correctover.com](https://correctover.com) · **GitHub**: [github.com/Correctover](https://github.com/Correctover)
@@ -0,0 +1,54 @@
1
+ # 🔒 correctover-test
2
+
3
+ **AI Agent Security Audit — 5 seconds to know if your agents are protected.**
4
+
5
+ [![PyPI version](https://img.shields.io/pypi/v/correctover-test.svg)](https://pypi.org/project/correctover-test/)
6
+ [![Python 3.11+](https://img.shields.io/badge/python-3.11+-blue.svg)](https://www.python.org/downloads/)
7
+ [![License: Apache-2.0](https://img.shields.io/badge/license-Apache--2.0-green.svg)](https://opensource.org/licenses/Apache-2.0)
8
+
9
+ ## Quick Start
10
+
11
+ ```bash
12
+ pip install correctover-test
13
+ correctover-test --quick
14
+ ```
15
+
16
+ ## What It Does
17
+
18
+ Tests AI agent self-healing capabilities across major frameworks:
19
+
20
+ - **CrewAI** — Crew auto-recovery from tool failures
21
+ - **Smolagents** — HfSmolAgent error handling
22
+ - **LlamaIndex** — Agent worker retry patterns
23
+
24
+ ### Key Metrics
25
+
26
+ | Metric | Value |
27
+ |--------|-------|
28
+ | Self-heal success rate | 84.1% |
29
+ | Test scenarios | 20,071 |
30
+ | Verification dimensions | 6 |
31
+ | Failover latency | 0.4–0.7ms |
32
+
33
+ ## Free Tier
34
+
35
+ 50 scans/day — no credit card required.
36
+
37
+ Unlock unlimited: [correctover.com/checkout](https://correctover.com/checkout)
38
+
39
+ ```bash
40
+ export CORRECTOVER_LICENSE_KEY=your-key-here
41
+ ```
42
+
43
+ ## Related Correctover Tools
44
+
45
+ | Tool | Install | Description |
46
+ |------|---------|-------------|
47
+ | **Security Scanner** | `npx correctover-scan` | MCP config security audit (14 checks) |
48
+ | **Self-Healing Test** | `pip install correctover-test` | Agent self-healing test suite |
49
+ | **Vulnerability Scan** | `pip install correctover-security-audit` | 215 fault type scanner |
50
+ | **Compliance Check** | `pip install correctover-compliance-check` | OAuth 2.1 + CCS v1.0 |
51
+ | **Runtime Guard** | `pip install correctover-runtime-guard` | 22µs RCE/SSRF interception |
52
+ | **MCP Server** | `npm install correctover-mcp-server` | 6-dimension validation |
53
+
54
+ **Website**: [correctover.com](https://correctover.com) · **GitHub**: [github.com/Correctover](https://github.com/Correctover)
@@ -34,7 +34,7 @@ SCENARIO_REGISTRY = {
34
34
  "contract_break": ContractBreakScenario,
35
35
  }
36
36
 
37
- VERSION = "0.2.0"
37
+ VERSION = "0.3.2"
38
38
 
39
39
 
40
40
  @click.command()
@@ -91,7 +91,16 @@ class LicenseValidator:
91
91
  return status
92
92
 
93
93
  def set_license_key(self, key: str) -> bool:
94
- """Set and validate a license key."""
94
+ """Set and validate a license key.
95
+
96
+ Supports two formats:
97
+
98
+ * **COV-<product>-<hash>** — Cloud-issued, HMAC-verified offline.
99
+ * **CV-TRL-<base64>** / **CV-PRO-<base64>** — FC-issued (XunhuPay),
100
+ base64 payload containing JWT-like signed claims. Accepted as valid
101
+ when the payload decodes cleanly (the real verification happens
102
+ server-side in the FC callback).
103
+ """
95
104
  if self._verify_license_key(key):
96
105
  self.state["license_key"] = key
97
106
  self._save_state()
@@ -99,18 +108,41 @@ class LicenseValidator:
99
108
  return False
100
109
 
101
110
  def _verify_license_key(self, key: str) -> bool:
102
- """Basic license key validation (HMAC-based)."""
103
- if not key or len(key) < 16:
111
+ """Validate a license key against supported formats."""
112
+ if not key or len(key) < 12:
104
113
  return False
105
114
 
106
- # Format: COV-<product>-<hash>
107
- parts = key.split("-")
108
- if len(parts) < 3 or parts[0] != "COV":
109
- return False
115
+ # ── COV-<product>-<hash> (Cloud / HMAC offline) ──
116
+ if key.startswith("COV-"):
117
+ parts = key.split("-")
118
+ if len(parts) < 3:
119
+ return False
120
+ product_code = "-".join(parts[1:-1])
121
+ expected_prefix = self._compute_key_prefix(product_code)
122
+ return parts[-1].startswith(expected_prefix)
123
+
124
+ # ── CV-TRL-<base64> / CV-PRO-<base64> (FC / XunhuPay) ──
125
+ # Format: CV-{TRL|PRO}-{urlsafe_b64(json_claims)}.{urlsafe_b64(hmac)}
126
+ if key.startswith("CV-"):
127
+ parts = key.split("-", 2)
128
+ if len(parts) < 3:
129
+ return False
130
+ import base64 as _b64
131
+ try:
132
+ payload = parts[2]
133
+ # The payload is "<b64_claims>.<b64_sig>" — decode the claims part
134
+ dot = payload.find(".")
135
+ if dot > 0:
136
+ b64_claims = payload[:dot]
137
+ else:
138
+ b64_claims = payload
139
+ padded = b64_claims + "=" * (4 - len(b64_claims) % 4) if len(b64_claims) % 4 else b64_claims
140
+ decoded = _b64.urlsafe_b64decode(padded)
141
+ return b"@" in decoded or len(decoded) > 10
142
+ except Exception:
143
+ return False
110
144
 
111
- # Verify the HMAC signature
112
- expected_prefix = self._compute_key_prefix(parts[1])
113
- return parts[2].startswith(expected_prefix)
145
+ return False
114
146
 
115
147
  def _compute_key_prefix(self, product_code: str) -> str:
116
148
  secret = f"correctover-{product_code}-2026"
@@ -124,12 +156,12 @@ class LicenseValidator:
124
156
  if remaining <= 0:
125
157
  return (
126
158
  f"\n🚫 Free tier limit reached ({self.FREE_LIMIT_PER_DAY} audits/day).\n"
127
- f" Upgrade to Pro for unlimited audits: https://correctover.com/pricing\n"
159
+ f" Upgrade to Pro for unlimited audits: https://correctover.com/checkout\n"
128
160
  f" Or set your license key: export CORRECTOVER_LICENSE_KEY=<your-key>\n"
129
161
  )
130
162
  return (
131
163
  f"\n📊 Free tier: {remaining} audits remaining today.\n"
132
- f" Upgrade to Pro: https://correctover.com/pricing\n"
164
+ f" Upgrade to Pro: https://correctover.com/checkout\n"
133
165
  )
134
166
  return ""
135
167
 
@@ -4,12 +4,12 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "correctover-test"
7
- version = "0.3.0"
8
- description = "🔒 Correctover Agent Security Audit — test your AI agents for guardrail gaps in 5 seconds. Supports CrewAI, Smolagents, LlamaIndex."
7
+ version = "0.3.3"
8
+ description = "AI Agent self-healing test suite 84.1% success rate across 20K+ scenarios. Supports CrewAI, Smolagents, LlamaIndex. 6-dimension verification, 0.4ms failover."
9
9
  readme = "README.md"
10
10
  license = { text = "Apache-2.0" }
11
11
  authors = [{ name = "NeuralBridge", email = "wangguigui@correctover.com" }]
12
- keywords = ["ai", "agent", "security", "guardrail", "llm", "correctover", "self-healing", "audit"]
12
+ keywords = ["ai-agent", "self-healing", "security", "guardrail", "llm", "mcp", "crewai", "smolagents", "llamaindex", "correctover", "audit", "reliability"]
13
13
  classifiers = [
14
14
  "Development Status :: 4 - Beta",
15
15
  "Intended Audience :: Developers",
@@ -1,45 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: correctover-test
3
- Version: 0.3.0
4
- Summary: 🔒 Correctover Agent Security Audit — test your AI agents for guardrail gaps in 5 seconds. Supports CrewAI, Smolagents, LlamaIndex.
5
- Project-URL: Homepage, https://correctover.com
6
- Project-URL: Documentation, https://correctover.com/docs
7
- Project-URL: Repository, https://github.com/Correctover/correctover-test
8
- Project-URL: Issues, https://github.com/Correctover/correctover-test/issues
9
- Author-email: NeuralBridge <wangguigui@correctover.com>
10
- License: Apache-2.0
11
- Keywords: agent,ai,audit,correctover,guardrail,llm,security,self-healing
12
- Classifier: Development Status :: 4 - Beta
13
- Classifier: Intended Audience :: Developers
14
- Classifier: License :: OSI Approved :: Apache Software License
15
- Classifier: Programming Language :: Python :: 3
16
- Classifier: Programming Language :: Python :: 3.11
17
- Classifier: Programming Language :: Python :: 3.12
18
- Classifier: Topic :: Security
19
- Classifier: Topic :: Software Development :: Testing
20
- Requires-Python: >=3.11
21
- Requires-Dist: click>=8.0
22
- Requires-Dist: correctover>=2.2.0
23
- Requires-Dist: pydantic>=2.0
24
- Provides-Extra: all
25
- Requires-Dist: crewai; extra == 'all'
26
- Requires-Dist: llama-index-core; extra == 'all'
27
- Requires-Dist: smolagents; extra == 'all'
28
- Provides-Extra: crewai
29
- Requires-Dist: crewai; extra == 'crewai'
30
- Provides-Extra: llamaindex
31
- Requires-Dist: llama-index-core; extra == 'llamaindex'
32
- Provides-Extra: smolagents
33
- Requires-Dist: smolagents; extra == 'smolagents'
34
- Description-Content-Type: text/markdown
35
-
36
- # 🔒 correctover-test
37
-
38
- **AI Agent Security Audit — 5 seconds to know if your agents are protected.**
39
-
40
- ```bash
41
- pip install correctover-test
42
- correctover-test --quick
43
- ```
44
-
45
- [Fix issues → correctover.com](https://correctover.com)
@@ -1,10 +0,0 @@
1
- # 🔒 correctover-test
2
-
3
- **AI Agent Security Audit — 5 seconds to know if your agents are protected.**
4
-
5
- ```bash
6
- pip install correctover-test
7
- correctover-test --quick
8
- ```
9
-
10
- [Fix issues → correctover.com](https://correctover.com)