
Packages, Backtrack 3, and Updates.
Well I guess I will start off again recovering this somewhat dead blog. I really don't have much better to do, so this is what comes as the result. In any event, here is some of what has been going on with me lately; I rediscovered my two WRT54G routers, so there may be some posts on that. I reformatted my computer again, to test out BackTrack 3 with two other partitons: Ubuntu&Vista. Broke out my old Linksys WPC54G ver.2 card, to test that around. And I grabbed a few books from the library including Wi-Foo, The art of Deception, and The Linux Cookbook. I designed a small bash script that connects to a network, and changes a few aspects of the connectivity. Alright so to start off from the beginning, I was rambling in my room, looked in one of my cabinets, and found two different Linksys routers that I had used back in the day. One is a WRT54G linksys G router with speed booster, and the other is just a linksys B router. I will probably upload DD-Wrt or OpenWRT onto one of them, and do some subnetwork things. Maybe a DMZ with a honeypot, or something to that effect, or even a firewall. This excerpt is going to mainly concern the BackTrack 3 install, and my bash script. The interesting thing here is that BackTrack 3 beta included a graphical installer for USB hard drives and the like, however in the final release, it was gone. Which deeply saddened me because I wanted to install BT3 onto my hard drive. Since BT3 is a slackware derivative (Slax for USB installs) it would be next to secondhand to me because of my background in slackware, and it would include all the amazing tools that BT3 has. So after some research, I came across a thread by pureh@te on the backtrack forums. I pay total homage to him for the design of installing BT3 from the shell, however I made my own modifications to it. The very first step is to format your drive, and get your partitions set. I had the following:
/dev/hda1 = WINDOWS/NTFS
/dev/hda2 = BT3/ext3
/dev/hda3 = SWAP/swap
/dev/hda4 = UBUNTU/ext3
I really don't like Ubuntu, or Windows. However I know a lot of people use them, so I figured the best way to go would be with those.
I had Vista installed, and that was it. The other partitions were just empty.
Obviously the next step is to burn the .iso. The first time I burned it, I burned at 4x. I verified the MD5 hash, and everything was set, but when I installed I couldn't log in as root/toor for some reason. So I re-burned at a lower speed, and everything worked.
Boot into the CD and open a shell.
The first thing we want to do is turn our swap on:
bt~# mkswap /dev/hda3
bt~# swapon /dev/hda3
Next we will mount the drive we want to install BT3 to:
bt~# mkdir /mnt/hda2 bt~# mount /dev/hda2 /mnt/hda2/
Then we will make the /boot directory for it:
bt~# mkdir /mnt/hda2/boot/
And now we begin to copy the files for our installation:
bt~# cp --preserve -R /{bin,dev,home,pentest,root,usr,etc,lib,opt,sbin,var,sbin} /mnt/hda2/
This takes quite a while. And for some reason when it finished it never showed me so to make sure it was done the second time, here is what I did:
Open up a second shell and
bt~# top
Watch the cp process and it will use the most process usage while you are copying. When it drops down, and cuts out, it is through, and you can just go and ctrl+c the copying.
A good idea before you cancel it, is to go and ls /mnt/hda2/ and compare it with /.
Next we will copy the vmlinuz image, bind the /dev/ files and set up our proc:
bt~# mkdir /mnt/hda2/{mnt,proc,sys,tmp}
bt~# mount --bind /dev/ /mnt/backtrack/dev/
bt~# mount -t proc proc /mnt/backtrack/proc/
bt~# cp /boot/vmlinuz /mnt/backtrack/boot/ Now for lilo.
Since editing lilo and saving it requires running lilo, we have to chroot into the new BT3 OS, and edit it.
bt~# chroot /mnt/backtrack/ /bin/bash
bt~# nano /etc/lilo.conf Here is what my lilo.conf looks like. Edit it to your settings:
# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
lba32 # Allow booting past 1024th cylinder with a recent BIOS
boot = /dev/hda
#message = /boot/boot_message.txt
prompt
timeout = 1200
# Override dangerous defaults that rewrite the partition table:
change-rules
reset
# VESA framebuffer console @ 1024x768x256
vga = 773
# Normal VGA console
# vga = normal
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/hda2
label = BackTrack3
# Linux bootable partition config ends
other = /dev/hda1
label = AstaLaVista
table = /dev/hda
# begin ubuntu
image=/mnt/hda4/vmlinuz
label="ubuntu"
root=/dev/hda4
initrd=/mnt/hda4/initrd.img
append="acpi=ht resume=/dev/hda4 splash=silent"
Now we can run lilo in verbose mode to make sure that everything is set, and no errors come out.
bt~# lilo -v
You may get some errors about the ubuntu partition or image, ignore that because you don't have ubuntu set up yet :P.
Now ctrl+d to exit the chroot, and reboot:
bt~# shutdown -r -time now
Now go make sure you can log in and all that jazz. Then shutdown, and install ubuntu onto the partition that you set up.
That is pretty much it on installing BT3. If you want to use slapt-get then you'll need to fix
the package, which this link informs you how to do:
http://airdump.net/papers/backtrack-3-slapt-get-correcting
And there are other things. I will probably get something up on the RTL8187 adapter, or the Linksys WPC54Gs ver.2 cards because I have both of those cards, and I know how to get them up and running easily.
The next subject is my package, and I am not really going to go into too much detail on, you can just check out the sourceforge page:
https://sourceforge.net/projects/wlan0up/
That's all for now,
Axl
/dev/hda1 = WINDOWS/NTFS
/dev/hda2 = BT3/ext3
/dev/hda3 = SWAP/swap
/dev/hda4 = UBUNTU/ext3
I really don't like Ubuntu, or Windows. However I know a lot of people use them, so I figured the best way to go would be with those.
I had Vista installed, and that was it. The other partitions were just empty.
Obviously the next step is to burn the .iso. The first time I burned it, I burned at 4x. I verified the MD5 hash, and everything was set, but when I installed I couldn't log in as root/toor for some reason. So I re-burned at a lower speed, and everything worked.
Boot into the CD and open a shell.
The first thing we want to do is turn our swap on:
bt~# mkswap /dev/hda3
bt~# swapon /dev/hda3
Next we will mount the drive we want to install BT3 to:
bt~# mkdir /mnt/hda2 bt~# mount /dev/hda2 /mnt/hda2/
Then we will make the /boot directory for it:
bt~# mkdir /mnt/hda2/boot/
And now we begin to copy the files for our installation:
bt~# cp --preserve -R /{bin,dev,home,pentest,root,usr,etc,lib,opt,sbin,var,sbin} /mnt/hda2/
This takes quite a while. And for some reason when it finished it never showed me so to make sure it was done the second time, here is what I did:
Open up a second shell and
bt~# top
Watch the cp process and it will use the most process usage while you are copying. When it drops down, and cuts out, it is through, and you can just go and ctrl+c the copying.
A good idea before you cancel it, is to go and ls /mnt/hda2/ and compare it with /.
Next we will copy the vmlinuz image, bind the /dev/ files and set up our proc:
bt~# mkdir /mnt/hda2/{mnt,proc,sys,tmp}
bt~# mount --bind /dev/ /mnt/backtrack/dev/
bt~# mount -t proc proc /mnt/backtrack/proc/
bt~# cp /boot/vmlinuz /mnt/backtrack/boot/ Now for lilo.
Since editing lilo and saving it requires running lilo, we have to chroot into the new BT3 OS, and edit it.
bt~# chroot /mnt/backtrack/ /bin/bash
bt~# nano /etc/lilo.conf Here is what my lilo.conf looks like. Edit it to your settings:
# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
lba32 # Allow booting past 1024th cylinder with a recent BIOS
boot = /dev/hda
#message = /boot/boot_message.txt
prompt
timeout = 1200
# Override dangerous defaults that rewrite the partition table:
change-rules
reset
# VESA framebuffer console @ 1024x768x256
vga = 773
# Normal VGA console
# vga = normal
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/hda2
label = BackTrack3
# Linux bootable partition config ends
other = /dev/hda1
label = AstaLaVista
table = /dev/hda
# begin ubuntu
image=/mnt/hda4/vmlinuz
label="ubuntu"
root=/dev/hda4
initrd=/mnt/hda4/initrd.img
append="acpi=ht resume=/dev/hda4 splash=silent"
Now we can run lilo in verbose mode to make sure that everything is set, and no errors come out.
bt~# lilo -v
You may get some errors about the ubuntu partition or image, ignore that because you don't have ubuntu set up yet :P.
Now ctrl+d to exit the chroot, and reboot:
bt~# shutdown -r -time now
Now go make sure you can log in and all that jazz. Then shutdown, and install ubuntu onto the partition that you set up.
That is pretty much it on installing BT3. If you want to use slapt-get then you'll need to fix
the package, which this link informs you how to do:
http://airdump.net/papers/backtrack-3-slapt-get-correcting
And there are other things. I will probably get something up on the RTL8187 adapter, or the Linksys WPC54Gs ver.2 cards because I have both of those cards, and I know how to get them up and running easily.
The next subject is my package, and I am not really going to go into too much detail on, you can just check out the sourceforge page:
https://sourceforge.net/projects/wlan0up/
That's all for now,
Axl
0 comments:
Post a Comment