Summary
UTT 进取 521G firmware 3.1.1-190816 contains an OS command injection vulnerability in the /goform/formPdbUpConfig handler, specifically in function sub_446B18, where the policyNames parameter is unsafely processed.
A remote attacker who can send crafted HTTP requests to the device can inject and execute arbitrary system commands under the privileges of the web management process, potentially compromising the router and its network context.
Affected context
This vulnerability occurs in the web management interface of UTT 进取 521G devices running firmware version 3.1.1-190816.
The affected code path lives in the /goform/formPdbUpConfig endpoint (function sub_446B18), which processes the policyNames parameter from HTTP requests.
The issue is exposed when the management interface is reachable over the network (e.g., LAN, WAN if misconfigured, or VPN), and when policy-related configuration requests are accepted without proper input sanitization.
Exploit preconditions
- Attack surface: HTTP-based web management interface exposed by the router.
- Required access: Network-level access to the management endpoint (e.g., ability to reach /goform/formPdbUpConfig); authentication requirements depend on deployment configuration and access control.
- Trigger point: Submission of a crafted HTTP request containing malicious content in the policyNames parameter, which is then passed to OS-level command execution logic.
- Why exploitation is possible: User-controlled input (policyNames) is concatenated or interpolated into a shell command without adequate validation, escaping, or use of safe execution APIs, allowing attacker-controlled tokens to alter command structure.
Why this happens
The bug is rooted in insecure construction of system commands using external input within sub_446B18 for /goform/formPdbUpConfig.
Instead of treating policyNames as pure data, the code likely combines it directly with shell command strings (e.g., using system(), popen(), or equivalent), without robust sanitization or without restricting allowed characters and semantics.
This corresponds to CWE-78: Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection'), and is closely related to CWE-77: Improper Neutralization of Special Elements used in a Command ('Command Injection').
Conceptually, the implementation violates the principle of separating code and data, giving attackers a way to inject control characters, operators, or additional commands into the execution pipeline.
Potential impact
- Execution of arbitrary OS commands with the privileges of the router's web management process.
- Full compromise of the device configuration, including modification of policies, firewall rules, and routing behavior.
- Deployment of persistent malware or backdoors on the device, depending on filesystem characteristics.
- Interception, redirection, or inspection of network traffic passing through the router.
- Use of the compromised router as a pivot point for attacks against internal network hosts or external targets (e.g., as part of a botnet).
General mitigation guidance
Effective mitigation focuses on eliminating direct command injection paths and constraining how external input is used in command execution components:
- Replace shell-based command construction with safer, parameterized APIs that do not invoke a shell (e.g., direct system or library calls) where possible.
- If command execution is unavoidable, strictly validate policyNames against a whitelist of allowed values and formats, rejecting or sanitizing any unexpected characters, especially shell metacharacters.
- Encapsulate user-supplied data as non-executable arguments rather than concatenating it into raw command strings.
- Apply least-privilege principles to the web management process so that even if commands are executed, their impact on the system is reduced.
- Restrict remote management exposure by limiting the management interface to trusted networks, using network-level access controls and strong authentication to narrow the reachable attack surface.
How teams detect issues like this
High-level detection approaches for this class of vulnerability include:
- Static analysis: Scan firmware or source code for unsafe command execution patterns such as system(), popen(), exec*, or backtick usage where any portion of the command string is derived from HTTP parameters like policyNames without strict validation.
- Code review signals: Identify code paths in request handlers (e.g., /goform/formPdbUpConfig) where user input is directly concatenated into shell commands, or where validation is absent, superficial, or blacklist-based.
- Dynamic testing: Use fuzzing or targeted testing tools against the management endpoints to observe anomalous behavior, unexpected command results, or error messages indicating shell interpretation of input.
- Policy enforcement: Implement secure coding policies for embedded and network devices that forbid shell invocation with raw user input, and enforce these via CI checks, linting, or automated review tools.

