PHPMailer Input Validation Flaw Lets Remote Users Execute Arbitrary Code on the Target System
SecurityTracker Alert ID: 1037533|
SecurityTracker URL: http://securitytracker.com/id/1037533
(Links to External Site)
Updated: Dec 29 2016|
Original Entry Date: Dec 26 2016
Execution of arbitrary code via network, User access via network|
Fix Available: Yes Vendor Confirmed: Yes |
Version(s): prior to 5.2.18 [separate vulnerability in 5.2.18/5.2.19]|
A vulnerability was reported in PHPMailer. A remote user can execute arbitrary code on the target system.|
A remote user can supply specially crafted data that, when processed by the target PHPMailer class to send email, will write data containing arbitrary code to a file on the target system that can later be executed. The code will run with the privileges of the target web service.
Several 3rd party products include the vulnerable code, including WordPress, Drupal, SugarCRM, and Joomla!.
Demonstration exploit code is available at:
The original advisory is available at:
Dawid Golunski (@dawid_golunski) reported this vulnerability.
A remote user can execute arbitrary code on the target system.|
The vendor has issued a fix (5.2.18).|
[Editor's note: A vulnerability exists in the fixed version (5.2.18 and 5.2.19) and has been assigned CVE-2016-10045. A revised fix (5.2.20) is available. The original advisory is available at: https://legalhackers.com/advisories/PHPMailer-Exploit-Remote-Code-Exec-CVE-2016-10045-Vuln-Patch-Bypass.html]
The vendor advisory is available at:
Vendor URL: github.com/PHPMailer/PHPMailer/blob/master/SECURITY.md (Links to External Site)
Input validation error|
|Underlying OS: Linux (Any), UNIX (Any), Windows (Any)|
This archive entry has one or more follow-up message(s) listed below.|
Source Message Contents
Date: Mon, 26 Dec 2016 00:21:07 -0200|
Subject: [oss-security] PHPMailer < 5.2.18 Remote Code Execution [CVE-2016-10033]
PHPMailer < 5.2.18 Remote Code Execution [CVE-2016-10033]
Dawid Golunski (@dawid_golunski)
"Probably the world's most popular code for sending email from PHP!
Used by many open-source projects: WordPress, Drupal, 1CRM, SugarCRM, Yii,
Joomla! and many more"
An independent research uncovered a critical vulnerability in PHPMailer that
could potentially be used by (unauthenticated) remote attackers to achieve
remote arbitrary code execution in the context of the web server user and
remotely compromise the target web application.
To exploit the vulnerability an attacker could target common website
components such as contact/feedback forms, registration forms, password
email resets and others that send out emails with the help of a vulnerable
version of the PHPMailer class.
Responsibly disclosed to PHPMailer team.
They've released a critical security release.
If you are using an affected release update to the 5.2.18 security
release as advised at:
I know this is a bad timing and a short notice (for everyone probably ;)
I've spent most of my Christmas break working on this issue with
This has been quite a rush as one of the vendors leaked excessive
information on this vulnerability at one point which could aid
I've released a limited advisory at the link below:
This is to give people a chance to immediately patch or at least be
aware of the issue before we get closer to a working day/end of
holiday for affected users to act on this issue.
I'm planning to release the full advisory and a PoC exploit shortly so
that everyone is on the same page.
Upcoming video PoC:
For updates follow:
I'll also send another email to the list once it is published.
Patch it now before someone else patches it for you (through a reverse shell ;)