# CVE-2022-31015: Uncaught Exception (due to a data race) leads to process termination in Waitress

- Severity: Medium 6.5 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- 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): 1.50%, higher than 74% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2022-05-31T22:50:12.000Z
- Modified: 2026-06-17T04:44:36.567Z
- Also known as: GHSA-f5x9-8jwc-25rw, PYSEC-2022-205
- Weaknesses: CWE-248, CWE-362
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Waitress is a Web Server Gateway Interface server for Python 2 and 3. Waitress versions 2.1.0 and 2.1.1 may terminate early due to a thread closing a socket while the main thread is about to call select(). This will lead to the main thread raising an exception that is not handled and then causing the entire application to be killed. This issue has been fixed in Waitress 2.1.2 by no longer allowing the WSGI thread to close the socket. Instead, that is always delegated to the main thread. There is no work-around for this issue. However, users using waitress behind a reverse proxy server are less likely to have issues if the reverse proxy always reads the full response.

(As written by CVE List.)

## Affected

- Pylons waitress: >= 2.1.0, < 2.1.2
- waitress (PyPI): from 2.1.0 before 2.1.2; before 4f6789b035610e0552738cdc4b35ca809a592d48
- agendaless waitress: from 2.1.0 before 2.1.2

## Every score

- GitHub_M: CVSS:3.1 6.5 Medium `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- GitHub: CVSS:3.1 6.5 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- GitHub: CVSS:4.0 High `CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:H/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:N/I:N/A:H`
- NVD: CVSS:2.0 4.3 Medium `AV:N/AC:M/Au:N/C:N/I:N/A:P`

## References

- <https://github.com/Pylons/waitress/issues/374> (exploit, issue-tracking, patch, report, third-party-advisory, web)
- <https://github.com/Pylons/waitress/security/advisories/GHSA-f5x9-8jwc-25rw> (advisory, third-party-advisory, web)
- <https://github.com/Pylons/waitress/pull/377> (issue-tracking, patch, third-party-advisory, web)
- <https://github.com/Pylons/waitress/commit/4f6789b035610e0552738cdc4b35ca809a592d48> (fix, patch, third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2022-31015> (advisory)
- <https://github.com/Pylons/waitress> (package)
- <https://github.com/pypa/advisory-database/tree/main/vulns/waitress/PYSEC-2022-205.yaml> (web)

## Sources

- CVE List: [CVE-2022-31015](https://www.cve.org/CVERecord?id=CVE-2022-31015), CVE Terms of Use, modified 2025-04-22
- GitHub Advisory Database: [GHSA-f5x9-8jwc-25rw](https://github.com/advisories/GHSA-f5x9-8jwc-25rw), CC-BY-4.0, modified 2024-11-19
- NVD: [CVE-2022-31015](https://nvd.nist.gov/vuln/detail/CVE-2022-31015), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2022-205](https://osv.dev/vulnerability/PYSEC-2022-205), CC-BY-4.0, modified 2023-11-08

---

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