[Editor's Note: Jeff McJunkin shares some insight into building a good virtualization infrastructure for practicing your pen test skills, evaluating tools, and just plain becoming a better penetration tester, all without breaking the bank. Nice! -Ed.]
Practical, hands-on experience is a good thing, right? As good as it is though, it doesn't excuse accidentally taking down your employer's production environment while doing some testing.
While NetWars (obligatory plug for my new employer) is great for getting this experience, it doesn't fit every situation. For example, if one of your servers crashed while being scanned by Nessus, you might want to isolate exactly which plugin is causing the crash, while avoiding future production outages.
Having a home lab with a trial version of the software creates a safe environment for otherwise disruptive testing and facilitates fast learning. It's hard to beat not only learning the attacks, but observing the artifacts those attacks leave behind, defending against them, and creating signatures to detect further attempts!
In this post, we'll discuss several hardware options for home labs at different price points. Since many employers don't have test labs, it often falls on the employee to keep up-to-date on the latest operating systems, software, and offensive/defensive techniques.
Depending on interest, we might do a follow-up post with a comparison of different virtualization software. Because many people already have some experience with it, though, VMware products are tough to beat. For dedicated machines, people often use VMware vSphere Hypervisor (ESXi), which is free.
Depending on your price point, there are a few approaches.
Price point: $0 - Re-Use Existing Hardware
At this price point, of course, you'll need to re-use existing hardware. Depending on the horsepower behind your personal computers, though, this might be enough. The main bottlenecks for virtual machines are, in order, memory, hard disk, and then CPU. With 8GB of RAM, you should be able to run 2-3 VM's in VMware Workstation / Player, which is sufficient for many labs. With 16GB, you'll be able to run enough VM's that your new bottleneck will be a single hard drive, if that's what you have. Replacing it with an SSD (such as the Samsung model recommended below) will allow you to scale to 5-7 simultaneous VM's, though hosted virtualization platforms (Type 2) tend to be less efficient than a bare-metal (Type 1) hypervisor such as ESXi or Xen.
Price point: ~$300 - HP N54L G7
Though you won't be able to get a system capable of running more than a couple of VM's at this price point, by getting the N54L you'll have a system you can upgrade over time. The rig I've linked to below comes with a 250GB hard drive and 2GB of RAM. Though not listed as compatible, there are many 16GB (2x8GB) memory kits that are compatible, including the link listed below.
When combined with a local SSD and several spinning disks (from the Storage section), the N54L can run quite a few VM's simultaneously, and should meet the needs of almost all virtual labs.
Amazon link: HP N54L G7
Amazon link: Kingston 16GB (2x8GB) memory kit
Price point: $600+ - Build Your Own
At this price point you can build an increasingly powerful home server. The trick in building your own virtualization host from scratch is normally finding a combination that works with the limited hardware compatibility of ESXi, but luckily this recommendation is well-vetted.
The advantage of this build compared to the N54L is the long-term upgradeability and increased capacity (32GB memory, six 3.5" drives and two 2.5" drives, more PCI-e slots, etc.).
You'll need to add some local storage from the below section or elsewhere, but these parts get you a working installation. You can re-use existing drives if you have them available, of course, which further reduces your initial costs.
Amazon link: Antec Three Hundred Two Case
Amazon link: Rosewill CAPSTONE-550 Power Supply
Amazon link: ASRock 970 EXTREME3 Motherboard
Amazon link: AMD FX-8320 Processor
Amazon link: Kingston Hyper-X 16GB Memory Kit (2x8GB) (The motherboard supports two of these kits, but you can buy one at first if you need to spend the money elsewhere)
Amazon link: SanDisk Cruzer Fit 16GB USB drive (you'll install ESXi on a USB drive so other drives can be fully utilized for VM's)
Depending on your needs and budget, there are a lot of options for VM storage. Though you may need to stick with spinning drives at first for cost reasons, I'd recommend purchasing a solid-state drive as soon as you can. Prices have been coming down, and $500 for one terabyte of SSD should fulfill nearly all VM storage requirements.
Amazon link: Samsung 840 Series 1TB SSD (smaller sizes available)
Amazon link: Western Digital Red 4TB Hard Drive (smaller sizes available)
Amazon link: Icy Dock EZConvert 2.5" to 3.5" Drive Tray (for putting an SSD into the N54L - the Antec case can fit two SSD's without this adapter)
Webcast: Jeff recorded a SANS Webcast about Building your Own Home Lab. Available now on YouTube: https://youtu.be/uzqwoufhwyk