This is my first Article/Tutorial so hopefully it is pretty good and that it is able to help those out who are in need and who want to become better Hackers.
This is meant as a Tutorial to help you learn what you should know for the different Basic Web Hacking Challenges and a guide to help you along.
It does not give you answers or tell you exactly what to do, it just helps lead you in the right direction with a little help and advice.
Please give me some feedback about what you think about it and what I could do to improve it.
*I use Mozilla Firefox, so this tutorial is based around that Web Browser. Sorry for any inconvenience.
Basic Web Hacking - Mission 1:
This mission is called "The Idiots Test" for some obvious reasons.
This mission and almost all of the other Basic Web Hacking Challenges will use a web designing code called HTML (Hyper Text Markup Language) and PHP (Hypertext Preprocessor), along with some others.
I recommend that if you know very little or nothing about HTML or PHP that you go and read up on it either on the web or in a book. You can check some sites that I listed in my References at the bottom for help.
If you are wondering how to check and view the HTML of a site, you have three options.
Option One: "Right click" any where on the page except on Pictures, Flash Documents, Java Applets and other content like that, and press "View Page Source". This will open up a file that has the HTML code used to make that site.
Option Two: On your Web Browsers top menu bar click "View" then choose "Page Source".
Option Three: Hold down on the control (Ctrl) button on your keyboard and press "U".
Explore the HTML source code and who knows what you might be able to find.
Basic Web Hacking - Mission 2:
This mission is A LOT easier than one might believe and to be completely honest, it even stumped me for a er ... lengthy period of time.
I can't stress how important it is to read the beginning information very clearly. Read it once, then read it again without even trying to get the password. This will come in handy for later challenges.
So remember Read The Beginning Information VERY CAREFULLY!
Basic Web Hacking - Mission 3:
This is the first mission that really relies on knowing how to read HTML, especially about forms in HTML.
You also need to start noticing how the directories of the different web pages are used and when a form is submitted what it does to make sure the password is right and on what directory and web page it would store the password in.
HTML knowledge is key for this challenge. Also, pay close attention to the action used in this form and to where it is being checked from.
Basic Web Hacking - Mission 4:
This is where you will probably notice the challenges getting a bit harder.
In this mission, Network Sam seems to be a forgetful person so he made a script that would E-Mail the password to him so that he be able to get it if he forgot it.
Some good references are listed in my references. This will be a main part of this mission and even the next one.
The other option is to re-write the HTML document. How and what exactly to re-write is up to you to find out. All I can say without giving it away is that you sould keep in mind the script that Network Sam created to E-Mail the password to himself and where it is being checked (the action of the form).
Basic Web Hacking - Mission 5:
This challenge is quite similar to the previous but Network Sam has gotten a bit smarter and made the script to E-Mail the password to him a bit more secure.
Basic Web Hacking - Mission 6:
Now Sam has gotten smarter. He has ... gulp ... ENCRYPTED his password. But not to worry because he always messes up somewhere.
He has a script on his page that when you type letters, number and/or symbols into and press "Encrypt", it gives you the encrypted version of what you typed in.
He has the encrypted password on the page, but the password that you need is the decrypted version of encrypted one that he gives you.
This can be achieved in different ways. You might want to fool around with the Encryptor and try to find a pattern in the way it encrypts what you type in. You can build a decryptor yourself, or once you find the pattern, try to figure it out yourself with the slow and time consuming method of Trial and Error.
Try some letter sequences and muck around with it and it will become a lot clearer. Try some sequences such as "aaaaa" which when encrypted becomes "abcde".
You might also want to read up on ASCII and how it works.
Basic Web Hacking - Mission 7:
This time Sam has made a nice little script that when you put in a year, the calendar of that year shows up. This is also knows as the UNIX "cal" command.
No when Sam usually puts things like this on his page there is usually always a way to exploit it, and that is what you are going to do.
If you know nothing about *NIX/UNIX Commands, I would highly recommend that you go do some research right now.
To get you going on the right track, you should know that he is currently running the "cal" command so you have to find a way to end that command and start another command that will do something else and maybe get you a list of important files.
Basic Web Hacking - Mission 8:
This mission introduces a new dot extension that you have never seen so far in the challenges. It is .shtml. Before going any further, I would reccommend you do some research on .shtml more specifically SSI (Server Side Includes).
Sam gives the file that the password file is stored in /var/www/hackthissite.org/html/missions/basic/9/.
When you use the script on that page you will notice that it takes you two directories ahead of where the password is stored.
Like the last challenge, you will want to list the files to find the one that you want but in a different format (SSI). You will also have to find the *NIX/UNIX command to go back two directories.
You will have to get the code dead on because your syntax is monitored very carefully.
Basic Web Hacking - Mission 9:
This challenge is very similar to BASIC 8, except that it is missing an input box to run a command.
His new password is now stored in /var/www/hackthissite.org/html/missions/basic/9/, which is very similar to where it was stored in BASIC 8, except in a different directory.
If only you had a place somewhat like BASIC 8 to type in your code and get to that directory.
Basic Web Hacking - Mission 10:
Network Sam has become a little more advanced. He has created a cookie script to see if you are authorized to view the password page or not.
I would like to conclude saying that I hoped that this quick and to the point Article/Tutorial has helped you understand how to complete the Basic Web Hacking Challenges and helped you learn something new.
Learning by doing most of the work and research is a lot better than getting the answer or how to get the answer given to you is critical for you Hacking future and because if it is given to you it is no fun and is basically making you rely on someone else. There is nothing better that the feeling of beating a challenge on your own.
I hope that I have not given any BIG spoilers and just helped you fellow and future hackers to understand the concepts use to get the answers but still making you do basically all of the main work yourself because it is a better way of learning.
If you think that I did not help enough and that I could have told you more on how to find the answer, you will thank me in the future when you realize that doing it yourself has taught you great knowledge that you can use with confidence because you took the time to figure it out yourself and do not have to wait on people to do it for you.
Please feel free to give me feedback on this article so that I can try to make it better. If anyone thinks that I said too much somewhere, please inform me because that definitely the last thing that I want to do. If you have a question that you don't think should be posted, Please PM me or E-Mail me at email@example.com.
Thank You for taking the time to read my article and please be sure to check out my References for further learning and knowledge.
Happy Hacking: DoS-man