Friday 29 July 2011

Tweaking BackTrack 5 for maximum effectiveness.

Ok, so you downloaded BackTrack 5. As did 9001 other security-interested people, ranging from script kiddies to professional pentesters and equally professional blackhats.

The first thing you notice is, it is *not* perfect. Fast-Track is half broken by the updated MetaSploit Framework, and some tools are just plain missing.

## Updating, adding tools.

In fact, some people preferred Gnack-Track, which is now End-of-Lifed thanks to the shiny new GNOME BackTrack for those of us who despise the Fisher-Price interfaces of KDE.

So, first off, we run apt-get update && apt-get upgrade to install any nice new "fixes" that the team has come up with.

Next, if you miss some of the stuff from the GnackTrack system, or just want to update and add more awesomeness, go here for the BT5-fix script that "fixes" some things and adds others...
https://www.phillips321.co.uk/bt5-fixit-sh/

So now we have updated a bunch of stuff, installed new tools, but what next?

Ever notice how much of a pain in the ass it is that every time you load BT5 you spend a moment starting WICD daemon so you can connect to wireless networks?

## Adding WICD to init.d

root@bt:~# cd /etc/init.d/
root@bt:/etc/init.d/# gedit

Now save the following shell script as "wicdstarter.sh" in /etc/init.d/.

#!/bin/bash
# startup script for WICD daemon
# starts wicd
echo "[+] STARTING WICD"
/etc/init.d/wicd start
echo "[+] WICD INITIATED"

Now run the following command: "update-rc.d wicdstarter.sh defaults"
Followed by "chmod +x wicdstarter.sh"

That adds the Wicd Start script to init.d, saving you 0.5 seconds of your day.

## Fixing Fast-Track.

Now Fast-Tracks DB-Autopwn Automation seems to fail miserably since the update to MSF, so let me refer you to Zero Colds website for the fix he came up with.
http://zerocold.co.uk/?p=801

It works fine and now those of you who use that feature have it.

Also, check out his fine guide to NeXpose Installation on BT5 and MSF NeXpose Integration...
http://zerocold.co.uk/?p=840

## Adding ZeroColds Meterpreter Scripts for Post Exploitation.
http://forum.intern0t.net/other-programming-languages/2121-installer-sh.html

That "installer script" should install all his goodies. Let me see if it works (doing all this as I type)

Ok, it needs modification to function correctly. LETS MOD!

Modified code ---> http://pastebin.com/raw.php?i=iYRZSra9

Now I see the use for SOME of the scripts, others I am not so sure about. Though I reckon they are somewhat useful in a pentest to prove the amount of power one can have over a compromised system...

## Wi-fEye Fixing and Installation (and installing evilgrade + hamester)

Hamster and Ferret installation...

I put the Hamster-2.0.0 zip file in /root/work while I worked on it.

root@bt:~/work# unzip hamster-2.0.0.zip
root@bt:~/work# cd hamster
root@bt:~/work/hamster# cd build
root@bt:~/work/hamster/build# cd gcc4
root@bt:~/work/hamster/build/gcc4# make
root@bt:~/work/hamster/build/gcc4# cd ..
root@bt:~/work/hamster/build# cd ..
root@bt:~/work/hamster# cd ..
root@bt:~/work# cd ferret
root@bt:~/work/ferret# cd build
root@bt:~/work/ferret/build# cd gcc4
root@bt:~/work/ferret/build/gcc4# make
root@bt:~/work/ferret/build/gcc4# cd ..
root@bt:~/work/ferret/build# cd ..
root@bt:~/work/ferret# cd bin
root@bt:~/work/ferret/bin# mv ferret ~/work/hamster/bin/
root@bt:~/work/ferret/bin# cd ~/work
root@bt:~/work# mv hamster /pentest

DONE!

That is Hamster and Ferret installed in /pentest/hamster/ where Wi-fEye can use them!

###

Now lets install evilgrade-ng...
First run "apt-get install expect" to install the wierd dependancies.

Now we are back in the work directory and this is very easy.

root@bt:~/work# tar -xf isr-evilgrade-2.0.0.tar.gz
root@bt:~/work# mv isr-evilgrade evilgrade
root@bt:~/work# mv evilgrade /opt

Now it gets a bit harder. "WHY WONT IT FUCKING RUN!" is a common cry I hear.

It is because we need the Data::Dump perl module, which I will now show you how to install using the CPAN shell...

root@bt:~/work# cpan
Now it will ask a buttload of questions to which I just say "yes" lol

cpan[1]> install Data::Dump

I promptly get a load of output. I just say yes, again, to any options.

Once it is done doing "lots of shit" just type exit then you can run Evilgrade

Now lets install Wi-fEye...

###

Wi-fEye installation!

root@bt:~/work# tar -xf Wi-fEye-v0.5.6.tar.gz
root@bt:~/work# cd Wi-fEye-v0.5.6
root@bt:~/work/Wi-fEye-v0.5.6# gedit Wi-fEye.py

Now check that the infodox is correct... as in the paths - to things. It should be...

http://wi-feye.za1d.com/Documentation.html <--- better Wi-fEye infodox there!

Also download Wi-fEye from there

Download Evilgrade-ng here
http://www.infobyte.com.ar/developments.html

I cannot find a good Hamester download for the life of me so here is one
http://www.mediafire.com/?8486i3frg82wo11
http://dl.dropbox.com/u/36983782/hamster-2.0.0.zip

YOUTUBE VIDEO NOW ADDED!




Enjoy...

4 comments:

  1. nice post bro hamster & ferret are in the repo's now i will be making a re-write of the installer script soon as i have some new scripts to add

    ZeroCold

    ReplyDelete
  2. ZeroCold - awesome that it is back in the repos, and I will update this post with more information and links to your revised script for installation. Nice BASH scripting you do, been looking at the LAK script and others for ideas :)

    ReplyDelete
  3. just cant get it working.
    did everything you did in de vid. but i got stuck on the part where i have to change variables.

    ReplyDelete