CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



GHSA-JF24-8G2H-2WG7

GHSA-JF24-8G2H-2WG7: Remote Code Execution in LibreNMS AboutController via Binary Path Substitution

Amit Schendel
Amit Schendel
Senior Security Researcher

Aug 19, 2026·6 min read·16 visits

Executive Summary (TL;DR)

Authenticated administrators can execute arbitrary system commands by changing the snmpget binary path to a malicious script uploaded on the local filesystem and visiting the /about page.

A critical security flaw in LibreNMS allows authenticated administrators to execute arbitrary commands by modifying the configured binary path for snmpget and accessing the About page. This occurs due to insufficient verification of the executable file's identity and integrity prior to executing it with shell_exec.

System Architecture and Attack Surface Overview

LibreNMS is an open-source, PHP-based autodiscovering network monitoring tool that relies extensively on external system binaries to query network devices. The application exposes an administrative interface that allows authorized users to manage system configurations, including the file paths for utilities such as Net-SNMP. One of these utilities is the snmpget binary, which LibreNMS executes to retrieve SNMP data and verify version information.

Historically, configuration systems that execute system commands face substantial risks if input fields are not strictly restricted to pre-defined safe paths. In LibreNMS, the configuration settings are stored in a database and can be modified by users holding administrative privileges. The /about endpoint of the application triggers a configuration check that invokes the binary path defined in this database.

This architecture creates an attack surface where an administrative user can influence the execution path of system commands. If an attacker can manipulate the binary path configuration to point to an arbitrary executable, they can abuse the application logic to execute arbitrary code on the underlying operating system. The vulnerability is classified under command injection and path traversal weaknesses.

Root Cause Analysis of the Path Validation Defect

The root cause of this vulnerability lies in the insufficient validation of the snmpget configuration value within the AboutController.php file. When the /about endpoint is accessed, the application retrieves the path to the snmpget executable and runs it using the PHP shell_exec() function. This function passes the command string directly to the host shell for execution, which inherently exposes the system to command execution vulnerabilities if the binary path itself is untrusted.

To prevent malicious inputs, LibreNMS employs a sanitization filter named sanitizePath() located in LibreNMS/Util/DynamicConfigItem.php. This helper function utilizes a regular expression pattern to detect and reject typical shell metacharacters such as semicolons, pipes, backticks, and redirection operators. It also verifies that the configured target is a valid, executable file on the local disk using PHP's native is_file() and is_executable() functions.

While this sanitization effectively blocks direct inline command injection (such as appending a command separator followed by malicious code), it fails to validate the identity and integrity of the executable itself. An attacker who can write a file to the filesystem can specify their malicious script as the target executable. Because the malicious script exists as a valid file and has the executable bit set, it satisfies both is_file() and is_executable(), allowing the path to be saved and subsequently executed by the application.

Detailed Code Path and Patch Analysis

The vulnerable version of the application processes the execution of the version check inside app/Http/Controllers/AboutController.php as follows:

// Vulnerable code in AboutController.php
'version_netsnmp' => str_replace('version: ', '', 
    rtrim(shell_exec(LibrenmsConfig::get('snmpget', 'snmpget') . ' -V 2>&1'))),

In this implementation, shell_exec() is used to execute the binary string directly. This passes the command to the default shell (typically /bin/sh), which interprets the string and runs the target process.

To remediate this issue, the patch replaces shell_exec() with the Symfony Process component, which executes the binary directly without spawning a shell interpreter. The updated code inside the controller is structured as follows:

// Patched code in AboutController.php
use Symfony\Component\Process\Process;
 
// The process is initialized with arguments as an array
$process = new Process([LibrenmsConfig::get('snmpget', 'snmpget'), '-V']);
$process->run();
 
'version_netsnmp' => str_replace('version: ', '', rtrim($process->getOutput())),

By passing the binary path and arguments as an array, the Symfony Process component bypasses shell parsing. Even if the path points to a customized script, it prevents any argument injection or command-chaining. This restricts the execution to the targeted file and safely processes the output.

Exploitation and Attack Path Analysis

Exploitation of this vulnerability requires administrative credentials to access the LibreNMS web interface and modify system settings. In addition, the attacker must have a mechanism to write or upload an executable script onto the local filesystem of the target server. Common avenues for dropping the script include using temporary directories like /tmp, leveraging existing file upload functionalities, or exploiting secondary vulnerabilities.

Once a malicious executable is written to the filesystem, the attacker modifies the snmpget binary path configuration. This can be accomplished by navigating to the 'Settings' panel under 'External Binaries' or by sending a direct PUT request to /settings/snmpget. The value is set to the absolute path of the newly written executable file, which passes the validation checks because it exists and is executable.

PUT /settings/snmpget HTTP/1.1
Host: librenms.target.local
Authorization: Bearer <ADMIN_API_TOKEN>
Content-Type: application/json
 
{
  "value": "/tmp/malicious_script.sh"
}

After saving the configuration, the attacker triggers the execution by requesting the /about endpoint. The server executes the malicious script via the web daemon's account. This allows the attacker to establish a reverse shell connection or execute arbitrary system commands, resulting in host compromise.

Security Impact and Blast Radius Assessment

The security impact of successful exploitation is high, leading to arbitrary code execution within the context of the web server daemon (such as www-data or apache). An attacker can leverage this execution access to read sensitive configuration files, modify application data, or access the database credentials stored within the LibreNMS environment.

Because LibreNMS acts as a centralized network monitoring platform, it typically holds sensitive operational data. This data includes SNMP community strings, API keys, network topology maps, and credentials for monitored network infrastructure. Access to the LibreNMS host allows an attacker to pivot and conduct lateral movement across the entire monitored corporate network.

From a CVSS perspective, the vulnerability is scored at 6.4 (CVSS v4.0) under the assumption that the immediate impact to the application itself is managed, but subsequent impact to the host OS and connected systems is high. Under CVSS v3, this scenario represents a high-severity vulnerability with a score of 7.2 due to the administrative privilege requirement.

Remediation, Patching, and Defense-in-Depth Strategies

The primary remediation for this vulnerability is upgrading LibreNMS to version 26.5.0 or higher. This version implements safe process execution via the Symfony Process component, neutralizing the command injection vector. System administrators should verify that all binary paths point to standard system directories after the upgrade.

If immediate upgrading is not feasible, several defensive workarounds should be applied to reduce the attack surface. Administrators should mount temporary write directories, such as /tmp and /var/tmp, with the noexec mount option to prevent the execution of arbitrary scripts dropped by attackers.

# Example of setting noexec on /tmp dynamically
mount -o remount,noexec /tmp

Additionally, access to the administration interface must be restricted to trusted networks using firewall rules, reverse proxies, or Web Application Firewalls (WAFs). WAF rules can be deployed to block PUT requests to the /settings/snmpget endpoint from unauthorized source IPs, ensuring that only authenticated maintenance channels can modify critical configurations.

Fix Analysis (1)

Technical Appendix

CVSS Score
7.2/ 10
CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:N/VI:N/VA:N/SC:H/SI:H/SA:H
1,200
via Shodan

Affected Systems

LibreNMS Network Monitoring System

Affected Versions Detail

Product
Affected Versions
Fixed Version
LibreNMS
librenms
< 26.5.026.5.0
AttributeDetail
CWE IDCWE-77, CWE-78
Attack VectorNetwork
CVSS v3.x Score7.2 (High)
CVSS v4.0 Score6.4 (Medium)
Exploit StatusProof-of-Concept (PoC)
KEV StatusNot Listed
Affected ComponentAboutController.php
Patch Version26.5.0

MITRE ATT&CK Mapping

T1059.004Command and Scripting Interpreter: Unix Shell
Execution
T1203Exploitation for Client Execution
Execution
CWE-78
Improper Neutralization of Special Elements used in an OS Command

Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')

Known Exploits & Detection

GitHub Security AdvisoryOfficial security advisory containing vulnerability analysis and a step-by-step reverse shell proof-of-concept.

References & Sources

  • [1]GitHub Security Advisory Page
  • [2]LibreNMS Core Repository Advisory
  • [3]LibreNMS GitHub Repository
  • [4]LibreNMS v26.5.0 Release Patch

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•35 minutes ago•CVE-2026-77331
2.0

CVE-2026-77331: Race Condition and Session State Corruption in memtomem-stm

CVE-2026-77331 (GHSA-72jh-722p-rqr3) is a concurrency and session-state synchronization vulnerability in memtomem-stm, a short-term memory proxy gateway for AI agents. In versions 0.1.2 prior to 0.1.34, concurrent Model Context Protocol (MCP) Remote Procedure Call (RPC) failures or mid-flight task cancellations can initiate duplicate reconnect loops and permit dirty or cancelled transport sessions to be reused. This deficiency results in session-state integrity loss and local service degradation.

Amit Schendel
Amit Schendel
1 views•9 min read
•about 2 hours ago•CVE-2026-132275
7.5

CVE-2026-132275: Exponential Resource Consumption via Nested <use> References in svglib

svglib versions prior to 2.3.1 contain an uncontrolled resource consumption vulnerability in the svg2rlg() renderer. When parsing SVG documents containing nested <use> elements, SvgRenderer.renderUse() recursively resolves and deep-copies referenced subtrees without enforcing a global expansion limit. Although the library detects and blocks direct circular references, an attacker can construct an acyclic directed reference graph with high fan-out (an SVG analogue to the XML Billion Laughs attack). Processing a crafted SVG payload of less than 2 KB triggers exponential node duplication, exhausting CPU and memory in applications that convert user-supplied SVGs or HTML documents embedding SVG content.

Amit Schendel
Amit Schendel
2 views•9 min read
•about 3 hours ago•CVE-2026-132277
5.3

CVE-2026-132277: Quadratic Memory Growth and Denial of Service in Inscriptis HTML-to-Text Library

CVE-2026-132277 (also tracked as GHSA-q87h-c5m7-659j) is an uncontrolled resource consumption and algorithmic complexity vulnerability in the Inscriptis Python library (versions 2.0.0 through 2.7.5). When rendering sibling HTML table elements inside a block-level parent container, the parser fails to pop the parent block's inline padding prefix from the internal canvas prefix stack upon closing the block. Consequently, each subsequent sibling table inherits and accumulates the indentation prefixes of all preceding tables. This causes the output string length and memory allocation of get_text() to grow quadratically with the number of sibling tables, allowing a compact untrusted HTML payload to trigger denial of service via memory exhaustion.

Amit Schendel
Amit Schendel
3 views•10 min read
•about 4 hours ago•CVE-2026-132276
5.9

CVE-2026-132276: Polynomial-Time Regular Expression Denial of Service (ReDoS) in wcmatch

CVE-2026-132276 (GHSA-53pm-wgxf-c6qf) is an algorithmic complexity and Regular Expression Denial of Service (ReDoS) vulnerability in the Python wcmatch wildcard and glob matching library prior to version 11.2. Under default flags, matching a non-matching attacker-controlled filename against a static developer-defined pattern containing multiple star (*) wildcards separated by literal delimiters causes polynomial-time backtracking O(n^k) in the compiled regular expression. A single 255-byte filename evaluated against a 5-star pattern consumes approximately 86 seconds of 100% CPU time, allowing unauthenticated attackers to induce severe availability degradation.

Alon Barad
Alon Barad
2 views•11 min read
•about 5 hours ago•CVE-2026-122244
7.7

CVE-2026-122244: Stored Cross-Site Scripting in Budibase Builder Formula Evaluation

CVE-2026-122244 (GHSA-r2q3-7m4h-63qg) is a high-severity cross-privilege Stored Cross-Site Scripting (XSS) vulnerability in Budibase prior to version 3.50.0. The flaw occurs due to defective character escaping in the JSON formatter utility combined with raw HTML rendering via Svelte's {@html} directive in the Budibase Builder interface. A low-privileged application user or an unauthenticated form visitor can store malicious HTML markup in a shared datasource, which subsequently executes arbitrary JavaScript in the browser session of an administrator or application builder inspecting Handlebars formula bindings.

Amit Schendel
Amit Schendel
4 views•9 min read
•about 6 hours ago•CVE-2026-122247
8.2

CVE-2026-122247: Unauthenticated Global-Admin and Database Creation via Tenant-Confusion Bypass in Budibase

A tenant-confusion vulnerability in the user initialization endpoint of the Budibase worker service (prior to version 3.50.0) allows unauthenticated remote attackers to bypass the one-time administrative setup guard. By supplying arbitrary tenant identifiers in POST requests to /api/global/users/init, an attacker can force the underlying CouchDB datastore to dynamically provision unlimited tenant databases and persist latent global administrator accounts. This results in datastore resource exhaustion, denial of service, and unauthorized administrative account creation inside non-default tenant contexts.

Amit Schendel
Amit Schendel
5 views•9 min read