Mastering Kali Linux for Advanced Penetration Testing
Total Page:16
File Type:pdf, Size:1020Kb
Mastering Kali Linux for Advanced Penetration Testing A practical guide to testing your network's security with Kali Linux, the preferred choice of penetration testers and hackers Robert W. Beggs BIRMINGHAM - MUMBAI Mastering Kali Linux for Advanced Penetration Testing Copyright © 2014 Packt Publishing All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews. Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book. Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information. First published: June 2014 Production reference: 1160614 Published by Packt Publishing Ltd. Livery Place 35 Livery Street Birmingham B3 2PB, UK. ISBN 978-1-78216-312-1 www.packtpub.com Cover image by Robert W. Beggs ([email protected]) Credits Author Copy Editors Robert W. Beggs Tanvi Gaitonde Dipti Kapadia Reviewers Insiya Morbiwala Terry P. Cutler Kirti Pai Danang Heriyadi Alfida Paiva Tajinder Singh Kalsi Stuti Srivastava Amit Pandurang Karpe Ashish Pandurang Karpe Proofreaders Simran Bhogal Kunal Sehgal Mario Cecere Joel Johnson Acquisition Editor James Jones Indexers Hemangini Bari Content Development Editor Amey Varangaonkar Monica Ajmera Mehta Technical Editors Graphics Pragnesh Bilimoria Ronak Dhruv Mrunal Chavan Production Coordinators Aparna Kumar Pooja Chiplunkar Pooja Nair Manu Joseph Project Coordinator Cover Work Akash Poojary Pooja Chiplunkar About the Author Robert W. Beggs is the founder and CEO of Digital Defence, a company that specializes in preventing and responding to information security incidents. He has more than 15 years of experience in the technical leadership of security engagements, including penetration testing of wired and wireless networks, incident response, and data forensics. Robert is a strong evangelist of security and is a cofounder of Toronto Area Security Klatch, the largest known vendor-independent security user group in North America. He is a member on the advisory board of the SecTor Security Conference as well as on several academic security programs. He is an enthusiastic security trainer and has taught graduates, undergraduates, and continuing education students courses in information security at several Canadian universities. Robert holds an MBA in Science and Technology from Queen's University and is a Certified Information Systems Security Professional. Firstly, and perhaps most importantly, I would like to thank the developers and supporters of Kali Linux. Together, they have produced one of the most significant tools for securing networks and data. I would like to thank the editors and reviewers at Packt Publishing for their support and seemingly unending patience during the writing of this book. I promise that the next one will go quicker! I would also like to thank Brian Bourne and other members of the Toronto Area Security Klatch. They've given me an incredible opportunity to learn and share knowledge with the best-ever community of security geeks. Throughout the writing of this book, my family has given me both incredible motivation and support. Thank you Sarah, Alex, and Annika. And finally, a very special thank you to my mother and father—I can't remember when I first learned to read—with your encouragement, it was always just natural to have a book in my hands. Thank you. About the Reviewers Terry P. Cutler is a cyber security expert (a certified ethical hacker) and the cofounder and chief technology officer of IT security and data defense firm, Digital Locksmiths Inc. in Montréal, Canada. They protect small businesses, large agencies, families, and individuals from cyber criminals who victimize an estimated 1.5 million people a day (600,000 on Facebook alone). He specializes in anticipation, assessment, and prevention of security breaches for governments, corporations, businesses, and consumers. Having been a certified ethical hacker, among other things since 2005, he had an opportunity to present in front of a live audience of 2,500 people and with tens of thousands across the world, on live and recorded streaming, how a hacker could break into almost any company with a fake LinkedIn request. You can view this video on his YouTube channel. Terry has been delivering Internet safety for children, parents, and law enforcement since 2006. He believes that prevention, street proofing, and parent-child communication are the most effective ways to prevent a child from being abducted or falling victim to aggression and exploitation. Giving children the knowledge and practical skills they need to look after themselves is as important as teaching them to read and write. You can find out more on this at http://www.TheCourseOnInternetSafety.com. He is a frequent contributor to media reportage about cybercrime, spying, security failures, Internet scams, and the real social network dangers that families and individuals face every day. He is acknowledged as a transformational leader, problem solver, and trusted advisor with a genuine talent for fostering positive and collaborative working relationships at all organizational levels. Before leaving his job in 2011 to concentrate full time on Digital Locksmiths, Terry worked for a software giant, Novell. He joined this global software corporation that specializes in enterprise operating systems and identity, security, and systems management solutions to provide engineering support to the company's premium service customers consisting of up to 45,000 users and 600 servers all across the world. I'd like to take a moment to thank Robert W. Beggs for generously taking me under his wing as a mentor back in 2004 and guiding me through the processes and pitfalls of working in this industry. Now that I've matured as an industry specialist, I'm honored to be able to share some of my own learning and experiences with Rob and with his readers. A very special thanks to my family, my wife, Franca, and our sons, David and Matthew, for their support, encouragement, patience, hugs, and unconditional love over the last few years. Danang Heriyadi is an Indonesian computer security researcher, specialized in reverse engineering and software exploitation with more than five years of hands-on experience. He is currently working at Hatsecure as an instructor for Advanced Exploit and Shellcode Development. As a researcher, he loves to share IT security knowledge through his blog at Fuzzerbyte (http://www.fuzzerbyte.com). I would like to thank my parents for giving me life; without them, I wouldn't be here today; my girlfriend, for supporting me every day with her smile and love; and my friends, whom I have no words to describe. Tajinder Singh Kalsi is the cofounder and a technical evangelist at Virscent Technologies Pvt. Ltd., with more than six years of working experience in the field of IT. He commenced his career with Wipro as a technical associate and later became an IT consultant and trainer. As of now, he conducts seminars in colleges across India on topics such as information security, Android application development, website development, and cloud computing. At this point, he has covered more than 120 colleges and more than 9,000 students. Apart from imparting training, he also maintains a blog (www.virscent.com/blog), which explains various hacking tricks. He has earlier reviewed Web Penetration Testing with Kali Linux, Joseph Muniz and Aamir Lakhani, Packt Publishing. He can be found on Facebook at www.facebook.com/tajinder.kalsi.tj or you can follow him on his website at www.tajinderkalsi.com. I would like to thank the team of Packt Publishing for approaching me through my blog and offering me this opportunity again. I would also like to thank my family and close friends for all the support they have given while I was working on this project. Amit Pandurang Karpe works for FireEye, Inc., a global information security company, as a support engineer supporting their Asia Pacific customers. He stays in Singapore with his wife, Swatee, and son, Sparsh. He has been active in the open source community from his college days, especially in Pune, where he was able to organize various activities with the help of vibrant and thriving communities, such as PLUG, TechPune, IT-Milan, and Embedded Nirvana. He writes blog posts about technologies at http://www.amitkarpe.com. He has worked on Rapid BeagleBoard Prototyping with MATLAB and Simulink, Dr. Xuewu Dai and Dr. Fei Qin, Packt Publishing. Currently, he is working on Building Virtual Pentesting Labs for Advanced Penetration Testing, Kevin Cardwell and Kali Linux CTF Blueprints, Cam Buchanan, both by Packt Publishing. I would like to thank the open source community, without whom I couldn't have succeeded. A special thanks to the visionaries behind Kali Linux, who believed in open source and led by providing various examples. Also, many thanks to the community members and information security experts, who keep doing a great job, which makes Kali Linux a success. I would like to thank the Packt Publishing team, editors, and the project coordinator, who kept doing the right things so that I was able to perform my job to the best of my abilities. I would like to thank Pune Linux Users Group (PLUG), Embedded Nirvana group, and VSS friends, because of whom I was able to work on this project.