First published: Mon Jun 19 2017(Updated: )
A flaw was found in php when creating a .phar file and configuring apache to handle phar files using php, when accessing invalid page the page name is reflected back to the user in the 404 response. This user input is not being sanitized and therefore it is vulnerable to a reflected XSS. Making, every site configured to run .phar files using php vulnerable. References: <a href="https://bugs.php.net/bug.php?id=74782">https://bugs.php.net/bug.php?id=74782</a> <a href="https://bugs.php.net/bug.php?id=74782">https://bugs.php.net/bug.php?id=74782</a> Patch: <a href="https://gist.github.com/anonymous/70d2f6bac8db576d6386bd79c1e6e081">https://gist.github.com/anonymous/70d2f6bac8db576d6386bd79c1e6e081</a>
Credit: cve@mitre.org cve@mitre.org
Affected Software | Affected Version | How to fix |
---|---|---|
redhat/php | <0:5.4.16-48.el7 | 0:5.4.16-48.el7 |
redhat/rh-php70-php | <0:7.0.27-1.el6 | 0:7.0.27-1.el6 |
redhat/rh-php70-php | <0:7.0.27-1.el7 | 0:7.0.27-1.el7 |
redhat/rh-php71-php | <0:7.1.30-1.el7 | 0:7.1.30-1.el7 |
PHP PHP | <=5.6.32 | |
PHP PHP | >=7.0.0<=7.0.26 | |
PHP PHP | >7.1.0<=7.1.12 | |
PHP PHP | =7.2.0 | |
Debian Debian Linux | =7.0 | |
Canonical Ubuntu Linux | =12.04 | |
Canonical Ubuntu Linux | =14.04 | |
Canonical Ubuntu Linux | =16.04 | |
Canonical Ubuntu Linux | =17.10 | |
PHP PHP | <7.0.30 | 7.0.30 |
redhat/php | <7.0.27 | 7.0.27 |
redhat/php | <7.1.13 | 7.1.13 |
redhat/php | <7.2.1 | 7.2.1 |
debian/php5 | ||
debian/php7.0 | ||
debian/php7.1 |
Sign up to SecAlerts for real-time vulnerability data matched to your software, aggregated from hundreds of sources.
(Appears in the following advisories)
CVE-2018-5712 is a vulnerability that allows for reflected XSS on the PHAR 404 error page in PHP.
The severity of CVE-2018-5712 is medium with a CVSS score of 6.1.
Versions before 5.6.33, 7.0.x before 7.0.27, 7.1.x before 7.1.13, and 7.2.x before 7.2.1 are affected by CVE-2018-5712.
To fix CVE-2018-5712, update your PHP version to 5.6.33 or above, 7.0.27 or above, 7.1.13 or above, or 7.2.1 or above.
You can find more information about CVE-2018-5712 in the following references: [1] [2] [3].