---
title: "Clang-introduced secret-dependent branches in liboqs HQC leak the key (CVE-2025-52473)"
url: "https://pqt-19a6ffd695e12a.pages.dev/feed/2025-07-10-clang-introduced-secret-dependent-branches-in-li/"
date: "2025-07-10"
classification: "Implementation vulnerability · Demonstrated"
action: "Patch"
affects: ["HQC"]
site: "PQ Tracker, maintained by zkSecurity"
reviewed: "2026-11-25"
license: "https://creativecommons.org/licenses/by/4.0/"
---

# Clang-introduced secret-dependent branches in liboqs HQC leak the key (CVE-2025-52473)

2025-07-10 · Implementation vulnerability · Demonstrated · Action: patch

The HQC reference implementation in liboqs, when compiled with Clang 17 to 20 at optimization levels above -O0, contained several secret-dependent branches, and a proof-of-concept local attack recovered the entire secret key. It was fixed in liboqs 0.14.0. This is the same class of compiler-induced leak as Clangover in ML-KEM.

- Affects: [HQC](https://pqt-19a6ffd695e12a.pages.dev/algorithms/hqc/)

## Sources

- [CVE-2025-52473 record](https://www.cve.org/CVERecord?id=CVE-2025-52473)
- [liboqs advisory GHSA-qq3m-rq9v-jfgm](https://github.com/open-quantum-safe/liboqs/security/advisories/GHSA-qq3m-rq9v-jfgm)

## Related entries

- 2026-11-24 · Theoretical result · No action required · [New generic syndrome-decoding records (length 580/weight 71; quasi-cyclic weight 64)](https://pqt-19a6ffd695e12a.pages.dev/feed/2026-11-24-new-generic-syndrome-decoding-records-length-580/)
- 2026-09-29 · Policy · Action: monitor · [Germany: BSI advises against Classic McEliece in new developments after new cryptanalysis](https://pqt-19a6ffd695e12a.pages.dev/feed/2026-09-29-germany-bsi-advises-against-classic-mceliece-in/)
- 2026-07-22 · Reduced security margin · Action: monitor · [Improved ISD puts HQC-1 about 3 bits under target; HQC team raises error weights](https://pqt-19a6ffd695e12a.pages.dev/feed/2026-07-22-improved-isd-puts-hqc-1-about-3-bits-under-targe/)
- 2025-04-02 · Reduced security margin · Action: patch · [IND-CCA2 flaw in HQC's February 2025 specification: salt not covered by the FO check](https://pqt-19a6ffd695e12a.pages.dev/feed/2025-04-02-ind-cca2-flaw-in-hqc-s-february-2025-specificati/)
- 2025-03-11 · Selection · [NIST selects HQC as a second KEM; fourth round ends (NIST IR 8545)](https://pqt-19a6ffd695e12a.pages.dev/feed/2025-03-11-nist-selects-hqc-as-a-second-kem-fourth-round-en/)
- 2024-12-06 · Implementation vulnerability · Action: patch · [liboqs HQC decapsulation returned wrong secret for malformed ciphertexts (CVE-2024-54137)](https://pqt-19a6ffd695e12a.pages.dev/feed/2024-12-06-liboqs-hqc-decapsulation-returned-wrong-secret-f/)
