ECRE-PQ White Paper
Draft for review, 5 December 2026.
Author: ثائر إبراهيم الهريني (Thaer Ibrahim Alherini) · Contact: [email protected] · Web: ecreqc.com, ecreqcs.com
الملخص التنفيذي (بالعربية)
ECRE-PQ (Exposure-Closed Recovery Escrow — Quantum Computer Security) نظام برخصة Apache 2.0 مفتوحة المصدر، وسيُنشر الكود عند الإطلاق، لحماية الملفات والمحافظ من الحواسيب الكمية المستقبلية. يجمع النظام ثلاثة أجزاء: تشفير الملفات وتوقيعها، وسجل استرداد للمحافظ يعطي مفتاح الاسترداد الأولوية على مفتاح الصرف المسروق، ومكتبة برمجية مع أداة سطر أوامر لدمجه في أنظمة أخرى.
لماذا الآن؟ المهاجم يستطيع أن يسجّل الملفات المشفرة اليوم ويفك تشفيرها بعد سنوات عندما يتوفر حاسوب كمي قوي. لذلك يجب أن تكون البيانات طويلة العمر محمية الآن بخوارزميات مقاومة للكم.
ما الذي يقدمه النظام:
- تشفير هجين: يجمع X25519 الكلاسيكي مع ML-KEM-768 المعياري (FIPS 203). يبقى الملف سرياً ما دام أحد الاثنين صامداً.
- توقيع مزدوج: كل توقيع يتكون من ML-DSA-65 (شبكات، FIPS 204) و SLH-DSA-SHA2-192s (دوال تجزئة، FIPS 205)، ويجب أن ينجح الاثنان. التزوير يحتاج إلى كسر عائلتين رياضيتين مستقلتين.
- ربط هوية المرسل بالملف: يغلق ثغرة "نزع التوقيع وإعادة التوقيع" التي وجدناها في النسخة 0.2.
- سجل الاسترداد: الصرف ينتظر مدة محددة، ومفتاح الاسترداد يستطيع خلالها إلغاء العمليات المعلقة وتبديل المفاتيح. القاعدة مثبتة بنموذج TLA+.
- حفظ المفاتيح في وحدة أمان عتادية (HSM) عبر PKCS#11.
الأدلة الرسمية: إثبات رمزي بأداة Tamarin لسرية الملفات، وتوثيق المرسل، ومنع إعادة التوقيع، مع تجربة ضابطة تجد الهجوم القديم تلقائياً في تصميم النسخة 0.2. وفحص شامل بأداة TLC لقاعدة أولوية الاسترداد.
الإتاحة ونموذج العمل: سيُنشر الكود كاملاً برخصة Apache 2.0 عند الإطلاق. وتحصل الشركات على خدمات مدفوعة حوله: اتفاقية مستوى خدمة (SLA) للدعم والتحديثات الأمنية، ودمج النظام مع أنظمتها الحالية، والمساعدة في تشغيل عقد السجل.
الحدود بصراحة:
- لم يخضع النظام لتدقيق أمني مستقل بعد. لا تستخدمه لحماية أسرار أو أموال حقيقية حتى يتم ذلك.
- صيغة الملف لا تمنع إعادة إرسال الملف نفسه كاملاً (replay). التطبيق الذي يحتاج ذلك يجب أن يحتفظ بسجل للملفات المقبولة.
- وحدة HSM تحمي المفاتيح وهي مخزنة فقط، أما التوقيع فيجري على الجهاز المضيف.
- الإثبات الرمزي يخص تصميم البروتوكول، ولا يثبت صحة الكود نفسه.
- عقدة السجل الشبكية تعتمد على مُسلسِل واحد، فهي تكشف التلاعب ولا تمنع الحجب أو التأخير.
Abstract
ECRE-PQ (Exposure-Closed Recovery Escrow, Quantum Computer Security) is an Apache 2.0 licensed system (source to be published at launch) that protects files and wallet authority against both classical and future quantum adversaries, using only standardized primitives from vetted libraries. It combines three components: a hybrid post-quantum file encryption and signature format, a recovery-priority ledger for wallets, and an integration library with a command-line tool.
Files are encrypted with HPKE over the X-Wing hybrid KEM (X25519 + ML-KEM-768) and signed with a composite ML-DSA-65 + SLH-DSA-SHA2-192s signature in which both halves must verify. The sender's identity is bound into key derivation, which closes a strip-and-re-sign attack found in the predecessor design (ECRE v0.2). The ledger lets a recovery key cancel pending spends and rotate keys before a stolen spending key can move value.
The design is supported by a symbolic Tamarin proof of the file protocol in four configurations, including a control run that rediscovers the v0.2 attack, by exhaustive TLC model checking of the ledger's block rule, and by an internal audit with open-source tools. ECRE-PQ has not yet been independently audited, and this paper states precisely what is and is not claimed.
Status (as of 5 December 2026). Research and pre-production. Format v2 with composite signatures and HSM custody, the Tamarin proof and an internal security audit are merged on main. The networked ledger node is still in an open pull request, and the paper says so where it describes it.
1. The problem: data that must outlive today's cryptography
Files encrypted today with RSA or elliptic-curve key exchange can be recorded now and decrypted later, once a cryptographically relevant quantum computer exists ("harvest now, decrypt later"). For data that must stay confidential for ten years or more, such as contracts, medical and legal records, keys and backups, the risk is already present.
Standards now give a concrete timeline. NIST approved FIPS 203 (ML-KEM), FIPS 204 (ML-DSA) and FIPS 205 (SLH-DSA) on 13 August 2024 (NIST CSRC). NIST IR 8547, finalized in October 2026, deprecates quantum-vulnerable key establishment and signatures after 2030 and disallows them after 2035 (NIST IR 8547).
Migration carries its own risk. The new algorithms are young, and implementations are still maturing. A cautious design therefore keeps a classical algorithm alongside the post-quantum one (hybrid), and does not rely on a single mathematical assumption for authenticity.
Wallets add a second problem. A stolen signing key lets an attacker move value immediately and irreversibly. Owners need a way to cancel a theft in progress and rotate keys, with rules that are simple enough to verify formally.
ECRE-PQ addresses both problems:
| Need | ECRE-PQ answer |
|---|---|
| Confidentiality against future quantum attackers | Hybrid X25519 + ML-KEM-768 key encapsulation |
| Robustness if one post-quantum family is broken | Composite ML-DSA-65 + SLH-DSA-SHA2-192s signatures (lattice and hash-based) |
| Knowing who really sent a file | Sender identity bound into key derivation and signature |
| Recovering from a stolen wallet key | Delayed spending with recovery that takes priority, checked in TLA+ |
| Fitting into existing systems | Python library, CLI, HTTP ledger node |
2. System overview
ECRE-PQ is one Python package (ecre_pq, Python 3.12+) with three layers that share a single identity model. An identity holds four key pairs: ML-KEM-768 and X25519 for receiving files, ML-DSA-65 and SLH-DSA-SHA2-192s for signing. Its fingerprint is the SHA-256 of the canonical public identity, and users pin each peer's fingerprint after comparing it over an independent channel.
Every component signs and receives with the same four-key identity, which is opened from a password or hardware vault only for the duration of an operation.
| Component | Modules | What it does |
|---|---|---|
| File encryption and signing | fileformat.py, signatures.py |
Encrypts any file to one recipient and signs it; detached signatures for documents |
| Identity custody | vault.py, custody.py |
Password vault (Argon2id) or hardware vault sealed by a PKCS#11 token |
| Recovery ledger | ledger.py, store.py, spec/RecoveryLedger.tla |
Delayed spending, priority recovery, key rotation, tamper-evident SQLite storage |
| Ledger network node | node.py, node_cli.py, deploy/ |
HTTP API, one attesting sequencer, verifying followers, Docker + Cloudflare Tunnel |
| Integration | api.py, cli.py |
Stable library functions and the ecre-pq command |
Engineering principles. The project implements no primitive and no KEM combiner of its own. ML-KEM, ML-DSA, X25519, HPKE, AES-GCM, HKDF and Argon2id come from pyca/cryptography (OpenSSL backend); SLH-DSA comes from liboqs 0.16.0 at a pinned commit, built from source by a checked script. Parsing is strict (exact fields, canonical bytes, fixed lengths). Plaintext is never written before every check has passed, and outputs are never overwritten.
Typical use.
ecre-pq keygen --out alice.vault # or: keygen --hsm
ecre-pq fingerprint bob.public.json # compare by phone or in person
ecre-pq peer add bob bob.public.json --fingerprint "<verified>"
ecre-pq encrypt report.pdf -o report.pdf.ecre --identity alice.vault --to bob
ecre-pq decrypt report.pdf.ecre -o report.pdf --identity bob.vault --from alice
3. Cryptographic design (format v2)
Every ECRE-PQ file is confidential while either X25519 or ML-KEM-768 holds, and authentic while either ML-DSA-65 or SLH-DSA-SHA2-192s holds. The full specification is docs/FORMAT.md; this section summarizes it.
3.1 Primitives
| Role | Primitive | Standard |
|---|---|---|
| Key encapsulation | HPKE base mode, KEM MLKEM768-X25519 (X-Wing) | RFC 9180, draft-ietf-hpke-pq, FIPS 203 |
| HPKE KDF / AEAD | HKDF-SHA256 / AES-256-GCM | RFC 5869, SP 800-38D |
| Payload encryption | AES-256-GCM, STREAM-style 64 KiB chunks | SP 800-38D; Hoang et al. 2015 |
| Signature, component 1 | ML-DSA-65, pure mode, with context | FIPS 204 |
| Signature, component 2 | SLH-DSA-SHA2-192s, pure mode, with context | FIPS 205 |
| Transcript hash | SHA-512 | FIPS 180-4 |
| Password vault | Argon2id (64 MiB, t=3, p=4) + AES-256-GCM | RFC 9106 |
Both signature components target NIST security category 3. The "s" (small) SLH-DSA set was chosen over "f" because files and ledger operations are signed rarely and stored long.
3.2 File layout
offset size field
0 8 magic = "ECREPQ" 0x00 0x02
8 4 header_len (1..4096)
12 header_len header: canonical JSON {type, suite, sender, recipient, chunk_size, salt}
.. 4 wrapped_len (= 1168)
.. 1168 HPKE output: enc (1120) || AEAD(file_key) (48)
.. n payload chunks
end-19533 19533 composite signature
3.3 Encryption
- Draw a random 32-byte
file_key. - Wrap it:
HPKE.Seal(pk_R, info = "ecre-pq file key v2\0" || header, file_key). - Derive
payload_key = HKDF-SHA256(file_key, salt, "ecre-pq payload v2\0" || SHA-256(header)). - Encrypt 65,536-byte chunks with AES-256-GCM; the nonce is the chunk counter (11 bytes) followed by a last-chunk flag (1 byte), which stops truncation, reordering and extension.
- Sign SHA-512 of all preceding bytes with the composite signature, context
ecre-pq-file-v2.
3.4 Decryption order
The recipient parses the header strictly, checks that the recipient fingerprint is its own and the sender fingerprint equals the peer it pinned, and verifies both signature halves before any key is used or any plaintext is produced. Only then does it unwrap the file key, decrypt chunks in order, re-hash what it read, and publish the output with a no-overwrite link.
3.5 Sender binding
ECRE v0.2 signed its envelope but did not bind the sender into key derivation. The internal audit demonstrated that a second trusted peer could strip the signature, re-sign the same ciphertext and be accepted as its author. In ECRE-PQ the header, and so the sender fingerprint, is part of both the HPKE info and the payload-key derivation. Changing the sender breaks decryption; keeping it makes any other signer's signature fail. A regression test and the Tamarin lemma A2 (section 5) cover this.
3.6 Composite signatures
M' = label || u8(len(ctx)) || ctx || M
sigma = ML-DSA-65.Sign(sk1, M', ctx) || SLH-DSA-SHA2-192s.Sign(sk2, M', ctx)
The label is "ecre-pq composite ML-DSA-65+SLH-DSA-SHA2-192s v2" 0x00. A verifier requires the exact length (3,309 + 16,224 = 19,533 bytes) and both component verifications. Neither half is a signature over M alone, so a half cannot be presented to a single-algorithm verifier; halves from two signers do not combine; and the signer verifies its own output before release as a fault countermeasure. The same construction signs files, detached signatures and ledger operations, separated by context strings.
3.7 Versioning and downgrade
v2 changes every domain label together (magic, HPKE info, HKDF label, identity, vault, detached and ledger contexts). v1 files are rejected rather than read, because accepting them would let an attacker downgrade a file to a single signature family. No v1 data exists outside test fixtures.
3.8 Cost
| Measure | v1 (ML-DSA only) | v2 (composite) |
|---|---|---|
| Per-file overhead | about 4.6 KB | about 20.8 KB |
| Detached signature file | about 4.6 KB | about 26.4 KB |
| Sign, x86-64, one core | about 1 ms | about 1.1 s |
| Verify | under 1 ms | about 2 ms |
Signing cost is dominated by SLH-DSA-192s. This suits archival files and wallet operations, not high-rate messaging.
4. Recovery-priority ledger
The ledger guarantees that a recovery key can always cancel a pending spend before it settles, so a thief holding only the spending key cannot move value faster than the owner can react. It is a deterministic state machine that defines authorization rules for a wallet, a custody service or a future on-chain integration (docs/LEDGER.md).
4.1 Accounts and operations
A genesis document creates each account with a spending identity, a separate recovery identity, a balance, a minimum delay (in blocks), an epoch, a spending nonce, pending reservations and a list of retired key fingerprints.
| Action | Required signatures | Effect |
|---|---|---|
RESERVE |
spending | Locks an amount; it settles after a delay of at least min_delay blocks |
RECOVER |
recovery, successor spending, successor recovery | Cancels every pending reservation, installs fresh keys, increments the epoch, retires the old keys |
Each signature is a composite signature over {domain: "ecre-pq-ledger-v2", role, payload}, so a signature for one role is never valid for another. Payloads carry the chain id, the epoch and an expiry height; RESERVE also carries the nonce. Successor keys must be fresh and must sign, which prevents installing keys nobody controls.
4.2 Block rule
All operations in a block are validated against the block-start state and processed in ascending operation-id order, so the result does not depend on submission order.
- Recovery first. The first valid
RECOVERper account is applied; later ones are superseded. - Settlement. Only for accounts not recovered in this block, reservations whose maturity height has arrived settle.
- New reservations. One per account nonce; skipped for recovered accounts.
Because recovery runs before settlement in the same block, a recovery that arrives in the block where a stolen spend matures still wins.
4.3 Formal model and verified properties
spec/RecoveryLedger.tla models one account and is checked exhaustively by TLC in CI (constants: total 3, amounts {1, 2}, delay 2, maximum height 7).
| Property | TLA+ (TLC) | Python tests |
|---|---|---|
| Conservation of value | Conservation invariant |
Hypothesis property test |
| Recovery has priority over settlement | RecoveryPriority invariant |
test_recovery_has_priority_at_maturity |
| No settlement before maturity | NoEarlySettlement invariant |
property test |
| Every reservation is eventually settled or cancelled | EventuallyResolved (weak fairness) |
none |
| Old keys are dead after recovery | none | test_old_keys_are_dead_after_recovery |
A deliberately broken variant that settles during recovery is caught by TLC, so the priority invariant is not vacuous. The model of the v0.2 study had a defect (height never advanced, so a deferred reservation could never settle); the new model fixes it and adds the liveness property.
4.4 Storage and network node
LedgerStore keeps the genesis and every block's raw operations in SQLite (WAL, synchronous=FULL, mode 0600). Opening a store replays every block and compares each recomputed head and state hash, so edits to the database are detected.
The network node (docs/NODE.md, open pull request) uses one sequencer and verifying followers. The primary orders operations and signs an attestation over {chain_id, height, head, state_hash} for each block. Followers pin the sequencer key, verify every attestation, replay every operation under the ledger rules and halt on any mismatch.
| Threat | Result |
|---|---|
| Network, CDN or proxy alters a block | Attestation or replay fails; follower halts |
| Compromised primary forges a spend | Impossible without the account keys; followers replay and reject |
| Compromised primary censors or delays operations | Possible. Detectable, not preventable |
| Primary signs two blocks at one height | Followers halt; the two signed blocks are proof. No automatic resolution |
| Primary loses its data | Rebuilt from a follower |
The node is designed to run behind Cloudflare Tunnel at ledger.ecreqc.com (primary) and ledger.ecreqcs.com (follower). Cloudflare terminates TLS and can read the public ledger traffic, but cannot forge operations or blocks.
5. Threat model and formal results
5.1 Adversaries
| Adversary | Capability | Mitigation |
|---|---|---|
| Network or storage attacker | Reads, modifies, truncates, reorders, replays files | AEAD chunks with position and final-flag nonces; signature over the full transcript; strict parsing |
| Harvest-now-decrypt-later quantum attacker | Records ciphertexts, later breaks X25519 | ML-KEM-768 inside the hybrid KEM |
| Future break of ML-KEM | Lattice cryptanalysis | X25519 inside the hybrid KEM |
| Future break of ML-DSA | Forges lattice signatures | SLH-DSA (hash-based) must also verify |
| Malicious trusted peer | Holds a valid identity, can re-sign data | Sender bound into HPKE info and payload key |
| Thief of the identity file | Copies the vault | Argon2id (password vault); useless without token and PIN (HSM vault) |
| Thief of a wallet spending key | Signs ledger operations | Settlement delay; recovery cancels and rotates within the delay |
| Malicious ledger operator | Edits stored rows | Replay and hash check on open; followers replay every block |
5.2 Symbolic proof of the file protocol (Tamarin)
The file format is modelled in spec/tamarin/ecre_file.spthy and checked with Tamarin prover 1.12.0 and Maude 3.5.1 on every push (docs/FORMAL_ANALYSIS.md). The adversary is Dolev-Yao: it controls all storage and transport, registers any number of identities, and can at any time reveal signing keys, reveal KEM keys, break X25519, break ML-KEM, break ML-DSA, break SLH-DSA, or use a signing oracle in the detached and ledger contexts. Each lemma's exceptions are exactly the compromises it names.
The same model runs in four configurations. The control run, which removes the header from key derivation as v0.2 did, is what shows the lemmas can discriminate: the prover finds the strip-and-re-sign attack there in 20 steps, and not in v1 or v2.
| Lemma | Claim | v2 | v1 | v2 + replay cache | v0.2 control |
|---|---|---|---|---|---|
| C1 confidentiality | Plaintext stays secret unless both of the recipient's KEM keys are broken | verified | verified | verified | verified |
| C2 file key secrecy | Same for the file key | verified | verified | verified | verified |
| A1 sender authentication | Accepted file was sent exactly so by the pinned sender, unless its signature keys are broken (v2: both families) | verified | verified | verified | verified |
| A2 no strip-and-re-sign | A malicious trusted peer cannot claim an honest sender's file | verified | verified | verified | attack found |
| A3 accepted plaintext secrecy | C1 and A1 from the recipient's side | verified | verified | verified | verified |
| T1 to T3 tightness | Each exception above is necessary (attack exists without it) | verified | verified | verified | verified |
| R0 replay is possible | The same file can be accepted twice | replay exists | replay exists | n/a | replay exists |
| R1 injective authentication | With a per-recipient salt cache, each file is accepted at most once | n/a | n/a | verified | n/a |
check.py fails CI if any result differs from expected.json. Run time is about 9 minutes for v1 and 15 minutes per v2 configuration on a 4-core machine.
5.3 What the formal results do not show
- Symbolic, not computational. Primitives are perfect; there are no probability bounds. Computational hybrid and composite claims rest on the X-Wing analysis (Barbosa et al., 2024), HPKE analyses and the composite-signature literature.
- One chunk. Truncation and reordering of chunks are not modelled; they rest on the STREAM construction and the test suite.
- Parsing is assumed injective, and HPKE is simplified to an AEAD under a key derived from the KEM secret and
info. - Hand-written model. Nothing checks mechanically that the Python code matches the model; a reviewer should compare the mapping table in
FORMAL_ANALYSIS.mdwith the code. - No cross-version downgrade lemma. v1 rejection is a test, not a proof.
- Ledger. The TLA+ model covers one account with small constants; the ledger's signature protocol and the network node are not yet modelled.
5.4 Testing
The test suite runs in CI on Linux x86-64 and ARM64 and on macOS, with Python 3.12 and 3.13. It includes Hypothesis property tests of the ledger, regression tests for every v0.2 audit finding, HSM tests against SoftHSM v2 (a missing SoftHSM fails CI), and composite-signature tests (each half checked, halves alone rejected, halves from two signers rejected, v1 files rejected, missing liboqs fails closed). SLH-DSA signing takes about 1.1 s, so the composite property test runs 8 examples per push and a thorough run weekly.
5.5 Internal security audit
An internal audit with open-source tools was completed and merged in December 2026 (docs/SECURITY_AUDIT_INTERNAL.md). It was performed by the same team that wrote the code, with AI assistance, and is not an independent audit. It covered static analysis (bandit, semgrep, ruff, mypy --strict), known-vulnerability scans (pip-audit, OSV), secret scanning of the full history (gitleaks), about 7 million coverage-guided fuzzing executions of every parser (atheris), Hypothesis property fuzzing, and a manual review against the threat model. All of these checks now run in CI on every pull request and weekly.
No finding breaks confidentiality, authenticity or funds. Two medium findings were fixed: a deeply nested ledger operation that crashed block processing (AUD-01), and GitHub Actions referenced by mutable tags (AUD-03). Open items are the whole-file replay noted in section 5.2 (AUD-07), hardening of the ledger node in the open pull request (AUD-08 to AUD-10), and several low-severity items listed with a recommendation each.
6. Key custody and deployment
An identity is stored either in a password vault or in a hardware-sealed vault; both open to the same in-memory identity, so the rest of the system is unchanged (docs/KEY_CUSTODY.md).
| Password vault | HSM vault | |
|---|---|---|
| Needs | Vault file and password | Vault file, the PKCS#11 token and its PIN |
| Offline guessing from the file | Possible, slowed by Argon2id (64 MiB, t=3, p=4) | Not possible: the 256-bit wrapping key never leaves the token |
| Copied to another machine | Enough to attack it | Useless without the token |
| Works with | Everything | Any PKCS#11 token with CKM_AES_GCM |
The token generates a non-extractable AES-256 key and seals the secret identity with AES-GCM; labels and the identity fingerprint are authenticated as additional data. Before every use, the key must report sensitive, always-sensitive and never-extractable; a key that was ever imported in clear is refused.
Custody at rest only. The token returns the identity seeds to the host for each operation, so malware on the host while a command runs can read them. In-token signing needs PKCS#11 3.2 ML-DSA and SLH-DSA mechanisms, which SoftHSM 2.6 and most deployed tokens do not yet provide. Losing the token loses the identity unless a second token or an offline password vault holds a copy; threshold (k-of-n) custody is not implemented.
Deployment. The ledger node ships as a Docker image with a compose file. Recommended exposure is through Cloudflare Tunnel, so servers open no inbound ports except SSH; a Caddy + Let's Encrypt variant is documented (docs/DEPLOY.md). The sequencer key is an Argon2id vault whose password is read from a mode-0600 file, and every follower pins the sequencer fingerprint recorded offline.
7. Limitations
ECRE-PQ is not ready to protect real secrets or funds: no independent security audit has been performed. The project's own internal audit, formal models and tests are evidence, not a substitute for external review. The limits below are part of the design statement and should be repeated to any customer.
| Limit | Consequence | Mitigation or plan |
|---|---|---|
| No independent audit | Unknown implementation flaws may exist | Internal open-source-tool audit done (section 5.5); external cryptographic review before any production use |
| Whole-file replay is not prevented by the format | An attacker can deliver the same valid file again and it will be accepted again (Tamarin R0) | Applications needing at-most-once acceptance keep a per-recipient cache of accepted salts; R1 proves this suffices. The library does not do it today |
| HSM protects keys at rest only | Host malware during an operation can read the seeds | In-token signing once tokens support PKCS#11 3.2 ML-DSA and SLH-DSA |
| No forward secrecy for files | Later theft of a recipient's KEM keys exposes past files sent to that identity | Rotate identities |
| Metadata is visible | Headers reveal sender and recipient fingerprints and file size | Out of scope; wrap in a transport that hides metadata if needed |
| Public keys are pinned manually | A wrong fingerprint defeats every guarantee | Users compare fingerprints over an independent channel |
| Compromised host while keys are unlocked | Python cannot reliably erase secrets from memory | Out of scope; use HSM custody and short sessions |
| Single-sequencer ledger node | The primary can censor, delay or equivocate (detectably) | Byzantine-fault-tolerant ordering is future work |
| No threshold custody | One token or vault is a single point of loss | k-of-n custody is future work |
| SLH-DSA from liboqs | liboqs is a research library and is not FIPS 140-3 validated; its side-channel resistance is not assured | Move to a validated backend when one exposes SLH-DSA |
| Symbolic, hand-written models | The proofs cover the design, not the code; chunking and parsing are abstracted | Code-to-model review, multi-chunk and downgrade models |
| Signing cost | About 1.1 s and 19.5 KB per composite signature | Fit for archival and wallet use, not high-rate messaging |
8. Availability and commercial model
The full source code is licensed under Apache 2.0 and will be published at launch; until then the repository is private. The license lets any organization use, modify and deploy ECRE-PQ without fees.
Companies that adopt it can contract for services around the open code:
| Service | What it covers |
|---|---|
| Service-level agreement (SLA) | Support with agreed response times, security patches and upgrade guidance |
| Integration | Connecting ECRE-PQ to the customer's existing systems: document storage, key management and HSMs, wallets or custody platforms |
| Deployment | Running or helping run ledger nodes for the customer |
Terms, prices and response times are agreed per customer. Paid services do not change the security claims in this paper, and they do not replace the independent audit that is still required before production use.
9. Roadmap
- Merge the networked ledger node. On merge, align the node's block attestation (
ecre-pq-block-v1, written against the ML-DSA-only identity) with the v2 composite signature. - Close the open low-severity findings of the internal audit and the node hardening items (AUD-08 to AUD-10).
- Optional accepted-salt cache in the API for at-most-once file acceptance (Tamarin R1).
- Extend the formal models: multi-chunk payloads, an explicit v1/v2 downgrade attempt, the ledger signature protocol and the follower replay rule.
- Run the primary and follower nodes on
ecreqc.comandecreqcs.com. - Independent external audit before any customer handles real secrets or funds.
- In-token signing, threshold custody, and multi-sequencer ordering.
10. Open points in this draft
One point is not yet settled and is worded conservatively:
- Ledger node. The node is described as designed to run at
ledger.ecreqc.comandledger.ecreqcs.com; deployment is in progress and it is not described as live.
References
- NIST, Post-quantum cryptography FIPS approved (FIPS 203, 204, 205), 13 August 2024.
- NIST IR 8547, Transition to Post-Quantum Cryptography Standards, October 2026.
- RFC 9180, Hybrid Public Key Encryption; draft-ietf-hpke-pq; RFC 5869 (HKDF); RFC 9106 (Argon2); NIST SP 800-38D (GCM); FIPS 180-4 (SHA-2).
- M. Barbosa et al., X-Wing: The Hybrid KEM You've Been Looking For, 2024.
- V. T. Hoang, R. Reyhanitabar, P. Rogaway, D. Vizár, Online Authenticated-Encryption and its Nonce-Reuse Misuse-Resistance (STREAM), CRYPTO 2015.
- Tamarin prover 1.12.0; TLA+ tools v1.8.0 (TLC).
- Repository documents:
docs/FORMAT.md,docs/LEDGER.md,docs/THREAT_MODEL.md,docs/AUDIT_V0_2.md,docs/KEY_CUSTODY.md,docs/NODE.md,docs/DEPLOY.md,docs/FORMAL_ANALYSIS.md.