Summary
100% of all REPORTED Findings have been addressed
- 0Acknowledged
- 0Risk Accepted
- 30Solved
- 30All Findings
- Critical3
- 3Solved
- High1
- 1Solved
- Medium3
- 3Solved
- Low3
- 3Solved
- Informational20
- 20Solved
Introduction#
Halborn was engaged to conduct a security assessment of the Soqucoin blockchain node, focusing on the post-quantum cryptographic subsystems, wallet encryption module, and block validation logic.
The audit scope encompassed the following components:
src/crypto/dilithium/— ML-DSA-44 (Dilithium2) reference implementation (key generation, signing)src/crypto/pat/— Post-Quantum Aggregate Transactions (logarithmic proof construction, BLAKE2b)src/wallet/pqwallet/— Post-quantum wallet module (key management, HD derivation, wallet encryption, address encoding, RPC commands)src/wallet/— Core wallet files (auxpow, hash, pow, pubkey, validation)
Assessment Summary#
The security assessment was conducted over a 22-day engagement by a multidisciplinary security engineer. The evaluation targeted memory safety, cryptographic correctness, key and wallet lifecycle management, consensus-critical logic, and operational robustness across the in-scope components.
The audit identified 30 findings — 3 Critical, 1 High, 3 Medium, and 3 Low, with 20 informational — spanning cryptographic design, wallet encryption, key derivation, memory hygiene, integer safety, and consensus validation.
Recommended remediation is organized into three priority tiers:
Immediate (Critical/High): Eliminate silent failure modes in the KDF and key derivation subsystems, implement functional HD seed-based key generation, persist KDF algorithm identifiers in the wallet file format, and correct the mainnet SegWit deployment configuration to enable witness-based Dilithium transactions.
Short-term (Medium): Harden memory handling by adopting
SecureBytesandmemory_cleanseconsistently for all buffers containing key material, passphrases, and cryptographic intermediates. Add bounds checking at allsize_t-to-intconversion boundaries, enforce block-level verification cost limits for post-quantum proof types, and extend HMAC coverage to include all encryption parameters.Longer-term (Low/Structural): Validate RPC input ranges, implement atomic file write operations for wallet persistence, and remove unreachable code paths from the RPC execution layer.
Test Approach and Methodology#
The assessment followed a layered methodology combining manual expert analysis with automated tooling to maximize coverage across the in-scope components.
Phase 1 — Specification Review and Threat Modeling. The engagement began with a review of project documentation, protocol specifications, and design logs to establish intended behaviors, trust boundaries, and the threat model. Key documents included the wallet cryptographic specification, PAT architecture, consensus cost specification, and the HD key derivation design log.
Phase 2 — Manual Code Review. Security engineers performed line-by-line review of consensus-critical and cryptographic code paths, including the Dilithium signing implementation, wallet encryption and key derivation routines, HD seed derivation, PAT proof construction, and block validation logic. This phase targeted logic errors, cryptographic design flaws, key lifecycle management issues, and silent failure modes that automated tools typically cannot detect.
Phase 3 — Automated Analysis. Static analysis and automated scanning were applied to broaden surface coverage and detect common defect classes including integer overflows, type truncation, buffer boundary violations, and API misuse patterns.
Phase 4 — Targeted Validation. Where feasible, findings were validated through targeted dynamic checks and runtime simulation to confirm exploitability and assess practical impact. This included tracing execution paths for KDF fallback behavior, verifying BIP9 state machine transitions for deployment configurations, and confirming memory residue behavior for sensitive data buffers.
The effort was weighted toward manual review for high-risk code paths — particularly wallet encryption, key derivation, and consensus validation — while automated techniques provided breadth across lower-risk surface area. All findings include reproducible descriptions and actionable remediation guidance.
Risk Methodology#
- 5 - Almost certain an incident will occur.
- 4 - High probability of an incident occurring.
- 3 - Potential of a security incident in the long term.
- 2 - Low probability of an incident occurring.
- 1 - Very unlikely issue will cause an incident.
- 5 - May cause devastating and unrecoverable impact or loss.
- 4 - May cause a significant level of impact or loss.
- 3 - May cause a partial impact or loss to many.
- 2 - May cause temporary impact or loss.
- 1 - May cause minimal or un-noticeable impact.
- 10 - CRITICAL
- 9 - 8 - HIGH
- 7 - 6 - MEDIUM
- 5 - 4 - LOW
- 3 - 1 - VERY LOW AND INFORMATIONAL
Scope#
Assessment Summary & Findings Overview#
Impact x Likelihood
HAL-05
HAL-01
HAL-02
HAL-03
HAL-08
HAL-04
HAL-09
HAL-06
HAL-07
HAL-10
HAL-11
HAL-12
HAL-13
HAL-14
HAL-15
HAL-16
HAL-17
HAL-18
HAL-19
HAL-20
HAL-21
HAL-22
HAL-23
HAL-24
HAL-25
HAL-26
HAL-27
HAL-28
HAL-29
HAL-30
# | Title | Severity | Score | Status |
|---|---|---|---|---|
| Out-of-Bounds Access in pat::VerifyLogarithmicProof | Critical | 5×5 | Solved02/23/2026 | |
| PAT proof allows forged signature - unforgeability bypass | Critical | 5×5 | Solved02/23/2026 | |
| PAT Merkle tree uses zero padding leads to possible chain-split | Critical | 5×5 | Solved03/08/2026 | |
| XOR-Based Key Aggregation Permits Rogue-Key Forgery | High | 7.3 | Solved03/18/2026 | |
| Heap buffer overflow in crypto_sign_open | Medium | 5×2 | Solved03/08/2026 | |
| KDF Algorithm Not Persisted in Wallet File Format | Medium | 6.3 | Solved03/18/2026 | |
| Non-Deterministic Address Generation Breaks Seed Recovery | Medium | 6.3 | Solved | |
| Simple-mode PAT verifier is forgeable | Low | 4×1 | Solved | |
| crypto_sign() unconditionally increments *smlen on error | Low | 3×2 | Solved | |
| Blinding Factor Collision from Index Truncation | Low | 2.5 | Solved | |
| Silent KDF Failure Produces All-Zero Encryption Key | Informational | 0.6 | Solved03/18/2026 | |
| DeriveFromSeed Returns Zeroed Keypair | Informational | 0.6 | Solved | |
| Entropy-Based Key Generation Silently Falls Back to Random | Informational | 0.6 | Solved | |
| Integer Overflow in RPC Timer Duration Conversion | Informational | 0.6 | Solved | |
| Non-Atomic Wallet File Write Risks Data Loss | Informational | 0.6 | Solved | |
| Unreachable Post-Command Signal in RPC Execution | Informational | 0.6 | Solved | |
| Heap Overflow via size_t-to-int Truncation in AES Decrypt | Informational | 0.5 | Solved | |
| Decrypted Private Key Material Not Wiped in DecryptFile | Informational | 0.4 | Solved | |
| Integer Overflow in Deserialize Bounds Check on 32-bit Platforms | Informational | 0.4 | Solved | |
| HMAC Authentication Tag Does Not Cover KDF Salt | Informational | 0.4 | Solved | |
| HMAC Intermediates Left Uncleansed on Stack | Informational | 0.4 | Solved | |
| Master Seed Residue in Uncleansed CSHA256 Stack State | Informational | 0.4 | Solved | |
| Decrypted Buffer Not Wiped on Decrypt Error Paths | Informational | 0.4 | Solved | |
| Plaintext Leaked via Vector Reallocation in Encrypt | Informational | 0.4 | Solved | |
| Passphrase Handled as std::string Instead of SecureString | Informational | 0.4 | Solved | |
| Dilithium Secret Key Material Not Zeroized on Stack | Informational | 0.4 | Solved | |
| Integer Overflow in Fee Estimation RPC Parameters | Informational | 0.3 | Solved | |
| Missing Negative Value Validation on Channel Capacity | Informational | 0.3 | Solved | |
| Wallet Plaintext Not Wiped on EncryptFile Output Failure | Informational | 0.2 | Solved | |
| Derived Key Residue on Stack Without NRVO | Informational | 0.2 | Solved |
Findings & Tech Details#
Description
Proof of Concept
Recommendation
Remediation Comment
Description
Proof of Concept
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Proof of Concept
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Description
Recommendation
Remediation Comment
Disclaimer#
Halborn strongly recommends conducting a follow-up assessment of the project either within six months or immediately following any material changes to the codebase, whichever comes first. This approach is crucial for maintaining the project’s integrity and addressing potential vulnerabilities introduced by code modifications.
