Ecosystem
OpenApe Grants
Human-in-the-loop permissions for agents.
OpenApe Grants
@openape/grants
The permission engine. Framework-agnostic.
Grant Lifecycle
Request β Pending β Approved/Denied β (if approved) Active β Used/Expired/Revoked
Grant Types
| Type | Behavior |
|---|---|
once | Single use β consumed after first use |
timed | Valid for a time window (TTL) |
always | Standing permission β active until revoked |
AuthZ-JWT
On approval, a signed AuthZ-JWT is issued:
{
"sub": "agent@example.com",
"aud": "target-system",
"grant_type": "once",
"permissions": ["deploy"],
"cmd_hash": "sha256:a1b2c3...",
"decided_by": "alice@example.com",
"exp": 1234567890,
"jti": "unique-grant-id"
}
Key security features:
audbinding β token only valid for the intended targetcmd_hashβ binds to exact command (prevents substitution attacks)decided_byβ dual accountability (agent owner β approver)jtiβ replay protection- Expiry β all grants have a maximum lifetime
@openape/nuxt-grants
Drop-in Nuxt module for grant management. Designed to work alongside nuxt-auth-idp.
Auto-registered routes:
/api/grantsβ list and create grant requests/api/grants/:idβ get grant details/api/grants/:id/approveβ approve a grant/api/grants/:id/denyβ deny a grant/api/grants/:id/revokeβ revoke an active grant/api/grants/:id/tokenβ issue AuthZ-JWT for approved grant/api/grants/verifyβ verify an AuthZ-JWT/api/agent/enrollβ register a new agent/api/agent/challengeβ request auth challenge/api/agent/authenticateβ authenticate with signed challenge
Pages (overridable):
/grantsβ grant dashboard/grant-approvalβ approve/deny UI/enrollβ agent enrollment form
openape-sudo (apes)
A Rust binary for local privilege elevation via the grant system.
# Install
cargo build --release
sudo make install # installs to /usr/local/bin/apes with setuid
# Enroll
sudo apes enroll --server https://id.example.com --agent-name my-server
# Use
apes --reason "Security update" -- apt-get upgrade
Security Model
- Setuid binary β starts as root, immediately drops to invoking user's UID
- Privileges re-elevated only after valid AuthZ-JWT with matching
cmd_hash - Environment sanitized β
LD_PRELOAD,PATHetc. reset before exec - Audit log β every execution logged as JSONL