So every time the BackTrack development team release a new version I download it and use it from fresh. I don’t like following the dist-upgrade route as I’ve had trouble in the past and it’s a good idea to get a clean build now and again.

I used to maintain a BT5-fixit.sh script but just don’t have the time. Instead I just use this script here: bt5r3gnome32.sh

I’ll walk through the code explain bit by bit what each section does.

Starting from a fresh install of BT5r3 gnome 32bit (this was created using the VM image)

First add the extra repository sources and keys:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
apt-get install -y python-software-properties
apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 4E5E17B5
apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 9BDB3D89CE49EC21

echo "deb http://packages.fwbuilder.org/deb/stable/ lucid contrib" >> /etc/apt/sources.list
echo "deb http://dl.google.com/linux/chrome/deb/ stable main #Google Stable Source" >> /etc/apt/sources.list
echo "deb http://deb.opera.com/opera/ lenny non-free #Opera Official Source" >> /etc/apt/sources.list
echo "deb http://archive.getdeb.net/ubuntu lucid-getdeb apps #GetDeb Software Portal" >> /etc/apt/sources.list.d/getdeb.list

add-apt-repository ppa:chromium-daily/stable
add-apt-repository ppa:shutter/ppa
add-apt-repository ppa:tualatrix/ppa
add-apt-repository ppa:ubuntu-wine/ppa
add-apt-repository ppa:deluge-team/ppa
add-apt-repository ppa:gnome-terminator/ppa
add-apt-repository ppa:mozillateam/firefox-stable
add-apt-repository ppa:nilarimogard/webupd8

wget -q -O - http://deb.opera.com/archive.key | apt-key add -
wget -q -O - http://archive.getdeb.net/getdeb-archive.key | apt-key add -
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -
wget -q -O - http://www.fwbuilder.org/PACKAGE-GPG-KEY-fwbuilder.asc | apt-key add -

Then we read in the packages from the repositories and apply updates:

1
2
apt-get update
apt-get -y dist-upgrade

Now install all the additional tools I want:

1
2
3
4
apt-get -y install jockey-gtk rungetty linux-headers filezilla synaptic geany shutter gnome-web-photo vino gufw nessus python-dev chromium-codecs-ffmpeg-extra chromium-codecs-ffmpeg-nonfree opera flashplugin-nonfree-extrasound flashplugin-nonfree file-roller giplet compiz-plugins fwbuilder gcalctool gtk-recordmydesktop mono-runtime mono-devel deluge tsclient meld launchpad-getkeys unetbootin wine1.3-gecko cmake tftp ntp rcconf rsh-client arp-scan dialog tree sslscan
apt-get -y clean
apt-get -y autoremove
apt-get -y autoclean

Now we need to make changes to the configuration of the system:
Allow bash completion(why isn’t this turned on by default???)

1
sed -i '/# enable bash completion in/,+3{/enable bash completion/!s/^#//}' /etc/bash.bashrc

Add the kernel sources

1
prepare-kernel-sources ; cd /usr/src/linux ; cp -rf include/generated/* include/linux/

Generate ssh keys to allow the ssh server to run

1
sshd-generate

Fix the pulseaudio sound server bug (this has been around since bt5r0 and it’s still here… why isn’t it fixed!!!)

1
cd /root/.config/ ; mkdir autostart ; cd autostart ; touch pulseaudio.desktop ; echo -e "\n[Desktop Entry]\nType=Application\nExec=/usr/bin/pulseaudio\nHidden=false\nNoDisplay=false\nX-GNOME-Autostart-enabled=true\nName[en_US]=PulseAudio Sound System\nName=PulseAudio Sound System\nComment[en_US]=Start the PulseAudio Sound System\nComment=Start the PulseAudio Sound System" > pulseaudio.desktop

Add nessus and openvas users:

1
2
3
nessus-adduser
nessus-fetch --register YOURKEYHERE
openvas-mkcert ; openvas-adduser ; openvas-nvt-sync

Change the location to be UK for both time and keyboard layout:

1
2
dpkg-reconfigure tzdata
dpkg-reconfigure console-setup

Fix warvox as it’s broke:

1
rm -rf /pentest/telephony/warvox/ ; svn co http://www.metasploit.com/svn/warvox/trunk /pentest/telephony/warvox

Complete the beef install:

1
beef_install.sh

Now we need to manually add tools that dont come with BT5r3 that I like to use:

1
2
3
4
cd /pentest/passwords/ ; wget http://www.unix-ag.uni-kl.de/~massar/soft/cisco-decrypt.c ; gcc -Wall -o cisco-decrypt cisco-decrypt.c $(libgcrypt-config --libs --cflags) ; rm cisco-decrypt.c
cd /tmp ; wget ftp://ftp.adobe.com/pub/adobe/reader/unix/9.x/9.5.1/enu/AdbeRdr9.5.1-1_i386linux_enu.deb ; dpkg -i AdbeRdr9.5.1-1_i386linux_enu.deb
svn checkout http://phillips321.googlecode.com/svn/trunk/ /root/phillips321
echo 'export PATH=$PATH:/root/phillips321' >> /root/.bashrc

And finally, every Sunday before I go on a job I like to update nessus, w3af, open-vas, metasploit and so on:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/pentest/wireless/wifite/wifite.py -upgrade
msfupdate
svn up /pentest/web/w3af/
openvas-nvt-sync
cd /pentest/exploits/set/ ; ./set-update
svn up /pentest/exploits/fasttrack/
cd /pentest/database/sqlmap/ ; ./sqlmap.py --update
cd /pentest/web/nikto/ ; svn up ; ./nikto.pl -update
svn up /pentest/exploits/exploitdb
ps -A | grep nessus > /dev/null
/etc/init.d/nessusd start ; sleep 10 ; nessus-update-plugins
svn up /pentest/telephony/warvox
svn up /pentest/wireless/giskismet/
nmap --script-updatedb
cd /pentest/web/fimap/ ; ./fimap.py --update-def ; rm /root/fimap.log
svn up /pentest/wireless/fern-wifi-cracker
svn up /root/phillips321

39 Responses to BT5 r3 new build details

  • soso97 says:

    Hi for the WarVox, you must change the command svn co for a git clone. It makes this:

    rm -rf /pentest/telephony/warvox; git clone git://github.com/rapid7/warvox.git /pentest/telephony/warvox

    Still thank you for all this work you’ve been done, it’s amazing and I couldn’t get my BackTrack working without this script and the others.

  • gman says:

    My friend I’m fairly new to the BT world but not brand new…..Let me tell you I wish I had come by this site when I was starting off my life could have been ALOT EASIER !!! Trial and error is how we learn but when you have went over the same problem over and over it can be off putting. Anyway keep up the good work this site has proved to be a great resource and I just got here.

  • rushdy says:

    svn up /pentest/web/w3af/
    svn: OPTIONS of ‘https://w3af.svn.sourceforge.net/svnroot/w3af/trunk': Could not resolve hostname `w3af.svn.sourceforge.net': Host not found (https://w3af.svn.sourceforge.net)
    how could i solve this problem plz?

  • ozzmond says:

    AW5UMz!!! XD Thanks Phil for the excellent work also support !!! ★★★★★
    Btw how about the additions from https://www.trustedsec.com/

  • rushdy says:

    it’s happened again
    cd /pentest/exploits/set/ ; ./set-update
    [-] Updating the Social-Engineer Toolkit, be patient…
    Updating a3a69e7..25062b5
    error: Untracked working tree file ‘config/set_config.py’ would be overwritten by merge. Aborting
    [*] The updating has finished, returning to main menu..

  • rushdy says:

    Dear phillip,

    when i make update today cd /pentest/exploits/set/ ; ./set-update
    it said
    [-] Updating the Social-Engineer Toolkit, be patient…
    Updating a3a69e7..25062b5
    error: Untracked working tree file ‘config/set_config.py’ would be overwritten by merge. Aborting
    [*] The updating has finished, returning to main menu..

    !!!!!!!!!!!!!!!!!!! is it ok? or there is some problem ? plz advise me

  • Antonyx says:

    I’m sorry phillips321 can help to enable the pae kernel on 32-bit BT5 gnome r3 I tried using the wiki site but without success you have an idea? thank you in advance :)

  • rushdy says:

    cd /pentest/exploits/set/ ; ./set-update

    [!] The Social-Engineer Toolkit has officially moved to github and no longer uses SVN.
    [!] Ensure that you have GIT installed and this conversion tool will automatically pull the latest git version for you.
    [!] Do you want to do a manual install or have SET do the conversion to GIT for you?

    1. Automatic
    2. Manual
    3. Continue using SET (NO UPDATES ANYMORE!)

    Enter your numeric choice: 1
    [*] BEFORE YOU START! Ensure you have GIT installed (apt-get install git)
    Have you installed GIT? y/n: n
    [*] Manual instructions:

    Remove the SET directory (rm -rf set/) then type:

    git clone https://github.com/trustedsec/social-engineer-toolkit set/
    Press {return} to continue to use SET.
    how could i install git ?cause when i did apt-get install git
    it said couldnt find package
    i need source plz

    after install code should be
    cd /pentest/exploits/set/ ; ./git-update?

  • rushdy says:

    Dear Phillip
    when i do msfupdate weekly it said updating and then
    skipped ‘msfupdate’ –Node remains in conflict
    at revision 16208
    skipped path :1
    somthing wrong here but i dont know?!!!!!

  • phillip thk you for your good work…can you help with this errror?‘export: command not found
    “export: command not found
    Reading: command not found
    Building: command not found
    Reading: command not found
    plz tell me what to do ..

  • abbas says:

    Hi phillips, Thanks for the great work, i have the following issue if you don’t mind helping me out just to let you know I am a beginner to Linux so go easy on me :)

    when i # add-apt-repository ppa:mozillateam/firefox-stable
    Error: can’t find signing_key_fingerprint at https://launchpad.net/api/1.0/~mozillateam/+archive/firefox-stable
    is it effect in order below ?

    Second Error when i try the following:

    apt-get -y install jockey-gtk rungetty linux-headers filezilla synaptic geany shutter gnome-web-photo vino gufw nessus python-dev chromium-codecs-ffmpeg-extra chromium-codecs-ffmpeg-nonfree opera flashplugin-nonfree-extrasound flashplugin-nonfree file-roller giplet compiz-plugins fwbuilder gcalctool gtk-recordmydesktop mono-runtime mono-devel deluge tsclient meld launchpad-getkeys unetbootin wine1.3-gecko cmake tftp ntp rcconf rsh-client arp-scan dialog tree sslscan
    Reading package lists… Done
    Building dependency tree
    Reading state information… Done
    nessus is already the newest version.
    W: Duplicate sources.list entry http://packages.fwbuilder.org/deb/stable/ lucid/contrib Packages (/var/lib/apt/lists/packages.fwbuilder.org_deb_stable_dists_lucid_contrib_binary-amd64_Packages)
    W: You may want to run apt-get update to correct these problems
    E: Couldn’t find package flashplugin-nonfree-extrasound

    i run the apt-get update and got the following error at the end.

    W: Failed to fetch http://ppa.launchpad.net/mozillateam/firefox-stable/ubuntu/dists/lucid/main/binary-amd64/Packages.gz 404 Not Found

    E: Some index files failed to download, they have been ignored, or old ones used instead.

  • rushdy says:

    Dear Pillips123,

    plz tell me about thees two sources what exactly this do for me
    svn checkout http://phillips321.googlecode.com/svn/trunk/ /root/phillips321
    echo ‘export PATH=$PATH:/root/phillips321′ >> /root/.bashrc
    also plz check
    echo ‘export PATH=$PATH:/root/phillips321′ >> /root/.bashrc
    as i said b4 if i add it it gives me that in terminal and command line
    ‘export: command not found
    root@bt:~#
    and plz be inform if i make like
    echo “export PATH=$PATH:/root/phillips321″ >> /root/.bashrc
    it’s ok but i need to know what exactly this tools do for me
    svn checkout http://phillips321.googlecode.com/svn/trunk/ /root/phillips321
    echo ‘export PATH=$PATH:/root/phillips321′ >> /root/.bashrc
    best regards

  • rushdy says:

    dears
    there is somthing wrong n this command about adding source
    echo ‘export PATH=$PATH:/root/phillips321′ >> /root/.bashrc

    after u add then reboot when u open terminal it gives u
    ‘export: command not found
    root@bt:~#

    • phillips321 says:

      Did you copy and paste the code? you need to ensure that the ‘ either side of the command are actaully a single speech mark.

      ‘ ` and ” are all different

      • rushdy says:

        actually i did but im using bt5r3 64bit gonme so plz make us video for all steps ,step by step sorry for disturbing you im just new use of lunix system im appreciate your kindness helping

        best regards
        rushdy

  • rushdy says:

    ‘export: command not found
    root@bt:~#

    is it bug and how can i fix it ?

  • rushdy says:

    Dear sir,
    im new user of uinxe i get bt5r364 if i follow this construction should update every tools in bt5r3? and if not plz tell us how to update every tools
    plz advise me in this problems

    when i # add-apt-repository ppa:mozillateam/firefox-stable
    Error: can’t find signing_key_fingerprint at https://launchpad.net/api/1.0/~mozillateam/+archive/firefox-stable
    is it effect in order below ?
    &
    when i did apt-get update
    it said
    W: Failed to fetch http://ppa.launchpad.net/mozillateam/firefox-stable/ubuntu/dists/lucid/main/binary-amd64/Packages.gz 404 Not Found

    E: Some index files failed to download, they have been ignored, or old ones used instead.
    &
    when i did apt-get -y dist-upgrade
    Setting up beef (0.4.3.5-bt1) …
    WARNING: You don’t have /root/.gem/ruby/1.9.2/bin in your PATH,
    gem executables will not run.
    &

    when i did

    apt-get -y install jockey-gtk rungetty linux-headers filezilla synaptic geany shutter gnome-web-photo vino gufw nessus python-dev chromium-codecs-ffmpeg-extra chromium-codecs-ffmpeg-nonfree opera flashplugin-nonfree-extrasound flashplugin-nonfree file-roller giplet compiz-plugins fwbuilder gcalctool gtk-recordmydesktop mono-runtime mono-devel deluge tsclient meld launchpad-getkeys unetbootin wine1.3-gecko cmake tftp ntp rcconf rsh-client arp-scan dialog tree sslscan

    said

    Reading package lists… Done
    Building dependency tree
    Reading state information… Done
    nessus is already the newest version.
    E: Couldn’t find package flashplugin-nonfree-extrasound

    finally help me to install Metasploit Framework.espcially they need subversion and subversion need apr-1.4.6 also needs apr-util-1.4.1 after i did installed them when i make
    cd /pentest/exploits/framework && ./msfupdate

    it givs me that error
    Updating ‘.':
    subversion/svn/update-cmd.c:163: (apr_err=170000)
    subversion/libsvn_client/update.c:612: (apr_err=170000)
    subversion/libsvn_client/update.c:553: (apr_err=170000)
    subversion/libsvn_client/update.c:336: (apr_err=170000)
    subversion/libsvn_client/ra.c:335: (apr_err=170000)
    subversion/libsvn_ra/ra_loader.c:483: (apr_err=170000)
    svn: E170000: Unrecognized URL scheme for ‘https://www.metasploit.com/svn/framework3/trunk’
    sorry for disturbing u by my question
    best regards

  • smuggbg says:

    This is what happens after using the script on BT5r3 gnome 64.Works,but if apt-get update it…

    W: GPG error: http://ppa.launchpad.net lucid Release: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY 9BDB3D89CE49EC21

    pls advice for a solution

    • phillips321 says:

      apt-key adv –keyserver keyserver.ubuntu.com –recv-keys 9BDB3D89 CE49EC21
      apt-get update

      • smuggbg says:

        Executing: gpg –ignore-time-conflict –no-options –no-default-keyring –secret-keyring /etc/apt/secring.gpg –trustdb-name /etc/apt/trustdb.gpg –keyring /etc/apt/trusted.gpg –primary-keyring /etc/apt/trusted.gpg –keyserver keyserver.ubuntu.com –recv-keys 9BDB3D89 CE49EC21
        gpg: requesting key 9BDB3D89 from hkp server keyserver.ubuntu.com
        gpg: requesting key CE49EC21 from hkp server keyserver.ubuntu.com
        gpgkeys: key 9BDB3D89 not found on keyserver
        gpg: key CE49EC21: public key “Launchpad PPA for Mozilla Team” imported
        gpg: no ultimately trusted keys found
        gpg: Total number processed: 1
        gpg: imported: 1 (RSA: 1)

        so far so good,but one of the keys is missing from the keyserver is this a problem?

        • phillips321 says:

          Hmm not too sure then, it’s not a problem, it just means that one of the repo’s keys hasnt been installed so you wont be able to verify the packages for authenticity.

          • smuggbg says:

            I see,thanks for the fast reply! Can you pls help with the wpscan warning,I know that it’s off topic, but if you have time… I google it and all of the solutions are no good for me somehow… I found one which shows the steps to edit the PATH…but cant find it anymore :S

            WARNING: You don’t have /root/.gem/ruby/1.9.2/bin in your PATH,
            gem executables will not run.

  • Just a note regarding Fimap updates. A lot of the updates are going into the SVN, so it is probably best if you SVN update instead of –update-def. I have yet to commit some of changes, but try SVN up every week to see :)

  • Cerberus says:

    I don’t see anything in the script that would break r3 64-bit, but I was just curious if you had any further insight as to whether or not it should/could be run before I do so. Thanks in advanvce!

Leave a Reply