Examers.io
ExamsOrganizationsHow it worksPricingHelp & FAQ
CompTIA logo

CompTIAPenTest+

Domain 2Objective 4

Script Modification PT0-003 Practice Questions (Page 1)

Part of the Reconnaissance and enumeration domain, which accounts for 21% of the PT0-003 exam. CompTIA does not publish an official question count, but from its 165-minute exam (~65–110 total, ~14–23 in this domain), expect 4–6 from this objective — we provide 26 practice questions to prepare you well beyond it. (estimate)

26questions here
6free pages
9concepts
21%of the exam

Questions 1–5

  1. 1foundation · easy

    A penetration tester has a Python script that scans a hardcoded list of ports. To make the script more flexible for different engagements, what is the most appropriate modification?

    Select an answer first
  2. 2expert · hard

    A penetration tester is writing a Bash script to enumerate SNMP community strings on a target. The script currently uses `snmpwalk` with a single community string. The tester needs to modify the script to try a list of common community strings from a file, and for each successful one, save the output to a separate file. The tester is concerned about the script's runtime and wants to avoid unnecessary delays. Which approach should the tester take?

    Select an answer first
  3. 3foundation · easy

    What is the purpose of the indentation in a Python script that performs banner grabbing?

    Select an answer first
  4. 4application · medium

    A penetration tester is modifying a Bash script that performs banner grabbing on a list of open ports. The script currently uses `nc` (netcat) to connect to each port. The tester wants to replace `nc` with a more reliable utility that is often available by default on Linux systems and can also be used for port scanning. Which utility should the tester use?

    Select an answer first
  5. 5application · medium

    A penetration tester is writing a PowerShell script to enumerate all network shares on a remote Windows machine. The script needs to use the `net view` command and capture its output for further processing. Which PowerShell approach should the tester use to run the external command and store the output in a variable?

    Select an answer first
Finished these 5 questions?

Review the revealed explanations, or continue through the curriculum.

Free Basic Practice is a study aid with revealable answers — not a scored exam. Examers.io is independent and not affiliated with or endorsed by CompTIA. “PT0-003” is a trademark of its owner, used for identification only.