ZeroHour
The Hacker Newspublished ()ingested @TheHackersNews

New Apache Struts RCE Flaw Lets Hackers Take Over Web Servers

Vulnerabilities mentionedAll →

CVEVulnerabilityCVSSEPSSFlagsAffectedExposurePublished
CVE-2017-5638
Unauthenticated RCE in Apache Struts Jakarta Multipart parser

CVE-2017-5638 is an improper input validation flaw (CWE-20) in the Jakarta Multipart parser of Apache Struts, in which the parser mishandles the Content-Type value of a file upload and allows malicious upload leading to remote code execution. It is triggered remotely without authentication by sending a crafted Content-Type header in a multipart request to a Struts endpoint; no valid upload or credentials are required. A successful attacker gains code execution in the security context of the application server, which typically enables host compromise, data theft, or ransomware deployment. Any organization running Apache Struts applications that use the Jakarta Multipart parser is affected; the provided data specifies only "Apache Struts" and gives no version ranges. Exploitation is confirmed in the wild: the flaw is listed in CISA KEV (added 2021-11-03) with known ransomware use, EPSS assigns it roughly a 100% exploitation probability (100th percentile), and no public PoC is catalogued in the source data.

Do: Apply updates per vendor instructions: upgrade Apache Struts to the releases that fix this flaw (2.3.32 / 2.5.10.1 or later, per Apache advisory S2-045), and check for Struts jars bundled inside application packages and vendor appliances. Prioritize internet-facing apps, and as an interim mitigation validate or filter the Content-Type header on multipart requests. Because exploitation is in the wild and ransomware use is known, also review web and application server logs for evidence of successful compromise.

9.8100% KEV ransomware PoC ×10
  • Apache Struts
masslikely hundreds of thousands of deployments (tens of thousands of Struts hosts were internet-exposed in public scans)
CVE-2017-9805
XML Deserialization RCE in Apache Struts 2 REST Plugin

CVE-2017-9805 is an unsafe deserialization vulnerability in the REST plugin of Apache Struts 2, which uses the XStream library to deserialize XML request payloads without any type filtering. An attacker triggers it by sending a crafted XML payload to an endpoint handled by the REST plugin, causing the payload to be deserialized into arbitrary objects. Successful exploitation yields remote code execution on the server with the privileges of the web application, typically enough to fully take over the host. Struts 2.1.1 through 2.3.x before 2.3.34 and 2.5.x before 2.5.13 are affected, including products from Cisco and NetApp that bundle vulnerable Struts versions. The flaw has a public proof-of-concept exploit, is on CISA's Known Exploited Vulnerabilities catalog, and was reported as under active exploitation after its 2017 disclosure, although the Apache Foundation disputed suggestions that this specific flaw was used in the Equifax breach.

Do: Upgrade Apache Struts to 2.3.34, 2.5.13, or later, or apply the fixed updates for any Cisco or NetApp product that embeds Struts per their advisories. If patching is not immediate, remove or disable the REST plugin, or restrict the XML content types it accepts. Inventory internet-facing applications for Struts REST endpoints and hunt for suspicious XML POSTs, since the CVE is on the CISA KEV list and was reported as actively exploited.

8.199% KEV PoC
  • Apache Struts 2 (REST plugin) 2.1.1 through 2.3.x before 2.3.34 and 2.5.x before 2.5.13
  • Cisco Digital Media Manager Bundled Struts within affected ranges (2.1.1 to 2.3.33 or 2.5.0 to 2.5.12); exact product versions per Cisco advisory
  • Cisco Hosted Collaboration Solution Bundled Struts within affected ranges (2.1.1 to 2.3.33 or 2.5.0 to 2.5.12); exact product versions per Cisco advisory
  • +4 more
mass~100,000-300,000+ internet-exposed Struts servers and applications (only a subset exposing the vulnerable REST plugin); embedded Cisco/NetApp deployments…
CVE-2018-11776
Apache Struts Remote Code Execution via Missing or Wildcard Namespace

Apache Struts 2 contains an improper input validation flaw (CWE-20) that allows unauthenticated remote code execution when an attacker-controlled namespace (for example, part of the request URL path) is evaluated as an OGNL expression on the server. It is triggered under two circumstances: (1) the alwaysSelectFullNamespace option is true and a result defined in the configuration has no namespace while its parent package's namespace is unset or a wildcard, or (2) a URL tag in a template has no namespace under the same parent-package conditions. An attacker who can reach an application in one of these configurations gains arbitrary code execution with the privileges of the application server, so any organization running affected Struts 2 releases (2.3.7-2.3.34 and 2.5-2.5.16) in such configurations is exposed. CISA added the flaw to its Known Exploited Vulnerabilities catalog on 2021-11-03, confirming exploitation in the wild (ransomware use unknown), and EPSS currently assigns a 100% probability of exploitation within 30 days. CVSS is not yet scored in this feed, but the KEV listing and EPSS signal indicate urgent patching priority.

Do: Upgrade Apache Struts to 2.3.35 or 2.5.17 (or later) on all applications, prioritizing internet-facing ones, per vendor instructions. If upgrading is not immediately possible, set alwaysSelectFullNamespace to false and ensure every result and URL tag specifies an explicit, non-wildcard namespace. Audit configurations, especially applications using the Convention Plugin or wildcard namespaces, for the vulnerable conditions and review web server logs for signs of OGNL injection in namespace values.

8.1100% KEV PoC ×5
  • Apache Struts 2 2.3.7-2.3.34 and 2.5-2.5.16 (fixed in 2.3.35 and 2.5.17, per vendor advisory)
massmillions of end users behind on the order of tens of thousands of internet-exposed Apache Struts deployments
Full article609 words · extracted from thehackernews.com · click to collapse

The Hacker NewsAug 22, 2018

Semmle security researcher Man Yue Mo has disclosed a critical remote code execution vulnerability in the popular Apache Struts web application framework that could allow remote attackers to run malicious code on the affected servers.

Apache Struts is an open source framework for developing web applications in the Java programming language and is widely used by enterprises globally, including by 65 percent of the Fortune 100 companies, like Vodafone, Lockheed Martin, Virgin Atlantic, and the IRS.

The vulnerability (CVE-2018-11776) resides in the core of Apache Struts and originates because of insufficient validation of user-provided untrusted inputs in the core of the Struts framework under certain configurations.

The newly found Apache Struts exploit can be triggered just by visiting a specially crafted URL on the affected web server, allowing attackers to execute malicious code and eventually take complete control over the targeted server running the vulnerable application.

Struts2 Vulnerability - Are You Affected?

All applications that use Apache Struts—supported versions (Struts 2.3 to Struts 2.3.34, and Struts 2.5 to Struts 2.5.16) and even some unsupported Apache Struts versions—are potentially vulnerable to this flaw, even when no additional plugins have been enabled.

"This vulnerability affects commonly-used endpoints of Struts, which are likely to be exposed, opening up an attack vector to malicious hackers," Yue Mo said.

Your Apache Struts implementation is vulnerable to the reported RCE flaw if it meets the following conditions:

  • The alwaysSelectFullNamespace flag is set to true in the Struts configuration.
  • Struts configuration file contains an "action" or "url" tag that does not specify the optional namespace attribute or specifies a wildcard namespace.

According to the researcher, even if an application is currently not vulnerable, "an inadvertent change to a Struts configuration file may render the application vulnerable in the future."

Here's Why You Should Take Apache Struts Exploit Seriously

Less than a year ago, credit rating agency Equifax exposed personal details of its 147 million consumers due to their failure of patching a similar Apache Struts flaw that was disclosed earlier that year (CVE-2017-5638).

The Equifax breach cost the company over $600 million in losses.

"Struts is used for publicly-accessible customer-facing websites, vulnerable systems are easily identified, and the flaw is easy to exploit," said Pavel Avgustinov, Co-founder & VP of QL Engineering at Semmle.
"A hacker can find their way in within minutes, and exfiltrate data or stage further attacks from the compromised system."

Patch Released for Critical Apache Struts Bug

Apache Struts has fixed the vulnerability with the release of Struts versions 2.3.35 and 2.5.17. Organizations and developers who use Apache Struts are urgently advised to upgrade their Struts components as soon as possible.

We have seen how previous disclosures of similar critical flaws in Apache Struts have resulted in PoC exploits being published within a day, and exploitation of the vulnerability in the wild, putting critical infrastructure as well as customers' data at risk.

Therefore, users and administrators are strongly advised to upgrade their Apache Struts components to the latest versions, even if they believe their configuration is not vulnerable right now.

This is not the first time the Semmle Security Research Team has reported a critical RCE flaw in Apache Struts. Less than a year ago, the team disclosed a similar remote code execution vulnerability (CVE-2017-9805) in Apache Struts.

UPDATE — Apache Struts RCE Exploit PoC Released

A security researcher has today released a PoC exploit for the newly discovered remote code execution (RCE) vulnerability (CVE-2018-11776) in Apache Struts web application framework.

Found this article interesting? Follow us on Google News, Twitter and LinkedIn to read more exclusive content we post.

Text extracted automatically; images, tables and formatting may be missing. Original: https://thehackernews.com/2018/08/apache-struts-vulnerability.html