This lab demonstrates exploiting a Remote Code Execution (RCE) vulnerability in PluXml v5.8.7 (CVE-2022-25018) by injecting a malicious PHP payload into a static page. Privilege escalation is achieved by discovering root credentials in the mail directory, enabling direct root access. This lab highlights weak web protections, file upload vulnerabilities, and privilege escalation through credential disclosure.
ports=$(nmap -p- --min-rate=1000 -T4 $VICTIM| grep '^[0-9]'| cut -d '/' -f 1| tr '\n'','| sed s/,$//)Running second nmap scan with open ports: 22,80
Starting Nmap 7.95 ( https://nmap.org ) at 2026-03-12 19:00 CET
Nmap scan report for$VICTIMHost is up (0.029s latency).
PORT STATE SERVICE VERSION
22/tcp open ssh OpenSSH 8.4p1 Debian 5+deb11u1 (protocol 2.0)| ssh-hostkey:
|3072 c9:c3:da:15:28:3b:f1:f8:9a:36:df:4d:36:6b:a7:44 (RSA)|256 26:03:2b:f6:da:90:1d:1b:ec:8d:8f:8d:1e:7e:3d:6b (ECDSA)|_ 256 fb:43:b2:b0:19:2f:d3:f6:bc:aa:60:67:ab:c1:af:37 (ED25519)80/tcp open http Apache httpd 2.4.56 ((Debian))|_http-title: PluXml - Blog or CMS, XML powered !
|_http-server-header: Apache/2.4.56 (Debian)Warning: OSScan results may be unreliable because we could not find at least 1 open and 1 closed port
Device type: general purpose|router
Running: Linux 4.X|5.X, MikroTik RouterOS 7.X
OS CPE: cpe:/o:linux:linux_kernel:4 cpe:/o:linux:linux_kernel:5 cpe:/o:mikrotik:routeros:7 cpe:/o:linux:linux_kernel:5.6.3
OS details: Linux 4.15 - 5.19, Linux 5.0 - 5.14, MikroTik RouterOS 7.2 - 7.5 (Linux 5.6.3)Network Distance: 4 hops
Service Info: OS: Linux; CPE: cpe:/o:linux:linux_kernel
We see the CMS. Let’s do a but of enumeration before looking it up online for exploits. We find it’s admin page from the footer and we are going to login with “default creds”.
Admin creds
admin:admin
Logged in as admin we can see the version of the CMS, PluXml 5.8.7. Looking it up online we find CVE-2022-25018.
A public exploit exists and instruction on how to exploit it manually. We are gonna do that. The exploit works by:
Login as Admin
In the Admin menu select static page and edit one
Insert the PHP code there with the relevant tags <?php ?>
Save changes and view the page for the code to execute
For the listener we are going to use penelope a really cool reverse listener with some extra stuff and automation like auto upgrading to a PTY when the callback comes.
After visiting the static page we get our callback.
We had linpeas run as usual but also from our own enumeration we see that there is an SMTP service running on port 25.
1
2
3
4
ss -tlnp
State Recv-Q Send-Q Local Address:Port Peer Address:Port Process
LISTEN 0128 0.0.0.0:22 0.0.0.0:* users:(("sshd",pid=569,fd=3))LISTEN 020 127.0.0.1:25 0.0.0.0:*
We are going to look on the interesting mail folders found for www-data user.
1
2
3
4
5
6
www-data@plum:/tmp$ cd /var/mail
www-data@plum:/var/mail$ ls -al
total 16drwxrwsr-x 2 root mail 4096 Mar 12 14:42 .
drwxr-xr-x 12 root root 4096 Aug 252023 ..
-rw-rw---- 1 www-data mail 4563 Mar 12 14:42 www-data
Reading up the mail we find hardcoded the root password!
www-data@plum:/var/mail$ cat www-data
From root@localhost Fri Aug 25 06:31:47 2023Return-path: <root@localhost>
Envelope-to: www-data@localhost
Delivery-date: Fri, 25 Aug 2023 06:31:47 -0400
Received: from root by localhost with local(Exim 4.94.2)(envelope-from <root@localhost>) id 1qZU6V-0000El-Pw
for www-data@localhost; Fri, 25 Aug 2023 06:31:47 -0400
To: www-data@localhost
From: root@localhost
Subject: URGENT - DDOS ATTACK"
Reply-to: root@localhost
Message-Id: <E1qZU6V-0000El-Pw@localhost>
Date: Fri, 25 Aug 2023 06:31:47 -0400
We are under attack. We've been targeted by an extremely complicated and sophisicated DDOS attack. I trust your skills. Please save us from this. Here are the credentials for the root user:
root:6s8kaZZNaZZYBMfh2YEW
Thanks,
Administrator