Summer Sale Special Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: xmas50

CompTIA PT0-003 - CompTIA PenTest+ Exam

Page: 1 / 10
Total 330 questions

During a preengagement activity with a new customer, a penetration tester looks for assets to test. Which of the following is an example of a target that can be used for testing?

A.

API

B.

HTTP

C.

IPA

D.

ICMP

During a web application assessment, a penetration tester accesses the site unauthenticated and receives the following Set-Cookie on the first response:

auth=yYKGORbrpabgr842ajbvrpbptau42342

When the tester logs in, the server sends only one Set-Cookie header, and the value is exactly the same as shown above. Which of the following vulnerabilities has the tester discovered?

A.

JWT manipulation

B.

Cookie poisoning

C.

Session fixation

D.

Collision attack

A penetration tester creates the following Python script that can be used to enumerate information about email accounts on a target mail server:

Which of the following logic constructs would permit the script to continue despite failure?

A.

Add a do/while loop.

B.

Add an iterator.

C.

Add a t.ry/except. block.

D.

Add an if/else conditional.

While performing a penetration test, a tester executes the following command:

PS c:\tools > c:\hacks\PsExec.exe \\server01.cor.ptia.org -accepteula cmd.exe

Which of the following best explains what the tester is trying to do?

A.

Test connectivity using PsExec on the server01 using cmd.exe

B.

Perform a lateral movement attack using PsExec

C.

Send the PsExec binary file to the server01 using cmd.exe

D.

Enable cmd.exe on the server01 through PsExec

During a penetration test, the tester identifies several unused services that are listening on all targeted internal laptops. Which of the following technical controls should the tester recommend to reduce the risk of compromise?

A.

Multifactor authentication

B.

Patch management

C.

System hardening

D.

Network segmentation

A penetration tester is using OSINT to identify client email addresses found on the web for a phishing campaign. Which of the following is the best search operator for the tester to use?

A.

site:

B.

intitle:

C.

intext:

D.

inurl:

openssl passwd password

$1$OjxLvZ85$Fdr51vn/Z4zXWsQR/Xrj.

The tester then adds the following line to the world-writable script:

echo ' root2:$1$0jxLvZ85$Fdr51vn/Z4zXWsQR/Xrj .: 1001:1001:,,,:/root:/bin/bash " > > /etc/passwd

Which of the following should the penetration tester do to enable this exploit to work correctly?

A.

Use only a single redirect to /etc/password.

B.

Generate the password using md5sum.

C.

Log in to the host using SSH.

D.

Change the 1001 entries to 0.

A penetration tester is attempting to exfiltrate sensitive data from a client environment without alerting the client ' s blue team. Which of the following exfiltration methods most likely remain undetected?

A.

Cloud storage

B.

Email

C.

Domain Name System

D.

Test storage sites

A penetration tester writes a Bash script to automate the execution of a ping command on a Class C network:

for var in --MISSING TEXT-- do

ping -c 1 192.168.10.$var

done

Which of the following pieces of code should the penetration tester use in place of —MISSING TEXT—?

A.

crunch 1 254 loop

B.

seq 1 254

C.

echo 1-254

D.

fl..254

A penetration tester gains access to a host with many applications that load at startup and run as SYSTEM. The penetration tester runs a command and receives the following output:

User accounts for \COMPTIA-Host

CompTIA User DefaultAccount Guest

CompTIA Admin CompTIA Accountant

The command completed successfully.

Which of the following attacks will most likely allow the penetration tester to escalate privileges?

A.

Credential dumping

B.

Local file inclusion

C.

Unquoted service path injection

D.

Process hijacking