module

Maltrail Unauthenticated Command Injection

Disclosed
Jul 31, 2023
Created
Aug 17, 2023

Description

Maltrail is a malicious traffic detection system, utilizing publicly
available blacklists containing malicious and/or generally suspicious trails.
The Maltrail versions The `subprocess.check_output` function in `mailtrail/core/httpd.py` contains
a command injection vulnerability in the `params.get("username")` parameter.
An attacker can exploit this vulnerability by injecting arbitrary OS commands
into the username parameter. The injected commands will be executed with the
privileges of the running process. This vulnerability can be exploited remotely
without authentication.

Successfully tested against Maltrail versions 0.52 and 0.53.

Authors

Ege BALCI [email protected]
Valentin Lobstein
Chris Wild

Platform

Linux,Unix

Architectures

cmd, x86, x64

Module Options

To display the available options, load the module within the Metasploit console and run the commands 'show options' or 'show advanced':


msf > use exploit/unix/http/maltrail_rce
msf exploit(maltrail_rce) > show targets
...targets...
msf exploit(maltrail_rce) > set TARGET < target-id >
msf exploit(maltrail_rce) > show options
...show and set options...
msf exploit(maltrail_rce) > exploit

Title
Rapid7 Labs

2026 Global Threat Landscape Report

The predictive window has collapsed. Exploitation follows disclosure in days. See how attackers are accelerating and how to stay ahead.