Wednesday, January 14, 2015

Dead Web Security Testing

I'd like to preface this blog post by saying that everything I'm doing is for educational purposes only and no one should ever use a tool like this for malicious purposes.

For this blog post I'm going to be focusing on website security.  There are a lot of ways websites can be insecure, and a lot of ways to test what kind of vulnerabilities different websites have.  Fortunately there are a lot of tools that exist already that bombard websites with all kinds of tests.  I'm going to be using one called Vega, which can be downloaded at https://subgraph.com/vega/download/.  This tool is very simple, simply give it a website URI and it does the rest, giving you a nice pretty printout with any security vulnerabilities it finds.

Since this is purely for educational purposes I'm going to be testing a fake website at http://testasp.vulnweb.com/search.asp. Here are the results of the Vega scan:

Vega Printout - 2 High Risk Flaws!!!
As you can see Vega is showing us 2 high risk errors, both having to do with cookies.

mmmmm cookies
Cookies, for anyone who doesn't know, are teeny tiny files that websites save on your computer so that website can look at them later and effectively use them to "remember" things.  In this case we have a cookie without the "Secure Flag" and a cookie without the "HttpOnly Flag".  Not having the "Secure Flag" means that the cookie can be sent over an insecure connection.  Basically, once you connect to a website you'll generally have an insecure connection but some websites will quickly redirect you to a secured connection.  The Secure Flag will stop the cookie from sending over the insecure connection and will make it wait for the secure connection before its sent.  Fixing this is quite simple, the developer simply has to mark the cookie as being "Secure Only".

The second vulnerability is marked "Cookie without the HttpOnly flag".  The HttpOnly flag affects who can access your cookies.  Enabling it means that only the webpage can look at your cookies, This is important as it can stop third parties from accessing you sensitive information through java script.  Again, fixing this is quite simple as its only requires a flag on the cookie to be set by the developer.

No comments:

Post a Comment