@intutic/proxy 1.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.
Potentially problematic release.
This version of @intutic/proxy might be problematic. Click here for more details.
- package/LICENSE +21 -0
- package/README.md +88 -0
- package/bin/intutic-proxy +0 -0
- package/bin/proxy.js +24 -0
- package/package.json +40 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Intutic
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPORTED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
# intutic-proxy
|
|
2
|
+
|
|
3
|
+
> High-performance AI agent proxy with WebAssembly-based governance policies.
|
|
4
|
+
|
|
5
|
+
## Overview
|
|
6
|
+
|
|
7
|
+
intutic-proxy is a high-performance AI agent proxy written in Rust (edition 2021) that intercepts agent-to-LLM traffic and enforces governance policies through a pluggable WASM sandbox. It is the local enforcement engine for the [Intutic](https://github.com/intutic/intutic) governance control plane.
|
|
8
|
+
|
|
9
|
+
## Features
|
|
10
|
+
|
|
11
|
+
### WASM Plugin Sandbox
|
|
12
|
+
|
|
13
|
+
- **Runtime**: wasmtime v21 with pre-compiled module caching
|
|
14
|
+
- **Memory limit**: 1 MB per plugin invocation
|
|
15
|
+
- **Execution timeout**: 5 ms hard wall-clock cutoff
|
|
16
|
+
- **Isolation**: Each plugin runs in a dedicated WASM store
|
|
17
|
+
|
|
18
|
+
### Plugin Chain
|
|
19
|
+
|
|
20
|
+
The proxy processes every request through an ordered plugin chain:
|
|
21
|
+
|
|
22
|
+
| Plugin | Purpose |
|
|
23
|
+
|--------|---------|
|
|
24
|
+
| Budget Gate | Enforce per-ticket and per-team token budgets |
|
|
25
|
+
| DLP Gate | Block or redact sensitive data (secrets, PII, credentials) |
|
|
26
|
+
| PCAS Gate | Prior Consent and Autonomy Scope enforcement |
|
|
27
|
+
| Semantic Cache | Deduplicate semantically similar prompts via Valkey |
|
|
28
|
+
| SOP Prompt Injector | Inject workspace governance SOPs into system prompts |
|
|
29
|
+
|
|
30
|
+
### Model Selection
|
|
31
|
+
|
|
32
|
+
- **Thompson Sampling bandit**: Selects the optimal model per-task based on historical cost, latency, and quality signals
|
|
33
|
+
|
|
34
|
+
### Network Enforcement
|
|
35
|
+
|
|
36
|
+
- **TLS MITM**: Transparent interception for Windsurf and other harnesses
|
|
37
|
+
- **OS-level firewall rules**: Generates platform-native rules to redirect agent traffic through the proxy
|
|
38
|
+
- macOS: `pf` (Packet Filter)
|
|
39
|
+
- Linux: `iptables` / `nftables`
|
|
40
|
+
- Windows: `netsh`
|
|
41
|
+
|
|
42
|
+
### Security & Observability
|
|
43
|
+
|
|
44
|
+
- **DLP scanner**: Pattern-based and entropy-based secret detection
|
|
45
|
+
- **Code skeleton extraction**: Uses `tree-sitter` and `syn` for AST-level code analysis
|
|
46
|
+
- **Token counting**: Accurate pre-flight token estimation via `tiktoken-rs`
|
|
47
|
+
- **Telemetry**: OpenTelemetry OTLP export for traces, metrics, and logs
|
|
48
|
+
|
|
49
|
+
## Dependencies
|
|
50
|
+
|
|
51
|
+
| Crate | Purpose |
|
|
52
|
+
|-------|---------|
|
|
53
|
+
| `axum` | HTTP server framework |
|
|
54
|
+
| `wasmtime` | WASM runtime |
|
|
55
|
+
| `reqwest` | Upstream LLM HTTP client |
|
|
56
|
+
| `redis` | Valkey / Redis connection |
|
|
57
|
+
| `tree-sitter` | Source code parsing |
|
|
58
|
+
| `tiktoken-rs` | Token counting |
|
|
59
|
+
| `rcgen` | TLS certificate generation |
|
|
60
|
+
|
|
61
|
+
## Development
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
# Build
|
|
65
|
+
cargo build
|
|
66
|
+
|
|
67
|
+
# Run tests
|
|
68
|
+
cargo test
|
|
69
|
+
|
|
70
|
+
# Run benchmarks
|
|
71
|
+
cargo bench
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
## Binary
|
|
75
|
+
|
|
76
|
+
The crate produces a single binary:
|
|
77
|
+
|
|
78
|
+
```
|
|
79
|
+
intutic-proxy
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Part of Intutic
|
|
83
|
+
|
|
84
|
+
This package is part of the [Intutic](https://github.com/intutic/intutic) monorepo — an open-core AI governance control plane for developer teams.
|
|
85
|
+
|
|
86
|
+
## License
|
|
87
|
+
|
|
88
|
+
MIT — see [LICENSE](../../LICENSE) for details.
|
|
Binary file
|
package/bin/proxy.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { spawn } from 'child_process';
|
|
3
|
+
import path from 'path';
|
|
4
|
+
import fs from 'fs';
|
|
5
|
+
import { fileURLToPath } from 'url';
|
|
6
|
+
|
|
7
|
+
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
8
|
+
const binaryName = process.platform === 'win32' ? 'intutic-proxy.exe' : 'intutic-proxy';
|
|
9
|
+
const binaryPath = path.join(__dirname, binaryName);
|
|
10
|
+
|
|
11
|
+
if (!fs.existsSync(binaryPath)) {
|
|
12
|
+
console.error(`Error: Native intutic-proxy binary not found at ${binaryPath}`);
|
|
13
|
+
process.exit(1);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
const child = spawn(binaryPath, process.argv.slice(2), { stdio: 'inherit' });
|
|
17
|
+
|
|
18
|
+
child.on('exit', (code, signal) => {
|
|
19
|
+
if (code !== null) {
|
|
20
|
+
process.exit(code);
|
|
21
|
+
} else if (signal) {
|
|
22
|
+
process.kill(process.pid, signal);
|
|
23
|
+
}
|
|
24
|
+
});
|
package/package.json
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@intutic/proxy",
|
|
3
|
+
"version": "1.2.0",
|
|
4
|
+
"description": "Native high-performance AI agent governance proxy binary",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./bin/proxy.js",
|
|
7
|
+
"bin": {
|
|
8
|
+
"intutic-proxy": "./bin/proxy.js"
|
|
9
|
+
},
|
|
10
|
+
"publishConfig": {
|
|
11
|
+
"access": "public"
|
|
12
|
+
},
|
|
13
|
+
"scripts": {
|
|
14
|
+
"build": "cargo build --release && mkdir -p bin && cp target/release/intutic-proxy bin/",
|
|
15
|
+
"prepublishOnly": "cargo build --release && mkdir -p bin && cp target/release/intutic-proxy bin/"
|
|
16
|
+
},
|
|
17
|
+
"files": [
|
|
18
|
+
"bin/",
|
|
19
|
+
"README.md",
|
|
20
|
+
"LICENSE"
|
|
21
|
+
],
|
|
22
|
+
"repository": {
|
|
23
|
+
"type": "git",
|
|
24
|
+
"url": "https://github.com/intutic/intutic"
|
|
25
|
+
},
|
|
26
|
+
"license": "MIT",
|
|
27
|
+
"homepage": "https://intutic.ai",
|
|
28
|
+
"keywords": [
|
|
29
|
+
"ai",
|
|
30
|
+
"governance",
|
|
31
|
+
"proxy",
|
|
32
|
+
"wasm",
|
|
33
|
+
"circuit-breaker",
|
|
34
|
+
"litellm",
|
|
35
|
+
"rust"
|
|
36
|
+
],
|
|
37
|
+
"engines": {
|
|
38
|
+
"node": ">=18"
|
|
39
|
+
}
|
|
40
|
+
}
|