ExamGecko
Home Home / CompTIA / PT0-003

CompTIA PT0-003 Practice Test - Questions Answers, Page 10

Question list
Search
Search

List of questions

Search

Related questions











A tester runs an Nmap scan against a Windows server and receives the following results:

Nmap scan report for win_dns.local (10.0.0.5)

Host is up (0.014s latency)

Port State Service

53/tcp open domain

161/tcp open snmp

445/tcp open smb-ds

3389/tcp open rdp

Which of the following TCP ports should be prioritized for using hash-based relays?

A.
53
A.
53
Answers
B.
161
B.
161
Answers
C.
445
C.
445
Answers
D.
3389
D.
3389
Answers
Suggested answer: C

Explanation:

Port 445 is used for SMB (Server Message Block) services, which are commonly targeted for hash-based relay attacks like NTLM relay attacks.

Step-by-Step Explanation

Understanding Hash-Based Relays:

NTLM Relay Attack: An attacker intercepts and relays NTLM authentication requests to another service, effectively performing authentication on behalf of the victim.

SMB Protocol: Port 445 is used for SMB/CIFS traffic, which supports NTLM authentication.

Prioritizing Port 445:

Vulnerability: SMB is often targeted because it frequently supports NTLM authentication, making it susceptible to relay attacks.

Tools: Tools like Responder and NTLMRelayX are commonly used to capture and relay NTLM hashes over SMB.

Execution:

Capture Hash: Use a tool like Responder to capture NTLM hashes.

Relay Hash: Use a tool like NTLMRelayX to relay the captured hash to another service on port 445.

Reference from Pentesting Literature:

Penetration testing guides frequently discuss targeting SMB (port 445) for hash-based relay attacks.

HTB write-ups often include examples of NTLM relay attacks using port 445.

Penetration Testing - A Hands-on Introduction to Hacking

HTB Official Writeups

During an assessment, a penetration tester runs the following command:

setspn.exe -Q /

Which of the following attacks is the penetration tester preparing for?

A.
LDAP injection
A.
LDAP injection
Answers
B.
Pass-the-hash
B.
Pass-the-hash
Answers
C.
Kerberoasting
C.
Kerberoasting
Answers
D.
Dictionary
D.
Dictionary
Answers
Suggested answer: C

Explanation:

Kerberoasting is an attack that involves requesting service tickets for service accounts from a Kerberos service, extracting the service tickets, and attempting to crack them offline to retrieve the plaintext passwords.

Step-by-Step Explanation

Understanding Kerberoasting:

Purpose: To obtain service account passwords by cracking the encrypted service tickets (TGS tickets) offline.

Service Principal Names (SPNs): SPNs are used in Kerberos authentication to uniquely identify a service instance.

Command Breakdown:

setspn.exe -Q /: This command queries all SPNs in the domain.

Use Case: Identifying accounts with SPNs that can be targeted for Kerberoasting.

Kerberoasting Steps:

Identify SPNs: Use setspn.exe to list service accounts with SPNs.

Request TGS Tickets: Request TGS tickets for the identified SPNs.

Extract Tickets: Use tools like Mimikatz to extract the service tickets.

Crack Tickets: Use password cracking tools like Hashcat to crack the extracted tickets offline.

Reference from Pentesting Literature:

Kerberoasting is a well-documented attack method in penetration testing guides, specifically targeting service accounts in Active Directory environments.

HTB write-ups often detail the use of Kerberoasting for gaining credentials from service accounts.

Penetration Testing - A Hands-on Introduction to Hacking

HTB Official Writeups

During an assessment, a penetration tester obtains a low-privilege shell and then runs the following command:

findstr /SIM /C:'pass' *.txt *.cfg *.xml

Which of the following is the penetration tester trying to enumerate?

A.
Configuration files
A.
Configuration files
Answers
B.
Permissions
B.
Permissions
Answers
C.
Virtual hosts
C.
Virtual hosts
Answers
D.
Secrets
D.
Secrets
Answers
Suggested answer: D

Explanation:

By running the command findstr /SIM /C:'pass' *.txt *.cfg *.xml, the penetration tester is trying to enumerate secrets.

Command Analysis:

findstr: A command-line utility in Windows used to search for specific strings in files.

/SIM: Combination of options; /S searches for matching files in the current directory and all subdirectories, /I specifies a case-insensitive search, and /M prints only the filenames with matching content.

/C:'pass': Searches for the literal string 'pass'.

***.txt .cfg .xml: Specifies the file types to search within.

Objective:

The command is searching for the string 'pass' within .txt, .cfg, and .xml files, which is indicative of searching for passwords or other sensitive information (secrets).

These file types commonly contain configuration details, credentials, and other sensitive data that might include passwords or secrets.

Other Options:

Configuration files: While .cfg and .xml files can be configuration files, the specific search for 'pass' indicates looking for secrets like passwords.

Permissions: This command does not check or enumerate file permissions.

Virtual hosts: This command is not related to enumerating virtual hosts.

Pentest

Reference:

Post-Exploitation: Enumerating sensitive information like passwords is a common post-exploitation activity after gaining initial access.

Credential Discovery: Searching for stored credentials within configuration files and documents to escalate privileges or move laterally within the network.

By running this command, the penetration tester aims to find stored passwords or other secrets that could help in further exploitation of the target system.

During an assessment, a penetration tester wants to extend the vulnerability search to include the use of dynamic testing. Which of the following tools should the tester use?

A.
Mimikatz
A.
Mimikatz
Answers
B.
ZAP
B.
ZAP
Answers
C.
OllyDbg
C.
OllyDbg
Answers
D.
SonarQube
D.
SonarQube
Answers
Suggested answer: B

Explanation:

Dynamic Application Security Testing (DAST):

Definition: DAST involves testing the application in its running state to identify vulnerabilities that could be exploited by an attacker.

Purpose: Simulates attacks on a live application, examining how it behaves and identifying security weaknesses.

ZAP (Zed Attack Proxy):

Description: An open-source DAST tool developed by OWASP.

Features: Capable of scanning web applications for vulnerabilities, including SQL injection, XSS, CSRF, and other common web application vulnerabilities.

Usage: Ideal for dynamic testing as it interacts with the live application and identifies vulnerabilities that may not be visible in static code analysis.

Other Tools:

Mimikatz: Used for post-exploitation activities, specifically credential dumping on Windows systems.

OllyDbg: A debugger used for reverse engineering and static analysis of binary files, not suitable for dynamic testing.

SonarQube: A static code analysis tool used for SAST (Static Application Security Testing), not for dynamic testing.

Pentest

Reference:

Web Application Security Testing: Utilizing DAST tools like ZAP to dynamically test and find vulnerabilities in running web applications.

OWASP Tools: Leveraging open-source tools recommended by OWASP for comprehensive security testing.

By using ZAP, the penetration tester can perform dynamic testing to identify runtime vulnerabilities in web applications, extending the scope of the vulnerability search.

During an engagement, a penetration tester found some weaknesses that were common across the customer's entire environment. The weaknesses included the following:

Weaker password settings than the company standard

Systems without the company's endpoint security software installed

Operating systems that were not updated by the patch management system

Which of the following recommendations should the penetration tester provide to address the root issue?

A.
Add all systems to the vulnerability management system.
A.
Add all systems to the vulnerability management system.
Answers
B.
Implement a configuration management system.
B.
Implement a configuration management system.
Answers
C.
Deploy an endpoint detection and response system.
C.
Deploy an endpoint detection and response system.
Answers
D.
Patch the out-of-date operating systems.
D.
Patch the out-of-date operating systems.
Answers
Suggested answer: B

Explanation:

Identified Weaknesses:

Weaker password settings than the company standard: Indicates inconsistency in password policies across systems.

Systems without the company's endpoint security software installed: Suggests lack of uniformity in security software deployment.

Operating systems not updated by the patch management system: Points to gaps in patch management processes.

Configuration Management System:

Definition: A configuration management system automates the deployment, maintenance, and enforcement of configurations across all systems in an organization.

Benefits: Ensures consistency in security settings, software installations, and patch management across the entire environment.

Examples: Tools like Ansible, Puppet, and Chef can help automate and manage configurations, ensuring compliance with organizational standards.

Other Recommendations:

Vulnerability Management System: While adding systems to this system helps track vulnerabilities, it does not address the root cause of configuration inconsistencies.

Endpoint Detection and Response (EDR): Useful for detecting and responding to threats, but not for enforcing consistent configurations.

Patch Management: Patching systems addresses specific vulnerabilities but does not solve broader configuration management issues.

Pentest

Reference:

System Hardening: Ensuring all systems adhere to security baselines and configurations to reduce attack surfaces.

Automation in Security: Using configuration management tools to automate security practices, ensuring compliance and reducing manual errors.

Implementing a configuration management system addresses the root issue by ensuring consistent security configurations, software deployments, and patch management across the entire environment.

A penetration tester obtains password dumps associated with the target and identifies strict lockout policies. The tester does not want to lock out accounts when attempting access. Which of the following techniques should the tester use?

A.
Credential stuffing
A.
Credential stuffing
Answers
B.
MFA fatigue
B.
MFA fatigue
Answers
C.
Dictionary attack
C.
Dictionary attack
Answers
D.
Brute-force attack
D.
Brute-force attack
Answers
Suggested answer: A

Explanation:

To avoid locking out accounts while attempting access, the penetration tester should use credential stuffing.

Credential Stuffing:

Definition: An attack method where attackers use a list of known username and password pairs, typically obtained from previous data breaches, to gain unauthorized access to accounts.

Advantages: Unlike brute-force attacks, credential stuffing uses already known credentials, which reduces the number of attempts per account and minimizes the risk of triggering account lockout mechanisms.

Tool: Tools like Sentry MBA, Snipr, and others are commonly used for credential stuffing attacks.

Other Techniques:

MFA Fatigue: A social engineering tactic to exhaust users into accepting multi-factor authentication requests, not applicable for avoiding lockouts in this context.

Dictionary Attack: Similar to brute-force but uses a list of likely passwords; still risks lockout due to multiple attempts.

Brute-force Attack: Systematically attempts all possible password combinations, likely to trigger account lockouts due to high number of failed attempts.

Pentest

Reference:

Password Attacks: Understanding different types of password attacks and their implications on account security.

Account Lockout Policies: Awareness of how lockout mechanisms work and strategies to avoid triggering them during penetration tests.

By using credential stuffing, the penetration tester can attempt to gain access using known credentials without triggering account lockout policies, ensuring a stealthier approach to password attacks.

A penetration tester runs a vulnerability scan that identifies several issues across numerous customer hosts. The executive report outlines the following information:

Server High-severity vulnerabilities

1. Development sandbox server 32

2. Back office file transfer server 51

3. Perimeter network web server 14

4. Developer QA server 92

The client is concerned about the availability of its consumer-facing production application. Which of the following hosts should the penetration tester select for additional manual testing?

A.
Server 1
A.
Server 1
Answers
B.
Server 2
B.
Server 2
Answers
C.
Server 3
C.
Server 3
Answers
D.
Server 4
D.
Server 4
Answers
Suggested answer: C

Explanation:

Client Concern:

Availability: The client is specifically concerned about the availability of their consumer-facing production application. Ensuring this application is secure and available is crucial to the business.

Server Analysis:

Server 1 (Development sandbox server): Typically not a production server; vulnerabilities here are less likely to impact the consumer-facing application.

Server 2 (Back office file transfer server): Important but generally more internal-facing and less likely to directly affect the consumer-facing application.

Server 3 (Perimeter network web server): Likely hosts the consumer-facing application or critical services related to it. High-severity vulnerabilities here could directly impact availability.

Server 4 (Developer QA server): Similar to Server 1, more likely to be used for testing rather than production, making it less critical for immediate manual testing.

Pentest

Reference:

Risk Prioritization: Focus on assets that have the most significant impact on business operations, especially those directly facing consumers.

Critical Infrastructure: Ensuring the security and availability of web servers exposed to the internet as they are prime targets for attacks.

By selecting Server 3 (the perimeter network web server) for additional manual testing, the penetration tester addresses the client's primary concern about the availability and security of the consumer-facing production application.

A penetration tester is conducting a wireless security assessment for a client with 2.4GHz and 5GHz access points. The tester places a wireless USB dongle in the laptop to start capturing WPA2 handshakes. Which of the following steps should the tester take next?

A.
Enable monitoring mode using Aircrack-ng.
A.
Enable monitoring mode using Aircrack-ng.
Answers
B.
Use Kismet to automatically place the wireless dongle in monitor mode and collect handshakes.
B.
Use Kismet to automatically place the wireless dongle in monitor mode and collect handshakes.
Answers
C.
Run KARMA to break the password.
C.
Run KARMA to break the password.
Answers
D.
Research WiGLE.net for potential nearby client access points.
D.
Research WiGLE.net for potential nearby client access points.
Answers
Suggested answer: A

Explanation:

Enabling monitoring mode on the wireless adapter is the essential step before capturing WPA2 handshakes. Monitoring mode allows the adapter to capture all wireless traffic in its vicinity, which is necessary for capturing handshakes.

Step-by-Step Explanation

Preparation:

Wireless USB Dongle: Ensure the wireless USB dongle is compatible with monitoring mode and packet injection.

Aircrack-ng Suite: Use the Aircrack-ng suite, a popular set of tools for wireless network auditing.

Enable Monitoring Mode:

Command: Use the airmon-ng tool to enable monitoring mode on the wireless interface.

airmon-ng start wlan0

Verify: Check if the interface is in monitoring mode.

iwconfig

Capture WPA2 Handshakes:

Airodump-ng: Use airodump-ng to start capturing traffic and handshakes.

airodump-ng wlan0mon

Reference from Pentesting Literature:

Enabling monitoring mode is a fundamental step in wireless penetration testing, discussed in guides like 'Penetration Testing - A Hands-on Introduction to Hacking'.

HTB write-ups often start with enabling monitoring mode before proceeding with capturing WPA2 handshakes.

Penetration Testing - A Hands-on Introduction to Hacking

HTB Official Writeups

A penetration tester gains access to a Windows machine and wants to further enumerate users with native operating system credentials. Which of the following should the tester use?

A.
route.exe print
A.
route.exe print
Answers
B.
netstat.exe -ntp
B.
netstat.exe -ntp
Answers
C.
net.exe commands
C.
net.exe commands
Answers
D.
strings.exe -a
D.
strings.exe -a
Answers
Suggested answer: C

Explanation:

The net.exe commands are native to the Windows operating system and are used to manage and enumerate network resources, including user accounts.

Step-by-Step Explanation

Using net.exe Commands:

User Enumeration: The net user command lists all user accounts on the system.

net user

Detailed User Information: To get detailed information about a specific user.

net user <username>

Additional net.exe Commands:

Groups: Enumerate groups and group memberships.

net localgroup

net localgroup <groupname>

Sessions: List active sessions.

net session

Advantages:

Native Tool: No need to install additional software.

Comprehensive: Provides detailed information about users and groups.

Reference from Pentesting Literature:

The use of net.exe commands for user enumeration is a standard practice discussed in various penetration testing guides.

HTB write-ups often include net.exe commands as part of the enumeration phase on Windows systems.

Penetration Testing - A Hands-on Introduction to Hacking

HTB Official Writeups

Which of the following is a term used to describe a situation in which a penetration tester bypasses physical access controls and gains access to a facility by entering at the same time as an employee?

A.
Badge cloning
A.
Badge cloning
Answers
B.
Shoulder surfing
B.
Shoulder surfing
Answers
C.
Tailgating
C.
Tailgating
Answers
D.
Site survey
D.
Site survey
Answers
Suggested answer: C

Explanation:

Understanding Tailgating:

Definition: Tailgating occurs when an unauthorized individual follows an authorized individual into a secure area without the need for the latter to provide credentials.

Risk: Bypasses physical access controls and can lead to unauthorized access to sensitive areas.

Methods to Prevent Tailgating:

Security Awareness: Train employees to be aware of tailgating risks and to challenge unknown individuals.

Physical Controls: Install turnstiles, mantraps, or security doors that only allow one person to enter at a time.

Monitoring: Use CCTV cameras to monitor entrances and exits.

Examples in Penetration Testing:

During a physical security assessment, a penetration tester might follow an employee into a secure area to test the effectiveness of physical security measures.

Tailgating is a common social engineering tactic used to gain unauthorized physical access.

Reference from Pentesting Literature:

Tailgating is discussed in penetration testing methodologies as a critical aspect of physical security assessments.

HTB write-ups occasionally cover scenarios where physical access was gained through tailgating.

Penetration Testing - A Hands-on Introduction to Hacking

HTB Official Writeups

Total 120 questions
Go to page: of 12