nerdexam
CompTIA

PT0-002 · Question #189

A penetration tester finds a PHP script used by a web application in an unprotected internal source code repository. After reviewing the code, the tester identifies the following: Which of the…

The correct answer is B. Netcat and cURL. The combination of Netcat and cURL is ideal for exploiting server-side web application vulnerabilities, using cURL to craft malicious requests and Netcat to establish network connections for shells or data transfer.

Attacks and Exploits

Question

A penetration tester finds a PHP script used by a web application in an unprotected internal source code repository. After reviewing the code, the tester identifies the following:

Which of the following combinations of tools would the penetration tester use to exploit this script?

Options

  • AHydra and crunch
  • BNetcat and cURL
  • CBurp Suite and DIRB
  • DNmap and OWASP ZAP

How the community answered

(49 responses)
  • A
    14% (7)
  • B
    78% (38)
  • C
    2% (1)
  • D
    6% (3)

Why each option

The combination of Netcat and cURL is ideal for exploiting server-side web application vulnerabilities, using cURL to craft malicious requests and Netcat to establish network connections for shells or data transfer.

AHydra and crunch

Hydra and crunch are primarily used for brute-forcing credentials or services, which is not the most direct method for exploiting a script vulnerability unless it specifically involves weak authentication.

BNetcat and cURLCorrect

cURL can be used to send crafted HTTP requests that exploit a vulnerability in the PHP script, such as command injection or file inclusion, while Netcat can then be used to establish a reverse shell, bind shell, or exfiltrate data from the compromised server. This pairing allows for both the initiation of an exploit and subsequent interaction with the compromised system.

CBurp Suite and DIRB

While Burp Suite is a powerful web application testing proxy, DIRB is a content discovery tool; this combination is more for finding vulnerabilities and enumeration rather than direct exploitation requiring network interaction like a shell.

DNmap and OWASP ZAP

Nmap is a network scanner for host and service discovery, and OWASP ZAP is an automated web vulnerability scanner; neither is ideal for manual, targeted exploitation and interactive shell access.

Concept tested: Web application exploitation tools

Topics

#Penetration Testing Tools#Web Exploitation#Command-line Utilities#PHP Script Exploitation

Community Discussion

No community discussion yet for this question.

Full PT0-002 Practice