The Anatomy of a Man in the Middle Attack

Similar documents
Post Connection Attacks

Man in the middle. Bởi: Hung Tran

NETGEAR-FVX Relation. Fabrizio Celli;Fabio Papacchini;Andrea Gozzi

Example: Configuring DHCP Snooping and DAI to Protect the Switch from ARP Spoofing Attacks

Progress Report 1. Group RP16. All work done by Ivan Gromov and Andrew McConnell

ICS 451: Today's plan

CIT 380: Securing Computer Systems. Network Security Concepts

SECURITY ON PUBLIC WI-FI New Zealand. A guide to help you stay safe online while using public Wi-Fi

Local DNS Attack Lab. 1 Lab Overview. 2 Lab Environment. 2.1 Install and configure the DNS server. SEED Labs Local DNS Attack Lab 1

When does it work? Packet Sniffers. INFO Lecture 8. Content 24/03/2009

WIRELESS EVIL TWIN ATTACK

12 WEEK EXAM NAME: ALPHA: SECTION:

ELEC5616 COMPUTER & NETWORK SECURITY

Material for the Networking lab in EITF25 & EITF45

Network Security. Dr. Ihsan Ullah. Department of Computer Science & IT University of Balochistan, Quetta Pakistan. June 18, 2015

A Framework for Optimizing IP over Ethernet Naming System

IPv6 Traffic Hijack Test System and Defense Tools Using DNSSEC

Switching & ARP Week 3

Telnet Session Hijack

CIS 76 Telnet Session Hijack. Admonition

Switched environments security... A fairy tale.

Computer Network Routing Challenges Associated to Tackle Resolution Protocol

Extending NTOP feature to detect ARP spoofing

COMP 2000 W 2012 Lab no. 3 Page 1 of 11

Hacking Wireless Networks by data

R (2) Implementation of following spoofing assignments using C++ multi-core Programming a) IP Spoofing b) Web spoofing.

Man In The Middle Project completed by: John Ouimet and Kyle Newman

FUN WITH ETTERCAP FILTERS IronGeek

shortcut Tap into learning NOW! Visit for a complete list of Short Cuts. Your Short Cut to Knowledge

Development of IDS for Detecting ARP Attack using DES Model

Wireless LAN Security (RM12/2002)

Network Attacks. CS Computer Security Profs. Vern Paxson & David Wagner

LOCATION SPOOFING ON IOS WITHOUT A JAILBREAK

Welcome to PHOENIX CONTACT Routing

Secure Communications Over a Network

Using Microsoft Outlook Data Files

CheckBook Pro 2 Help

Sum or difference of Cubes

Cisco CCNA Basic IP Routing Part I

Computer Networks (Introduction to TCP/IP Protocols)

What is Eavedropping?

Lab1. Definition of Sniffing: Passive Sniffing: Active Sniffing: How Does ARP Spoofing (Poisoning) Work?

1 TABLE OF CONTENTS UNCLASSIFIED//LES

VERSION Lab 3: Link Layer

Internet Layers. Physical Layer. Application. Application. Transport. Transport. Network. Network. Network. Network. Link. Link. Link.

Selected Network Security Technologies

AN INTRODUCTION TO ARP SPOOFING

Internetwork Expert s CCNA Security Bootcamp. Mitigating Layer 2 Attacks. Layer 2 Mitigation Overview

CYBER ATTACKS EXPLAINED: WIRELESS ATTACKS

Wireless Network Security

in-the-middle attack

ARP Inspection and the MAC Address Table for Transparent Firewall Mode

Network Defenses 21 JANUARY KAMI VANIEA 1

ETHICAL HACKING OF WIRELESS NETWORKS IN KALI LINUX ENVIRONMENT

DKT 224/3 LAB 2 NETWORK PROTOCOL ANALYZER DATA COMMUNICATION & NETWORK SNIFFING AND IDENTIFY PROTOCOL USED IN LIVE NETWORK

How to Configure Mobile VPN for Forcepoint NGFW TECHNICAL DOCUMENT

CCNP Switch Questions/Answers Securing Campus Infrastructure

Attacks on DNS: Risks of Caching

Section 4 Cracking Encryption and Authentication

Foundations of Network and Computer Security

ARP SPOOFING Attack in Real Time Environment

Sybex CCENT Chapter 8: IP Routing. Instructor & Todd Lammle

Analysis of OpenFlow Networks.

The following virtual machines are required for completion of this lab: Exercise I: Mapping a Network Topology Using

Hands-On Ethical Hacking and Network Defense Chapter 5 Port Scanning

Assignment 2 TCP/IP Vulnerabilities

Lab Using Wireshark to Examine Ethernet Frames

Hands-On Ethical Hacking and Network Defense Chapter 5 Port Scanning

CS 161 Computer Security

VPN Tracker for Mac OS X

Network security - basic attacks

GenCyber Networking. ARP Poisoning

MIS2502: Data Analytics MySQL and SQL Workbench. Jing Gong

DNS CACHE POISONING LAB

5. Write a capture filter for question 4.

Lab Using Wireshark to Examine Ethernet Frames

Course Workbook 1st Edition

Web Design Competition Tutorial. Designed for use by the Michigan Council of Women in Technology Copyright 2018 Patricia Howard All Rights Reserved

Detecting Sniffers on Your Network

Defeating All Man-in-the-Middle Attacks

CYBER ATTACKS EXPLAINED: PACKET SPOOFING

Recent advances in IPv6 insecurities Marc van Hauser Heuse CCC Congress 2010, Berlin Marc Heuse

[Yagnik* et al., 5(9): September, 2016] ISSN: IC Value: 3.00 Impact Factor: 4.116

CSc 466/566. Computer Security. 18 : Network Security Introduction

CCENT Study Guide. Chapter 9 IP Routing

Sniffing. Michael Sonntag Institute for Information processing and microprocessor technology (FIM) Johannes Kepler University Linz, Austria

VRRP with VPN FAILOVER

Computer Forensics: Investigating Network Intrusions and Cybercrime, 2nd Edition. Chapter 2 Investigating Network Traffic

Introduction to SSL. Copyright 2005 by Sericon Technology Inc.

network security s642 computer security adam everspaugh

THIS PAPER SHOULD NOT BE OPENED UNTIL PERMISSION HAS BEEN GIVEN BY THE INVIGILATOR

Kaleidoscope User Guide. Kaleidoscope Pro. Quickstart: Bat Auto-ID

2. Network Infrastructure Security -- Switching

Lab 9.8.1: Address Resolution Protocol (ARP)

Recent advances in IPv6 insecurities reloaded Marc van Hauser Heuse GOVCERT NL Marc Heuse

Ethical Hacking as a Professional Penetration Testing Technique ISSA Southern Tier & Rochester Chapters

Copyright 2000: PictureTel Corporation Printed in U.S.A. PictureTel Corporation, 100 Minuteman Road, Andover, MA

Internet Protocol and Transmission Control Protocol

ARP Inspection and the MAC Address Table

CSC 6575: Internet Security Fall Attacks on Different OSI Layer Protocols OSI Layer Basic Attacks at Lower Layers

Transcription:

Before we dig into this tutorial, lets take an opportunity to cover a fundamental ARP based attack, the Man in the Middle. We re going to cover how this attack works and then we re going to launch this attack on our test network. So, let s discuss how this attack works. The Anatomy of a Man in the Middle Attack A Man in the Middle is just what is sounds like. We re going to insert ourselves into the middle of a connection. Let s take a look at a diagram of a MitM attack, then we ll dissect it further: We can see in the diagram above that the attacker has killed the victim s original connection to the server. The victim and server now think they are connected to each other, when they re actually both connected to the attacking machine. Neither ends of the connection know that anything is wrong, and the attacker can see all unencrypted traffic that flows between them. This attack can be used to do a whole slue of attacks. The attacker and spy on the victim (which is what we re going to do here), they can send fake information to the victim as the server, and they can catch any passwords that the victim uses to log into the server. Side Note: Since ARP is a layer 2 protocol, it can only be used in LANs. Therefore, ARP based MitM attacks can only be performed on a LAN Now that we know the end result of a MitM, let s discuss the technology behind it. When hosts use ARP, they are trying to resolve IP addresses to MAC addresses. When a host has the MAC address of another host, it will use that address to send data across a LAN. These associations of IP to MAC addresses are stored in the MAC address table of the host. If we can manage to replace the MAC address associated with a certain IP address

with our own, that host will send all data meant for that IP to us instead. Now image if we do this for two hosts and replace the MAC address associated with the other host with ours. All data that goes between those two hosts would then be sent to us instead. Now that we know the ins and outs of MitM attacks, let s move on to launching the attack! Step 1: Find Your Victim and the Gateway If we re going to be launching an attack, we ll need to find a victim. You could find victim on your LAN via a ping scan or an ARP scan (just to name a few). We also need to default gateway. Since we re on a LAN, we re going to spy on our victims activity on the Internet. This means that we ll need to launch our MitM between them and the default gateway of the network, that way all data from the victim intended for the Internet must go through us first. I ve already selected my victim (10.0.0.15), and we can find our default gateway by using the route command: We can see by the highlighted output of the route command that our default gateway is 10.0.0.1. Now that we have our victims IP addresses, we re almost ready to launch our attack. Step 2: Enable IP Forwarding Now one of the main issues with ARP based MitM attacks is that since all the data is being sent to the attacker, it won t get to it s destination. This will effectively kill the victim s Internet access and will generate quite a bit of suspicion! We need to make it so that the data can pass through the attacking system instead of bouncing off of it. Doing this will allow our attack to seamlessly come together with minimal suspicion from the victims. In order to enable IP forwarding, we need to write a 1 to a file under the /proc directory. Let s take a look at the command that will enable IP forwarding for us:

If you think about it, this actually makes sense. In binary, a one stands for on. If we put a one in the ip_forward file, we effectively turn IP forwarding on. Now that we ve enabled IP forwarding, we can establish our MitM. Step 3: Launch the MitM We re going to be using a tool by the name of arpspoof in order to launch our attack. First things first, let s take a look at the help page for this tool: Alright, it looks like we need to use -t and -r in order to specify our victims. We also need to use -i to specify the network interface we want to send our attack out of (in our case, wlan0). Now that we know what flags we need to give, let s take a look at the command to launch our attack, and some of the output that it will give: Here we can see that we re sending ARP replies that say our MAC address is tied to both the victim s IP addresses. We ve successfully launched a Man in the Middle attack! Now that we have this attack going, let s use it spy on their web surfing. Step 4: Sniff the Victim s Activity We re going to be using a tool named urlsnarf in order to sniff the victims web activity. Let s take a look at the command we ll need to use to start this sniffing: Now, when we execute this command, we re going to get LOTS of output, so I m just going to filter through it and highlight what we re looking for. Let s take a look at our sniffing results:

We can see in the highlighted output above that our victim at 10.0.0.15 is browsing on none other than howtohackin.com/blog! Let s give a brief wrap-up and end this lesson. Today, we not only learned the anatomy of a MitM attack, we learned how to perform one and how to utilize it to spy on a victim s web activity. This attack is very common on LANs and, given the proper circumstances, can be very effective in successfully hacking a target.