{"id":"CVE-2022-31015","published":"2022-05-31T22:50:12Z","modified":"2025-04-22T17:55:26Z","title":"Uncaught Exception (due to a data race) leads to process termination in Waitress","vendor":"Pylons","product":"waitress","tier":"tail","description":{"text":"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.","provenance":"source","from":"CVE.org"},"cvss":{"score":6.5,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.01498,"percentile":0.74858,"provenance":"source"},"cwes":[{"id":"CWE-248","name":"Uncaught Exception"},{"id":"CWE-362","name":"Concurrent Execution using Shared Resource with Improper Synchronization"}],"references":[{"url":"https://github.com/Pylons/waitress/security/advisories/GHSA-f5x9-8jwc-25rw","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/Pylons/waitress/issues/374","tags":["x_refsource_MISC"]},{"url":"https://github.com/Pylons/waitress/pull/377","tags":["x_refsource_MISC"]},{"url":"https://github.com/Pylons/waitress/commit/4f6789b035610e0552738cdc4b35ca809a592d48","tags":["x_refsource_MISC"]}],"priority":{"score":19.5,"factors":[{"name":"EPSS percentile","points":14.97},{"name":"CVSS severity","points":4.55}]},"vendorSlug":"pylons","affectedVersions":[{"vendor":"Pylons","product":"waitress","versions":[">= 2.1.0, < 2.1.2"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"partial","timestamp":"2025-04-22T15:46:10.856460Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"PyPI","package":"waitress","vulnerableRanges":[">=2.1.0, <2.1.2"],"patched":["2.1.2"],"from":["GHSA-f5x9-8jwc-25rw","PYSEC-2022-205"],"provenance":"source"}],"summary":{"text":"A data race in Waitress versions 2.1.0 and 2.1.1, a Python WSGI server, can cause a thread to close a socket while the main thread is about to call select(), leading to an unhandled exception that terminates the entire application. An attacker with network access and low-privilege authentication can trigger the condition, with no user interaction or special configuration needed, to crash the service; the issue is fixed in Waitress 2.1.2.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T07:17:27Z"},"euvd":{"id":"EUVD-2022-0359","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-pylons-waitress-cve-2022-31015","children":[{"from":"CVE-2022-31015","to":"CVE-2024-49768","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["src/waitress/channel.py"],"commits":["https://github.com/Pylons/waitress/commit/4f6789b035610e0552738cdc4b35ca809a592d48","https://github.com/Pylons/waitress/commit/e4359018537af376cf24bd13616d861e2fb76f65"],"basis":"shared function","functions":["received"]}]},{"from":"CVE-2022-31015","to":"CVE-2024-49769","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["src/waitress/channel.py","src/waitress/wasyncore.py"],"commits":["https://github.com/Pylons/waitress/commit/4f6789b035610e0552738cdc4b35ca809a592d48","https://github.com/Pylons/waitress/commit/1ae4e894c9f76543bee06584001583fc6fa8c95c"],"basis":"shared function","functions":["handle_write"]}]}],"packageHistory":[{"cve":"CVE-2019-16789","published":"2019-12-26","fixed":"1.4.2","kev":false},{"cve":"CVE-2020-5236","published":"2020-02-04","fixed":"1.4.3","kev":false},{"cve":"CVE-2022-24761","published":"2022-03-17","fixed":"2.1.1","kev":false,"link":{"from":"CVE-2022-24761","to":"CVE-2022-31015","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"PyPI:waitress","fromFixed":"2.1.1","toFixed":"2.1.2","daysApart":75}]}},{"cve":"CVE-2022-31015","published":"2022-05-31","fixed":"2.1.2","kev":false},{"cve":"CVE-2024-49768","published":"2024-10-29","fixed":"3.0.1","kev":false},{"cve":"CVE-2024-49769","published":"2024-10-29","fixed":"3.0.1","kev":false}],"package":"PyPI:waitress"}}