/

CVE-2026-18613

Severity:

CRITICAL RISK

(9.8)

Injection Flaw (CWE-74) in GL-iNet GL-MT3000 Plugin API

CVE-2026-18613

Deferred

Vulnerability type

Category:

Input Injection

CWE:

CWE-74, CWE-707

Impact:

Remote Code Execution / Configuration Manipulation

Severity:

CRITICAL RISK

(9.8)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

A critical injection vulnerability in the GL-iNet GL-MT3000 router affects the plugins.set_config function exposed via /cgi-bin/glc in the native plugins.so component.

When untrusted input is passed into configuration handling routines without sufficient validation or encoding, a remote attacker may inject crafted data to alter system behavior or execute unintended actions.

Affected context

The issue arises in GL-iNet GL-MT3000 devices (firmware up to 4.4.5) where the web-based management interface exposes native plugin functionality through /cgi-bin/glc.

The plugins.set_config action processes attacker-controlled request parameters as part of plugin configuration logic.

In environments where this interface is reachable from untrusted networks, and request data is not canonically validated or contextually encoded, the vulnerable code path can be reached by remote users.

Exploit preconditions

  • Attack surface: HTTP(S) interface on the GL-MT3000 router, specifically requests targeting /cgi-bin/glc with actions invoking plugins.set_config.
  • Required access: Network reachability to the management interface; depending on deployment, this may be from LAN clients, VPN users, or misconfigured WAN exposure.
  • Trigger point: Submission of crafted parameters that are passed by plugins.set_config into downstream interpreters, configuration engines, or command contexts without strict validation and encoding.
  • Why exploitation is possible: The plugin configuration routine mixes untrusted input with trusted control data, failing to normalize or constrain it before interpretation, enabling injection into the underlying configuration or execution context.

Why this happens

This vulnerability stems from improper neutralization of special elements when constructing configuration or command-like data from user input.

The plugins.set_config function appears to treat external request parameters as trusted configuration fragments, combining them into downstream strings or structures that are subsequently interpreted by other components.

Under CWE-74 (Improper Neutralization of Special Elements in Output Used by a Downstream Component), this pattern occurs when an application fails to escape, encode, or constrain user-supplied values before embedding them in contexts like configuration files, shell commands, or scripting environments.

The additional mapping to CWE-707 (Improper Neutralization) highlights a broader absence of centralized, consistent input sanitization and context-aware encoding, allowing malicious input to alter the meaning of the constructed content and leading to unintended behavior or code execution.

Potential impact

  • Remote attackers could alter router configuration, including plugin settings and potentially network policies.
  • Arbitrary command or code execution may be possible if injected values are ultimately passed to interpreters (e.g., shell, scripting engines).
  • Persistent compromise of the device, including installing or enabling malicious plugins or traffic redirection rules.
  • Loss of confidentiality and integrity for network traffic traversing the router, including potential man-in-the-middle scenarios.
  • Use of the compromised device as a pivot point for attacks on internal networks or other connected systems.

General mitigation guidance

Effective mitigation focuses on enforcing strict separation between untrusted input and any interpreted or configuration contexts.

Pattern-based safeguards include:

  • Introducing centralized, context-aware validation for all plugin-related inputs, limiting allowed characters, value ranges, and structures to a minimal, documented subset.
  • Applying appropriate encoding/escaping before embedding user-supplied data into downstream components such as configuration files, system commands, or scripts, ensuring it cannot alter control structures.
  • Designing plugin configuration APIs such that clients submit structured, strongly typed data (e.g., fixed JSON schemas) instead of free-form strings that can contain control characters.
  • Reducing privilege of the plugin management component so that even if a configuration entry is misused, its ability to modify core system state or execute privileged actions is constrained.
  • Isolating plugin execution environments (e.g., via separate processes, sandboxes, or restricted chroot/jails) to limit the blast radius of misconfigured or malicious plugins.
  • Restricting access to the management interface to trusted administrative networks and disabling unneeded plugin management endpoints by default.

How teams detect issues like this

Detection typically revolves around identifying unsafe input handling and unusual configuration manipulations.

Common approaches include:

  • Static analysis rules that flag concatenation or interpolation of HTTP parameters into configuration or command-building code within native modules like plugins.so, especially around plugins.set_config.
  • Code review checklists that require explicit justification and documentation whenever user-supplied data is passed into interpreters, configuration engines, or shell commands, with reviewers looking for missing encoding or validation layers.
  • Policy-based linting or security gates in build pipelines that enforce the use of vetted input-validation and encoding utilities for all plugin management functions.
  • Runtime monitoring of router logs and plugin activity for anomalous configuration changes, unexpected plugin deployments, or sudden shifts in management interface usage patterns.
  • Periodic security testing (including fuzzing and negative testing) of web-based configuration endpoints to uncover injection vectors and validate that new code adheres to safe patterns.

Sources

SourceLink
github.comgithub.com/StrTzz123/iot_vul/blob/main/GL-iNet/MT3000/4.4.5/plugins_set_config_glc_write/CVE.md
vuldb.comvuldb.com/cve/CVE-2026-18613
vuldb.comvuldb.com/submit/851557
vuldb.comvuldb.com/vuln/385533
vuldb.comvuldb.com/vuln/385533/cti

Frequently asked

questions

Exploitability depends on how the management interface is exposed; if /cgi-bin/glc is reachable from untrusted networks (for example, due to misconfigured WAN access or open administrative ports), the vulnerability can be exploited remotely by any network-adjacent attacker. In more locked-down deployments, exposure may be limited to internal or authenticated users.

At minimum, an attacker needs network access to the router's management interface where the vulnerable endpoint is reachable. If the interface requires authentication, exploitation may require valid credentials or another weakness to bypass access controls; however, if the endpoint is exposed without strict authentication, even unauthenticated attackers could attempt injection.

The safest fix is to ensure that no untrusted input is ever passed directly into configuration or interpreter contexts: enforce strict, centralized validation for all plugin configuration parameters, use structured schemas, and apply context-appropriate encoding before any interpretation. Refactoring the design so that configuration values are treated as data only—never as executable or control-bearing content—greatly reduces risk.

Future prevention relies on adopting secure-by-default development practices: mandate the use of vetted input-validation and encoding libraries, establish coding standards for handling untrusted data, and integrate security reviews and automated checks into the development pipeline. Additionally, designing management APIs with minimal, well-defined capabilities and isolating high-risk functionality (like plugin management) into least-privileged, sandboxed components helps prevent injection flaws from leading to full system compromise.

Find out what's already
exploitable in your codebase.