MITM: Loading a https logon form over http

Ok, we talked about XSS before, lets talk about MITM now.

MITM (Short for Man In The Middle) is a security flaw / risk in many websites. MITM attacks usually happen when a website has a weak TSL (Transport Security Layer) or a website has loaded parts over http (Without TSL) and parts over https (With TSL).

TSL is a way of verifying that the client and website are communicating securely. All websites that use TSL should be on a https connection, those without TSL will be on a http connection (You can check this in the address bar)

What is the risk of a MITM attack?

Well, let’s say you have a https logon form loaded over http. Normally, When the user enters their credentials, the credentials were securely hashed and salted using a hashing algorithm, they would then sent off to a server php file that analyzed the credentials.

However, during a MITM attack, because the logon form was loaded over a http connection with no TSL, the attacker could manipulate the logon form to send the credentials off to a 3rd party website/server and not to the legit website/server.

Moreover, the attacker could even redirect the client/victim to the legit website, so everything would seem normal to the victim and they wouldn’t even know that their account had been compromised or breached.

At which internet point between the client and the website/server could this be done?

It could happen anywhere. Your router, ISP, proxy or even your computer itself!

I still don’t understand what you are talking about.

If you prefer a video to watch instead of reading this, Troy Hunt did a video about it here. That should help you understand a bit more about the risks of a MITM attack.


Even though this example was using a logon form, an attacker could easily manipulate anything else that was loaded on a http connection with no TSL. An attacker could manipulate the webpage to make the victim download and run a malicious script or program.

Even if you do not have any logon forms or personal info on your website, it’s still a good idea to secure your site with a https connection and a valid security certificate, to stop the people who visit your website being the victims of a MITM attack.

Check out the risks of XSS attacks with a https logon form being loaded over http here.



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s