CompTIA Network+ N10-009 · Network Troubleshooting · medium
A Linux systems administrator suspects that a compromised container is opening an unauthorized outbound reverse shell connection over TCP port 4444 to an external command-and-control (C2) IP address, and also wants to capture the raw packets on interface eth0 for port 4444 into a .pcap file for forensic analysis. Which pair of Linux CLI commands lists active TCP socket connections with process IDs (PID) and captures matching packets on eth0?
Published · Last updated · checked before publication — how we verify questions
Options
Answer: B. Run ss -tulnp to list sockets/PIDs and tcpdump -i eth0 port 4444 -w out.pcap
- ss -tulnp (or netstat -tulnp / netstat -ano) displays all listening and established TCP/UDP sockets along with numeric IP/port addresses and the owning Process ID (PID) / program name. - tcpdump -i eth0 tcp port 4444 -w capture.pcap captures raw packets matching the BPF filter on eth0 into a standard libpcap file.
Why the other options are wrong
- A. Run dig +short -x 4444 to list local process IDs and arp -d to capture .pcap packets — dig queries DNS servers and arp -d deletes an ARP cache entry; neither lists local PIDs or captures packets.
- C. Run traceroute -n 4444 to list local process IDs and nslookup to write .pcap files — traceroute maps Layer 3 router hops and nslookup queries DNS names.
- D. Run chmod 777 /etc/resolv.conf to list TCP sockets and ping -c 4 to capture payloads — chmod changes file permissions and ping sends ICMP Echo Requests.
More Network Troubleshooting questions
- A user reports that their Windows workstation can no longer reach internal file servers or the internet. Running…
- According to the official CompTIA 7-Step Network Troubleshooting Methodology, a network technician has already (1)…
- A network engineer is installing a 10GBASE-LR Single-Mode Fiber link between two buildings. The SFP+ transmitter…
- A technician is troubleshooting an unlabeled bundle of 48 Cat 6 copper cables inside a wiring closet to find which…
- A user on a desktop connected to switch port Gi1/0/12 complains that large file transfers are painfully slow (< 1 Mbps…
All Network Troubleshooting questions and the topic overview →
CompTIA and Security+ are trademarks of the Computing Technology Industry Association. PrepIQ Hub is not affiliated with, endorsed by, or sponsored by CompTIA.