Ubuntu 7.04
In order to provide some variety for the course and to provide a target other than Microsoft Windows, we will also set up a vulnerable Ubuntu 7.04 Feisty Fawn virtual machine.To begin, we'll download the x86 virtual machine of Ubuntu 7.04 Server provided by Canonical.
root@bt4:~# wget http://isv-image.ubuntu.com/vmware/Ubuntu-7.04-server-i386.zip
--2009-09-13 08:01:08-- http://isv-image.ubuntu.com/vmware/Ubuntu-7.04-server-i386.zip
Resolving isv-image.ubuntu.com... 91.189.88.35
Connecting to isv-image.ubuntu.com|91.189.88.35|:80... connected.
HTTP request sent, awaiting response... 200 OK
...snip...While Canonical is very good about making older versions of Ubuntu available, they don't keep the repositories for each distro online forever. In order to enable file and print sharing we'll need to download the Ubuntu 7.04 Server iso image and install our packages from there.
root@bt4:~# wget http://old-releases.ubuntu.com/releases/feisty/ubuntu-7.04-server-i386.iso
--2009-09-13 08:46:04-- http://old-releases.ubuntu.com/releases/feisty/ubuntu-7.04-server-i386.iso
Resolving old-releases.ubuntu.com... 91.189.88.35
Connecting to old-releases.ubuntu.com|91.189.88.35|:80... connected.
HTTP request sent, awaiting response... 200 OK
...snip...Once our downloads are finished, we first need to extract the Ubuntu Server virtual machine.
root@bt4:~# unzip Ubuntu-7.04-server-i386.zip
Archive: Ubuntu-7.04-server-i386.zip
inflating: Ubuntu-7.04-server-i386/Ubuntu-7.04-server-i386.vmdk
inflating: Ubuntu-7.04-server-i386/Ubuntu-7.04-server-i386.vmxOpen up the VM in VMware Player, power it on, and wait for it to boot up. It will appear to be hung at '* Running local boot scripts (/etc/rc.local)' but it's not. Just hit 'Enter' to get the command prompt. The username and password for this VM is ubuntu for both of them.
By default, the VM does not have the ethernet interface enabled so we'll need to bring that up first. Change the IP address and subnet in the example below to match your target network.
ubuntu@ubuntu:~$ sudo ifconfig eth1 up
Password:
ubuntu@ubuntu:~$ sudo ifconfig eth1 192.168.1.166 netmask 255.255.255.0
ubuntu@ubuntu:~$ ifconfig eth1
eth1 Link encap:Ethernet HWaddr 00:0C:29:C2:E7:E6
inet addr:192.168.1.166 Bcast:192.168.1.255 Mask:255.255.255.0
...snip...Next, we need to install Samba on the VM so we can enable file and print sharing. In order to install it, we will need to first attach the Ubuntu 7.04 Server iso to the VM. On the VMware Player menu, select Devices -> CD/DVD (IDE) -> Connect to Disk Image File (iso). You may first have to disconnect the drive if it is already connected.
With the iso attached to the VM, we will install Samba. You will be prompted to confirm the installation. Just press Y to continue.
ubuntu@ubuntu:~$ sudo apt-get install samba
Password:
...snip...
* Starting Samba daemons...We can now verify that file and print sharing is indeed enabled.
ubuntu@ubuntu:~$ netstat -antp | grep 445
tcp 0 0 0.0.0.0:445 0.0.0.0:* LISTEN © Offensive Security 2009

