tenuo
Cryptographic authorization primitive for AI agents.
Status: v0.2 — Production/Stable. Core semantics are stable. See CHANGELOG.
Install Tenuo's implementation skill to have a supported coding agent inspect the resolved crate features, select an enforcement topology, and generate deny-before-effect tests:
Overview
Tenuo implements capability tokens (Warrants) for AI agent authorization:
- Offline verification in under 50 μs - no network calls
- Monotonic attenuation - delegated tokens can only shrink in scope
- Proof-of-possession - stolen tokens are useless without the private key
- Constraint types -
Exact,Pattern,Range,OneOf,Regex,Wildcard,CEL,UrlPattern,Cidr - Multi-sig approvals - M-of-N cryptographic approval requirements
Quick Start
use HashMap;
use Duration;
use ;
let issuer_key = generate;
let holder_key = generate;
let mut constraints = new;
constraints.insert;
let warrant = builder
.capability
.holder
.ttl
.build
.expect;
let mut authorizer = new;
authorizer.add_trusted_root;
let mut args = new;
args.insert;
let pop = warrant
.sign
.expect;
authorizer
.authorize_one
.expect;
Rust SDK (sdk feature)
Default-off. Guard enforces; ObservingGuard only assesses and is not a substitute.
#
#
An enforcement point uses Tenuo::enforcement() and Guard::guard_received on a ReceivedAuthorization decoded from _meta.tenuo or HTTP headers. The holder path always signs; the received path never does.
A long-lived process that receives warrants over time uses Runtime: persist
the holder key, apply signed revocation lists as they arrive, and bind each
warrant into a Session. Tenuo::local is deprecated.
#
#
Receipt collection needs the receipts feature: set
evidence_policy(EvidencePolicy::BestEffort), then peek_receipts
and acknowledge_receipts to drop uploaded items.
Callers that obtain warrants and SRLs over the network should not assemble Authorizer, PresentedAuthority, LocalReceiptSigner, or MemoryReceiptSink.
| Feature | Description |
|---|---|
sdk |
Guard, Call, delegation, observe, Runtime / Session |
mcp-transport |
params._meta.tenuo encode/decode |
http-transport |
Signed header binding |
receipts |
Authorization receipts (draft receipt-v1) |
async |
Async Guard methods and AttemptControl |
otel |
OpenTelemetry API spans only; no exporter |
test-utils |
FixedClock and sdk::test_utils scaffolding — not for production |
Run the MCP hop and runtime demos:
&&
&&
Features
| Feature | Description |
|---|---|
control-plane |
Warrant issuance (default) |
data-plane |
Warrant verification (default) |
python |
PyO3 bindings |
server |
HTTP server dependencies |
Use Cases
- Sidecar authorizer - Verify warrants at the edge
- Gateway integration - Envoy/Istio external authorization
- Embedded verification - In-process authorization checks
Documentation
- tenuo.ai - Full documentation
- docs.rs/tenuo - API reference
- GitHub - Source code
License
Apache-2.0. See LICENSE for details.