GHSA-hvh4-5qr6-3v7r: Pypqc Observable Timing Discrepancy Vulnerability
HIGHGHSA-hvh4-5qr6-3v7r is a HIGH (CVSS 8.2) observable timing discrepancy vulnerability (CWE-385: Covert Timing Channel) affecting Pypqc libraries in the PyPI ecosystem. The issue involves observable timing discrepancy in pypqc. Remediation is available in the latest vendor maintenance releases.
GHSA-hvh4-5qr6-3v7r at a Glance
Security Impact
CVSS: 8.2
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N/E:P/RL:U/RC:C).
How to Fix GHSA-hvh4-5qr6-3v7r
To remediate this vulnerability, upgrade all affected Pypqc dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install pypqc>=Latest secure release
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show pypqc
How to Check if You Are Affected
To determine whether your Python environment is affected by GHSA-hvh4-5qr6-3v7r, inspect your installed packages using pip:
pip show pypqc
Analyze the terminal output to locate any version of Pypqc in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.
Note: The pip show pypqc command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-385: Covert Timing Channel, where covert timing channels convey information by modulating some aspect of system behavior over time, so that the program receiving the information can observe system behavior and infer protected information. In Pypqc, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-hvh4-5qr6-3v7r Affected Pypqc Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
pypqc
|
PyPI |
≥ 0.0.4
≤ 0.0.6.2
|
|
References
Frequently Asked Questions
What is GHSA-hvh4-5qr6-3v7r?
Which Pypqc versions are affected?
What version fixes GHSA-hvh4-5qr6-3v7r?
Is pypqc affected?
What is the CVSS score of GHSA-hvh4-5qr6-3v7r?
What CWE is associated with GHSA-hvh4-5qr6-3v7r?
How can I check PyPI dependencies for GHSA-hvh4-5qr6-3v7r?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-hvh4-5qr6-3v7r",
"modified" : "2024-06-05T18:36:15Z",
"published" : "2024-06-05T16:56:35Z",
"aliases" : [ ],
"summary" : "Observable Timing Discrepancy in pypqc",
"details" : "### Impact\n`kyber512`, `kyber768`, and `kyber1024` on Mac OS \\(or when compiled with clang\\) only: An attacker able to submit many decapsulation requests against a single private key, and to gain timing information about the decapsulation, could recover the private key. Proof-of-concept exploit exists for a local attacker.\n\nCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N/E:P/RL:U/RC:C \n\n### Patches\nNo patch is currently available / pending upstream [PQClean#556](https://github.com/PQClean/PQClean/issues/556).\n\n### Workarounds\nNo workarounds have been reported. The 0.0.7 -> 0.0.7.1 upgrade, when available, should be a drop-in replacement<!--; it has no known breaking changes-->.\n\n### References\n\nhttps://pqshield.com/pqshield-plugs-timing-leaks-in-kyber-ml-kem-to-improve-pqc-implementation-maturity/\n\nhttps://github.com/antoonpurnal/clangover\n\nhttps://www.github.com/PQClean/PQClean/issues/556\n\nhttps://www.github.com/pq-crystals/kyber/commit/9b8d30698a3e7449aeb34e62339d4176f11e3c6c",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:N/E:P/RL:U/RC:C"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "pypqc"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0.0.4"
}, {
"last_affected" : "0.0.6.2"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/JamesTheAwesomeDude/pypqc/security/advisories/GHSA-hvh4-5qr6-3v7r"
}, {
"type" : "WEB",
"url" : "https://github.com/PQClean/PQClean/issues/556"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/JamesTheAwesomeDude/pypqc"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-385", "CWE-733" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2024-06-05T16:56:35Z",
"nvd_published_at" : null
}
}