CompTIA PenTest+ (PT0-002) — Question 203
During a vulnerability scanning phase, a penetration tester wants to execute an Nmap scan using custom NSE scripts stored in the following folder:
/home/user/scripts
Which of the following commands should the penetration tester use to perform this scan?
Answer options
- A. nmap --resume "not intrusive"
- B. nmap --script default,safe
- C. nmap --script /home/user/scripts
- D. nmap --load /home/user/scripts
Correct answer: C
Explanation
The correct answer is C because the --script option allows the tester to specify a directory containing custom NSE scripts. Options A and B do not point to the custom scripts directory, and option D is incorrect because Nmap does not have a --load option for executing scripts.