Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

[Tutorial] Basic XSS

Okay, in this tutorial I aim to give you a very basic understanding of cross-site scripting, also known on XSS. I advise you do this on Mozilla's Firefox web browser, as newer versions of Internet Explorer edit the site to prevent XSS.

Finding your target.

Obviously, before you can hack a site, you need to find a site vulnerable to what you want to do, in this case, XSS. We can do this using a search engine. I recommend google. What we want to search is:

Quote:inurl:guestbook html enabled


What you should see as a list of results is many websites containing "guestbooks". A guestbook is a page of website, where users may leave comments, it is recommended the guestbook you choose doesn't send posts for moderation before they are publically shown.


Is my target vulnerable?

To find this out, we need to do a small XSS test. Doing this is simple. Go into the guestbook and add a post. In the comment/content/post box, send the following line of code.

Quote:"><script>alert("Vulnerability Test")</script>


If the site is vulnerable, a popup window saying "Vulnerability Test" will appear.


Injecting HTML.

Now we want to take advantage of the XSS vulnerability. Type in the following:

Quote:"><script>alert("I have hacked your site")</script>
<!--Hacked By (Your name)-->
(Message to the viewer)
[Any other HTML code you would like to add]


You can put as much HTML as you want in it, and if you have a good understanding of HTML, you can edit the page itself, but I won't go into that, as this is just a basic XSS Tutorial.


I hope you understood and learned something from my tutorial. Any questions? PM me!
Good tutorial brother I love the colors and the <code> it really helped me understand :)

Very simple, 4/5
nice tutorial...help it in good way..keep posting....
Thank you for the feedback! Once I learn more advanced XSS myself I'll add a tutorial on it! ^^
This is solid. Thanks heaps.
No problem. Thanks for the feedback.
nice nice :D

keep writing stuff like this

greets
kito
Thanks Kito ^^ I've never actually seen you on Hackforums before xD
Great Job Dude Keep It Up .. <3 ur Thread!!
Thanks a lot. Every bit of feedback is appreciated, positive or negative. ^^ I'm disappointed with the amount of views and the small amount of replies though!
Great job, short and simple tutorial. Thanks
good tut, easy to read and not complicated. perfect for the amount of knowledge most people have. :)


Possibly Related Threads...
Thread / Author Replies Views Last Post
by ~[DogiD]~Jul 2, 2023 09:34 AM 74 12,751 Jul 2, 2023 09:34 AM
Last Post: SIM-5382664
by webbOct 17, 2019 06:17 PM 73 3,659 Oct 17, 2019 06:17 PM
Last Post: sain321
by xSellizeJan 26, 2019 10:22 AM 61 7,377 Jan 26, 2019 10:22 AM
Last Post: ratsandmice