Interpreter
Executive summary — Interpreter chains an unauthenticated RCE in Mirth Connect 4.4.0 (an HL7/FHIR healthcare integration platform) via CVE-2023-43208, a bypass of the incomplete patch for CVE-2023-37679 that swaps the XStream deserialization gadget (the already-blocked
ImageIO/NativeStringfor an Apache commons-collections4ChainedTransformer) to get code execution as themirthservice user. From there, Mirth's own internal database credentials lead to an HL7 channel that forwards data to a local Flask microservice running as root — and that microservice feeds user-controlled patient fields into aneval()'d f-string, behind an input filter that permits exactly the characters needed to build an arbitrary Python expression.
| Platform | Hack The Box |
| Operating system | Linux |
| Difficulty | Medium |
| Status | Retired |
| Target IP | <TARGET_IP> |
Attack map
[22,80,443,6661] Mirth Connect Administrator 4.4.0 (Jetty)
| CVE-2023-43208 - XStream deserialization (commons-collections4 gadget)
v
[RCE] mirth (uid=103, HOME=/nonexistent)
| conf/mirth.properties -> MariaDB mirthdb; HL7 channel -> 127.0.0.1:54321
v
[127.0.0.1:54321] notif.py (Flask, root)
| eval of an f-string with interpolated patient fields (CWE-94/95);
| regex filter allows ( ) { } ' " + . / =
v
[ROOT] Python expression embedded in a field -> command execution as root
-> user.txt + root.txt
1. Reconnaissance
sudo nmap -sS -p- --min-rate 3000 -T4 <TARGET_IP> -oN nmap_allports.txt
sudo nmap -sCV -p 22,80,443,6661 <TARGET_IP> -oN nmap_services.txt
22/tcp open ssh OpenSSH 9.2p1 Debian 2+deb12u7
80/tcp open http Jetty | http-title: Mirth Connect Administrator
443/tcp open ssl/http Jetty | ssl-cert: commonName=mirth-connect
6661/tcp open unknown (Mirth channel listener, java)
Service Info: OS: Linux
A small, unambiguous port set: SSH, the Mirth Connect web admin panel over HTTP/HTTPS, and a listener on 6661 that (confirmed later) is a Mirth channel port waiting for HL7 messages. The exact application version doesn't show in any standard banner; Mirth's API only exposes it when asked with the right header:
curl -sk https://<TARGET_IP>/api/server/version -H "X-Requested-With: XMLHttpRequest"
# 4.4.0
Mirth Connect 4.4.0 is vulnerable to CVE-2023-43208, a bypass of the incomplete patch for CVE-2023-37679 (fixed in 4.4.1).
Root Access unlocks the content you can't see — everything else on the site is already open.
See Root Access plansNo account? Create one free then upgrade from your console.