Patchfirst
CVE-2023-22952 KEVPublic exploit High · 8.8 EPSS 80.1%

Multiple SugarCRM Products Remote Code Execution Vulnerability

SugarCRM · Multiple Products

Summary

A missing input validation flaw in the EmailTemplates component of multiple SugarCRM products, affecting versions before 12.0 Hotfix 91155, lets crafted requests inject custom PHP code. An attacker who can reach the application over the network and holds a low-privileged account can trigger the injection without any user interaction.

Official description · NVD

In SugarCRM before 12.0. Hotfix 91155, a crafted request can inject custom PHP code through the EmailTemplates because of missing input validation.

Breakdown
69.1 / 100
Exploited
Yes, in CISA KEV
Reports
0
Tactics
8/15

How an attack unfolds

Based on mappings. Select a step to see the evidence.
  1. How attackers get in

  2. What they do

  3. What can follow

First seen exploited 7 days before it was disclosed. Public exploit code (Metasploit) was available 14 days before disclosure.

  1. Public exploit codeMetasploit14 days before
  2. First seen exploitedVulnCheck KEV evidence7 days before
  3. Disclosedday 0
  4. Added to CISA KEVEU database agrees+22 days

CISA KEV listing is when exploitation was confirmed, not necessarily the first attack.

techniques

9 , grouped by in kill-chain order 9

Initial AccessTA0001

Valid Accounts T1078 Medium also Persistence, Privilege Escalation, Stealth
MITRE CTID mapping of the KEV entry · follow-on activity

This Remote Code Execution (RCE) vulnerability is exploited by an unauthenticated attacker via a crafted request can inject custom PHP code through the EmailTemplates because of missing input validation. This vulnerability has been exploited by threat actors to gain initial access to AWS accounts by injecting custom PHP code through the SugarCRM email templates module. Attackers leveraged misconfigurations to expand their access, obtaining long-term AWS access keys from compromised EC2 instances. They used tools like Pacu and Scout Suite to explore AWS services such as EC2, IAM, RDS, and S3, and gathered account information via AWS Organizations and Cost and Usage services. The attackers moved laterally by creating RDS snapshots and new EC2 instances, modifying security groups, and attempting to escalate privileges by logging in as the Root user. They also employed defense evasion techniques, including deploying resources in non-standard regions and intermittently stopping EC2 instances to avoid detection and minimize costs. The exploit in question is actively being used to compromise hosts by installing a PHP-based web shell. It involves an authentication bypass against the "/index.php" endpoint of the targeted service. Once bypassed, the attacker obtains a cookie and sends a secondary POST request to "/cache/images/sweet.phar" to upload a small PNG-encoded file containing PHP code. This file acts as a web shell, allowing the execution of commands specified in the base64-encoded query argument "c". For example, a request like 'POST /cache/images/sweet.phar?c="L2Jpbi9pZA=="' would execute the command "/bin/id" with the same permissions as the web service's user.

Exploit Public-Facing Application T1190 Medium
MITRE CTID mapping of the KEV entry · how it is exploited

ExecutionTA0002

Command and Scripting Interpreter T1059 Medium
MITRE CTID mapping of the KEV entry · primary impact

PersistenceTA0003

Web Shell T1505.003 Medium
MITRE CTID mapping of the KEV entry · follow-on activity

Stealth

File Deletion T1070.004 Medium
MITRE CTID mapping of the KEV entry · follow-on activity

DiscoveryTA0007

File and Directory Discovery T1083 Medium
MITRE CTID mapping of the KEV entry · follow-on activity
Domain Trust Discovery T1482 Medium
MITRE CTID mapping of the KEV entry · follow-on activity

Lateral MovementTA0008

Remote Desktop Protocol T1021.001 Medium
MITRE CTID mapping of the KEV entry · follow-on activity

CollectionTA0009

Data from Cloud Storage T1530 Medium
MITRE CTID mapping of the KEV entry · follow-on activity

Detection

0 rules for this CVE · 407 general rules for its techniques

Rules for this CVE

0 that reference CVE-2023-22952 directly.

CVE-specific rules are not available in this build. Search SigmaHQ ↗

General rules for this CVE’s techniques

These detect the technique in general, not this specific vulnerability.

Exploit Public-Facing ApplicationT1190149 general rules
Command and Scripting InterpreterT105995 general rules
Valid AccountsT107856 general rules
Web ShellT1505.00335 general rules
File DeletionT1070.00415 general rules
File and Directory DiscoveryT108324 general rules
Domain Trust DiscoveryT148217 general rules
Remote Desktop ProtocolT1021.00116 general rules

Sigma rules © SigmaHQ, Detection Rule License 1.1; linked, not reproduced.

What security researchers reported

Not named in any threat report yet

Also mentioned in 50 community threat pulses (AlienVault OTX)

Weaker evidence

Pulses are indicator collections that anyone can publish. A mention is not confirmation of exploitation.

References

3 links, grouped by NVD tag (2 duplicates merged)
↑ ↓ chooseEnter openEsc close