CVE-2007-2052: Off-by-one error in the PyLocale_strxfrm function in Modules/_localemodule.c for Python 2.4 and 2.5 causes an incorrect buffer size to be…
Noroxi assessment
Priority: Monitor (action score 24/100)
- Public proof-of-concept code exists (Exploit-DB); there is no record of exploitation in the wild.
- Probability of exploitation in the next 30 days: 14% (FIRST EPSS); higher than 96.6% of all records.
- No special conditions are required; it is repeatable.
- Fixed version: python2.4 (Debian:4.0) 2.4.4-3+etch1; python2.5 (Debian:4.0) 2.5-5+etch1; python (openSUSE:Tumbleweed) 2.7.18-8.1.
Low priority for now. Upgrade to python2.4 (Debian:4.0) 2.4.4-3+etch1; python2.5 (Debian:4.0) 2.5-5+etch1; python (openSUSE:Tumbleweed) 2.7.18-8.1 or later.
Generated automatically from the record's data: CVSS (NVD and CNA), CISA KEV and SSVC, FIRST EPSS, exploit sources, fixed versions. How we calculate it
Primary sources: NVD · CVE.org · FIRST EPSS
Off-by-one error in the PyLocale_strxfrm function in Modules/_localemodule.c for Python 2.4 and 2.5 causes an incorrect buffer size to be used for the strxfrm function, which allows context-dependent attackers to read portions of memory via unknown manipulations that trigger a buffer over-read due to missing null termination.
- Published
- Apr 16, 2007
- Updated
- Jun 16, 2026
- EPSS
- 14.0% · 96th percentile
- CWE
- CWE-193
Report tools
Action score
24
Low priority for now.
- CVSS
- 20 / 40 · 5.0 / 10
- CISA KEV
- 0 / 30 · Not listed
- EPSS
- 4 / 30 · 14.0%
Get told when this record changes
- Not in KEV: no record of exploitation in the wild
- Proof of concept exists, no weaponized module
- A fix has been released
If any of these changes, we'll tell you in the daily email digest.
Is your version affected? Check itNoroxi analysis
What does it mean in your environment?
The assessment above is generated automatically from the record's data; it doesn't know your environment. Our team verifies on your systems whether this vulnerability is actually exploitable and which mitigation is enough.
We use this product, ask for helpAffected systems
Is your version affected?
Pick the product and type the version you run. It's compared with this record's version ranges in your browser; the version isn't sent anywhere.
| Vendor | Product | CPE |
|---|---|---|
| python | python | cpe:2.3:a:python:python |
Affected versions
NVD version ranges (for catalog products). Add the product to your stack with a version and matching uses these.
- python python2.4.0
- python python2.5.0
Package-level exposure
OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.
| Ecosystem | Package | Affected range | Fix |
|---|---|---|---|
| Debian:4.0 | python2.4 | before 2.4.4-3+etch1 | 2.4.4-3+etch1 |
| Debian:4.0 | python2.5 | before 2.5-5+etch1 | 2.5-5+etch1 |
| openSUSE:Tumbleweed | python | before 2.7.18-8.1 | 2.7.18-8.1 |
| Red Hat:enterprise_linux:2.1::as | python | before 0:1.5.2-43.72.2 | 0:1.5.2-43.72.2 |
| Red Hat:enterprise_linux:2.1::as | python-devel | before 0:1.5.2-43.72.2 | 0:1.5.2-43.72.2 |
| Red Hat:enterprise_linux:2.1::as | python-docs | before 0:1.5.2-43.72.2 | 0:1.5.2-43.72.2 |
| Red Hat:enterprise_linux:2.1::as | python-tools | before 0:1.5.2-43.72.2 | 0:1.5.2-43.72.2 |
| Red Hat:enterprise_linux:2.1::as | tkinter | before 0:1.5.2-43.72.2 | 0:1.5.2-43.72.2 |
| Red Hat:enterprise_linux:3::as | python | before 0:2.2.3-6.8 | 0:2.2.3-6.8 |
| Red Hat:enterprise_linux:3::as | python-debuginfo | before 0:2.2.3-6.8 | 0:2.2.3-6.8 |
| Red Hat:enterprise_linux:3::as | python-devel | before 0:2.2.3-6.8 | 0:2.2.3-6.8 |
| Red Hat:enterprise_linux:3::as | python-tools | before 0:2.2.3-6.8 | 0:2.2.3-6.8 |
| Red Hat:enterprise_linux:3::as | tkinter | before 0:2.2.3-6.8 | 0:2.2.3-6.8 |
| Red Hat:enterprise_linux:4::as | python | before 0:2.3.4-14.4.el4_6.1 | 0:2.3.4-14.4.el4_6.1 |
| Red Hat:enterprise_linux:4::as | python-debuginfo | before 0:2.3.4-14.4.el4_6.1 | 0:2.3.4-14.4.el4_6.1 |
| Red Hat:enterprise_linux:4::as | python-devel | before 0:2.3.4-14.4.el4_6.1 | 0:2.3.4-14.4.el4_6.1 |
| Red Hat:enterprise_linux:4::as | python-docs | before 0:2.3.4-14.4.el4_6.1 | 0:2.3.4-14.4.el4_6.1 |
| Red Hat:enterprise_linux:4::as | python-tools | before 0:2.3.4-14.4.el4_6.1 | 0:2.3.4-14.4.el4_6.1 |
| Red Hat:enterprise_linux:4::as | tkinter | before 0:2.3.4-14.4.el4_6.1 | 0:2.3.4-14.4.el4_6.1 |
| Red Hat:enterprise_linux:5::client | python-tools | before 0:2.4.3-24.el5_3.6 | 0:2.4.3-24.el5_3.6 |
| Red Hat:enterprise_linux:5::client | tkinter | before 0:2.4.3-24.el5_3.6 | 0:2.4.3-24.el5_3.6 |
| Red Hat:enterprise_linux:5::client_workstation | python | before 0:2.4.3-24.el5_3.6 | 0:2.4.3-24.el5_3.6 |
| Red Hat:enterprise_linux:5::client_workstation | python-debuginfo | before 0:2.4.3-24.el5_3.6 | 0:2.4.3-24.el5_3.6 |
| Red Hat:enterprise_linux:5::client_workstation | python-devel | before 0:2.4.3-24.el5_3.6 | 0:2.4.3-24.el5_3.6 |
+6
Same product
python: all recordsOther highest-scoring records for the same primary product.
- CVE-2016-5636Integer overflow in the get_data function in zipimport.c in CPython (aka Python) before 2.7.12, 3.x before 3.4.5, and 3.5.x before 3.5.2…47Plan
- CVE-2007-4559Directory traversal vulnerability in the (1) extract and (2) extractall functions in the tarfile module in Python allows user-assisted…47Plan
- CVE-2021-3177Python 3.x through 3.9.1 has a buffer overflow in PyCArg_repr in _ctypes/callproc.c, which may lead to remote code execution in certain…46Plan
Published before and after this one in the same product
- ← EarlierCVE-2006-1542Mar 30, 2006 · Stack-based buffer overflow in Python 2.4.2 and earlier, running on Linux 2.6.12.5 under gcc 4.0.3 with libc 2.3.5, allows local users to…14Monitor
- ← EarlierCVE-2006-4980Oct 10, 2006 · Buffer overflow in the repr function in Python 2.3 through 2.6 before 20060822 allows context-dependent attackers to cause a denial of…32Monitor
- Later →CVE-2007-4965Sep 18, 2007 · Multiple integer overflows in the imageop module in Python 2.5.1 and earlier allow context-dependent attackers to cause a denial of service…27Monitor
Remediation
Which version to upgrade to
Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.
| Product / package | Fixed version | Source |
|---|---|---|
| debian:python2.4 | 2.4.4-3+etch1 · Debian:4.0 | Package registry (OSV) |
| debian:python2.5 | 2.5-5+etch1 · Debian:4.0 | Package registry (OSV) |
| opensuse:python | 2.7.18-8.1 · openSUSE:Tumbleweed | Package registry (OSV) |
| red hat:python | 0:2.2.3-6.8 · Red Hat:enterprise_linux:3::as | Package registry (OSV) |
| red hat:python-debuginfo | 0:2.2.3-6.8 · Red Hat:enterprise_linux:3::as | Package registry (OSV) |
| red hat:python-devel | 0:2.2.3-6.8 · Red Hat:enterprise_linux:3::as | Package registry (OSV) |
| red hat:python-docs | 0:2.3.4-14.4.el4_6.1 · Red Hat:enterprise_linux:4::as | Package registry (OSV) |
| red hat:python-tools | 0:2.2.3-6.8 · Red Hat:enterprise_linux:3::as | Package registry (OSV) |
| red hat:rhn_solaris_bootstrap_5_0_2_3 | 0:1-0 · Red Hat:network_satellite:5.0:el4 | Package registry (OSV) |
| red hat:rhn_solaris_bootstrap_5_1_1_3 | 0:1-0 · Red Hat:network_satellite:5.1::el4 | Package registry (OSV) |
| red hat:rhn-solaris-bootstrap | 0:5.0.2-3 · Red Hat:network_satellite:5.0:el4 | Package registry (OSV) |
| red hat:tkinter | 0:2.2.3-6.8 · Red Hat:enterprise_linux:3::as | Package registry (OSV) |
| suse:python | 2.7.17-7.32.2 · SUSE:Linux Enterprise Module for Basesystem 15 | Package registry (OSV) |
| suse:python-base | 2.7.17-7.32.1 · SUSE:Linux Enterprise Module for Basesystem 15 | Package registry (OSV) |
Exploit status
Proof of concept available
A public proof of concept or detection signature exists. Exploit knowledge is out there; don't delay patching.
Evidence
- Exploit-DB entry ×1
Noroxi does not host or link to exploit code. Metasploit module names and Nuclei template ids are shown (names, not code); Exploit-DB entries and PoC repositories are given as counts only.
| Source | Kind | Date |
|---|---|---|
| Exploit-DB entry | remote | 2007-05-08 |
Research context
For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.
Timeline
From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.
- Published
- First PoC+21 d
- TodayNov 16, 2026+7153 d
FIRST EPSS daily score; only changes of 0.01 or more are recorded (step chart).
Not on record for this CVE: patch commit or PR link · researcher credit · variant or chain candidate · public bounty program.
Technical details
Attack conditions
- No special conditions are required; it is repeatable.
If successful
- Confidentiality
- P · data can be read
- Integrity
- none
- Availability
- none
- Attack complexity
- Low
- Confidentiality impact
- P
- Integrity impact
- None
- Availability impact
- None
Weakness class (CWE)
CWE-193 · Off-by-one ErrorCVSS vector
AV:N/AC:L/Au:N/C:P/I:N/A:N
nvd-primary
Attack context
MITRE CAPEC attack patterns and ATT&CK techniques for this weakness class (CWE). A starting point for detection rules and threat hunting.
MITRE has no CAPEC/ATT&CK mapping for this CWE.
Change log (1)
- Fix✗ → ✓
For records you follow, these changes also arrive as notifications. →
References
Show all references (19 more)Show less
- lists.vmware.com/pipermail/security-announce/2008/000005.html
- secunia.com/advisories/25190
- secunia.com/advisories/25217
- secunia.com/advisories/25233
- secunia.com/advisories/25353
- secunia.com/advisories/25787
- secunia.com/advisories/28027
- secunia.com/advisories/28050
- secunia.com/advisories/29032
- secunia.com/advisories/29303
- secunia.com/advisories/29889
- secunia.com/advisories/31255
- secunia.com/advisories/31492
- secunia.com/advisories/37471
- www.debian.org/security/2008/dsa-1551
- www.debian.org/security/2008/dsa-1620
- www.mandriva.com/security/advisories?name=MDKSA-2007:099
- www.novell.com/linux/security/advisories/2007_13_sr.html
- www.python.org/download/releases/2.5.1/NEWS.txt
Vendor advisories and official records. Exploit/PoC links are deliberately left out.