Hybrid (Chain)

This is not a writeup, just my notes about the machine.

Machine information

Operating System: Windows

Chain: True (2 Machines)

Credentials

Username
Password
Method
Scope

admin@hybrid.vl

Duckling21

Backup File

Roundcube Webmail

peter.turner@hybrid.vl

PeterIstToll!

Backup File

Roundcube Webmail

✅ Valid Usernames

🔑 Passwords list

Information Gathering

Nmap

Initial Enumeration

Enumerating the network file system

Mounting the network file system

Discovering leaked credentials into a files.

RoudCube enumeration

Discovering a vulnerable pluging

circle-info

Roundcube version 1.6.1 and prior has a vulnerability in markasjunk plugin allows attackers that send a specially crafted identity email address to cause the plugin to execute arbitrary code.

Exploitation

Modifying the user's email field to abuse the RCE.

Lateral Movement to peter.turner

Abusing UID Spoofing and NFS Share

Attack Path:

To escalate privileges, the tester leveraged an NFS share misconfiguration that allowed file manipulation using the www-data account. The exploitation flow was as follows:

  1. UID Spoofing: On the tester's machine, a local user was created with the same UID as the target user peter.turner@hybrid.vl (UID: 902601108) to impersonate them over the NFS share:

  2. Abusing NFS Share with www-data: The compromised www-data account had write access to a shared NFS directory. A custom Bash binary was placed into the NFS share from this account.

  3. Setting the SetUID Bit (on Attacker's Machine): From the attacker-controlled machine (where the spoofed user existed), the tester moved the Bash binary to a temporary directory (e.g., /tmp), modified its permissions to include the setuid bit, and moved it back into the NFS directory:

  4. Privilege Escalation: Back on the target machine, the www-data account executed the Bash binary with elevated privileges using the -p flag:

    This resulted in a shell running with the effective UID of peter.turner@hybrid.vl, allowing privilege escalation.

Privilege Escalation to root on mail01

Finding a Keepass database

Inside the peter.turner@hybrid.vl 's directory there was a keepass database file. I moved to my machine and extracted the credentials due reusing credentials.

Abusing the sudoers configuration

Compromising Domain controller

Discovering Domain Computers is vulnerable to ESC1

Extracting the Compromised Computer NT Hash to abuse the ESC1

Abusing the ESC1 to compromise domain controler.

Requesting administrator's Ticket Granting ticket TGT

Obtaining a shell as Administrator on DC01

Last updated