Summary
CVE-2026-86426 is a critical authentication bypass vulnerability in the LibreNMS REST API, caused by a type-confusion flaw in API token validation. It affects all LibreNMS versions before 26.8.0 and allows unauthenticated remote attackers to gain the privileges of an existing API token holder — potentially escalating to remote code execution. The vulnerability carries a CVSS score of 9.2 (Critical).
Technical details
- Root cause: LibreNMS’s
ApiTokenGuardaccepts API tokens supplied as JSON body parameters. Laravel preserves JSON data types, so a value like{"api_token": 9}is decoded as an integer rather than a string. - The application compares this integer against the
token_hashtext column in MySQL. MySQL coerces the text column to a number by its leading characters, so a hash like9cd9a5e2...evaluates to9while a hash beginning with a letter (e.g.,abcdef01...) evaluates to0. - Sending
{"api_token": [0]}bypassesempty()validation (since an array is not empty), and Laravel’s query builder then flattens the array to the integer0before executing the query. - Attack vector: unauthenticated, network-based requests to REST API endpoints with a crafted numeric
api_tokenvalue; no rate limiting exists on the API route group, enabling rapid guessing across digits 0–9 to match a valid token. - Impact: an attacker who matches a token inherits that token’s full permissions, including access to device credentials and administrative functions. If the matched token belongs to an administrator, alert templates can be abused (via
@phpblocks) to achieve remote code execution. - Precondition: at least one enabled API token must exist on the target instance.
Affected software
- LibreNMS versions prior to 26.8.0 (all versions up to and including 26.7.0)
Severity
- CVSS v4.0 Base Score: 9.2 (Critical)
- Vector:
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Mitigation and recommended actions
- Immediate: Upgrade LibreNMS to version 26.8.0 or later, which fixes the type-confusion flaw in API token validation.
- If immediate patching is not possible: restrict network access to the LibreNMS REST API (e.g., via firewall rules or VPN) to trusted hosts only, disable or rotate all existing API tokens, and monitor API access logs for requests using numeric or array-formatted
api_tokenvalues.
How IONIX identifies potentially affected assets
IONIX matches the following signals against data already collected when it crawled the asset; identifying the technology sends no request beyond that crawl.
- Raw response body:
<title>LibreNMS</title>

