Vulnerable VMs
Metasploitable and DVWA.
Vulnerable VMs is a free Ethical Hacking Academy lesson on CoddyKit — lesson 3 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the Ethical Hacking Academy learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.
Why Practice on Vulnerable VMs
To practice attacks legally and safely you need targets you are allowed to break. Intentionally vulnerable VMs are built for exactly this.
They contain known weaknesses so you can learn scanning, exploitation, and post-exploitation in a controlled lab.
Metasploitable
Metasploitable 2 is an intentionally vulnerable Ubuntu-based VM from Rapid7. It runs many outdated, exploitable services like vsftpd, Samba, and an old Apache.
It is a classic target for learning Metasploit and network exploitation.
Metasploitable Logins
Metasploitable 2 uses well-known weak credentials so you can log in after exploitation or via brute force practice.
- Username: msfadmin
- Password: msfadmin
Never expose this VM to the internet - it is wildly insecure by design.
DVWA
DVWA (Damn Vulnerable Web Application) is a PHP/MySQL web app built to be insecure. It is ideal for learning web attacks like SQL injection, XSS, command injection, and file upload abuse.
DVWA Security Levels
DVWA lets you set a security level that changes how hard each vulnerability is to exploit:
- Low - no protection, easiest.
- Medium - weak filtering.
- High - stronger but still bypassable.
- Impossible - shows the secure code as a reference.
Running DVWA in Docker
The fastest way to run DVWA is via Docker. This spins up the app on port 80 of your lab host or a dedicated VM.
docker run --rm -it -p 80:80 vulnerables/web-dvwaOther Practice Targets
Beyond Metasploitable and DVWA there are many trainers:
- OWASP Juice Shop - modern web app vulns.
- bWAPP - 100+ web bugs.
- VulnHub - downloadable boot-to-root VMs.
- HackTheBox / TryHackMe - online labs.
Confirming Connectivity
After importing a target VM, confirm Kali can reach it on the isolated lab network. Find the target IP and ping it, or scan for it.
# discover live hosts on the lab subnet
nmap -sn 192.168.56.0/24Snapshot Before Attacking
Exploits often corrupt or crash a target. Take a clean snapshot of each vulnerable VM right after setup.
When a service dies or you fill the disk with payloads, roll back and try again.
Never Expose Them
These VMs have no security at all. If reachable from the internet, real attackers will compromise them within minutes and could use them to pivot into your network.
- Keep them on host-only or internal networks.
- Power them off when not in use.
Mapping Tools to Targets
Different targets teach different skills:
- Metasploitable - network service exploitation with Metasploit and Nmap.
- DVWA / Juice Shop - web app attacks with Burp Suite and manual injection.
A complete lab usually runs at least one of each.
Quick Check
Pick the right target for the job.
Recap
You now have legal practice targets:
- Metasploitable 2 - vulnerable network services (login msfadmin/msfadmin).
- DVWA - vulnerable web app with Low to Impossible security levels.
- Snapshot before attacking and never expose these to the internet.
Next: building the isolated network that connects them.
Frequently asked questions
Is the “Vulnerable VMs” lesson free?
Yes — the full text of “Vulnerable VMs” is free to read here on the web, and the Ethical Hacking Academy course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the Ethical Hacking Academy course, upgrade to CoddyKit PRO.
What will I learn in “Vulnerable VMs”?
Metasploitable and DVWA. You practise Ethical Hacking Academy with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.
Do I need any experience to start Ethical Hacking Academy?
No prior experience is required. Ethical Hacking Academy on CoddyKit is structured for beginners through advanced learners; this is — lesson 3 of 4, so you can start here or from the beginning and move at your own pace.
How long does the “Vulnerable VMs” lesson take?
Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.
Can I write and run code in this Ethical Hacking Academy lesson?
Yes. Every Ethical Hacking Academy lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.
All lessons in this course
- Virtualization Basics
- Installing Kali Linux
- Vulnerable VMs
- Lab Networking