CEHPC Exam Questions & Answers
Ethical Hacking Professional Certification Exam • CertiProf
100% money-back guarantee
Sample CEHPC Questions
Practice with real exam-style questions, each with the verified correct answer and explanation.
What is a reverse shell?
A reverse shell is a technique used in ethical hacking and penetration testing where the target (victim) system initiates a connection back to the attacker's system, allowing the attacker to execute commands remotely. This makes option C the correct answer.
Unlike a bind shell, where the victim opens a listening port, a reverse shell is particularly effective in environments protected by firewalls or Network Address Translation (NAT). Since outbound connections are often allowed, the victim system connects outward to the attacker, bypassing many network restrictions. Ethical hackers commonly use reverse shells during the exploitation and post-exploitation phases of penetration testing to maintain access to compromised systems.
Option A is incorrect because running a terminal as root does not define a reverse shell. Option B is incorrect because a reverse shell is not a standard command-line interface but rather a remote command execution channel.
From an ethical hacking perspective, reverse shells help demonstrate the real-world impact of vulnerabilities such as command injection, remote code execution, or misconfigured services. Once established, a reverse shell may allow privilege escalation, lateral movement, or data exfiltration---highlighting serious security risks.
Understanding reverse shells is essential for both attackers and defenders. Defenders can mitigate reverse shell attacks by implementing strict egress filtering, intrusion detection systems, endpoint protection, and proper system hardening. Ethical testing of reverse shells enables organizations to identify weaknesses and improve overall security posture.
What is a persistent XSS?
Comprehensive and Detailed 250 to 300 words of Explanation From Ethical Hacking documents:
Persistent Cross-Site Scripting (XSS), also known as Stored XSS, is one of the most dangerous forms of web application vulnerabilities. It occurs when a web application receives data from a user and stores it permanently in its backend database or filesystem without proper sanitization or encoding. Common vectors for persistent XSS include comment sections, user profiles, message boards, and 'Contact Us' forms. Unlike Reflected XSS, where the payload is included in a specific URL and only affects the user who clicks that link, a persistent XSS payload is served automatically to every user who visits the affected page.
When an attacker successfully injects a malicious script (typically JavaScript), the server 'remembers' this script. Every time a legitimate user requests the page where the data is displayed, the server includes the malicious code in the HTML response. The user's browser, trusting the source, executes the script. This can lead to devastating consequences, such as session hijacking through the theft of session cookies, account takeover, or the redirection of users to malicious websites. From an ethical hacking perspective, identifying persistent XSS involves testing all input fields that result in data being displayed later. Mitigation strategies focus on the principle of 'filter input, escape output.' Input should be validated against a strict whitelist of allowed characters, and any data rendered in the browser must be context-aware encoded (e.g., converting < to <) to prevent the browser from interpreting the data as executable code. Because the payload is stored on the server, this vulnerability represents a significant risk to the entire user base of an organization, making it a high-priority finding in any security assessment.
What is Nmap?
Comprehensive and Detailed 250 to 300 words of Explanation From Ethical Hacking documents: Nmap, short for 'Network Mapper,' is one of the most critical tools in the reconnaissance and scanning phases of a penetration test. It is an open-source command-line utility primarily used for network discovery and security auditing. While many beginners associate it simply with 'pinging' devices (Option A), its functionality is significantly more sophisticated, allowing a tester to map out an entire network infrastructure, identify active hosts, and determine the specific services (and their versions) running on open ports.
In the pentesting process, Nmap is used to perform 'Active Reconnaissance.' By sending specially crafted packets to a target IP address, Nmap analyzes the responses to determine the operating system of the target (OS Fingerprinting), the types of firewalls or filters in use, and the specific applications listening on various ports. This information is vital for the next phase of an attack, as it allows the ethical hacker to identify specific versions of software that may have known vulnerabilities.
Nmap supports various scanning techniques, such as TCP SYN scans (stealthy), UDP scans, and comprehensive Scripting Engine (NSE) scans that can even detect common misconfigurations or vulnerabilities automatically. However, it is important to distinguish Nmap from an exploitation tool (Option B); while it identifies the 'door' and 'what is behind it,' it does not perform the actual 'break-in' or exploitation. In a professional environment, Nmap provides the foundation for the attack surface analysis, giving the pentester a clear picture of what services are exposed and providing the necessary data to plan a targeted and efficient security assessment.
What is a firewall?
Comprehensive and Detailed 250 to 300 words of Explanation From Ethical Hacking documents: A firewall is a cornerstone master information security control that serves as a protective barrier between a trusted internal network and untrusted external networks, such as the internet. Its primary function is to monitor and control incoming and outgoing network traffic based on a predetermined set of security rules. By analyzing packet headers---specifically IP addresses, port numbers, and protocols---the firewall determines whether to 'allow,' 'block,' or 'drop' a connection attempt.
Firewalls can be implemented as hardware appliances, software installed on a host, or a combination of both. They generally fall into several categories:
Packet Filtering Firewalls: These examine individual packets in isolation and are the most basic form of protection.
Stateful Inspection Firewalls: These track the state of active connections, ensuring that incoming traffic is only allowed if it is a response to a legitimate outgoing request.
Next-Generation Firewalls (NGFW): These go beyond simple port/IP filtering by performing 'Deep Packet Inspection' (DPI) to identify specific applications and even filter out malware or malicious commands within the traffic.
In the pentesting process, the firewall is the first major obstacle a tester encounters. It defines the 'perimeter' of the organization. An ethical hacker will use port scanning to identify which 'holes' exist in the firewall's ruleset. For defenders, a properly configured firewall is essential for implementing 'Default Deny' policies, where all traffic is blocked unless it is explicitly permitted. This significantly reduces the attack surface by ensuring that services like database ports are never exposed to the public internet. While a firewall is not a substitute for antivirus (Option A) or an exploit method (Option B), it is the most vital tool for regulating network access and preventing unauthorized intrusions.
What is ethical responsibility in hacking?
Ethical responsibility in hacking refers to the obligation to perform all security testing activities legally, transparently, and with explicit authorization, making option B the correct answer. Ethical hacking is not defined solely by technical skill, but by adherence to legal boundaries, professional conduct, and organizational policies.
Ethical hackers must always obtain written permission before conducting reconnaissance, scanning, or exploitation activities. This authorization clearly defines the scope, targets, and limitations of the engagement. Without permission, even basic scanning activities may be considered illegal or unethical, regardless of intent.
Option A is incorrect because technical knowledge alone does not make hacking ethical. Skills must be applied responsibly. Option C is incorrect because performing scans without permission is a violation of ethical and legal standards and may result in criminal charges.
From an ethical hacking perspective, responsibility also includes responsible disclosure, minimizing impact, protecting sensitive data, and reporting findings accurately. Ethical hackers must avoid data misuse, service disruption, or unnecessary system damage.
Understanding ethical responsibility is foundational to professional cybersecurity practice. It distinguishes ethical hackers from malicious actors and ensures that security testing contributes positively to risk reduction, compliance, and organizational trust.
Get access to all 125 verified questions with detailed answers.
Unlock All CEHPC Questions