CVE-2024-25412

6.1 MEDIUM

📋 TL;DR

This cross-site scripting (XSS) vulnerability in Flatpress v1.3 allows attackers to inject malicious scripts into the email field, which then execute in victims' browsers. Any Flatpress v1.3 installation with user registration or email input functionality is affected. Attackers can steal session cookies, redirect users, or perform actions on their behalf.

💻 Affected Systems

Products:
  • Flatpress
Versions: v1.3
Operating Systems: All
Default Config Vulnerable: ⚠️ Yes
Notes: Requires email field functionality to be accessible (typically via registration or contact forms).

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete account takeover via session cookie theft, leading to administrative privilege escalation, data exfiltration, or website defacement.

🟠

Likely Case

Session hijacking of regular users, credential theft via phishing, or malicious redirects to attacker-controlled sites.

🟢

If Mitigated

Limited impact with proper input validation and output encoding, potentially only affecting the attacker's own session.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ⚠️ Yes
Complexity: LOW

Public proof-of-concept available on GitHub demonstrates simple script injection. No authentication required if email field is publicly accessible.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Not available

Vendor Advisory: Not available

Restart Required: No

Instructions:

1. Monitor Flatpress official channels for security updates. 2. Apply workarounds immediately. 3. Consider upgrading to a newer version if available.

🔧 Temporary Workarounds

Input Validation and Sanitization

all

Implement server-side validation and sanitization of email field input to remove or encode script tags.

Edit Flatpress source code to add input sanitization for email fields

Content Security Policy (CSP)

all

Implement CSP headers to restrict script execution sources.

Add 'Content-Security-Policy' header to web server configuration

🧯 If You Can't Patch

  • Disable user registration or email input functionality if not required
  • Implement web application firewall (WAF) rules to block XSS payloads

🔍 How to Verify

Check if Vulnerable:

Test email field with XSS payload like <script>alert('XSS')</script> and check if script executes.

Check Version:

Check Flatpress admin panel or read version.txt file in installation directory

Verify Fix Applied:

Retest with same XSS payload after applying workarounds; script should not execute.

📡 Detection & Monitoring

Log Indicators:

  • Unusual email field submissions containing script tags or JavaScript code
  • Multiple failed login attempts following suspicious email submissions

Network Indicators:

  • HTTP requests with script tags in email parameter
  • Outbound connections to suspicious domains following email submission

SIEM Query:

source="web_logs" AND (email="*<script>*" OR email="*javascript:*")

🔗 References

📤 Share & Export