The errorlog function in basicfunctions.c in PHP before 4.4.4 and 5.x before 5.1.5 allows local users to bypass safe mode and openbasedir restrictions via a "php://" or other scheme in the third argument, which disables safe mode.
A security flaw was found in the way SOAP parser of PHP processed certain SOAP objects (due to allowed expansion of XML external entities during SOAP WSDL files parsing, it was previously possible to read arbitrary system files, accessible with the privileges of the PHP application). If a PHP application accepted untrusted SOAP object input remotely from clients, an attacker could use this flaw for unauthorized of read system files (accesible with the privileges of the PHP application).
References: [1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=702221 [2] https://bugs.gentoo.org/showbug.cgi?id=459904 [3] http://www.mandriva.com/en/support/security/advisories/advisory/MDVSA-2013:016/
Relevant upstream patch: [4] http://git.php.net/?p=php-src.git;a=commitdiff;h=c737b89473df9dba6742b8fc8fbf6d009bf05c36
sapi/cgi/cgimain.c in PHP before 5.3.13 and 5.4.x before 5.4.3, when configured as a CGI script (aka php-cgi), does not properly handle query strings that lack an = (equals sign) character, which allows remote attackers to cause a denial of service (resource consumption) by placing command-line options in the query string, related to lack of skipping a certain phpgetopt for the 'T' case. NOTE: this vulnerability exists because of an incomplete fix for CVE-2012-1823.
A flaw in John the Ripper and cryptblowfish was reported [1],[2],[3] where passwords with 8-bit characters were mishandled. A password containing a single character with the 8th bit set have 1 to 3 characters immediately preceding the 8-bit character ignored (approximately 3 in 16 passwords). With more than one 8-bit character in the password, there may be more ignored characters. This can result in passwords being even easier to crack than expected. This is due to a char signedness bug in cryptblowfish.
Other programs, such as PHP Suhosin, PHP 5.3.x, and PostgreSQL's pgcrypt module, contain the vulnerable cryptblowfish code.
A fix for this flaw [4], as well as 8-bit tests [5] and a self-test at runtime [6] have been committed upstream.
[1] http://www.openwall.com/lists/oss-security/2011/06/20/2 [2] http://www.openwall.com/lists/john-dev/2011/06/20/3 [3] http://www.openwall.com/lists/john-dev/2011/06/20/5 [4] http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/glibc/cryptblowfish/cryptblowfish.c.diff?r1=1.9;r2=1.10 [5] http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/glibc/cryptblowfish/wrapper.c.diff?r1=1.9;r2=1.10 [6] http://cvsweb.openwall.com/cgi/cvsweb.cgi/Owl/packages/glibc/cryptblowfish/cryptblowfish.c.diff?r1=1.10;r2=1.11
The rfc1867posthandler function in main/rfc1867.c in PHP before 5.3.7 does not properly restrict filenames in multipart/form-data POST requests, which allows remote attackers to conduct absolute path traversal attacks, and possibly create or overwrite arbitrary files, via a crafted upload request, related to a "file path injection vulnerability."
Multiple memory leaks in the OpenSSL extension in PHP before 5.3.6 might allow remote attackers to cause a denial of service (memory consumption) via (1) plaintext data to the opensslencrypt function or (2) ciphertext data to the openssldecrypt function.
Common Vulnerabilities and Exposures assigned an identifier CVE-2011-1469 to the following vulnerability:
Unspecified vulnerability in the Streams component in PHP before 5.3.6 allows context-dependent attackers to cause a denial of service (application crash) by accessing an ftp:// URL during use of an HTTP proxy with the FTP wrapper.
References: [1] http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2011-1469 [2] http://bugs.php.net/bug.php?id=54092 [3] http://www.php.net/ChangeLog-5.php
Upstream patch: [4] http://svn.php.net/viewvc/?view=revision&revision=308734
Integer overflow in the SdnToJulian function in the Calendar extension in PHP before 5.3.6 allows context-dependent attackers to cause a denial of service (application crash) via a large integer in the first argument to the calfromjd function.
An insufficient input validation flaws was discovered in the PHP's Exif extension that allows extracting Exif data from image files: http://thread.gmane.org/gmane.comp.security.oss.general/4198
An integer overflow causes PHP to not validate offsets read from the file properly, causing it to read behind the end of the buffer. This leads to PHP interpreter crash when reading specially crafted Exif data.
Before the code over-reading the buffer is reached, PHP needs to allocate a large amount of memory (based on the components / length value read from the file). This attempt triggers the integer overflow check in safeemalloc on 32bit platforms and requires the memorylimit for the script to be set to -1 (i.e. no limit is enforced by PHP) on 64bit platforms.
Upstream commits, which include reproducers: http://svn.php.net/viewvc?view=revision&revision=308316 http://svn.php.net/viewvc?view=revision&revision=308317
The follow-up commit replaces the use of hard-coded numeric constant with INT32MAX: http://svn.php.net/viewvc?view=revision&revision=308362
This fix should first appear in upstream version 5.3.6.
Common Vulnerabilities and Exposures assigned an identifier CVE-2009-5016 to the following vulnerability:
Name: CVE-2009-5016 URL: http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2009-5016 Assigned: 20101112 Reference: MISC: http://sirdarckcat.blogspot.com/2009/10/couple-of-unicode-issues-on-php-and.html Reference: MISC: http://www.blackhat.com/presentations/bh-usa-09/VELANAVA/BHUSA09-VelaNava-FavoriteXSS-SLIDES.pdf Reference: CONFIRM: http://bugs.php.net/bug.php?id=49687
Integer overflow in the xmlutf8decode function in ext/xml/xml.c in PHP before 5.2.11 makes it easier for remote attackers to bypass cross-site scripting (XSS) and SQL injection protection mechanisms via a crafted string that uses overlong UTF-8 encoding, a different vulnerability than CVE-2010-3870.
PHP 5.2.12 was released with the following reference:
Fixed bug #49785 (insufficient input string validation of htmlspecialchars()). (CVE-2009-4142, Moriyoshi, hello at iwamot dot com)
A little more detail is available in upstream's bug report: http://bugs.php.net/bug.php?id=49785
http://www.php-security.org/MOPB/PMOPB-46-2007.html
"The sessionstart function in ext/session in PHP 4.x up to 4.4.7 and 5.x up to 5.2.3 allows remote attackers to insert arbitrary attributes into the session cookie via special characters in a cookie that is obtained from (1) PATHINFO, (2) the sessionid function, and (3) the sessionstart function, which are not encoded or filtered when the new session cookie is generated."
Better expressed as: "The sessionstart function allows a cross-site cookie insertion attack if a user follows an untrusted carefully-crafted URL"
"Affected are PHP4 <= 4.4.7 and PHP5 <= 5.2.3"
Flaw bug created to hold information about an old flaw we knew something about. For more details see the MITRE CVE description.
Flaw bug created to hold information about an old flaw we knew something about. For more details see the MITRE CVE description.
PHP before 5.3.4 accepts the \0 character in a pathname, which might allow context-dependent attackers to bypass intended access restrictions by placing a safe file extension after this character, as demonstrated by .php\0.jpg at the end of the argument to the fileexists function.
Race condition in the symlink function in PHP 5.1.6 and earlier allows local users to bypass the openbasedir restriction by using a combination of symlink, mkdir, and unlink functions to change the file path after the openbasedir check and before the file is opened by the underlying system, as demonstrated by symlinking a symlink into a subdirectory, to point to a parent directory via .. (dot dot) sequences, and then unlinking the resulting symlink.
The zendrestoreinientrycb function in zendini.c in PHP 5.3.0, 5.2.10, and earlier versions allows context-specific attackers to obtain sensitive information (memory contents) and cause a PHP crash by using the iniset function to declare a variable, then using the inirestore function to restore the variable.
The memorylimit functionality in PHP 4.x up to 4.3.7, and 5.x up to 5.0.0RC3, under certain conditions such as when registerglobals is enabled, allows remote attackers to execute arbitrary code by triggering a memorylimit abort during execution of the zendhashinit function and overwriting a HashTable destructor pointer before the initialization of key data structures is complete.
The striptags function in PHP 4.x up to 4.3.7, and 5.x up to 5.0.0RC3, does not filter null (\0) characters within tag names when restricting input to allowed tags, which allows dangerous tags to be processed by web browsers such as Internet Explorer and Safari, which ignore null characters and facilitate the exploitation of cross-site scripting (XSS) vulnerabilities.
CRLF injection vulnerability in the mbsendmail function in PHP before 5.1.0 might allow remote attackers to inject arbitrary e-mail headers via line feeds (LF) in the "To" address argument.
The exifreaddata function in the Exif module in PHP before 4.4.1 allows remote attackers to cause a denial of service (infinite loop) via a malformed JPEG image.
The parsestr function in PHP 4.x up to 4.4.0 and 5.x up to 5.0.5, when called with only one parameter, allows remote attackers to enable the registerglobals directive via inputs that cause a request to be terminated due to the memorylimit setting, which causes PHP to set an internal flag that enables registerglobals and allows attackers to exploit vulnerabilities in PHP applications that would otherwise be protected.
Cross-site scripting (XSS) vulnerability in the phpinfo function in PHP 4.x up to 4.4.0 and 5.x up to 5.0.5 allows remote attackers to inject arbitrary web script or HTML via a crafted URL with a "stacked array assignment."
exif.c in PHP before 4.3.11 allows remote attackers to cause a denial of service (memory consumption and crash) via an EXIF header with a large IFD nesting level, which causes significant stack recursion.
scanf.c in PHP 5.1.4 and earlier, and 4.4.3 and earlier, allows context-dependent attackers to execute arbitrary code via a sscanf PHP function call that performs argument swapping, which increments an index past the end of an array and triggers a buffer over-read.
PHP before 5.1.3-RC1 might allow remote attackers to obtain portions of memory via crafted binary data sent to a script that processes user input in the htmlentitydecode function and sends the encoded results back to the client, aka a "binary safety" issue. NOTE: this issue has been referred to as a "memory leak," but it is an information leak that discloses memory contents.
Argument injection vulnerability in certain PHP 3.x, 4.x, and 5.x applications, when used with sendmail and when accepting remote input for the additionalparameters argument to the mail function, allows remote attackers to read and create arbitrary files via the sendmail -C and -X arguments. NOTE: it could be argued that this is a class of technology-specific vulnerability, instead of a particular instance; if so, then this should not be included in CVE.
The session extension in PHP before 5.2.4 might allow local users to bypass openbasedir restrictions via a session file that is a symlink.
Buffer overflow in the makehttpsoaprequest function in PHP before 5.2.2 has unknown impact and remote attack vectors, possibly related to "/" (slash) characters.
Multiple integer signedness errors in the printf function family in PHP 4 before 4.4.5 and PHP 5 before 5.2.1 on 64 bit machines allow context-dependent attackers to execute arbitrary code via (1) certain negative argument numbers that arise in the phpformattedprint function because of 64 to 32 bit truncation, and bypass a check for the maximum allowable value; and (2) a width and precision of -1, which make it possible for the phpsprintfappendstring function to place an internal buffer at an arbitrary memory location.