Crowd Security Advisory 2017-03-10

Crowd - CVE-2017-5638

Summary

CVE-2017-5638 - Remote code execution in Crowd

Advisory Release Date

 10 AM PDT (Pacific Time, -7 hours)

Product

Crowd. (CrowdID is also affected but Embedded Crowd is not affected)

 

Affected Crowd Versions
  • 2.8.3 <= version < 2.9.7
  • 2.10.1 <= version < 2.10.3
  • 2.11.0 <= version < 2.11.1
CVE ID(s)
  • CVE-2017-5638

 

Summary of vulnerability

This advisory discloses a critical severity security vulnerability that was introduced in version 2.8.3 of Crowd. Versions of Crowd from 2.8.3 before 2.9.7 (the fixed version for 2.9.x), from version 2.10.1 before 2.10.3 (the fixed version for 2.10.x) and from version 2.11.0 before 2.11.1 (the fixed version for 2.11.x) are affected by this vulnerability.

 

Atlassian Cloud instances aren't affected by the issue described on this page.

If you have upgraded Crowd to version 2.9.7 or 2.10.3 or 2.11.1, you are not affected by this issue.

Customers who have downloaded and installed Crowd >= 2.8.3 and less than 2.9.7 (the fixed version for 2.9.x)

Customers who have downloaded and installed Crowd >= 2.10.1 and less than 2.10.3 (the fixed version for 2.10.x)

Customers who have downloaded and installed Crowd >= 2.11.0 and less than 2.11.1 (the fixed version for 2.11.x)

 

Please upgrade your Crowd installations immediately to fix this vulnerability.



Remote code execution through Apache Struts 2 (CVE-2017-5638)

Severity

We rate the severity level of this vulnerability as critical, according to our Atlassian severity levels. The scale allows us to rank the severity as critical, high, moderate or low.

This is an independent assessment. You should evaluate its applicability to your own IT environment.

 

Description

Crowd used a version of Apache Struts 2 that was vulnerable to CVE-2017-5638. Attackers can use this vulnerability to execute Java code of their choice without prior authentication on systems that have a vulnerable version of Crowd.

All versions of Crowd from 2.8.3 before 2.9.7 (the fixed version for 2.9.x), from version 2.10.1 before 2.10.3 (the fixed version for 2.10.x) and from version 2.11.0 before 2.11.1 (the fixed version for 2.11.x) are affected by this vulnerability. You can track this issue here:  CWD-4879 - Getting issue details... STATUS

 

Fix

To address this issue, we have released the following versions containing a fix:

  • Crowd version 2.9.7
  • Crowd version 2.10.3
  • Crowd version 2.11.1

What you need to do

Upgrade Crowd to version 2.11.1 or higher

The vulnerabilities and fix versions are described above. If affected, you should upgrade to the latest version immediately.

If you're running Crowd 2.10.x and cannot upgrade to 2.11.1, upgrade to version 2.10.3.

If you're running Crowd 2.9.x and cannot upgrade to 2.11.1, upgrade to version 2.9.7.

 

For a full description of the latest version of Crowd, see the Crowd release notes. You can download the latest version of Crowd from the download centre.

 

Detection

Given that we have confirmed exploitation in the wild, we recommend customers look for signs of compromise even if they upgrade immediately. Detection of such attacks is very environment-specific but below are some indicators that customers may find useful in their investigations.

The same expression can be used across all log types, which is especially useful if you are using a SIEM or log aggregator to analyze the logs all at once:

grep -E 'InvalidContentTypeException.+multipart\/form\-data' *.log

If remote code was executed, you will see an OGNL expression being evaluated on the server. These commands will typically start with `#cmd=` or `#cmds=` such as:

(#cmd='ls')
(#cmds=(#iswin?{'cmd.exe','/c',#cmd}:{'/bin/bash','-c',#cmd}))


Crowd logs all its application events inside `atlassian-crowd.log`.  The default path is: `<CROWD_HOME>/logs/atlassian-crowd.log`.

017-03-10 10:27:29,340 http-bio-8095-exec-22 WARN [struts2.dispatcher.multipart.JakartaMultiPartRequest] Unable to parse request
org.apache.commons.fileupload.FileUploadBase$InvalidContentTypeException: the request doesn't contain a multipart/form-data or multipart/mixed stream, content type header is %{(#nike='multipart/form-data').(#dm=@ognl.OgnlContext@DEFAULT_MEMBER_ACCESS).(#_memberAccess?(#
_memberAccess=#dm):((#container=#context['com.opensymphony.xwork2.ActionContext.container']).(#ognlUtil=#container.getInstance(@com.opensymphony.xwork2.ognl.OgnlUtil@class)).(#ognlUtil.getExcludedPackageNames().clear()).(#ognlUtil.getExcludedClasses().clear()).(#context.setMemberAccess(#dm)))).(#cmd='touch /tmp/pwned').(#iswin=(@java.lang.System@getProperty('os.name').toLowerCase().contains('win'))).(#cmds=(#iswin?{'cmd.exe','/c',#cmd}:{'/bin/bash','-c',#cmd})).(#p=new java.lang.ProcessBuilder(#cmds)).(#p.redirectErrorStream(true)).(#process=#p.start()).(#ros=(@org.apache.struts2.ServletActionContext@getResponse().getOutputStream())).(@org.apache.commons.io.IOUtils@copy(#process.getInputStream(),#ros)).(#ros.flush())}
...


Support

If you have questions or concerns regarding this advisory, please raise a support request at https://support.atlassian.com/.

References

Security Bug fix Policy

As per our new policy, critical security bug fixes will be back-ported to major software versions for up to 12 months for JIRA and Confluence. We'll release new maintenance releases for the versions covered by the new policy instead of binary patches.

Binary patches will no longer be released. 

Severity Levels for security issuesAtlassian security advisories include a severity level and a CVE identifier. This severity level is based on our self-calculated CVSS score for each specific vulnerability. CVSS is an industry standard vulnerability metric. You can also learn more about CVSS at FIRST.org.
End of Life Policy Our end-of-life policy varies for each product. Please refer to our EOL Policy for details.
Last modified on Mar 14, 2017

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.