A man-in-the-middle attack (MITM attack), sometimes known as a person-in-the-middle attack, is a cyber attack where an attacker relays and possibly alters communication between two parties who believe they are communicating directly. This allows the attacker to intercept communication, listen in, and even modify what each party is saying.
Man-in-the-middle attacks enable eavesdropping between people, clients and servers, such as browser connections to websites, other machine-to-machine web service connections, Wi-Fi networks connections and more.
Imagine logging in to a web site to download a statement. An attacker wishes to intercept the conversation with the intention of pretending to be you at a later time.
You first type the URL of the web site into your browser, then your browser uses DNS to look up the IP address of the web site. An attacker sends back a false DNS result with the IP address of a machine they control. You’re not sure how the attacker managed this attack. Perhaps they were on the same network as your machine, or maybe they physically hacked into the ethernet cable connected to your internet service provider.
At this point, the attack begins. Everything your browser sends is communicated to the attacker’s machine, which is then relayed onto the real server. Every response from the real server is sent back to you. Imitating a website with HTTPS is difficult without the certificate in hand, so the attacker may send back a redirect response to send you to a website owned by the attacker with its own certificate. Or they may use the original domain under the insecure HTTP with a false IP address.
The attacker captures your username and password, to log in later as you so they can perform unauthorized transactions from your account. If a site is protected by multi-factor authentication, the attacker could instead capture your session token. With your session token, they would block your logout action so they can continue the current session when you close your browser.
This example highlights how digital communications can be intercepted. Protocols like HTTPS and DNSSec mitigate the risks of a MITM attack. These protocols alert users when something is wrong and disallow the connection if it is not protected.
Man-in-the-middle attacks are dangerous and generally have two goals:
In practice, this means gaining access to:
Common targets for MITM attacks are websites and emails. Email, by default, does not use encryption, which enables an attacker to intercept and spoof emails from the sender with only their login credentials.
Due to the nature of Internet protocols, much of the information sent to the Internet is publicly accessible. When you connect to a local area network (LAN), every other computer can see your data packets.
When an attacker is on the same network as you, they can use a sniffer to read the data, letting them listen to your communication if they can access any computers between your client and the server (including your client and the server).
In a man-in-the-middle attack, the attacker fools you or your computer into connecting with their computer. This attack makes you believe that the attacker's offer is the place you wanted to connect to. Then they connect to your actual destination and pretend to be you, relaying and modifying information both ways if desired. This is a much bigger cybersecurity risk because information can be modified.
As cybersecurity trends towards encryption by default, sniffing and man-in-the-middle attacks become more difficult but not impossible. Attackers can use various techniques to fool users or exploit weaknesses in cryptographic protocols to become a man-in-the-middle.
There are many types of man-in-the-middle attacks but in general they will happen in four ways:
A man-in-the-middle attack can be divided into three stages:
Once the attacker is able to get between you and your desired destination, they become the man-in-the-middle. For this to be successful, they will try to fool your computer with one or several different spoofing attack techniques.

ARP (or Address Resolution Protocol) translates the physical address of a device (its MAC address or media access control address) and the IP address assigned to it on the local area network. An attacker who uses ARP spoofing aims to inject false information into the local area network to redirect connections to their device.
Imagine your router's IP address is [.rt-script]192.169.2.1[.rt-script]. To connect to the Internet, your laptop sends IP (Internet Protocol) packets to [.rt-script]192.169.2.1[.rt-script]. To do this, your machine must known which physical device has this address. For this example, the router has a MAC address of [.rt-script]00:0a:95:9d:68:16[.rt-script].
Here's how ARP spoofing happens:

IP spoofing is when a machine pretends to have a different IP address, usually the same address as another machine. On its own, IP spoofing isn't a man-in-the-middle attack but it becomes one when combined with TCP sequence prediction.
Generally, internet connections are established with TCP/IP (Transmission Control Protocol / Internet Protocol):
In an IP spoofing attack, the attacker first sniffs the connection. On a local network, all IP packets go into the network and are readable by the devices on the network. The attacker learns the sequence numbers, predicts the next one, and sends a packet pretending to be the original sender. If the packet reaches the destination first, the attack can intercept the connection.
Imagine an attacker joins your local area network with the goal of IP spoofing:

ARP spoofing and IP spoofing both rely on the attack being connected to the same local area network as you. With DNS spoofing, an attack can come from anywhere. DNS spoofing is more difficult because it relies on a vulnerable DNS cache, but it can affect a large number of people if it is successful.
DNS (Domain Name System) is the system used to translate IP addresses and domain names, like directing from an IP address to [.rt-script]example.com[.rt-script]. The system has two primary elements:
Here is an example of DNS spoofing:

Web browser spoofing is a form of typosquatting where an attacker registers a domain name that looks very similar to the domain you want to connect to. Then they deliver the false URL to use other techniques like phishing.
The Google security team believe the address bar is the most important security indicator in modern browsers. It provides the true identity of a website and verification that you are on the right website.
One example of address bar spoofing was the Homograph vulnerability that took place in 2017. It exploited the International Domain Name (IDN) feature that allows domain names to be written in foreign characters using characters from various alphabets to trick users.
For example, [.rt-script]xn--80ak6aa92e.com[.rt-script] would show as [.rt-script]аррӏе.com[.rt-script] due to IDN, which is virtually indistinguishable from [.rt-script]apple.com[.rt-script]. This has since been patched by showing IDN addresses in ASCII format.

Email hijacking is when an attacker compromises an email account and silently gathers information by eavesdropping on email conversations. Email hijacking can make social engineering attacks very effective by impersonating the person who owns the email. This approach is often used for spearphishing.

A man-in-the-browser attack exploits vulnerabilities in web browsers like Google Chrome or Firefox. Trojan horses, worms, exploits, SQL injections and browser add-ons can all be attack vectors.
The goal is often to capture login credentials, especially financial services companies like your credit card company or bank account. When you log in to the site, the man-in-the-browser captures your credentials to transfer funds and modify what you see to hide the transaction.

If you've ever logged into a public Wi-Fi access point at a coffee shop or airport, you may have noticed a pop-up that said This network is not secure.
Unencrypted Wi-Fi connections are easy to eavesdrop. It's like having a conversation in a public place where anyone can listen in. You can limit your exposure by setting your network to public, which disables Network Discovery and prevents other users on the network from accessing your device.

Another example of Wi-Fi eavesdropping is when an attacker creates their own Wi-Fi hotspot, called an Evil Twin. They make the connection look identical to the authentic one, down to the network ID and password. Users may accidentally or automatically connect to the Evil Twin, allowing the attacker to eavesdrop on their activity.

SSL hijacking is when an attacker intercepts a connection and generates SSL/TLS certificates for all domains you visit. They present the fake certificate to you, establish a connection with the original server, and then relay the traffic on.
This attack only works if the attacker is able to make your browser believe the certificate is signed by a trusted Certificate Authority (CA). Otherwise your browser will display a warning or refuse to open the page.
Here's how SSL hijacking works:
SSL hijacking can be used for legitimate purposes. For example, parental control software often uses SSL hijacking to block sites.

SSL Stripping or an SSL Downgrade Attack is an attack used to circumvent the security enforced by SSL certificates on HTTPS-enabled websites.
When you go to website, your browser connects to the insecure site (HTTP) and then is generally redirected to the secure site (HTTPS). If the website is available without encryption, an attacker can intercept your packets and force an HTTP connection that could expose login credentials or other sensitive information to the attacker.
The risk of this type of attack is reduced as more websites use HTTP Strict Transport Security (HSTS) which means the server refuses to connect over an insecure connection, though there are still some risk factors facing HSTS setup.
Older versions of SSL and TLS are vulnerable to exploits, but you can strengthen weak SSL.

Session hijacking is a type of attack that typically compromises social media accounts. Most social media sites store a session browser cookie on your machine. This cookie is then invalidated when you log out. But while the session is active, the cookie provides identity, access, and tracking information.
When an attacker steals a session cookie through malware, browser hijacking, or a cross-site scripting (XSS) attack on a popular web application with malicious JavaScript, they can then log into your account to listen in on conversations or impersonate you.
There are more methods for attackers to place themselves between you and your end destination. These methods usually fall into one of three categories:
There are many types of man-in-the-middle attacks and some are difficult to detect. The best countermeasure against man-in-the-middle attacks is to prevent them. While it is difficult to prevent an attacker from intercepting your connection if they have access to your network, you can ensure that your communication is strongly encrypted.
Here are some general tips you can follow:

The Babington Plot: In 1586 there was a plan to assassinate Queen Elizabeth I and put Mary, Queen of Scots on the English throne. Communications between Mary, Queen of Scots and her co conspirators was intercepted, decoded, and modified by Robert Poley, Gilbert Gifford, and Thomas Phelippes, which lead to the execution of the Queen of Scots.
%2C445%2C291%2C400%2C400%2Carial%2C12%2C4%2C0%2C0%2C5_SCLZZZZZZZ_.jpeg)
Belkin: In 2003, a non-cryptographic attack was perpetrated by a Belkin wireless network router. Periodically, it would take over HTTP connection being routed through it, fail to pass the traffic onto the destination, and respond as the intended server. In the reply it sent, it would replace the web page the user requested with an advertisement for another Belkin product. This issue was later resolved.

DigiNotar: In 2011, a DigiNotar security breach resulted in fraudulent issuing of certificates that were then used to perform man-in-the-middle-attacks.

Nokia: In 2013, Nokia's Xpress Browser was revealed to be decrypting HTTPS traffic giving clear text access to its customers' encrypted traffic.

Equifax: In 2017, Equifax withdrew its mobile phone apps due to man-in-the-middle vulnerability concerns.
UpGuard's platform can help you understand which of your sites are susceptible to man-in-the-middle attacks and how to fix their vulnerabilities. UpGuard Breach Risk can help combat typosquatting, prevent data breaches and data leaks, so you can avoid regulatory fines and protect your customer's trust through cyber security ratings and continuous exposure detection.
We can also help you continuously monitor, rate and send security questionnaires to your vendors to control third-party risk and fourth-party risk and improve your security posture, as well as automatically create an inventory, enforce policies, and detect unexpected changes to your IT infrastructure. Helping you scale the processes in your Third-Party Risk Management framework and Vendor Risk Management program.