Writeup by wook413

Enumeration

Nmap

initial TCP scan

Second TCP scan performed on the discovered ports

Lastly, UDP scan on the top 10 ports

Initial Access

HTTP 80

I tried to access the target IP via a web browser, but the host postfish.off could not be resolved so I added the following in /etc/hosts

The /team.html page lists four team members; I have noted their names as they may serve as potential usernames later.

image-20260128120402288

SMTP 25

Having exhausted potential leads from the web interface, I proceeded to enumerate the SMTP service. I first used username-anarchy to generate a list of potential username permutations based on the identified staff names.

Running smtp-user-enum confirmed that three usernames from the generated list are valid on the server.

Despite extensive brute-force attempts, I was initially unable to identify passwords for these three accounts.

I ran smtp-user-enum again using this custom wordlist, which successfully identified two additional valid accounts.

The consolidated list of discovered valid usernames is as follows::

Finally found a set of valid credentials using hydra

I successfully logged into pop3 server and found the following email

Then I sent a phishing email to Brian Moore who is a part of the sales team using swaks

After waiting a few minutes, I received a callback on my listener containing Brian’s credentials: EternaLSunshinE

Successfully got into SSH using his credentials

Found local.txt under /home/brian.moore

Privilege Escalation

id command revealed that the user brian.moore is a member of the filter group

I identified an unusual file at /etc/postfix/disclaimer which is writable by any user in the filter group

I replaced the original file with the following code

To execute the modified script and establish a connection to my listener, I sent another email to trigger the mail filter.

Got the shell as filter

filter can run /usr/bin/mail without password

Got the shell as root

Found proof.txt