/

CVE-2026-104585

Severity:

CRITICAL RISK

(9.8)

Command Injection (CWE-77) in MobSF Dynamic ADB Module

CVE-2026-104585

Deferred

Vulnerability type

Category:

Command Injection

CWE:

CWE-77

Impact:

Remote Code Execution

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 command injection vulnerability in Mobile Security Framework (MobSF) v4.5.2 affects data download, scanning, and Dynamic Analyzer ADB integration functionality. If attacker-controlled input reaches an affected command-building path, an attacker may execute operating-system commands with the privileges of the MobSF process.

A critical command injection vulnerability in Mobile Security Framework (MobSF) v4.5.2 affects data download, scanning, and Dynamic Analyzer ADB integration functionality. If attacker-controlled input reaches an affected command-building path, an attacker may execute operating-system commands with the privileges of the MobSF process.

Affected context

The vulnerability occurs in MobSF v4.5.2 where request or analysis data may be incorporated into operating-system commands used by the /download_data/, /api/v1/scan, or Dynamic Analyzer ADB integration functionality. Risk depends on the affected interfaces being reachable and on input flowing into command execution without sufficient separation or validation.

The vulnerability occurs in MobSF v4.5.2 where request or analysis data may be incorporated into operating-system commands used by the /download_data/, /api/v1/scan, or Dynamic Analyzer ADB integration functionality. Risk depends on the affected interfaces being reachable and on input flowing into command execution without sufficient separation or validation.

Exploit preconditions

  • Attack surface: MobSF web or API interfaces and Dynamic Analyzer ADB integration
  • Required access: Access to an affected endpoint or workflow; authentication requirements depend on deployment configuration
  • Trigger point: Processing a crafted request or analysis parameter that reaches an operating-system command invocation
  • Why exploitation is possible: External input may be interpreted as part of a command rather than as data, allowing command syntax to influence execution
  • Attack surface: MobSF web or API interfaces and Dynamic Analyzer ADB integration
  • Required access: Access to an affected endpoint or workflow; authentication requirements depend on deployment configuration
  • Trigger point: Processing a crafted request or analysis parameter that reaches an operating-system command invocation
  • Why exploitation is possible: External input may be interpreted as part of a command rather than as data, allowing command syntax to influence execution

Why this happens

The underlying bug is an unsafe command-construction pattern in which externally influenced values are passed to a shell or command interpreter without adequate isolation. This maps to CWE-77: Improper Neutralization of Special Elements used in a Command, commonly known as command injection. The insecure behavior allows data intended as an argument or configuration value to alter the structure or meaning of the executed command.

The underlying bug is an unsafe command-construction pattern in which externally influenced values are passed to a shell or command interpreter without adequate isolation. This maps to CWE-77: Improper Neutralization of Special Elements used in a Command, commonly known as command injection. The insecure behavior allows data intended as an argument or configuration value to alter the structure or meaning of the executed command.

Potential impact

  • An attacker may execute arbitrary operating-system commands
  • The MobSF service or analysis environment could be compromised
  • Sensitive application files, scan results, or credentials may be accessed
  • The host or connected analysis devices could be affected
  • The vulnerability could enable follow-on attacks or disruption of security workflows
  • An attacker may execute arbitrary operating-system commands
  • The MobSF service or analysis environment could be compromised
  • Sensitive application files, scan results, or credentials may be accessed
  • The host or connected analysis devices could be affected
  • The vulnerability could enable follow-on attacks or disruption of security workflows

General mitigation guidance

Mitigation generally focuses on preventing untrusted data from becoming command syntax.

Common defensive patterns include:

  • Prefer direct process APIs that pass arguments separately and avoid shell interpretation
  • Apply strict allowlists and type validation to endpoint and analyzer inputs
  • Use fixed command templates with controlled arguments rather than concatenated command strings
  • Reduce the trust placed in client-controlled scan and download parameters
  • Run MobSF and analysis tooling with least-privilege accounts and isolated environments
  • Restrict access to administrative, scanning, and dynamic-analysis interfaces
  • Apply resource, filesystem, network, and device permissions appropriate to the workflow

Mitigation generally focuses on preventing untrusted data from becoming command syntax.

Common defensive patterns include:

  • Prefer direct process APIs that pass arguments separately and avoid shell interpretation
  • Apply strict allowlists and type validation to endpoint and analyzer inputs
  • Use fixed command templates with controlled arguments rather than concatenated command strings
  • Reduce the trust placed in client-controlled scan and download parameters
  • Run MobSF and analysis tooling with least-privilege accounts and isolated environments
  • Restrict access to administrative, scanning, and dynamic-analysis interfaces
  • Apply resource, filesystem, network, and device permissions appropriate to the workflow

How teams detect issues like this

Organizations can look for command injection risks through:

  • Static analysis rules identifying shell invocation APIs, command-string concatenation, and interpolation of request data
  • Code review checks for subprocess calls that enable shell parsing or accept unsanitized values
  • Testing that supplies metacharacter-like input to verify strict validation and argument isolation
  • Runtime monitoring for unexpected child processes, shell launches, or unusual ADB activity
  • API gateway and application logs showing anomalous parameters or unexpected command-related errors
  • Policy enforcement that requires approved process-execution wrappers and prohibits direct shell use where unnecessary

Organizations can look for command injection risks through:

  • Static analysis rules identifying shell invocation APIs, command-string concatenation, and interpolation of request data
  • Code review checks for subprocess calls that enable shell parsing or accept unsanitized values
  • Testing that supplies metacharacter-like input to verify strict validation and argument isolation
  • Runtime monitoring for unexpected child processes, shell launches, or unusual ADB activity
  • API gateway and application logs showing anomalous parameters or unexpected command-related errors
  • Policy enforcement that requires approved process-execution wrappers and prohibits direct shell use where unnecessary

Sources

SourceLink
github.comgithub.com/AmalJafarzade/CVE-2026-104585
github.comgithub.com/MobileSecurityFramework/Mobile-Security-Framework-MobSF/blob/master/mobsf/DynamicAnalyzer/views/android/tests_common.py

Frequently asked

questions

It may be remotely exploitable when an affected MobSF web or API interface is reachable by an attacker and accepts input that reaches the vulnerable command path. Exposure depends on network placement and access controls.

Not necessarily. The required access depends on the deployment's authentication and authorization configuration, but access to an affected workflow is generally necessary.

Avoid shell-based command construction, pass arguments through APIs that preserve argument boundaries, and enforce strict allowlists for values that influence analysis or download operations.

Combine secure process-execution wrappers, input validation, least-privilege execution, interface access controls, static analysis, and runtime monitoring for unexpected child processes.

It may be remotely exploitable when an affected MobSF web or API interface is reachable by an attacker and accepts input that reaches the vulnerable command path. Exposure depends on network placement and access controls.

Not necessarily. The required access depends on the deployment's authentication and authorization configuration, but access to an affected workflow is generally necessary.

Avoid shell-based command construction, pass arguments through APIs that preserve argument boundaries, and enforce strict allowlists for values that influence analysis or download operations.

Combine secure process-execution wrappers, input validation, least-privilege execution, interface access controls, static analysis, and runtime monitoring for unexpected child processes.

Find out what's already
exploitable in your codebase.