@cirvix_ai/agent-control 0.1.3 → 0.2.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 +76 -17
- package/bin/cirvix.mjs +539 -85
- package/bin/escape-benchmark.mjs +67 -0
- package/package.json +36 -16
- package/src/adapters/base.mjs +150 -0
- package/src/adapters/claude-code.mjs +161 -0
- package/src/adapters/cline.mjs +107 -0
- package/src/adapters/codex.mjs +104 -0
- package/src/adapters/cursor.mjs +104 -0
- package/src/adapters/frameworks.mjs +110 -0
- package/src/adapters/gemini-cli.mjs +104 -0
- package/src/adapters/generic-mcp.mjs +101 -0
- package/src/adapters/index.mjs +209 -0
- package/src/adapters/roo-code.mjs +106 -0
- package/src/adapters/vscode.mjs +104 -0
- package/src/adapters/windsurf.mjs +107 -0
- package/src/commands/console.mjs +58 -0
- package/src/commands/demo.mjs +55 -124
- package/src/commands/doctor.mjs +235 -0
- package/src/commands/init.mjs +292 -30
- package/src/commands/interactive.mjs +690 -0
- package/src/commands/kill.mjs +74 -0
- package/src/commands/login.mjs +227 -0
- package/src/commands/onboard.mjs +52 -0
- package/src/commands/passport.mjs +149 -0
- package/src/commands/policy.mjs +10 -6
- package/src/commands/protect.mjs +293 -0
- package/src/commands/prove.mjs +209 -0
- package/src/commands/redteam.mjs +51 -0
- package/src/commands/scan.mjs +11 -9
- package/src/commands/shadow.mjs +62 -0
- package/src/commands/simulate.mjs +96 -0
- package/src/commands/status.mjs +122 -41
- package/src/commands/upgrade.mjs +11 -11
- package/src/commands/welcome.mjs +105 -0
- package/src/core/authority.mjs +909 -0
- package/src/core/baseline.mjs +97 -0
- package/src/core/config-store.mjs +280 -0
- package/src/core/cost.mjs +0 -0
- package/src/core/detect.mjs +4 -33
- package/src/core/entitlements.mjs +7 -24
- package/src/core/escape-benchmark.mjs +597 -0
- package/src/core/events.mjs +234 -0
- package/src/core/evidence.mjs +212 -0
- package/src/core/format.mjs +44 -18
- package/src/core/gateway.mjs +15 -211
- package/src/core/graph.mjs +270 -0
- package/src/core/guard.mjs +118 -4
- package/src/core/intent.mjs +166 -0
- package/src/core/journal.mjs +131 -40
- package/src/core/kill-switch.mjs +122 -0
- package/src/core/notices.mjs +22 -2
- package/src/core/packs.mjs +193 -0
- package/src/core/passport.mjs +555 -0
- package/src/core/pipeline.mjs +148 -6
- package/src/core/prompts.mjs +51 -0
- package/src/core/proof.mjs +440 -0
- package/src/core/redteam/index.mjs +185 -0
- package/src/core/referral.mjs +187 -0
- package/src/core/sandbox.mjs +139 -0
- package/src/core/session.mjs +172 -0
- package/src/core/shadow.mjs +95 -0
- package/src/core/theme.mjs +240 -0
- package/src/core/trifecta.mjs +321 -0
- package/src/core/ui/controller.mjs +192 -0
- package/src/core/ui/decisions.mjs +55 -0
- package/src/core/ui/index.mjs +49 -0
- package/src/core/ui/intercept.mjs +103 -0
- package/src/core/ui/live.mjs +51 -0
- package/src/core/ui/primitives.mjs +123 -0
- package/src/core/ui/theme.mjs +92 -0
- package/src/core/verified.mjs +108 -0
- package/src/core/windows.mjs +270 -0
- package/src/index.mjs +67 -0
- package/src/tui/activity.mjs +71 -0
- package/src/tui/app.mjs +292 -0
- package/src/tui/cards.mjs +235 -0
- package/src/tui/composer.mjs +88 -0
- package/src/tui/palette.mjs +48 -0
- package/src/tui/status.mjs +42 -0
- package/src/core/cinematic.mjs +0 -545
package/README.md
CHANGED
|
@@ -13,6 +13,7 @@ No account, no signup, no config file, no daemon to leave running.
|
|
|
13
13
|
|
|
14
14
|
```bash
|
|
15
15
|
npx @cirvix_ai/agent-control scan
|
|
16
|
+
# or: npm install -g @cirvix_ai/agent-control && cirvix scan
|
|
16
17
|
```
|
|
17
18
|
|
|
18
19
|
That reads your machine and tells you which agent runtimes are ungoverned. It
|
|
@@ -20,6 +21,7 @@ writes nothing and sends nothing anywhere. Then decide one call:
|
|
|
20
21
|
|
|
21
22
|
```bash
|
|
22
23
|
npx @cirvix_ai/agent-control check --action fs.read --resource .env.production
|
|
24
|
+
# or with a global install: cirvix check --action fs.read --resource .env.production
|
|
23
25
|
```
|
|
24
26
|
|
|
25
27
|
```
|
|
@@ -34,7 +36,8 @@ To govern an agent rather than a single call, wrap its tools — the call cannot
|
|
|
34
36
|
leave without being decided, so there is no verdict to forget to check:
|
|
35
37
|
|
|
36
38
|
```bash
|
|
37
|
-
npm install @cirvix_ai/agent-control
|
|
39
|
+
npm install @cirvix_ai/agent-control # local to your project
|
|
40
|
+
# or globally for the CLI: npm install -g @cirvix_ai/agent-control
|
|
38
41
|
```
|
|
39
42
|
|
|
40
43
|
```js
|
|
@@ -60,9 +63,9 @@ conformance fixture that both must pass.
|
|
|
60
63
|
|
|
61
64
|
## Licence
|
|
62
65
|
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
+
Proprietary. Not open source — see [LICENSE](./LICENSE), and the full terms at
|
|
67
|
+
[cirvix.com/terms.html](https://www.cirvix.com/terms.html). The free local
|
|
68
|
+
runtime carries no fee and no support, availability or fitness commitment.
|
|
66
69
|
|
|
67
70
|
## `cirvix scan`
|
|
68
71
|
|
|
@@ -316,26 +319,82 @@ guarantees doing so is *visible*.
|
|
|
316
319
|
Hashes are SHA-256 over a canonical JSON serialization with sorted keys, so
|
|
317
320
|
two semantically identical records hash identically.
|
|
318
321
|
|
|
322
|
+
## Enterprise Agent Authorization & Security Architecture
|
|
323
|
+
|
|
324
|
+
Cirvix enforces full-lifecycle governance across autonomous software:
|
|
325
|
+
`DISCOVER -> IDENTITY -> INTENT -> AUTHORITY -> POLICY -> ACTION -> RUNTIME ENFORCEMENT -> HUMAN APPROVAL -> AUDIT/RECEIPT -> DETECTION -> RESPONSE -> RECOVERY`.
|
|
326
|
+
|
|
327
|
+
### 1. Cryptographic Agent Passports (`@cirvix_ai/agent-control/passport`)
|
|
328
|
+
Zero-trust agent identity backed by Ed25519 asymmetric cryptography. Every agent instance issues a cryptographically signed passport declaring its identity, organizational tenant scope, allowed capabilities, parameter limits, and valid lifetime.
|
|
329
|
+
- Fast keypair generation with SHA-512 canonical envelope signing.
|
|
330
|
+
- Non-repudiation: tool calls and action requests carry cryptographic signatures.
|
|
331
|
+
- Zero-downtime key rotation (`rotatePassportKeys`) and immediate revocation.
|
|
332
|
+
|
|
333
|
+
### 2. Intent-Aware Agent Firewall (`@cirvix_ai/agent-control/intent`)
|
|
334
|
+
Prevents mission hijacking and prompt injection drift:
|
|
335
|
+
- Compares requested tool actions against the agent's declared mission semantic context.
|
|
336
|
+
- Classifies operations into risk categories: `READ_ONLY`, `CODE_EDIT`, `DATA_MUTATION`, `INFRASTRUCTURE`, `SECRET_ACCESS`, `FINANCIAL`, `PRIVILEGED`.
|
|
337
|
+
- Automatically rejects out-of-scope actions before execution.
|
|
338
|
+
|
|
339
|
+
### 3. Stateful Session Security & Kill Chain Detection (`@cirvix_ai/agent-control/session`)
|
|
340
|
+
Stateless per-call inspection cannot catch staged attacks. Cirvix tracks action timelines across agent sessions to detect multi-step kill chains:
|
|
341
|
+
- **Exfiltration Chains**: `read sensitive file/secret -> encode/stage -> external network egress`.
|
|
342
|
+
- **Reconnaissance Chains**: Rapid privilege probing across sensitive targets.
|
|
343
|
+
- Computes cumulative session risk and triggers automated circuit breakers upon threat threshold breach.
|
|
344
|
+
|
|
345
|
+
### 4. Behavioral Profiling & Anomaly Detection (`@cirvix_ai/agent-control/baseline`)
|
|
346
|
+
Builds rolling statistical baselines per agent family:
|
|
347
|
+
- Tracks normal tool distribution, approved network egress domains, parameter entropy, and call frequency.
|
|
348
|
+
- Evaluates actions for statistical drift, flagging anomalous calls before destructive impact.
|
|
349
|
+
|
|
350
|
+
### 5. Universal Multi-Scope Emergency Kill Switches (`@cirvix_ai/agent-control/kill-switch`)
|
|
351
|
+
Instant, sub-millisecond containment across granular blast radiuses:
|
|
352
|
+
- `agent`: Terminate a compromised agent instance immediately.
|
|
353
|
+
- `family`: Freeze all agents sharing a behavioral profile or code lineage.
|
|
354
|
+
- `org`: Emergency lockdown of an entire tenant's autonomous operations.
|
|
355
|
+
- `tool` / `mcp`: Block a specific vulnerable tool or rogue MCP server globally.
|
|
356
|
+
- `credential`: Instantly invalidate all handles tied to a compromised secret.
|
|
357
|
+
- CLI: `cirvix kill trigger --scope agent --target <agent-id> --reason "Suspicious behavior"`
|
|
358
|
+
|
|
359
|
+
### 6. Universal Agent Sandbox (`@cirvix_ai/agent-control/sandbox`)
|
|
360
|
+
Runtime confinement ensuring agent isolation:
|
|
361
|
+
- Filesystem confinement within approved root directories, preventing path traversal.
|
|
362
|
+
- Network confinement blocking SSRF and cloud instance metadata (`169.254.169.254`).
|
|
363
|
+
- Strict process execution and shell argument boundaries.
|
|
364
|
+
|
|
365
|
+
### 7. Shadow Mode & Counterfactual Evaluation (`@cirvix_ai/agent-control/shadow`)
|
|
366
|
+
Safely benchmark and tune policies without disrupting operations:
|
|
367
|
+
- Evaluates candidate policies against live production streams in parallel.
|
|
368
|
+
- Generates counterfactual verdicts (`Would Allow`, `Would Block`, `Diff`) with latency tracking.
|
|
369
|
+
- CLI: `cirvix shadow run --policy candidate.json --input events.jsonl`
|
|
370
|
+
|
|
371
|
+
### 8. Continuous Adversarial Red Teaming (`@cirvix_ai/agent-control/redteam`)
|
|
372
|
+
Automated security validation against modern attack vectors:
|
|
373
|
+
- Built-in adversarial plugins: Direct & indirect prompt injections, secret exfiltration chains, SSRF / IMDS probes, and unauthorized tool invocation.
|
|
374
|
+
- Scored evaluation reports highlighting authorization weaknesses.
|
|
375
|
+
- CLI: `cirvix redteam run --target local`
|
|
376
|
+
|
|
377
|
+
### 9. Verified MCP Server Registry (`@cirvix_ai/agent-control/verified`)
|
|
378
|
+
Supply chain verification for Model Context Protocol tools:
|
|
379
|
+
- Scans MCP server definitions and tool schemas for prompt injection hooks, unpinned network endpoints, and dangerous wildcard parameters.
|
|
380
|
+
- Validates vendor signatures, trust levels, and scopes.
|
|
381
|
+
|
|
382
|
+
### 10. Tamper-Proof Merkle Action Receipts (`@cirvix_ai/agent-control/proof`)
|
|
383
|
+
Cryptographic receipts proving execution authorization:
|
|
384
|
+
- Every approved or denied action emits an immutable receipt with Merkle evidence hashes (`agentPassportHash`, `policyHash`, `inputHash`, `verdict`).
|
|
385
|
+
- Can be independently validated by compliance auditors or relying parties.
|
|
386
|
+
|
|
387
|
+
---
|
|
388
|
+
|
|
319
389
|
## Tests
|
|
320
390
|
|
|
321
391
|
```bash
|
|
322
392
|
npm test
|
|
323
393
|
```
|
|
324
394
|
|
|
325
|
-
|
|
326
|
-
safety under hostile patterns, condition safety, chain tamper detection,
|
|
327
|
-
gateway interception against a real child-process MCP server, handle
|
|
328
|
-
substitution on both the outbound and return paths, and the `guard.wrap`
|
|
329
|
-
surface.
|
|
330
|
-
|
|
331
|
-
## Status
|
|
332
|
-
|
|
333
|
-
Pre-release. `scan`, `check`, `policy`, `why`, `replay`, `audit verify`,
|
|
334
|
-
`gateway`, and `daemon` work today, as does secret brokering and `guard.wrap`
|
|
335
|
-
when a control plane is configured. Not yet built: a Python SDK, and the
|
|
336
|
-
hosted control plane — the one in `packages/control-plane` is self-hosted. See
|
|
337
|
-
[cirvix.com](https://www.cirvix.com).
|
|
395
|
+
806 unit and integration tests covering policy invariants, cryptographic passports, Merkle receipts, stateful session kill chains, multi-scope kill switches, sandbox confinement, shadow evaluation, MCP verification, and adversarial red teaming.
|
|
338
396
|
|
|
339
397
|
## License
|
|
340
398
|
|
|
341
399
|
See LICENSE. Cirvix is a product of Umang Kumar, trading as Cirvix.
|
|
400
|
+
|