Sunday, December 12, 2010

How to hack a Website or websites database


 Hello friends , welcome back to hacking class, today i will explain all the methods that are being used to hack a website or websites database. This is the first part of the class "How to hack a website or Websites database" and in this i will introduce all website hacking methods. Today I will give you the overview and in later classes we will discuss them one by one with practical examples. So guys get ready for first part of Hacking websites class.... Don't worry i will also tell you how to protect your websites from these attacks and other methods like hardening of SQL and hardening of web servers and key knowledge about CHMOD rights that what thing should be give what rights...

Note : This post is only for Educational Purpose only.



What are basic things you should know before website hacking?
First of all everything is optional as i will start from very scratch. But you need atleast basic knowledge of following things..
1. Basics of HTML, SQL, PHP.
2. Basic knowledge of Javascript.
3. Basic knowledge of servers that how servers work.
4. And most important expertize in removing traces otherwise u have to suffer consequences.
Now First two things you can learn from a very famous website for basics of Website design with basics of HTML,SQL,PHP and javascript.

And for the fourth point that you should be expert in removing traces . For this you can refer to first 5 hacking classes and specially read these two...

As we know traces are very important. Please don't ignore them otherwise you can be in big trouble for simply doing nothing. so please take care of this step. 

METHODS OF HACKING WEBSITE:

1. SQL INJECTION
2. CROSS SITE SCRIPTING
3. REMOTE FILE INCLUSION
4. LOCAL FILE INCLUSION
5. DDOS ATTACK 
6. EXPLOITING VULNERABILITY.

1. SQL INJECTION
 First of all what is SQL injection? SQL injection is a type of security exploit or loophole in which a attacker "injects" SQL code through a web form or manipulate the URL's based on SQL parameters.  It exploits web applications that use client supplied SQL queries.
The primary form of SQL injection consists of direct insertion of code into user-input variables that are concatenated with SQL commands and executed. A less direct attack injects malicious code into strings that are destined for storage in a table or as metadata. When the stored strings are subsequently concatenated into a dynamic SQL command, the malicious code is executed.

For more basic knowledge about SQL injection visit: 
http://www.hackingloops.com/2009/12/hacking-class-14-how-to-deface-websites.html
The above tutorial consists of both types of SQL injection i.e. Manual and automatic through softwares. I will explain SQL injection in more detail with practical example in Next class.


2. CROSS SITE SCRIPTING
  Cross site scripting (XSS) occurs when a user inputs malicious data into a website, which causes the application to do something it wasn’t intended to do.  XSS attacks are very popular and some of the biggest websites have been affected by them including the FBI, CNN, Ebay, Apple, Microsft, and AOL. 
Some website features commonly vulnerable to XSS attacks are:
•  Search Engines
•  Login Forms
•  Comment Fields 


Cross-site scripting holes are web application vulnerabilities that allow attackers to bypass client-side security mechanisms normally imposed on web content by modern browsers. By finding ways of injecting malicious scripts into web pages, an attacker can gain elevated access privileges to sensitive page content, session cookies, and a variety of other information maintained by the browser on behalf of the user. Cross-site scripting attacks are therefore a special case of code injection.

 I will explain this in detail in later hacking classes. So keep reading..


3. REMOTE FILE INCLUSION
Remote file inclusion is the most often found vulnerability on the website.
Remote File Inclusion (RFI) occurs when a remote file, usually a shell (a graphical interface for browsing remote files and running your own code on a server), is included into a website which allows the hacker to execute server side commands as the current logged on user, and have access to files on the server. With this power the hacker can continue on to use local
exploits to escalate his privileges and take over the whole system. 
RFI can lead to following serious things on website :
  • Code execution on the web server
  • Code execution on the client-side such as Javascript which can lead to other attacks such as cross site scripting (XSS).
  • Denial of Service (DoS)
  • Data Theft/Manipulation


 4. LOCAL FILE INCLUSION
  Local File Inclusion (LFI) is when you have the ability to browse through the server by means of directory transversal. One of the most common uses of LFI is to discover the /etc/passwd file. This file contains the user information of a Linux system. Hackers find sites vulnerable to LFI the same way I discussed for RFI’s.
Let’s say a hacker found a vulnerable site, www.target-site.com/index.php?p=about, by means of directory transversal he would try to browse to the /etc/passwd file: 
   www.target-site.com/index.php?p= ../../../../../../../etc/passwd


I will explain it in detail with practical websites example in latter sequential classes on Website Hacking.


5. DDOS ATTACK
Simply called distributed denial of service attack. A denial-of-service attack (DoS attack) or distributed denial-of-service attack (DDoS attack) is an attempt to make a computer resource unavailable to its intended users. Although the means to carry out, motives for, and targets of a DoS attack may vary, it generally consists of the concerted efforts of a person or people to prevent an Internet site or service from functioning efficiently or at all, temporarily or indefinitely. In DDOS attack we consumes the bandwidth and resources of any website and make it unavailable to its legitimate users.
 For more detailed hack on DDOS visit:
http://www.hackingloops.com/2009/11/hacking-class-11-attacking-websitesddos.html


6.EXPLOTING VULNERABILITY
Its not a new category it comprises of above five categories but i mentioned it separately because there are several exploits which cannot be covered in the above five categories. So i will explain them individually with examples. The basic idea behind this is that find the vulnerability in the website and exploit it to get the admin or moderator privileges so that you can manipulate the things easily.

I hope you all now have a overview of that what is Website Hacking. In consecutive future  classes i will explain all of these techniques in details. So guys keep reading..

IF YOU HAVE ANY QUERIES ASK IN COMMENTS...

19 comments:

  1. as always awesome man... really nice tutorial...

    ReplyDelete
  2. great guide, thanks ...

    ReplyDelete
  3. simply superb brother... keep it up. We are looking forward to your future tutorials...

    ReplyDelete
  4. @Tarun,munish

    Thanks guys for your valuable comments. In my further classes i will explain how to hack websites using SQL,cross site scripting,Remote file inclusion etc... in detail with practical examples. So frens keep reading my blog.

    ReplyDelete
  5. Keep the awesome work going !!

    ReplyDelete
  6. Hello,

    Could you write in your blog about my animated Christmas trees for desktop?

    Screenshot:
    http://get-xmas.com/trees/trees.jpg

    Homepage:
    http://get-xmas.com/


    Description:
    A collection of 19 animated desktop Christmas trees to suit every taste.

    If you are decorating your home for Christmas, why not do the same with your computers desktop?
    Raise your own Christmas spirit and do not forget to share it with your friends.
    A Christmas tree on your desktop that can remind you of how many days are left until Christmas, or even the New Year!

    It can be set to optionally stay on top of other windows, while the transparency is fully adjustable.
    Christmas trees - absolutely freeware.


    Merry Christmas :)

    ReplyDelete
  7. great tutorial buddy i hope you make new tutorials as soon as possibile xDDD ... if you know Zend Amf server how to do it ... pse make a tutorial for me :) thnx

    ReplyDelete
  8. hey dude can i kno how to hack my college website?
    sjpu.com

    plz help me!

    ReplyDelete
  9. dude i want hack this site http://gpgcm.lges.edu.pk/index.htm plz tell me which method should I use.....thnx

    ReplyDelete
  10. superb bro............... i need to recover my lost yahoo password ........ no one is using it ..............i forget it......what can i do

    ReplyDelete
  11. My name is Abram Armstrong, i want to thank you for the wonderful tutorial you have provided us with.
    Thank you.

    ReplyDelete
  12. how do i hack a login websiteg?

    ReplyDelete
  13. i mail you sir, please please reply me

    ReplyDelete
  14. I want to change the data of a website by hacking.But the data I want to change will be permanent.So,please help me to do this.
    Personally contact me at sandhugagandeep90@yahoo.com

    ReplyDelete
  15. nice.......
    contact me email:sund2703@gmail.com

    ReplyDelete
  16. hi..very nice. I hav a gud deal with u.. plz mail me at samuraik5@yahoo.com

    ReplyDelete

Please do not spam.

Designed by Hackingloops.