Some time ago i had found a possibility to prevent the browser to establish any unsecured connections to a server. I already redirect my users from HTTP to HTTPS but if a user sends a Request with sensitive data to http first and gets a redirect to HTTPS the data already has send to the server via HTTP.
Asked
Active
Viewed 262 times
3 Answers
2
There is absolutely nothing you can do to prevent anyone from sending data in clear text. The only control you have is how your server responds to it, if at all. With that in mind, I suggest you use normal means to either reject the request outright or to simply redirect it to HTTPS. Realistically there is nothing else you can do.
John Gardeniers
- 27,558
1
I was searching for the HTTP Strict-Transport-Security Header. http://hacks.mozilla.org/2010/08/firefox-4-http-strict-transport-security-force-https/
Maximilian Ruta
- 153
0
You could configure the webserver to not listen on port 80. This way there will be no TCP Handshake and the browser will not even send his first data packet. Obviously then the redirection will not work any more.
leepfrog
- 488