Executive Summary

Summary
Title PHPUnit: Remote code execution
Informations
Name GLSA-201711-15 First vendor Publication 2017-11-19
Vendor Gentoo Last vendor Modification 2017-11-19
Severity (Vendor) N/A Revision N/A

Security-Database Scoring CVSS v3

Cvss vector : N/A
Overall CVSS Score NA
Base Score NA Environmental Score NA
impact SubScore NA Temporal Score NA
Exploitabality Sub Score NA
 
Calculate full CVSS 3.0 Vectors scores

Security-Database Scoring CVSS v2

Cvss vector : (AV:N/AC:L/Au:N/C:P/I:P/A:P)
Cvss Base Score 7.5 Attack Range Network
Cvss Impact Score 6.4 Attack Complexity Low
Cvss Expoit Score 10 Authentication None Required
Calculate full CVSS 2.0 Vectors scores

Detail

Synopsis

A vulnerability was discovered in PHPUnit which may allow an unauthenticated remote attacker to execute arbitrary PHP code.

Background

PHPUnit is a programmer-oriented testing framework for PHP. It is an instance of the xUnit architecture for unit testing frameworks.

Description

When PHPUnit is installed in a production environment via composer and these modules are in a web accessible directory, the eval-stdin.php file in PHPUnit contains vulnerable statements that trigger the vulnerability.

Impact

A remote attacker could possibly execute arbitrary PHP code or cause a Denial of Service condition.

Workaround

There are several ways to fix or mitigate this vulnerability:

Remove PHPUnit from the production environment.

Update PHPUnit.

Manually apply the patch.

Disable direct access to the composer packages by placing .htaccess file to /vendor folder.

Resolution

All PHPUnit users should upgrade to the latest version:

Â
# emerge --sync
Â
# emerge --ask --oneshot --verbose ">=dev-php/phpunit-5.7.15-r1"

References

[ 1 ] CVE-2017-9841
      https://nvd.nist.gov/nvd.cfm?cvename=CVE-2017-9841

Availability

This GLSA and any updates to it are available for viewing at the Gentoo Security Website:

 https://security.gentoo.org/glsa/201711-15

Original Source

Url : http://security.gentoo.org/glsa/glsa-201711-15.xml

CWE : Common Weakness Enumeration

% Id Name
100 % CWE-94 Failure to Control Generation of Code ('Code Injection')

CPE : Common Platform Enumeration

TypeDescriptionCount
Application 9
Application 2

Snort® IPS/IDS

Date Description
2018-03-29 PHPUnit PHP remote code execution attempt
RuleID : 45749 - Revision : 2 - Type : SERVER-WEBAPP

Nessus® Vulnerability Scanner

Date Description
2017-11-20 Name : The remote FreeBSD host is missing one or more security-related updates.
File : freebsd_pkg_298829e2ccce11e792e4000c29649f92.nasl - Type : ACT_GATHER_INFO
2017-11-20 Name : The remote Gentoo host is missing one or more security-related patches.
File : gentoo_GLSA-201711-15.nasl - Type : ACT_GATHER_INFO

Alert History

If you want to see full details history, please login or register.
0
1
Date Informations
2017-11-21 13:24:01
  • Multiple Updates
2017-11-20 00:21:36
  • First insertion