Dark Reading is part of the Informa Tech Division of Informa PLC

This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them.Informa PLC's registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.

Application Security //

Open Source

12/19/2018
09:35 AM
Larry Loeb
Larry Loeb
Larry Loeb
50%
50%

Jenkins Flaw Can Allow Attackers to Log In as Admins

New research from CyberArk finds a critical flaw in Jenkins servers that can allow an attacker to log in as an administrator, which can lead to any number of compromises and malicious activity.

Jenkins is an open source Java server tool that has found wide use in DevOps methodology, where software development is more automated to allow for testing and continuous updating and delivery.

One can set up Jenkins to automatically watch for any code changes that occur in places such as Apache Subversion (SVN) and GitHub, automatically do a code build using a tool like Maven, run static code tests, as well as utilize container technology such as Docker and Kubernetes. Further, it can take actions on production installs such as rolling back or rolling forward.

Quite the useful item when new versions of software routinely appear.

Using the "x-jenkins" search string in Shodan shows over 78,000 installations world-wide that are Internet-facing. One vendor in the Jenkins community finds there are more than 165,000 active installations and an estimated 1.65 million users around the world as of February.

Now, however, researchers at CyberArk have found that Jenkins has had some serious problems inside of it, even though it has been around since 2005 -- albeit in different forms.

The critical problems would allow attackers to gain admin status or log in with invalid credentials, allowing them to take over the server.

CyberArk researchers first identified the problem -- CVE-2018-1999001 -- which allowed attackers to provide crafted login credentials that would cause Jenkins to move the startup configuration (config.xml) file from the Jenkins home directory.

On restart without the configuration file, it will be running in the "Security Disabled" mode. This mode requires no authentication, and considers any actor with access to the Jenkins master program an administrator.

A problem, to be sure.

How would an attacker force a restart to happen so that they may exploit this?

It can because of another bug that CyberArk found -- CVE-2018-1999043 -- which will crash the Java virtual machine. By using the Curl command with very long usernames, CyberArk showed that they able to crash the Java virtual machine due to low memory. That meant that an attacker could force the Jenkins admin to restart the Jenkins server whenever they wanted after moving the configuration file.

But wait, there's more.

Once restarted, the attacker could then copy the previously moved config.xml file back into its original place. If done at the right time and quickly enough, security configurations would be restored without any trace that there had been a time period where the security master switch was not enabled. Very stealthy and untraceable.

Of course, when security is not in an enabled state attackers can carry out their nefarious activities, including slapping a cryptominer onto it, or installing a backdoor.

Even though these two problems were corrected in recent patched Jenkins distributions, a more targeted search on Shodan shows that thousands of unpatched Jenkins versions are still out there, which are still at risk from these two vulnerabilities.

This is what is so often seen after a security problem has been patched: the patch may not get applied to vulnerable systems. Yet again, security teams need to make sure that the latest versions of a program are the ones that are in use or pay the price.

Related posts:

— Larry Loeb has written for many of the last century's major "dead tree" computer magazines, having been, among other things, a consulting editor for BYTE magazine and senior editor for the launch of WebWeek.

Comment  | 
Print  | 
More Insights
Comments
Newest First  |  Oldest First  |  Threaded View
COVID-19: Latest Security News & Commentary
Dark Reading Staff 8/3/2020
Pen Testers Who Got Arrested Doing Their Jobs Tell All
Kelly Jackson Higgins, Executive Editor at Dark Reading,  8/5/2020
New 'Nanodegree' Program Provides Hands-On Cybersecurity Training
Nicole Ferraro, Contributing Writer,  8/3/2020
Register for Dark Reading Newsletters
White Papers
Video
Cartoon Contest
Current Issue
Special Report: Computing's New Normal, a Dark Reading Perspective
This special report examines how IT security organizations have adapted to the "new normal" of computing and what the long-term effects will be. Read it and get a unique set of perspectives on issues ranging from new threats & vulnerabilities as a result of remote working to how enterprise security strategy will be affected long term.
Flash Poll
The Changing Face of Threat Intelligence
The Changing Face of Threat Intelligence
This special report takes a look at how enterprises are using threat intelligence, as well as emerging best practices for integrating threat intel into security operations and incident response. Download it today!
Twitter Feed
Dark Reading - Bug Report
Bug Report
Enterprise Vulnerabilities
From DHS/US-CERT's National Vulnerability Database
CVE-2020-15820
PUBLISHED: 2020-08-08
In JetBrains YouTrack before 2020.2.6881, the markdown parser could disclose hidden file existence.
CVE-2020-15821
PUBLISHED: 2020-08-08
In JetBrains YouTrack before 2020.2.6881, a user without permission is able to create an article draft.
CVE-2020-15823
PUBLISHED: 2020-08-08
JetBrains YouTrack before 2020.2.8873 is vulnerable to SSRF in the Workflow component.
CVE-2020-15824
PUBLISHED: 2020-08-08
In JetBrains Kotlin before 1.4.0, there is a script-cache privilege escalation vulnerability due to kotlin-main-kts cached scripts in the system temp directory, which is shared by all users by default.
CVE-2020-15825
PUBLISHED: 2020-08-08
In JetBrains TeamCity before 2020.1, users with the Modify Group permission can elevate other users' privileges.