# Pterodactyl writeup

## Phase 1: Scanning and Recon

First step is starting nmap scan to scan for open ports on the machine

<figure><img src="/files/DxJYtBea0scCGO4rna7L" alt=""><figcaption></figcaption></figure>

Found two open ports 22 (SSH) and 80 (HTTP)

By accessing the http server through the browser it redirects to pterodactyl.htb, so we have to add it in /etc/hosts file

<figure><img src="/files/DdT9tSyEBDf0dSkm8uya" alt=""><figcaption></figcaption></figure>

By enumerating for Subdomains using FFUF, found panel subdomain

```
ffuf -w /home/mohab/Downloads/subdomains-top1million-5000.txt -u http://pterodactyl.htb/ -H "Host: FUZZ.pterodactyl.htb" -fs 145
```

<figure><img src="/files/XpZn6EEuRbbHzqhqf7zU" alt=""><figcaption></figcaption></figure>

We can visit panel.pterodactyl.htb after adding it to /etc/hosts

<figure><img src="/files/RjtX4Ug3DKT9KBWIDBX2" alt=""><figcaption></figcaption></figure>

After researching i found an Unautheticated RCE vulnerability CVE-2025-49132

## Exploitation

after searching for CVE-2025-49132, I found an exploit on github

{% embed url="<https://github.com/malw0re/CVE-2025-49132-Mods>" %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://0xk3rypton.gitbook.io/0xk3rypt0n-blog/penetration-testing/ctf-writeups/hackthebox/pterodactyl-writeup.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
