Architecture
AMP2 operates as a Rust service between client applications and Liquid Network infrastructure. The page explains system components, COSE encryption, and integration modes.
AMP2 is a Rust service that sits between client applications and Liquid Network infrastructure. It manages wallet state, enforces transfer policies, constructs and cosigns transactions, and broadcasts them to the network.
System overview
COSE encryption flow
All authenticated request and response bodies are wrapped in COSE (RFC 9052) with CBOR serialization. The encryption is layered:
Request (client → server):
- JSON → CBOR encode
- Sign CBOR with client ECDSA private key → COSE_Sign1
- Generate ephemeral AES-256-GCM key
- Encrypt signed payload → COSE_Encrypt0
- Encrypt ephemeral key with server RSA public key (RSA-OAEP)
- Pack encrypted key into KID header field
- Send as
application/octet-stream
Response (server → client):
- JSON → CBOR encode
- Sign CBOR with server ECDSA private key (via HSM)
- Generate ephemeral AES-256-GCM key
- Encrypt signed payload → COSE_Encrypt0
- Encrypt ephemeral key with client RSA public key
- Send as
application/octet-stream
This ensures that even if TLS is terminated at a load balancer, payloads remain encrypted and authenticated.
Integration modes
| Mode | Client | Transport | Typical user |
|---|---|---|---|
| Issuer SDK | @blockstream/cryptic + @blockstream/amp-registry | COSE wrapped HTTP | Asset issuers |
| LWK + Proxy | LWK (Rust) + Proxy Service | HTTP → Proxy translates to COSE | Investors, venues |
Next steps
- PSET Lifecycle: how transactions flow through the system
- Key Management: generating and rotating client keys
Liquid overview
Liquid is a Bitcoin sidechain operated by a federation of functionaries. The page explains settlement, Confidential Transactions, asset issuance, and AMP2 relevance.
Use cases
AMP2 supports tokenization scenarios on Liquid. The page maps each scenario to issuance, restrictions, lifecycle operations, and monitoring capabilities.