FAIL (the browser should render some flash content, not this).

You are currently browsing the archives for the VMs category.

Archive for the ‘VMs’ Category

Metasploit Unleashed on OS X

February 18, 2010 @ 1:32 pm
posted by Pheno

So I was taking a look at a blog the other day by Andrew Waite and saw him talk about a great little tutorial on Metasploit by the guys at Offensive Security. Being that half of the things I know I learned on my own and not in a formal learning environment, I thought it would be a great review and maybe learn something new along the way. The only problem is that I use a Mac, and some of this stuff became a stumbling block, so this is how I got through it.

One of the main problems with the Mac and using VMs is that the main two programs (VMware and Parallels) are not free. In Windows you can get the VMware player and converter for free, but not in OS X. So I use VirtualBox for all of my VM needs. Sure it might be missing some bells and whistles, but it works good for what I do, and it seems a bit faster than the other two.

The first thing they have you do in the tutorial is setup Ubuntu. That step is very easy, you download the zip, expand it to a directory, then mount the HD image in VirtualBox. Set up a new machine, make sure to use the HD from a SCSI/SATA interface, and your ready to go. Once up you mount the CD image they have you download for Samba and your set.

The Windows XP image is actually where I had problems. They have you download an XP VM that is cut up into four different zip files. It turns out that OS X doesn’t handle divvied up zip files (such as, .zip,.z01,.z02). One method i found was to actually ‘cat’ the files together, then tell zip to fix the headers, then unzip it. I unfortunately couldn’t get that one to work, so I sadly resorted over to an XP virtual machine that I already had, mounted the directly as a shared folder and used WinRAR to uncompress it. Once you have virtual hard drive file (which is in Virtual PC) VirtualBox can actually just mount it and use it just fine. I left it as an IDE device on the new VM setup and it seems to work just fine. Once up, you should install the VirtualBox Tools. The ‘local security options’ are going to keep you from installing the drivers. So to change that you go to Control Panels > Administrative Tools > Local Security Settings > Local Policies > Security Options > Devices: Unsigned driver installation behavior. Once you drill all of that down you can change it to ‘Warn but allow install’.

You now have your two VM machines ready to go, all you need is Metasploit installed on your Mac. You can find several ways to do that via Google or on the actual Metasploit page. One of the easiest is probably to use MacPorts, but I like to maintain the most up-to-date plugins and exploits, so use the subversion.

This should have you pretty much up and running for the whole tutorial, if any more stumbling blocks are encountered I will make sure to update this.

Installing ESXi 3.5 . . . half assed.

February 17, 2010 @ 1:38 pm
posted by Pheno

So the other day I started having weird problems with an ESX server that I had in my lab. Being that I don’t use it for anything too critical I decided to just put ESXi 3.5 (it is only 32-bit) on it. So I shutdown my VMs that were running, copied them off to my NAS, and put in the install CD to do the reinstall.

So the CD boots up, finds the SATA drive, and the install goes off just fine . . . so I thought.

About half way through the boot-up it starts looking for a USB drive and just freezes. Well I remember from a PaulDotCom episode that the hyper-visor is pretty small and it is handy to just boot from a USB stick.

So I went in search for this old Lexar 1GB drive that I knew I had sitting around here. Found it, then used the program to ‘switch the bit’ to make it look like non removable drive. I don’t remember all the original pages I used, but here is one that shows how easy it SHOULD be to do the install.

Well that didn’t work because the 3.5 install disk didn’t see my USB drive. So I moved back to the old method (posted here). Well that works like a charm, ESXi boots up and I start configuring the system and the network, then copy over the VMs from the NAS.

If only life was that easy though… I do an update on the ESXi server, reboot, and get this:

cannot get bank 1 parameters.

warning: bank 1 partition type invalid. Ignoring.

cannot get bank 2 parameters.

warning: bank 2 partition type invalid. Ignoring.

Panic: no usable banks found.

Well crap! So we have to reinstall and live without updates? I just got back from Shmoocon and saw a talk about stealing VMs, so this really doesn’t sit well with me. So I start the process over, but no matter what I do (partition, format, switch the bit back) nothing will boot on that drive again, and this is pre-update. So I start thinking . . .

Well I remember the HD install would freeze while looking for the stick, so the kernel was good to boot from SATA. And the USB drive shows information on it, but won’t boot, so the filesystem is good on there. See where I am going with this?

Well it worked, and the updates work and don’t kill it either. I installed from the CD to the SATA HD. Then I restored the image to the USB stick. Now the boot process starts up from the SATA HD, then moves over to using the filesystem from the USB drive. It all SEEMS to work ok. My only concern is the updates to the kernel. I am pretty sure those will not work because that is housed on the SATA drive, and the USB stick is what is getting updated. But for now, for what I am doing, this all makes me happy. . .