# CVE-2022-24302: Race Condition in Paramiko

- Severity: Medium 5.9 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 2.08%, higher than 82% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2022-03-17T21:02:10.000Z
- Modified: 2026-06-17T04:31:34.943Z
- Also known as: GHSA-f8q4-jwww-x3wv, PYSEC-2022-166
- Weaknesses: CWE-362
- Assigned by: mitre

## Description

In Paramiko before 2.10.1, a race condition (between creation and chmod) in the write_private_key_file function could allow unauthorized information disclosure.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- paramiko (PyPI): from 2.10.0 before 2.10.1; from 2.9.0 before 2.9.3; before 2.9.3
- paramiko paramiko: before 2.10.1
- debian debian_linux: 9.0; 10.0
- fedoraproject fedora: 34; 35; 36

## Every score

- GitHub: CVSS:3.1 5.9 High `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N`
- GitHub: CVSS:4.0 High `CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N`
- NVD: CVSS:3.1 5.9 Medium `CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N`
- NVD: CVSS:2.0 4.3 Medium `AV:N/AC:M/Au:N/C:P/I:N/A:N`

## References

- <https://github.com/paramiko/paramiko/blob/363a28d94cada17f012c1604a3c99c71a2bda003/paramiko/pkey.py#L546> (exploit, third-party-advisory, web)
- <https://www.paramiko.org/changelog.html> (release-notes, vendor-advisory, web)
- <https://lists.debian.org/debian-lts-announce/2022/03/msg00032.html> (mailing-list, third-party-advisory, web)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/U63MJ2VOLLQ35R7CYNREUHSXYLWNPVSB/> (vendor-advisory)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/LUEUEGILZ7MQXRSUF5VMMO4SWJQVPTQL/> (vendor-advisory)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/TPMKRUS4HO3P7NR7P4Y6CLHB4MBEE3AI/> (vendor-advisory)
- <https://lists.debian.org/debian-lts-announce/2022/09/msg00013.html> (mailing-list, third-party-advisory, web)
- <https://lists.debian.org/debian-lts-announce/2025/12/msg00020.html> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2022-24302> (advisory)
- <https://github.com/paramiko/paramiko/commit/4c491e299c9b800358b16fa4886d8d94f45abe2e> (web)
- <https://github.com/advisories/GHSA-f8q4-jwww-x3wv> (advisory)
- <https://github.com/paramiko/paramiko> (package)
- <https://github.com/pypa/advisory-database/tree/main/vulns/paramiko/PYSEC-2022-166.yaml> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/LUEUEGILZ7MQXRSUF5VMMO4SWJQVPTQL> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/TPMKRUS4HO3P7NR7P4Y6CLHB4MBEE3AI> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/U63MJ2VOLLQ35R7CYNREUHSXYLWNPVSB> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/LUEUEGILZ7MQXRSUF5VMMO4SWJQVPTQL> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/TPMKRUS4HO3P7NR7P4Y6CLHB4MBEE3AI> (web)
- <https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/U63MJ2VOLLQ35R7CYNREUHSXYLWNPVSB> (web)

## Sources

- CVE List: [CVE-2022-24302](https://www.cve.org/CVERecord?id=CVE-2022-24302), CVE Terms of Use, modified 2025-12-16
- GitHub Advisory Database: [GHSA-f8q4-jwww-x3wv](https://github.com/advisories/GHSA-f8q4-jwww-x3wv), CC-BY-4.0, modified 2025-12-20
- NVD: [CVE-2022-24302](https://nvd.nist.gov/vuln/detail/CVE-2022-24302), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2022-166](https://osv.dev/vulnerability/PYSEC-2022-166), CC-BY-4.0, modified 2023-11-08

---

Page: https://cve.day/CVE-2022-24302 · Whole record: https://cve.day/CVE-2022-24302.json · Rebuilt by cve.day 2026-11-25T22:58:10.157Z
