THAMER
Sovereign Bitcoin Wallet

WALLET AI BITCOIN

Your Bitcoin Wallet. Your Keys. Your Engine.

Self-hosted Bitcoin software built for developers, applications, and AI agents.

CREATE WALLET

Why Bitcoin Agent .SO Libraries Must Never Contain API Keys or BTC KEY

permalink THAMER
#agent-architecture#bitcoin-security#docker#environment-variables#secrets-management

A specialized Bitcoin agent should be distributable to many operators without carrying any operator's secrets. That principle is central to the proposed THAMER.AI design: the compiled agent .so implements bounded behavior, while the local runner supplies configuration at startup.

Build-time versus runtime

The factory knows which operations an agent can perform; it does not need the operator's BTC KEY, AI provider token, wallet identity, or service credentials. These values belong to the operator's own deployment. The same binary can therefore serve different businesses without recompilation.

A local .env file is one possible configuration input. A Docker Compose deployment can inject selected variables into the container at startup. Keep .env out of version control, release archives, image layers, and diagnostic output. Use a template such as .env.example with blank values only.

An .env file is not encryption

Environment variables are convenient, but can be exposed through container inspection, process diagnostics, or careless logs. Restrict filesystem permissions, limit container access, avoid printing configuration values, and consider a secrets manager or mounted secret files for more sensitive deployments. Never send BTC KEY or other secrets to the language-model provider.

Wallet authorization is a separate boundary

A public invoice chatbot should not hold a credential capable of unrestricted wallet spending. Hiding the SEND button or disabling a tool in a prompt is not an authorization boundary. Where the wallet engine uses a broad credential, a private intermediary should provide narrowly scoped receive/watch operations to the public-facing agent. Keep spending in a separate authenticated owner process.

Updates without secret migration

The operator should be able to replace agent.so and restart the host while preserving the local .env and persistent database. Installer upgrades must not overwrite operator credentials or delete order state.

Status: Proposed security and deployment guidance for future agent releases. It does not claim that storing a secret in .env alone makes a deployment secure.

Questions & Answers

Explore all questions →

Latest from the Lab

THAMER illustrated developer portrait and signature

ABOUT THE DEVELOPER

Independent Software Developer specializing in Bitcoin Script, Golang, and AI Agents.

Software engineering · Independent research · Open-source projects