CVE-2023-41419: Privilege Escalation in Gevent

gevent Updated 02 Oct 2025

Summary

25/09/2023
Yes i
Critical
9.8

CVE-2023-41419: An issue in Gevent before version 23.9.0 allows a remote attacker to escalate privileges via a crafted script to the WSGIServer component. Affects gevent across 2 version ranges.

< 2f53c851eaf926767fbac62385615efd4886221c < 23.9.0

Fixed in 2f53c851eaf926767fbac62385615efd4886221c. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

Gevent is a Python library that provides a high-level synchronous API on top of the libev or libuv event loop. It is commonly used for concurrent networking and distributed task scheduling. Gevent's WSGIServer component is responsible for serving WSGI applications over HTTP. This vulnerability affects Gevent versions prior to 23.9.1.

Vulnerability Detail

The vulnerability in Gevent allows a remote attacker to escalate privileges by exploiting a flaw in the WSGIServer component. By sending a specially crafted script, the attacker can execute arbitrary code with elevated privileges. This can lead to unauthorized access, data leakage, or further compromise of the affected system.

How To Fix

Minimum fixed version

2f53c851eaf926767fbac62385615efd4886221c

This is the first release that contains the fix.

pip install --upgrade "gevent==2f53c851eaf926767fbac62385615efd4886221c"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If upgrading Gevent is not immediately feasible, a possible workaround is to implement network-level controls to restrict access to the affected WSGIServer component. This can be achieved by using firewalls or other network security measures to limit incoming connections to trusted sources only.

Conclusion

In conclusion, the vulnerability in Gevent's WSGIServer component can be exploited by a remote attacker to escalate privileges. It is crucial to upgrade to the latest version of Gevent or implement network-level controls to mitigate the risk. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for gevent →

Share this vulnerability

FAQ

Gevent is a Python library that provides a high-level synchronous API for concurrent networking and distributed task scheduling.

The WSGIServer component in Gevent is responsible for serving WSGI applications over HTTP.

The vulnerability occurs due to a flaw in the WSGIServer component, which can be exploited by sending a specially crafted script.

The vulnerability can allow a remote attacker to escalate privileges, leading to unauthorized access, data leakage, or further compromise of the affected system.

To fix this vulnerability, it is recommended to upgrade Gevent to version 23.9.1 or later.

How To Fix

Minimum fixed version

2f53c851eaf926767fbac62385615efd4886221c

This is the first release that contains the fix.

pip install --upgrade "gevent==2f53c851eaf926767fbac62385615efd4886221c"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback