Ethical hacking, also known as penetration testing or pen testing, is legally breaking into computers and devices to test an organization’s defenses. It’s among the most exciting IT jobs any person can be involved in. You are literally getting paid to keep up with the latest technology and get to break into computers without the threat of being arrested.
Companies engage ethical hackers to identify vulnerabilities in their systems. From the penetration tester’s point of view, there is no downside: If you hack in past the current defenses, you’ve given the client a chance to close the hole before an attacker discovers it. If you don’t find anything, your client is even happier because they now get to declare their systems “secure enough that even paid hackers couldn’t break into it.” Win-win!
I’ve been in computer security for over 30 years, and no job has been more challenging and fun than professional penetration testing. You not only get to do something fun, but pen testers often are seen with an aura of extra coolness that comes from everyone knowing they could break into almost any computer at will. Although now long turned legit, the world’s former most notorious uber hacker, Kevin Mitnick, told me that he gets the exact same emotional thrill out of being paid to legally break into places as he did for all those years of illegal hacking. Mitnick said, the only difference “is the report writing.”
Scope and goal setting
It is essential for any professional pen tester to document agreed upon scope and goals. These are the kinds of questions regarding scope you need to ask:
Ask these questions regarding the goals of the penetration test.
It’s important that the scope and goals be described in detail, and agreed upon, prior to any penetration testing attempts.
Discovery: Learn about your target
Every ethical hacker begins their asset hacking (excluding social engineering techniques for this discussion) by learning as much about the pen test targets as they can. They want to know IP addresses, OS platforms, applications, version numbers, patch levels, advertised network ports, users, and anything else that can lead to an exploit. It is a rarity that an ethical hacker won’t see an obvious potential vulnerability by spending just a few minutes looking at an asset. At the very least, even if they don’t see something obvious, they can use the information learned in discovery for continued analysis and attack tries.
Exploitation: Break into the target asset
This is what the ethical hacker is being paid for – the “break-in.” Using the information learned in the discovery phase, the pen tester needs to exploit a vulnerability to gain unauthorized access (or denial of service, if that is the goal). If the hacker can’t break-in to a particular asset, then they must try other in-scope assets. Personally,
if I’ve done a thorough discovery job, then I’ve always found an exploit. I don’t even know of a professional penetration tester that has not broken into an asset they were hired to break into, at least initially, before their delivered report allowed the defender to close all the found holes. I’m sure there are penetration testers that don’t always find exploits and accomplish their hacking goals, but if you do the discovery process thoroughly enough, the exploitation part isn’t as difficult as many people believe. Being a good penetration tester or hacker is less about being a genius and more about patience and thoroughness.
Depending on the vulnerability and exploit, the now gained access may require “privilege escalation” to turn a normal user’s access into higher administrative access. This can require a second exploit to be used, but only if the initial exploit didn’t already give the attacker privileged access.
Depending on what is in scope, the vulnerability discovery can be automated using exploitation or vulnerability scanning software. The latter software type usually finds vulnerabilities,but does not exploit them to gain unauthorized access.
Next, the pen tester either performs the agreed upon goal action if they are in their ultimate destination, or they use the currently exploited computer to gain access closer to their eventual destination. Pen testers and defenders call this “horizontal” or “vertical” movement, depending on whether the attacker moves within the same class of system or outward to non-related systems. Sometimes the goal of the ethical hacker must be proven as attained (such as revealing system secrets or confidential data) or the mere documentation of how it could have been successfully accomplished is enough.
Document the pen-test effort
Lastly, the professional penetration tester must write up and present the agreed upon report, including findings and conclusions.
Any hacker must take some common steps to become an ethical hacker, the bare minimum of which is to make sure you have documented permission from the right people before breaking into something. Not breaking the law is paramount to being an ethical hacker. All professional penetration testers should follow a code of ethics to guide everything they do. The EC-Council, creators of the Certificated Ethical Hacker (CEH) exam, have one of the best public code of ethics available.
Most ethical hackers become professional penetration testers one of two ways. Either they learn hacking skills on their own or they take formal education classes. Many, like me, did both. Although sometimes mocked by self-learners, ethical hacking courses and certifications are often the gateway to a good paying job as a full-time penetration tester.
Today’s IT security education curriculum is full of courses and certifications that teach someone how to be an ethical hacker. For most of the certification exams you can self-study and bring your own experience to the testing center or take an approved education course. While you don’t need an ethical hacking certification to get employed as professional penetration tester, it can’t hurt.
As CBT Nuggets trainer, Keith Barker said, “I think the opportunity to have ‘certified ethical anything’ on your resume can only be a good thing, but it’s more of an entry way into more study. Plus, if companies see that you are certified in ethical hacking, they know you have seen and agreed to a particular code of ethics. If an employer is looking at resumes and they see someone who has an ethical hacking certification and someone that didn’t, it’s got to help.”
Even though they teach the same skill every ethical hacking course and certification is different. Do a little research to find the right one for you.
The EC-Council’s Certificate Ethical Hacker (CEH) is easily the oldest and most popular penetration course and certification. The official course, which can be taken online or with a live in-person instructor, contains 18 different subject domains including traditional hacking subjects, plus modules on malware, wireless, cloud and mobile platforms. The full remote course includes six months of access to the online Cyber Range iLab, which will allow students to practice over 100 hacking skills.
Sitting for the CEH certification requires taking an official course or, if self-study, proof of two years of relevant experience or education. It contains 125 multiple-choice questions with a four-hour time limit. Taking the exam requires accepting the EC-Council’s Code of Ethics, which was one of the first required codes of ethics required of computer security test takers. The courseware and testing is routinely updated.
SysAdmin, Networking, and Security (SANS) Institute is a highly respected training organization, and anything they teach along with their certifications are greatly respected by IT security practitioners. SANS offers multiple pen testing courses and certifications, but its base GIAC Penetration Tester (GPEN) is one of the most popular.
The official course for the GPEN, SEC560: Network Penetration Testing and Ethical Hacking, can be taken online or live in-person. The GPEN exam has 115 questions, a three-hour time limit, and requires a 74 percent score to pass. No specific training is required for any GIAC exam. The GPEN is covered on GIAC’s general code of ethics, which they take very seriously as attested to by a running count of exam passers who have been disqualified for violating the code.
“I like how [the GPEN exam] ties to practical skills that penetration testers need to have to do their jobs every day,” says Skoudis. “It covers everything from detailed technical approaches to testing all the way up through scoping, rules of engagement, and reporting. The exam is very scenario focused, so it will present a given penetration test scenario and ask which is the best way forward. Or, it’ll show you the output from a tool, and ask what the tool is telling you and what you should do next. I appreciate that so much, as it measures real-world skills better. The exam doesn’t have a lot of questions that are merely definitional, where they have a sentence that is missing one word and ask you which of the following words best fill in the sentence. That’s not a particularly good way of measuring skills.”
The Offensive Security Certified Professional (OSCP) course and certification has gained a well-earned reputation for toughness with a very hands-on learning structure and exam. The official online, self-paced training course is called Penetration Testing with Kali Linux and includes 30 days of lab access. Because it relies on Kali Linux (the successor to pen testers’ previous favorite Linux distro, BackTrack), participants need to have a basic understanding of how to use Linux, bash shells and scripts.
The OSCP is known for pushing its students and exam takers harder than other pen testing paths. For example, the OSCP course teaches, and the exam requires, the ability to obtain, modify and use publicly obtained exploit code. For the “exam”, the participant is given instructions to remotely attach to a virtual environment where they are expected to compromise multiple operating systems and devices within 24-hours, and thoroughly document how they did it. Offensive Security also offers even more advanced pen testing courses and exams (e.g., including involving web, wireless, and advanced Windows exploitation). Readers may want to take advantage of their free, online basic Metasploit tool course.
McAfee’s Foundstone business unit (which I worked for over 10 years ago) was one of the first hands-on penetration testing courses available. Its series of Ultimate Hacking courses and books led the field for a long time. They covered Windows, Linux, Solaris, web, SQL, and a host of advanced hacker techniques (such as tunneling). Unfortunately, Ultimate Hacking courses don’t have formal exams and certifications.
Today, Foundstone offers a host of training options well beyond just pen testing, including forensics and incident response (as do many of the other players in this article). Additionally, Foundstone offers training in hacking internet of things (IoT), firmware, industrial control security systems, Bluetooth and RFID. Foundstone instructors are often real-life pen testers and security consultants, although many, if not most, of the training courses are handled by partners.
Internationally, the not-for-profit CREST information assurance accreditation and certification body’s pen test courses and exams are commonly accepted in many countries, including the United Kingdom, Australia, Europe, and Asia. CREST’s mission is to educate and certify quality pen testers. All CREST-approved exams have been reviewed and approved by the UK’s Government Communication Headquarters (GCHQ), which is analogous to the United States’ NSA.
CREST’s basic pen testing exam is known as the CREST Registered Tester (or CRT), and there are exams for web and infrastructure pen testers. Exams and costs vary by country. CREST test takers must review and acknowledge the CREST Code of Conduct. The Offensive Security OSCP certification can be used to obtain the CRT.
All the instructors I spoke to believed that the courses they taught were just a beginning. Barker of CBT Nuggets said, “[Certification exams] are a great entry point and exposure to all the foundations that you can then go onto more.”
“Each [of our classes] is not just a standalone class someone takes for six days and then disappears,” says Skoudis. “Instead, our classes are more like an ecosystem, centered around that 6 days of training, but with webcasts and follow up blogs for continued learning going forward. Also, we’ve been super fortunate to have our previous students contributing to this ecosystem through their own blogs and tool development, giving back to the community. It’s really a beautiful virtuous cycle, and I’m so thankful to be a little part of it.”
Ethical hackers usually have a standard set of hacking tools that they use all the time, but they might have to look for and stock up on different tools depending on the particular job. For example, if the penetration tester is asked to attack SQL servers and has no relevant experience, they might want to start researching and testing different SQL attack tools.
Most penetration testers start with a Linux OS “distro” that is specialized for penetration testing. Linux distros for hacking come and go over the years, but right now the Kali distro is the one most professional ethical hackers prefer. There are thousands of hacking tools, including a bunch of stalwarts that nearly every pen tester uses.
The most important point of any hacking tool, beyond its quality and fit for the job at hand, is to make sure it does not contain malware or other code designed to hack the hacker. The vast majority of hacking tools that you can get on internet, especially for free, contain malware and undocumented backdoors. You can usually trust the most common and popular hacking tools, like Nmap, but the best ethical hackers write and use their own tools because they don’t trust anything written by someone else.
For a more in-depth look at ethical hacking tools, read “17 penetration testing tools the pros use.”
Like every other IT security discipline, ethical hacking is maturing. Standalone hackers who simply show technical prowess without professionalism and sophistication are becoming less in demand. Employers are looking for the complete professional hacker — both in practice and the toolsets they use.
Better toolkits: Penetration or vulnerability testing software has always been a part of the ethical hacker’s toolkit. More than likely, the customer already is running one or both of these on a regular basis. One of the most exciting developments in pen testing are tools that essentially do all of the hard work from discovery to exploitation, much like an attacker might.
An example of this type of tool is open source Bloodhound. Bloodhound allows attackers to see, graphically, relationships among different computers on an Active Directory network. If you input a desired target goal, Bloodhound can help you quickly see multiple hacking paths to get from where you start to that target, often identifying paths you didn’t know existed. I’ve seen complex uses where pen testers simply entered in starting and ending points, and Bloodhound and a few scripts did the rest, including all hacking steps necessary to get from point A to Z. Of course, commercial penetration testing software has had this sort of sophistication for much longer.
A picture is worth a thousand words: It used to be that to sell a defense to senior management, pen testers would hack senior management or show them documentation. Today, senior management wants slide decks, videos or animations of how particular hacks were performed in their environment. They use it not only to sell other senior managers on particular defenses but also as part of employee education.
Risk management: It’s also not enough to hand off a list of found vulnerabilities to the rest of the company and consider your job done. No, today’s professional penetration testers must work with IT management to identify the biggest and most likely threats. Penetration testers are now part of the risk management team, helping to efficiently reduce risk even more so than just pure vulnerabilities. This means that ethical hackers provide even more value by showing management and defenders what is most likely to happen and how, and not just show them a one-off hack that is unlikely to occur from a real-life intruder.
Professional penetration testing isn’t for everyone. It requires becoming a near-expert in several different technologies and platforms, as well as an intrinsic desire to see if something can be broken into past the normally presented boundaries. If you’ve got that desire, and can follow some legal and ethical guidelines, you, too, can be a professional hacker.
This story, “What is ethical hacking? How to get paid to break into computers” was originally published by