CVE-2025-65013: Librenms/librenms Cross-Site Scripting Vulnerability

MODERATE
Advisory Identifier: GHSA-j8cq-7f6p-256x
CVSS 6.2
CWE-79
Published
Advisory Summary

CVE-2025-65013 is a MODERATE (CVSS 6.2) cross-site scripting vulnerability (CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')) affecting Librenms/librenms libraries in the Packagist ecosystem. The issue involves librenms vulnerable to reflected cross-site scripting (xss) in endpoint `/maps/nodeimage` parameter `image name`. Remediation is available by upgrading affected packages to version 25.11.0.

CVE-2025-65013 at a Glance

CVE Identifier CVE-2025-65013
GHSA Identifier GHSA-j8cq-7f6p-256x
Severity MODERATE
CVSS v3.1 Base Score 6.2
CWE Classification CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
Affected Product Librenms/librenms
Package Ecosystem Packagist
Published Date
Last Updated

Security Impact

CVSS: 6.2

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:N/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required High (PR:H)
User Interaction Required (UI:R)
Scope Changed (S:C)
Confidentiality High (C:H)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2025-65013

To remediate this vulnerability, upgrade all affected Librenms/librenms dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

librenms/librenms fixed: 25.11.0
Upgrade librenms/librenms to 25.11.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for librenms/librenms

How to Check if You Are Affected

To determine whether your application is affected by CVE-2025-65013, inspect your project dependencies for Librenms/librenms:

inspect dependencies for librenms/librenms

Analyze the terminal output to locate any version of Librenms/librenms in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 25.11.0), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'), where the product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. In Librenms/librenms, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

## Summary A Reflected Cross-Site Scripting (XSS) vulnerability was identified in the LibreNMS application at the `/maps/nodeimage` endpoint. The `Image Name` parameter is reflected in the HTTP response without proper output encoding or sanitization, allowing an attacker to craft a URL that, when visited by a victim, causes arbitrary JavaScript execution in the victim’s browser. ## Details - **Vulnerable Endpoint:** `GET /maps/nodeimage` - **Parameter:** `Image Name` (reflected in response) - **Vulnerability type:** Reflected Cross-Site Scripting (XSS) — input is reflected in server response and executed in victim browser. - **CWE:** CWE-79 (Improper Neutralization of Input During Web Page Generation — Cross-site Scripting) ## Description The application takes the value of the `Image Name` parameter from a request to `/maps/nodeimage` and includes it in the generated page or response without proper contextual encoding. Because the input is reflected immediately back to the client and parsed as HTML/JavaScript by the browser, an attacker can craft a URL containing a malicious script. If a victim (for example, an authenticated user or administrator) is tricked into visiting that URL, the injected script will execute in the victim’s browser context. ## Proof of Concept (PoC) Construct a request that includes the following payload in the `Image Name` parameter. The payload below should be used exactly as provided: ``` <script>alert('PoC-XXS51')</script> ``` ## Steps to reproduce 1. Authenticate as any user allowed to manage Node Images; 2. Navigate the endpoint '/maps/nodeimage' and click on "New Image". Choose any valide image and, on `Image Name` parameter, insert the payload above . <img width="804" height="408" alt="image" src="https://github.com/user-attachments/assets/e6de8fc5-80a3-4cc3-81c5-2435dec25372" /> 3. Observe the server response page; if vulnerable, the payload will be executed by the browser and an alert box with `PoC-XXS51` will appear. <img width="713" height="589" alt="image" src="https://github.com/user-attachments/assets/202d602a-5f0b-4c7c-bb89-ffd1280c9e29" /> ## Observed behavior The supplied payload is reflected in the HTTP response and interpreted by the browser, resulting in immediate execution (demonstrated by an alert popup). This confirms the application does not perform appropriate output encoding for the `Image Name` parameter. ## Impact Reflected XSS can be used to: - Execute arbitrary JavaScript in the context of any user who visits the crafted link. - Steal session cookies or authentication tokens (leading to session hijacking). - Perform actions on behalf of the victim (CSRF-like actions executed via script). - Phish users by manipulating the page UI, or exfiltrate sensitive information visible to the victim. - Pivot to further attacks depending on application context and user privileges. ## References - CWE-79 — Cross-Site Scripting (XSS). - OWASP XSS Prevention Cheat Sheet.

CVE-2025-65013 Affected Librenms/librenms Versions

1 component(s)
Fixed Versions:
25.11.0
Product / Package Ecosystem Affected Versions Fixed Version
librenms/librenms
Packagist
< 25.11.0
25.11.0

References

Frequently Asked Questions

What is CVE-2025-65013?
CVE-2025-65013 is a security vulnerability in Librenms/librenms involving LibreNMS vulnerable to Reflected Cross-Site Scripting (XSS) in endpoint `/maps/nodeimage` parameter `Image Name` under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting').
Which Librenms/librenms versions are affected?
Affected versions include releases prior to 25.11.0 across affected packages: librenms/librenms.
What version fixes CVE-2025-65013?
Upgrading to 25.11.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is librenms/librenms affected?
Yes, librenms/librenms is affected in releases prior to 25.11.0. Upgrade your dependency to 25.11.0 or later.
What is the CVSS score of CVE-2025-65013?
CVE-2025-65013 has a CVSS v3.1 base score of 6.2 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:N/A:N.
What CWE is associated with CVE-2025-65013?
CVE-2025-65013 is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') (The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.).
How can I check Packagist dependencies for CVE-2025-65013?
Run the dependency tree command: 'inspect dependencies for librenms/librenms'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-j8cq-7f6p-256x",
  "modified" : "2025-11-19T14:22:54Z",
  "published" : "2025-11-18T18:21:28Z",
  "aliases" : [ "CVE-2025-65013" ],
  "summary" : "LibreNMS vulnerable to Reflected Cross-Site Scripting (XSS) in endpoint `/maps/nodeimage` parameter `Image Name`  ",
  "details" : "## Summary\n\nA Reflected Cross-Site Scripting (XSS) vulnerability was identified in the LibreNMS application at the `/maps/nodeimage` endpoint. The `Image Name` parameter is reflected in the HTTP response without proper output encoding or sanitization, allowing an attacker to craft a URL that, when visited by a victim, causes arbitrary JavaScript execution in the victim’s browser.\n\n## Details\n\n- **Vulnerable Endpoint:** `GET /maps/nodeimage`\n    \n- **Parameter:** `Image Name` (reflected in response)\n    \n- **Vulnerability type:** Reflected Cross-Site Scripting (XSS) — input is reflected in server response and executed in victim browser.\n    \n- **CWE:** CWE-79 (Improper Neutralization of Input During Web Page Generation — Cross-site Scripting)\n    \n\n## Description\n\nThe application takes the value of the `Image Name` parameter from a request to `/maps/nodeimage` and includes it in the generated page or response without proper contextual encoding. Because the input is reflected immediately back to the client and parsed as HTML/JavaScript by the browser, an attacker can craft a URL containing a malicious script. If a victim (for example, an authenticated user or administrator) is tricked into visiting that URL, the injected script will execute in the victim’s browser context.\n\n## Proof of Concept (PoC)\n\nConstruct a request that includes the following payload in the `Image Name` parameter. The payload below should be used exactly as provided:\n\n```\n<script>alert('PoC-XXS51')</script>\n```\n\n## Steps to reproduce\n\n1. Authenticate as any user allowed to manage Node Images;\n    \n2. Navigate the endpoint '/maps/nodeimage' and click on \"New Image\". Choose any valide image and, on `Image Name` parameter, insert the payload above .\n\n<img width=\"804\" height=\"408\" alt=\"image\" src=\"https://github.com/user-attachments/assets/e6de8fc5-80a3-4cc3-81c5-2435dec25372\" />\n\n    \n3. Observe the server response page; if vulnerable, the payload will be executed by the browser and an alert box with `PoC-XXS51` will appear.\n\n<img width=\"713\" height=\"589\" alt=\"image\" src=\"https://github.com/user-attachments/assets/202d602a-5f0b-4c7c-bb89-ffd1280c9e29\" />\n\n## Observed behavior\n\nThe supplied payload is reflected in the HTTP response and interpreted by the browser, resulting in immediate execution (demonstrated by an alert popup). This confirms the application does not perform appropriate output encoding for the `Image Name` parameter.\n\n## Impact\n\nReflected XSS can be used to:\n\n- Execute arbitrary JavaScript in the context of any user who visits the crafted link.\n    \n- Steal session cookies or authentication tokens (leading to session hijacking).\n    \n- Perform actions on behalf of the victim (CSRF-like actions executed via script).\n    \n- Phish users by manipulating the page UI, or exfiltrate sensitive information visible to the victim.\n    \n- Pivot to further attacks depending on application context and user privileges.\n   \n\n## References\n\n- CWE-79 — Cross-Site Scripting (XSS).\n    \n- OWASP XSS Prevention Cheat Sheet.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "librenms/librenms"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "25.11.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/librenms/librenms/security/advisories/GHSA-j8cq-7f6p-256x"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-65013"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/librenms/librenms"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-79" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-11-18T18:21:28Z",
    "nvd_published_at" : "2025-11-18T23:15:56Z"
  }
}