Where
AND
-Infinity
0
Severity
7.5
Buffer Overflow
AV:N/AC:L/Au:N/C:P/I:P/A:P

Stack-based buffer overflow in the filecompress function in minigzip (Modules/zlib) in Python 2.5 allows context-dependent attackers to execute arbitrary code via a long file argument.

First published (updated )
Severity
7.5
Integer Overflow
AV:N/AC:L/Au:N/C:P/I:P/A:P

Multiple integer overflows in Python 2.5.2 and earlier allow context-dependent attackers to have an unknown impact via vectors related to the (1) stringobject, (2) unicodeobject, (3) bufferobject, (4) longobject, (5) tupleobject, (6) stropmodule, (7) gcmodule, and (8) mmapmodule modules. NOTE: The expandtabs integer overflows in stringobject and unicodeobject in 2.5.2 are covered by CVE-2008-5031.

First published (updated )
Severity
5.8
Integer Overflow, Buffer Overflow
AV:N/AC:M/Au:N/C:P/I:N/A:P

Common Vulnerabilities and Exposures assigned an identifier CVE-2007-4965 to the following vulnerability:

Multiple integer overflows in the imageop module in Python 2.5.1 and earlier allow context-dependent attackers to cause a denial of service (application crash) and possibly obtain sensitive information (memory contents) via crafted arguments to (1) the tovideo method, and unspecified other vectors related to (2) imageop.c, (3) rbgimgmodule.c, and other files, which trigger heap-based buffer overflows.

References: http://lists.grok.org.uk/pipermail/full-disclosure/2007-September/065826.html http://www.securityfocus.com/bid/25696

Upstream bug report for the issue: http://bugs.python.org/issue1179

1 / 2
Source: Red Hat
First published (updated )
Severity
5
AV:N/AC:L/Au:N/C:P/I:N/A:N

Description of problem:

Modules/localemodule.c:361 356 n1 = strlen(s) + 1; 357 buf = PyMemMalloc(n1); 358 if (!buf) 359 return PyErrNoMemory(); 360 n2 = strxfrm(buf, s, n1);

In case the transformed string is longer than original string... (see the PoC for an exapmle)

361 if (n2 > n1) { 362 / more space needed /

We allocate n2 bytes here:

363 buf = PyMemRealloc(buf, n2); 364 if (!buf) 365 return PyErrNoMemory();

And here the string will be n2 chars long and terminating NUL won't fit and thus the string won't be terminated what can lead to an information leak in certain rare cases (see the original Debian report for details).

366 strxfrm(buf, s, n2); 367 } 368 result = PyStringFromString(buf); 369 PyMemFree(buf); 370 return result; 371 } 372 373 #if defined(MSWINDOWS) 374 static PyObject 375 PyLocalegetdefaultlocale(PyObject self)

Version-Release number of selected component (if applicable):

FC5, FC6, RHEL2.1, RHEL3, RHEL4, RHEL5

How reproducible:

Proof of concept code attached.

Additional info:

See the URL for an original bug report to Debian and PoC by Piotr Engelking. It contains details on how to reproduce and recognize the flaw.

1 / 2
Source: Red Hat
First published (updated )
Severity
5
Integer Overflow
AV:N/AC:L/Au:N/C:N/I:N/A:P

Multiple integer overflows in the PyOSvsnprintf function in Python/mysnprintf.c in Python 2.5.2 and earlier allow context-dependent attackers to cause a denial of service (memory corruption) or have unspecified other impact via crafted input to string formatting operations. NOTE: the handling of certain integer values is also affected by related integer underflows and an off-by-one error.

First published (updated )
EOL
May 26, 2011

End of life: 5/26/2011, Latest version: 2.5.6

First published (updated )

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203