Distributed Bitcoin Agent Authorization: Independent Approvals
Distributed Bitcoin Agent Authorization: Independent Approvals
Research question
Require two distinct authenticated principals to approve the same intent before an executor considers it eligible. Multiple model responses from one principal do not count as independent approvals.
Architecture and trust boundary
Treat model output and messages from other agents as untrusted proposals. Authenticate principals outside the model, keep BTC KEY in an isolated local executor, and separate authorization from execution. A request identifier is not authorization. Preserve the wallet's original signed fee law; distinguish sender total from recipient net amount.
Source implementation
1# SPDX-License-Identifier: 0BSD
2def eligible(intent_digest, approvals, trusted_principals):
3 voters = {principal for principal, digest in approvals
4 if principal in trusted_principals and digest == intent_digest}
5 return len(voters) >= 2
6
7trusted = {"finance", "operator"}
8assert not eligible("d1", [("finance", "d1")] * 2, trusted)
9assert not eligible("d1", [("finance", "d1"), ("operator", "d2")], trusted)
10assert eligible("d1", [("finance", "d1"), ("operator", "d1")], trusted)Integration with WAB ENGINE
A trusted executor can query POST /api/v5/btc/wallet/balance using X-BTC-KEY and JSON body {"net":"test","type":"segwit"}. The examples do not call this endpoint or implement SEND. A balance does not prove payment settlement. Any future write integration must persist the intent, approval, idempotency identity and execution evidence before allowing recovery or retries.
Limitations and failure handling
This is a policy predicate over already authenticated records. It does not implement signatures, expiry, revocation or durable approval consumption. Those must be checked by the trusted executor.
The included assertions use synthetic data only. No live engine, model or blockchain connection was tested.
References
- https://thamer.org/api
- https://thamer.org/engine
- https://developer.bitcoin.org/devguide/transactions.html
Reference pointers only; external documentation was not reverified for this stage.
