Architecture: ISO 20022 Adapter
Status: MVP Implemented Component:
core/iso20022
The Problem
Banks speak XML (pacs.008, camt.053). Blockchains and modern ledgers speak binary (Protobuf, SSZ, RLP). Bridging this gap usually involves "Enterprise Service Buses" (ESB) which are slow, expensive, and fragile.
The Qazna Solution ("Trojan Horse")
We embed the ISO 20022 understanding inside the kernel, but keep the execution binary.
Data Flow
mermaid
graph LR
Bank[Bank System] -->|XML pacs.008| Adapter[core/iso20022]
Adapter -->|Parse & Validate| Structs[Rust Structs]
Structs -->|Convert| Proto[IsoBinaryMessage]
Proto -->|Embed| Tx[Qazna Transaction]
Tx -->|Execute| Ledger[core/ledger]Implementation Details
- Parsing: We use
quick-xmlfor zero-copy parsing where possible. - Mapping: We implemented a semantic mapping from
Document/FIToFICrdtTrfto our internalIsoBinaryMessage. - Storage: The original XML is discarded after extraction. Only the semantic data (Who, Whom, How Much, Remittance Info) is stored in the efficient Protobuf format within the transaction log.
- Export: If a regulator needs XML, we can re-hydrate the
pacs.008from the binary data (Future Work).
Key Rust Crates
iso20022: Standalone crate with no IO dependencies. Pure data transformation.qazna-ledger: Depends oniso20022to enrich its transaction model.