Stop hackers before they hack you!
In order to outsmart a would-be hacker, you need to get into the hacker’s mindset. And with this book, thinking like a bad guy has never been easier. In Hacking For Dummies, expert author Kevin Beaver shares his knowledge on penetration testing, vulnerability assessments, security best practices, and every aspect of ethical hacking that is essential in order to stop a hacker in their tracks.
Whether you’re worried about your laptop, smartphone, or desktop computer being compromised, this no-nonsense book helps you learn how to recognize the vulnerabilities in your systems so you can safeguard them more diligently—with confidence and ease.
- Get up to speed on Windows 10 hacks
- Learn about the latest mobile computing hacks
- Get free testing tools
- Find out about new system updates and improvements
There’s no such thing as being too safe—and this resourceful guide helps ensure you’re protected.
Stop hackers before they hack you!
In order to outsmart a would-be hacker, you need to get into the hacker’s mindset. And with this book, thinking like a bad guy has never been easier. In Hacking For Dummies, expert author Kevin Beaver shares his knowledge on penetration testing, vulnerability assessments, security best practices, and every aspect of ethical hacking that is essential in order to stop a hacker in their tracks.
Whether you’re worried about your laptop, smartphone, or desktop computer being compromised, this no-nonsense book helps you learn how to recognize the vulnerabilities in your systems so you can safeguard them more diligently—with confidence and ease.
- Get up to speed on Windows 10 hacks
- Learn about the latest mobile computing hacks
- Get free testing tools
- Find out about new system updates and improvements
There’s no such thing as being too safe—and this resourceful guide helps ensure you’re protected.


Paperback(6th ed.)
-
SHIP THIS ITEMIn stock. Ships in 1-2 days.PICK UP IN STORE
Your local store may have stock of this item.
Available within 2 business hours
Related collections and offers
Overview
Stop hackers before they hack you!
In order to outsmart a would-be hacker, you need to get into the hacker’s mindset. And with this book, thinking like a bad guy has never been easier. In Hacking For Dummies, expert author Kevin Beaver shares his knowledge on penetration testing, vulnerability assessments, security best practices, and every aspect of ethical hacking that is essential in order to stop a hacker in their tracks.
Whether you’re worried about your laptop, smartphone, or desktop computer being compromised, this no-nonsense book helps you learn how to recognize the vulnerabilities in your systems so you can safeguard them more diligently—with confidence and ease.
- Get up to speed on Windows 10 hacks
- Learn about the latest mobile computing hacks
- Get free testing tools
- Find out about new system updates and improvements
There’s no such thing as being too safe—and this resourceful guide helps ensure you’re protected.
Product Details
ISBN-13: | 9781119485476 |
---|---|
Publisher: | Wiley |
Publication date: | 07/11/2018 |
Series: | For Dummies Books |
Edition description: | 6th ed. |
Pages: | 416 |
Product dimensions: | 7.30(w) x 9.10(h) x 0.80(d) |
About the Author
Kevin Beaver is an independent information security consultant with more than three decades of experience. Kevin specializes in performing vulnerability and penetration testing and security consulting work for Fortune 1000 corporations, product vendors, independent software developers, universities, and government organizations. He has appeared on CNN and been quoted in The Wall Street Journal.
Read an Excerpt
Hacking For Dummies
By Kevin Beaver
John Wiley & Sons
ISBN: 0-7645-5784-XChapter One
Introduction to Ethical HackingIn This Chapter
* Understanding hacker objectives
* Outlining the differences between ethical hackers and malicious hackers
* Examining how the ethical hacking process has come about
* Understanding the dangers that your computer systems face
* Starting the ethical hacking process
This book is about hacking ethically - the science of testing your computers and network for security vulnerabilities and plugging the holes you find before the bad guys get a chance to exploit them.
Although ethical is an often overused and misunderstood word, the Merriam-Webster dictionary defines ethical perfectly for the context of this book and the professional security testing techniques that I cover - that is, conforming to accepted professional standards of conduct. IT practitioners are obligated to perform all the tests covered in this book aboveboard and only after permission has been obtained by the owner(s) of the systems - hence the disclaimer in the introduction.
How Hackers Beget Ethical Hackers
We've all heard of hackers. Many of us have even suffered the consequences of hacker actions. So who are these hackers? Why is it important to know about them? The next few sections give you the lowdown on hackers.
Defining hacker
Hacker is a word that has two meanings:
The good-guy (white-hat) hackers don't like being in the same category as the bad-guy (black-hat) hackers. (These terms come from Western movies where the good guys wore white cowboy hats and the bad guys wore black cowboy hats.) Whatever the case, most people give hacker a negative connotation.
Many malicious hackers claim that they don't cause damage but instead are altruistically helping others. Yeah, right. Many malicious hackers are electronic thieves.
REMEMBER
In this book, I use the following terminology:
Hackers go for almost any system they think they can compromise. Some prefer prestigious, well-protected systems, but hacking into anyone's system increases their status in hacker circles.
Ethical Hacking 101
You need protection from hacker shenanigans. An ethical hacker possesses the skills, mindset, and tools of a hacker but is also trustworthy. Ethical hackers perform the hacks as security tests for their systems.
TIP
If you perform ethical hacking tests for customers or simply want to add another certification to your credentials, you may want to consider the ethical hacker certification Certified Ethical Hacker, which is sponsored by EC-Council. See eccouncil.org/CEH.htm for more information.
Ethical hacking - also known as penetration testing or white-hat hacking - involves the same tools, tricks, and techniques that hackers use, but with one major difference: Ethical hacking is legal. Ethical hacking is performed with the target's permission. The intent of ethical hacking is to discover vulnerabilities from a hacker's viewpoint so systems can be better secured. It's part of an overall information risk management program that allows for ongoing security improvements. Ethical hacking can also ensure that vendors' claims about the security of their products are legitimate.
To hack your own systems like the bad guys, you must think like they think. It's absolutely critical to know your enemy; see Chapter 2 for details.
Understanding the Need to Hack Your Own Systems
To catch a thief, think like a thief. That's the basis for ethical hacking.
The law of averages works against security. With the increased numbers and expanding knowledge of hackers combined with the growing number of system vulnerabilities and other unknowns, the time will come when all computer systems are hacked or compromised in some way. Protecting your systems from the bad guys - and not just the generic vulnerabilities that everyone knows about - is absolutely critical. When you know hacker tricks, you can see how vulnerable your systems are.
Hacking preys on weak security practices and undisclosed vulnerabilities. Firewalls, encryption, and virtual private networks (VPNs) can create a false feeling of safety. These security systems often focus on high-level vulnerabilities, such as viruses and traffic through a firewall, without affecting how hackers work. Attacking your own systems to discover vulnerabilities is a step to making them more secure. This is the only proven method of greatly hardening your systems from attack. If you don't identify weaknesses, it's a matter of time before the vulnerabilities are exploited.
As hackers expand their knowledge, so should you. You must think like them to protect your systems from them. You, as the ethical hacker, must know activities hackers carry out and how to stop their efforts. You should know what to look for and how to use that information to thwart hackers' efforts.
TIP
You don't have to protect your systems from everything. You can't. The only protection against everything is to unplug your computer systems and lock them away so no one can touch them - not even you. That's not the best approach to information security. What's important is to protect your systems from known vulnerabilities and common hacker attacks.
It's impossible to buttress all possible vulnerabilities on all your systems. You can't plan for all possible attacks - especially the ones that are currently unknown. However, the more combinations you try - the more you test whole systems instead of individual units - the better your chances of discovering vulnerabilities that affect everything as a whole.
Don't take ethical hacking too far, though. It makes little sense to harden your systems from unlikely attacks. For instance, if you don't have a lot of foot traffic in your office and no internal Web server running, you may not have as much to worry about as an Internet hosting provider would have. However, don't forget about insider threats from malicious employees!
Your overall goals as an ethical hacker should be as follows:
Understanding the Dangers Your Systems Face
It's one thing to know that your systems generally are under fire from hackers around the world. It's another to understand specific attacks against your systems that are possible. This section offers some well-known attacks but is by no means a comprehensive listing. That requires its own book: Hack Attacks Encyclopedia, by John Chirillo (Wiley Publishing, Inc.).
Many information-security vulnerabilities aren't critical by themselves. However, exploiting several vulnerabilities at the same time can take its toll. For example, a default Windows OS configuration, a weak SQL Server administrator password, and a server hosted on a wireless network may not be major security concerns separately. But exploiting all three of these vulnerabilities at the same time can be a serious issue.
Nontechnical attacks
Exploits that involve manipulating people - end users and even yourself - are the greatest vulnerability within any computer or network infrastructure. Humans are trusting by nature, which can lead to social-engineering exploits. Social engineering is defined as the exploitation of the trusting nature of human beings to gain information for malicious purposes. I cover social engineering in depth in Chapter 5.
Other common and effective attacks against information systems are physical. Hackers break into buildings, computer rooms, or other areas containing critical information or property. Physical attacks can include dumpster diving (rummaging through trash cans and dumpsters for intellectual property, passwords, network diagrams, and other information).
Network-infrastructure attacks
Hacker attacks against network infrastructures can be easy, because many networks can be reached from anywhere in the world via the Internet. Here are some examples of network-infrastructure attacks:
Operating-system attacks
Hacking operating systems (OSs) is a preferred method of the bad guys. OSs comprise a large portion of hacker attacks simply because every computer has one and so many well-known exploits can be used against them.
Occasionally, some operating systems that are more secure out of the box - such as Novell NetWare and the flavors of BSD UNIX - are attacked, and vulnerabilities turn up. But hackers prefer attacking operating systems like Windows and Linux because they are widely used and better known for their vulnerabilities.
Here are some examples of attacks on operating systems:
Application and other specialized attacks
Applications take a lot of hits by hackers. Programs such as e-mail server software and Web applications often are beaten down:
Ethical hacking helps reveal such attacks against your computer systems. Parts II through V of this book cover these attacks in detail, along with specific countermeasures you can implement against attacks on your systems.
Obeying the Ethical Hacking Commandments
Every ethical hacker must abide by a few basic commandments. If not, bad things can happen. I've seen these commandments ignored or forgotten when planning or executing ethical hacking tests. The results weren't positive.
Working ethically
The word ethical in this context can be defined as working with high professional morals and principles. Whether you're performing ethical hacking tests against your own systems or for someone who has hired you, everything you do as an ethical hacker must be aboveboard and must support the company's goals. No hidden agendas are allowed!
Trustworthiness is the ultimate tenet. The misuse of information is absolutely forbidden. That's what the bad guys do.
Respecting privacy
Treat the information you gather with the utmost respect. All information you obtain during your testing - from Web-application log files to clear-text passwords - must be kept private. Don't use this information to snoop into confidential corporate information or private lives. If you sense that someone should know there's a problem, consider sharing that information with the appropriate manager.
TIP
Involve others in your process. This is a "watch the watcher" system that can build trust and support your ethical hacking projects.
Not crashing your systems
One of the biggest mistakes I've seen when people try to hack their own systems is inadvertently crashing their systems. The main reason for this is poor planning. These testers have not read the documentation or misunderstand the usage and power of the security tools and techniques.
You can easily create DoS conditions on your systems when testing. Running too many tests too quickly on a system causes many system lockups. I know because I've done this! Don't rush things and assume that a network or specific host can handle the beating that network scanners and vulnerability-assessment tools can dish out.
TIP
Many security-assessment tools can control how many tests are performed on a system at the same time. These tools are especially handy if you need to run the tests on production systems during regular business hours.
You can even create an account or system lockout condition by social engineering someone into changing a password, not realizing that doing so might create a system lockout condition.
The Ethical Hacking Process
Like practically any IT or security project, ethical hacking needs to be planned in advance. Strategic and tactical issues in the ethical hacking process should be determined and agreed upon. Planning is important for any amount of testing - from a simple password-cracking test to an all-out penetration test on a Web application.
Formulating your plan
Approval for ethical hacking is essential. Make what you're doing known and visible - at least to the decision makers. Obtaining sponsorship of the project is the first step. This could be your manager, an executive, a customer, or even yourself if you're the boss. You need someone to back you up and sign off on your plan. Otherwise, your testing may be called off unexpectedly if someone claims they never authorized you to perform the tests.
Continues...
Excerpted from Hacking For Dummies by Kevin Beaver Excerpted by permission.
All rights reserved. No part of this excerpt may be reproduced or reprinted without permission in writing from the publisher.
Excerpts are provided by Dial-A-Book Inc. solely for the personal use of visitors to this web site.
Table of Contents
Introduction 1
About This Book 1
Foolish Assumptions 2
Icons Used in This Book 3
Beyond the Book 3
Where to Go from Here 4
Part 1: Building the Foundation for Security Testing 5
Chapter 1: Introduction to Vulnerability and Penetration Testing 7
Straightening Out the Terminology 7
Hacker 8
Malicious user 9
Recognizing How Malicious Attackers Beget Ethical Hackers 10
Vulnerability and penetration testing versus auditing 10
Policy considerations 11
Compliance and regulatory concerns 12
Understanding the Need to Hack Your Own Systems 12
Understanding the Dangers Your Systems Face 14
Nontechnical attacks 14
Network infrastructure attacks 15
Operating system attacks 15
Application and other specialized attacks 15
Following the Security Assessment Principles 16
Working ethically 16
Respecting privacy 17
Not crashing your systems 17
Using the Vulnerability and Penetration Testing Process 18
Formulating your plan 18
Selecting tools 20
Executing the plan 22
Evaluating results 23
Moving on 23
Chapter 2: Cracking the Hacker Mindset 25
What You’re Up Against 25
Who Breaks into Computer Systems 28
Hacker skill levels 28
Hacker motivations 30
Why They Do It 30
Planning and Performing Attacks 33
Maintaining Anonymity 35
Chapter 3: Developing Your Security Testing Plan 37
Establishing Your Goals 37
Determining Which Systems to Test 40
Creating Testing Standards 43
Timing your tests 43
Running specific tests 44
Conducting blind versus knowledge assessments 45
Picking your location 46
Responding to vulnerabilities you find 46
Making silly assumptions 46
Selecting Security Assessment Tools 47
Chapter 4: Hacking Methodology 49
Setting the Stage for Testing 49
Seeing What Others See 51
Scanning Systems 52
Hosts 53
Open ports 53
Determining What’s Running on Open Ports 54
Assessing Vulnerabilities 56
Penetrating the System 58
Part 2: Putting Security Testing in Motion 59
Chapter 5: Information Gathering 61
Gathering Public Information 61
Social media 62
Web search 62
Web crawling 63
Websites 64
Mapping the Network 64
WHOIS 65
Privacy policies 66
Chapter 6: Social Engineering 67
Introducing Social Engineering 67
Starting Your Social Engineering Tests 68
Knowing Why Attackers Use Social Engineering 69
Understanding the Implications 70
Building trust 71
Exploiting the relationship 72
Performing Social Engineering Attacks 74
Determining a goal 75
Seeking information 75
Social Engineering Countermeasures 80
Policies 80
User awareness and training 80
Chapter 7: Physical Security 83
Identifying Basic Physical Security Vulnerabilities 84
Pinpointing Physical Vulnerabilities in Your Office 85
Building infrastructure 85
Utilities 87
Office layout and use 88
Network components and computers 90
Chapter 8: Passwords 95
Understanding Password Vulnerabilities 96
Organizational password vulnerabilities 97
Technical password vulnerabilities 97
Cracking Passwords 98
Cracking passwords the old-fashioned way 99
Cracking passwords with high-tech tools 102
Cracking password-protected files 110
Understanding other ways to crack passwords 112
General Password Cracking Countermeasures 117
Storing passwords 118
Creating password policies 118
Taking other countermeasures 120
Securing Operating Systems 121
Windows 121
Linux and Unix 122
Part 3: Hacking Network Hosts 123
Chapter 9: Network Infrastructure Systems 125
Understanding Network Infrastructure Vulnerabilities 126
Choosing Tools 127
Scanners and analyzers 128
Vulnerability assessment 128
Scanning, Poking, and Prodding the Network 129
Scanning ports 129
Scanning SNMP 135
Grabbing banners 137
Testing firewall rules 138
Analyzing network data 140
The MAC-daddy attack 147
Testing denial of service attacks 152
Detecting Common Router, Switch, and Firewall Weaknesses 155
Finding unsecured interfaces 155
Uncovering issues with SSL and TLS 156
Putting Up General Network Defenses 156
Chapter 10: Wireless Networks 159
Understanding the Implications of Wireless Network Vulnerabilities 159
Choosing Your Tools 160
Discovering Wireless Networks 162
Checking for worldwide recognition 162
Scanning your local airwaves 163
Discovering Wireless Network Attacks and Taking Countermeasures 165
Encrypted traffic 167
Countermeasures against encrypted traffic attacks 170
Wi-Fi Protected Setup 172
Countermeasures against the WPS PIN flaw 175
Rogue wireless devices 175
Countermeasures against rogue wireless devices 179
MAC spoofing 179
Countermeasures against MAC spoofing 183
Physical security problems 183
Countermeasures against physical security problems 184
Vulnerable wireless workstations 185
Countermeasures against vulnerable wireless workstations 185
Default configuration settings 185
Countermeasures against default configuration settings exploits 186
Chapter 11: Mobile Devices 187
Sizing Up Mobile Vulnerabilities 187
Cracking Laptop Passwords 188
Choosing your tools 188
Applying countermeasures 193
Cracking Phones and Tablets 193
Cracking iOS passwords 194
Taking countermeasures against password cracking 197
Part 4: Hacking Operating Systems 199
Chapter 12: Windows 201
Introducing Windows Vulnerabilities 202
Choosing Tools 203
Free Microsoft tools 203
All-in-one assessment tools 204
Task-specific tools 204
Gathering Information About Your Windows Vulnerabilities 205
System scanning 205
NetBIOS 208
Detecting Null Sessions 210
Mapping 211
Gleaning information 212
Countermeasures against null-session hacks 214
Checking Share Permissions 215
Windows defaults 216
Testing 216
Exploiting Missing Patches 217
Using Metasploit 220
Countermeasures against missing patch vulnerability exploits 224
Running Authenticated Scans 225
Chapter 13: Linux and macOS 227
Understanding Linux Vulnerabilities 228
Choosing Tools 229
Gathering Information About Your System Vulnerabilities 229
System scanning 229
Countermeasures against system scanning 233
Finding Unneeded and Unsecured Services 234
Searches 234
Countermeasures against attacks on unneeded services 236
Securing the rhosts and hosts.equiv Files 238
Hacks using the hosts.equiv and rhosts files 239
Countermeasures against rhosts and hosts.equiv file attacks 240
Assessing the Security of NFS 241
NFS hacks 241
Countermeasures against NFS attacks 242
Checking File Permissions 242
File permission hacks 243
Countermeasures against file permission attacks 243
Finding Buffer Overflow Vulnerabilities 244
Attacks 244
Countermeasures against buffer overflow attacks 245
Checking Physical Security 245
Physical security hacks 245
Countermeasures against physical security attacks 245
Performing General Security Tests 246
Patching 248
Distribution updates 248
Multiplatform update managers 249
Part 5: Hacking Applications 251
Chapter 14: Communication and Messaging Systems 253
Introducing Messaging System Vulnerabilities 253
Recognizing and Countering Email Attacks 254
Email bombs 255
Banners 258
SMTP attacks 260
General best practices for minimizing email security risks 269
Understanding VoIP 270
VoIP vulnerabilities 271
Countermeasures against VoIP vulnerabilities 275
Chapter 15: Web Applications and Mobile Apps 277
Choosing Your Web Security Testing Tools 278
Seeking Out Web Vulnerabilities 279
Directory traversal 279
Countermeasures against directory traversals 283
Input-filtering attacks 283
Countermeasures against input attacks 290
Default script attacks 291
Countermeasures against default script attacks 293
Unsecured login mechanisms 293
Countermeasures against unsecured login systems 297
Performing general security scans for web application vulnerabilities 297
Minimizing Web Security Risks 298
Practicing security by obscurity 299
Putting up firewalls 300
Analyzing source code 300
Uncovering Mobile App Flaws 301
Chapter 16: Databases and Storage Systems 303
Diving Into Databases 303
Choosing tools 304
Finding databases on the network 304
Cracking database passwords 305
Scanning databases for vulnerabilities 306
Following Best Practices for Minimizing Database Security Risks 307
Opening Up About Storage Systems 308
Choosing tools 309
Finding storage systems on the network 309
Rooting out sensitive text in network files 310
Following Best Practices for Minimizing Storage Security Risks 312
Part 6: Security Testing Aftermath 315
Chapter 17: Reporting Your Results 317
Pulling the Results Together 317
Prioritizing Vulnerabilities 319
Creating Reports 321
Chapter 18: Plugging Your Security Holes 323
Turning Your Reports into Action 323
Patching for Perfection 324
Patch management 325
Patch automation 325
Hardening Your Systems 326
Assessing Your Security Infrastructure 328
Chapter 19: Managing Security Processes 331
Automating the Security Assessment Process 331
Monitoring Malicious Use 332
Outsourcing Security Assessments 334
Instilling a Security-Aware Mindset 336
Keeping Up with Other Security Efforts 337
Part 7: The Part of Tens 339
Chapter 20: Ten Tips for Getting Security Buy-In 341
Cultivate an Ally and a Sponsor 341
Don’t Be a FUDdy-Duddy 342
Demonstrate That the Organization Can’t Afford to Be Hacked 342
Outline the General Benefits of Security Testing 343
Show How Security Testing Specifically Helps the Organization 344
Get Involved in the Business 344
Establish Your Credibility 345
Speak on Management’s Level 345
Show Value in Your Efforts 346
Be Flexible and Adaptable 346
Chapter 21: Ten Reasons Hacking Is the Only Effective Way to Test 347
The Bad Guys Think Bad Thoughts, Use Good Tools, and Develop New Methods 347
IT Governance and Compliance Are More Than High-Level Checklist Audits 348
Vulnerability and Penetration Testing Complements Audits and Security Evaluations 348
Customers and Partners Will Ask How Secure Your Systems Are 348
The Law of Averages Works Against Businesses 349
Security Assessments Improve Understanding of Business Threats 349
If a Breach Occurs, You Have Something to Fall Back On 349
In-Depth Testing Brings Out the Worst in Your Systems 350
Combined Vulnerability and Penetration Testing Is What You Need 350
Proper Testing Can Uncover Overlooked Weaknesses 350
Chapter 22: Ten Deadly Mistakes 351
Not Getting Approval 351
Assuming That You Can Find All Vulnerabilities 352
Assuming That You Can Eliminate All Vulnerabilities 352
Performing Tests Only Once 353
Thinking That You Know It All 353
Running Your Tests Without Looking at Things from a Hacker’s Viewpoint 353
Not Testing the Right Systems 354
Not Using the Right Tools 354
Pounding Production Systems at the Wrong Time 354
Outsourcing Testing and Not Staying Involved 355
Appendix: Tools and Resources 357
Index 375