root@kali:~/Desktop# nmap -T4 -A -v -Pn 10.10.11.242 Host discovery disabled (-Pn). All addresses will be marked 'up' and scan times may be slower. Starting Nmap 7.94SVN ( https://nmap.org ) at 2024-01-25 00:12 CST NSE: Loaded 156 scripts for scanning. NSE: Script Pre-scanning. Initiating NSE at 00:12 Completed NSE at 00:12, 0.00s elapsed Initiating NSE at 00:12 Completed NSE at 00:12, 0.00s elapsed Initiating NSE at 00:12 Completed NSE at 00:12, 0.00s elapsed Initiating Parallel DNS resolution of 1 host. at 00:12 Completed Parallel DNS resolution of 1 host. at 00:12, 0.01s elapsed Initiating SYN Stealth Scan at 00:12 Scanning 10.10.11.242 [1000 ports] Discovered open port 22/tcp on 10.10.11.242 Discovered open port 80/tcp on 10.10.11.242 Increasing send delay for 10.10.11.242 from 0 to 5 due to max_successful_tryno increase to 5 Increasing send delay for 10.10.11.242 from 5 to 10 due to max_successful_tryno increase to 6 Completed SYN Stealth Scan at 00:13, 48.63s elapsed (1000 total ports) Initiating Service scan at 00:13 Scanning 2 services on 10.10.11.242 Completed Service scan at 00:13, 7.42s elapsed (2 services on 1 host) Initiating OS detection (try #1) against 10.10.11.242 Retrying OS detection (try #2) against 10.10.11.242 Retrying OS detection (try #3) against 10.10.11.242 Initiating Traceroute at 00:14 Completed Traceroute at 00:14, 1.81s elapsed Initiating Parallel DNS resolution of 2 hosts. at 00:14 Completed Parallel DNS resolution of 2 hosts. at 00:14, 0.01s elapsed NSE: Script scanning 10.10.11.242. Initiating NSE at 00:14 Completed NSE at 00:14, 27.06s elapsed Initiating NSE at 00:14 Completed NSE at 00:14, 4.96s elapsed Initiating NSE at 00:14 Completed NSE at 00:14, 0.00s elapsed Nmap scan report for 10.10.11.242 Host is up (0.50s latency). Not shown: 998 closed tcp ports (reset) PORT STATE SERVICE VERSION 22/tcp open ssh OpenSSH 8.2p1 Ubuntu 4ubuntu0.9 (Ubuntu Linux; protocol 2.0) | ssh-hostkey: | 3072 48:ad:d5:b8:3a:9f:bc:be:f7:e8:20:1e:f6:bf:de:ae (RSA) | 256 b7:89:6c:0b:20:ed:49:b2:c1:86:7c:29:92:74:1c:1f (ECDSA) |_ 256 18:cd:9d:08:a6:21:a8:b8:b6:f7:9f:8d:40:51:54:fb (ED25519) 80/tcp open http nginx 1.18.0 (Ubuntu) |_http-title: Did not follow redirect to http://devvortex.htb/ | http-methods: |_ Supported Methods: GET HEAD POST OPTIONS |_http-server-header: nginx/1.18.0 (Ubuntu) Aggressive OS guesses: Linux 5.0 (97%), Linux 4.15 - 5.8 (96%), Linux 5.3 - 5.4 (95%), Linux 2.6.32 (95%), Linux 5.0 - 5.5 (95%), Linux 3.1 (95%), Linux 3.2 (95%), AXIS 210A or 211 Network Camera (Linux 2.6.17) (95%), ASUS RT-N56U WAP (Linux 3.4) (93%), Linux 3.16 (93%) No exact OS matches for host (test conditions non-ideal). Uptime guess: 0.000 days (since Thu Jan 25 00:14:02 2024) Network Distance: 2 hops TCP Sequence Prediction: Difficulty=252 (Good luck!) IP ID Sequence Generation: All zeros Service Info: OS: Linux; CPE: cpe:/o:linux:linux_kernel
TRACEROUTE (using port 111/tcp) HOP RTT ADDRESS 1 792.32 ms 10.10.14.1 2 792.48 ms 10.10.11.242
NSE: Script Post-scanning. Initiating NSE at 00:14 Completed NSE at 00:14, 0.00s elapsed Initiating NSE at 00:14 Completed NSE at 00:14, 0.00s elapsed Initiating NSE at 00:14 Completed NSE at 00:14, 0.00s elapsed Read data files from: /usr/bin/../share/nmap OS and Service detection performed. Please report any incorrect results at https://nmap.org/submit/ . Nmap done: 1 IP address (1 host up) scanned in 115.80 seconds Raw packets sent: 1442 (66.912KB) | Rcvd: 1303 (58.018KB)
从上面扫描的结果来看,可以发现主机开启了80和22端口,那么就先从80端口下手。
可以尝试访问80端口,但是发现页面无法打开,那么就尝试将IP和域名在host表中进行绑定
1 2 3 4 5
root@kali:~/Desktop# vim /etc/hosts root@kali:~/Desktop# cat /etc/hosts 127.0.0.1 localhost 127.0.1.1 kali 10.10.11.242 devvortex.htb
root@kali:~/Desktop# dirsearch -u http://devvortex.htb/ /usr/lib/python3/dist-packages/dirsearch/dirsearch.py:23: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html from pkg_resources import DistributionNotFound, VersionConflict