> For the complete documentation index, see [llms.txt](https://qanchain.gitbook.io/qan/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://qanchain.gitbook.io/qan/quantum-proof-onchain/mldsa-87.md).

# MLDSA-87

### **1. Overview**

**MLDSA-87** (Module-Lattice Digital Signature Algorithm with 87-bit security) is a post-quantum cryptographic (PQC) signature scheme based on **structured lattice cryptography**. It is part of the **NIST PQC Standardization Project** (Finalist in the Digital Signature category) and is optimized for blockchain environments.

#### **Key Features**

* **Quantum-Resistant**: Secure against attacks from both classical and quantum computers (e.g., Shor’s algorithm).
* **Efficiency**: Balances security and performance with compact key sizes (\~3KB public keys) and fast verification.
* **On-Chain Compatibility**: Designed for low gas costs and high throughput in smart contracts.

***

### **2. Technical Details**

#### **2.1 Algorithm Structure**

| Parameter            | Specification                              |
| -------------------- | ------------------------------------------ |
| **Security Level**   | 87-bit (Post-Quantum NIST Tier 3)          |
| **Base Problem**     | Module-Lattice Learning With Errors (MLWE) |
| **Signature Size**   | \~2.5 KB                                   |
| **Public Key Size**  | \~3 KB                                     |
| **Private Key Size** | \~1.5 KB                                   |

#### **2.2 Performance Metrics**

| Operation    | Speed (QAN Testnet) |
| ------------ | ------------------- |
| Verification | \~10 ms             |

*Benchmarked on QAN’s quantum-resistant VM with 4 vCPUs.*

***

### **3. Integration with QAN Blockchain**

**Advantages for QAN**

* **Gas Efficiency**: 30% lower gas costs vs. traditional ECDSA.
* **Future-Proof**: Immune to Grover’s/Shor’s attacks.

***

### **4. Comparison with Classical Algorithms**

| Algorithm    | Quantum-Safe? | Key Size | Speed (Verification) |
| ------------ | ------------- | -------- | -------------------- |
| **MLDSA-87** | ✅ Yes         | \~3 KB   | ⚡ 10 ms              |
| ECDSA        | ❌ No          | 64 B     | ⚡ 5 ms               |
| RSA-2048     | ❌ No          | 256 B    | 🐢 150 ms            |

***

### **5. Use Cases in QAN Ecosystem**

* **Smart Contracts**: Tamper-proof agreements.
* **Government/Gaming**: Where long-term security is critical.
