HP Printers are common home and business printers. More information can be found at the vendor's website:
Remote exploitation of a directory traversal vulnerability in Hewlett-Packard Development Co. LP (HP)'s PostScript Interpreter, as included with multiple printers and MFPs, could allow an attacker to execute arbitrary code with the privileges of the affected service.
HP Printers contain support for multiple scripting languages embedded within printed documents, including PostScript. The vulnerability occurs in the PostScript Interpreter, and allows an attacker with access to printing services to access and modify arbitrary files on the file system. When opening files, the PostScript Interpreter does not check for embedded directory traversal sequences (such as "../"). This allows a malicious print job to open, read and write to arbitrary files on the system outside of the print job "sandbox" area. Additionally, the interpreter runs with root privileges. An attacker can use this to execute arbitrary code by overwriting system libraries, or adding users to the password file.
Exploitation of this vulnerability results in the execution of arbitrary code with the privileges of the affected service, usually root. To exploit this vulnerability, an attacker requires the ability to connect to the target printer over TCP port 9100, the JetDirect port. Since port 9100 would typically be firewalled at the network perimeter, the likely attack vector is from an attacker already behind the firewall. Additionally, a remote attacker could convince a user to print a malicious document on their behalf, which would remove the need for direct access.
HP has confirmed the following printers to be vulnerable:
It is possible to disable file system access for the PostScript interpreter in the device settings.
HP has released a fix which addresses this issue. For more information, consult their advisory at the following URL:
The Common Vulnerabilities and Exposures (CVE) project has assigned the name CVE-2012-5221 to this issue. This is a candidate for inclusion in the CVE list (http://cve.mitre.org/), which standardizes names for security problems.
08/29/2012 Initial Vendor Notification
08/30/2012 Initial Vendor Reply
04/26/2013 Coordinated Public Disclosure
This vulnerability was reported to iDefense by Andrei Costin.
Get paid for vulnerability research
Free tools, research and upcoming events
Copyright © 2013 Verisign, Inc.
Permission is granted for the redistribution of this alert electronically. It may not be edited in any way without the express written consent of iDefense Verisign. If you wish to reprint the whole or any part of this alert in any other medium other than electronically, please e-mail customer service for permission.
Disclaimer: The information in the advisory is believed to be accurate at the time of publishing based on currently available information. Use of the information constitutes acceptance for use in an AS IS condition. There are no warranties with regard to this information. Neither the author nor the publisher accepts any liability for any direct, indirect, or consequential loss or damage arising from use of, or reliance on, this information.