agent-wallet
Qué hace
Esta skill configura una cartera de criptomonedas para un agente de IA, controlada por reglas que solo el administrador puede cambiar. El código comprueba cada gasto contra un archivo de políticas antes de firmarlo, así que las reglas se mantienen aunque el agente sea manipulado.
Cuándo usarla
- ✓Cuando quieres que un agente haga pagos desde su propia cartera dentro de los límites que fijas.
- ✓Cuando necesitas una cartera que siga segura aunque el agente sea engañado por un mensaje malicioso.
- ✓Cuando quieres una lista de direcciones permitidas o un interruptor de emergencia para el gasto de un agente.
Link de la skill
https://github.com/internet-court/internet-court-skill/blob/main/vendored/chaingpt/agent-wallet/SKILL.mdCópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.
Cómo usar
La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.
Mensaje listo para pegar
Para Claude Code, Codex o Cursor: ejecútalo en la carpeta del proyecto y la skill queda instalada.
Descarga el SKILL.md y ponlo en la carpeta de skills de tu agente.
Ejemplo de qué pedirle a la IA
“Quiero darle a mi agente su propia cartera, pero que solo pueda enviar a mis direcciones aprobadas.”
5 skills nuevas por semana. 1 minuto de lectura.
Cómo funciona
El administrador crea una cartera cifrada y un archivo de políticas con las reglas, como las direcciones permitidas y los importes máximos. Cada vez que el agente intenta enviar, la herramienta comprueba la política en el código y rechaza el envío si falla alguna regla. El agente no tiene ninguna herramienta para editar la política.
Contenido técnico (SKILL.md original)
Texto original del autor, en inglés, directo de GitHub.
ChainGPT Agent Wallet Skill
The agent has its own EOA wallet on every EVM chain it supports. The admin (you, in your shell) sets policies that the agent cannot violate or revoke — even if a malicious prompt convinces the LLM to try.
Threat model
The attacker's goal: prompt-inject the agent to drain its wallet to an attacker address.
The plugin's defense: the policy check is in code, not in the LLM's prompt. Every chaingpt_agent_wallet_sign_and_send call:
- Loads the policy file fresh from disk (no caching — admin can update mid-session).
- Runs
checkPolicy(intent)— pure deterministic code that doesn't see the LLM's context. - Refuses if any rule fails, with a clear reason the agent surfaces back to the user.
The attacker can convince the LLM to call sign_and_send(to=attacker, value=ALL) — but the tool layer refuses because attacker isn't in allowedToAddresses or value exceeds maxTxValueWei or killSwitch=true. The trust boundary is the tool code, not the LLM.
There is no MCP tool that writes the policy file. The admin edits it directly with a text editor. There is no MCP tool that reads or sets the passphrase. The passphrase lives only in the shell env var or the OS keychain — never in the keystore file, never in the LLM's context.
Setup (admin steps — done once)
The keystore passphrase resolves in this priority order:
CHAINGPT_AGENT_WALLET_PASSPHRASEenv var — explicit override. Best for CI / headless / power users who want zero process-list and zero keychain exposure.- OS keychain — auto-managed. On macOS (Keychain via
security) or Linux (libsecret viasecret-tool), if no env var is set,chaingpt_agent_wallet_initgenerates a strong 256-bit passphrase and stores it in the keychain. You never type or remember it; the MCP server reads it back on each load.
Option A — zero-setup (macOS / Linux with a keychain) — recommended for most
# Just init — a strong passphrase is generated + stored in your OS keychain.
claude
> initialize the agent wallet
The init output tells you it used the keychain and how to export the passphrase for backup.
Option B — explicit env var (CI / headless / max control)
# Set a strong passphrase BEFORE starting the MCP server (>= 16 chars)
export CHAINGPT_AGENT_WALLET_PASSPHRASE="your-strong-passphrase-here-min-16-chars"
claude
> initialize the agent wallet
Back up the passphrase either way. Keychain entry:
service=chaingpt-mcp-agent-wallet account=keystore-passphrase. Export on macOS withsecurity find-generic-password -s chaingpt-mcp-agent-wallet -a keystore-passphrase -w. Lose it (and any backup) → the keystore is unrecoverable. There is no recovery path.
Security tradeoff of the keychain option: the secret stays out of plaintext-on-disk and out of the LLM context, but the keychain is unlocked while you're logged in — a local attacker on an unlocked session could read it. That's a much higher bar than a plaintext file and appropriate for a low-value bounded hot wallet. For zero local exposure, use Option B.
This creates two files:
| File | Contents | Who edits it |
|---|---|---|
~/.chaingpt-mcp/agent-wallet/keystore.json |
AES-256-GCM encrypted private key | Generated once by the init tool. Never edit by hand. Back it up. |
~/.chaingpt-mcp/agent-wallet/policy.json |
Plain JSON rules | You, the admin, with a text editor. The agent has NO tool that writes this file. |
Both default to ~/.chaingpt-mcp/agent-wallet/ but can be overridden via CHAINGPT_KEYSTORE_FILE and CHAINGPT_AGENT_POLICY_FILE.
Tools
| Tool | Mutates state? | Notes |
|---|---|---|
chaingpt_agent_wallet_init |
Creates keystore | One-shot. Refuses if file exists. |
chaingpt_agent_wallet_address |
No | Returns the agent's EOA address. Use this to receive funds. |
chaingpt_agent_wallet_status |
No | Address + policy digest + kill-switch state. Run this before any signing. |
chaingpt_agent_wallet_balances |
No | Native-coin balances across requested chains. |
chaingpt_agent_wallet_policy |
No (read-only) | Shows the current policy JSON. Cannot modify it. |
chaingpt_agent_wallet_sign_and_send |
Signs + broadcasts a tx | The only tool that can move funds. Gated by policy. |
chaingpt_agent_wallet_serve_ui |
Starts a local HTTP server | Dashboard on http://127.0.0.1:8787. Read-only view. |
Policy file format
Default policy.json (lazily
Preguntas frecuentes
¿Puede el agente cambiar sus propias reglas de gasto?
No. No hay ninguna herramienta que le permita escribir el archivo de políticas, y solo el administrador lo edita directamente.
¿Dónde se guarda la contraseña de la cartera?
Se guarda en una variable de entorno de la terminal o en el llavero del sistema operativo, no en el archivo de la cartera.
¿Qué pasa si un pago incumple una regla?
La herramienta se niega a firmarlo y da un motivo que el agente puede transmitirte.
Detalles
Descripción original del autor
Give the AI agent its own EVM wallet with admin-controlled policies the agent CANNOT bypass even under prompt injection. Encrypted keystore (AES-256-GCM, scrypt KDF), policy file the agent has no tool to write, deterministic policy gate on every signing operation, optional local HTTP dashboard. Triggers: agent wallet, give the agent a wallet, agent address, fund the agent, agent autonomy, policy gate, kill switch, agent permissions, bounded autonomy, ERC-4337 alternative, session-key alternative.
Popularidad
- Estrellas en GitHub
- 7,0 mil
- Posición en el ranking
- #13620
- Licencia
- —
- Actualizada
- 26/10/2026
Comentarios
- …
Más skills de este repositorio
internet-court
7,0 milAyuda a tu agente a pagar, contratar o tratar de forma segura con otro agente de IA o con un servicio de pago, y lo dirige a la guía especializada adecuada.
genlayer-erc7710-connector
7,0 milAyuda a tu agente a conectar el resultado de una revisión de IA con un sistema de permisos, para que una mala revisión limite o cancele los permisos de un agente.
genlayer-intelligent-contracts
7,0 milAyuda a tu agente a definir las reglas, las pruebas y los resultados de un juez de IA que comprueba si otro agente cumplió su mandato.
x402-erc7710
7,0 milAyuda a tu agente a pagar servicios web una solicitud a la vez, y a configurar un gasto continuo que se mantenga dentro de un presupuesto de permisos.
Skills parecidas
add-model-provider
394 milPermite que tu agente conecte un nuevo proveedor de modelos de IA a OpenClaw con comandos de configuración seguros, mantenga las claves API fuera del texto plano y haga una prueba en vivo.
acp-router
394 milAyuda a tu agente a enviar una tarea a un asistente de programación como Claude Code o Cursor a través de OpenClaw, para que el trabajo se ejecute en esa herramienta.
browser-automation
394 milEnseña a tu agente a controlar páginas web paso a paso, incluidos los inicios de sesión, las pestañas y la recuperación cuando una página deja de responder.