CVE-2018-19518 Command injection in n/a
Attackers can execute arbitrary OS commands via argument injection in the IMAP Toolkit if rsh is replaced by ssh and server names are untrusted.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2018-19518?
CVE-2018-19518 is a high-severity command injection vulnerability in Canonical Ubuntu Linux, published on 25 Nov 2018. Any signed-in user can exploit it over the network, with no action from the victim.
Official description
University of Washington IMAP Toolkit 2007f on UNIX, as used in imap_open() in PHP and other products, launches an rsh command (by means of the imap_rimap function in c-client/imap4r1.c and the tcp_aopen function in osdep/unix/tcp_unix.c) without preventing argument injection, which might allow remote attackers to execute arbitrary OS commands if the IMAP server name is untrusted input (e.g., entered by a user of a web application) and if rsh has been replaced by a program with different argument semantics. For example, if rsh is a link to ssh (as seen on Debian and Ubuntu systems), then the attack can use an IMAP server name containing a "-oProxyCommand" argument.
Weakness: CWE-88
Which versions are affected by CVE-2018-19518?
It affects 4 products.
Linux distribution packages (9)
php5 SUSE:Linux Enterprise Module for Web and Scripting 12 | All versions | 5.5.14-109.45.2 |
php7 SUSE:Linux Enterprise Module for Web and Scripting 12 | All versions | 7.0.7-50.56.2 |
php53 SUSE:Linux Enterprise Server 11 SP4 | All versions | 5.3.17-112.45.1 |
php53 SUSE:Linux Enterprise Server for SAP Applications 11 SP4 | All versions | 5.3.17-112.45.1 |
php53 SUSE:Linux Enterprise Software Development Kit 11 SP4 | All versions | 5.3.17-112.45.1 |
php5 SUSE:Linux Enterprise Software Development Kit 12 SP3 | All versions | 5.5.14-109.45.2 |
php7 SUSE:Linux Enterprise Software Development Kit 12 SP3 | All versions | 7.0.7-50.56.2 |
php5 SUSE:Linux Enterprise Software Development Kit 12 SP4 | All versions | 5.5.14-109.45.2 |
php7 SUSE:Linux Enterprise Software Development Kit 12 SP4 | All versions | 7.0.7-50.56.2 |
Products include Canonical Ubuntu Linux, Debian Debian Linux, Php Php, Uw-Imap Project Uw-Imap.
How do I fix CVE-2018-19518?
Apply the vendor's patch.
Upgrade, and pass arguments to programs as a list instead of through a shell. More about Command injection.
Is CVE-2018-19518 being exploited?
It is not confirmed as exploited in the wild, but public exploit code for CVE-2018-19518 exists.
Public exploit code: 1 Metasploit module, 2 Exploit-DB entries and 2 proofs of concept on GitHub.
Other vulnerabilities in Canonical Ubuntu Linux
Sources
Also known as AZL-37053, AZL-37158, CVE-2018-1000859, DEBIAN-CVE-2018-19518, DLA-1700-1, DLA-2866-1 and 7 more.