Hacked Laptop to Full Network: Step-by-Step
In this article
One compromised laptop can bring down an entire network in under an hour if the attacker moves laterally through weak spots. This guide shows the exact chain of events—from initial foothold to domain-wide control—so you can spot the gaps and close them. You’ll need a test lab with at least two machines, a shared network, and permission to attack your own systems. Do not attempt this on any network you don’t own.
What You'll Need
- Two or more computers on the same LAN (one “victim” laptop, one “attacker” machine)
- A virtual machine platform (VirtualBox or VMware) to isolate the test environment
- A vulnerable service on the laptop—e.g., an outdated SMB version or an unpatched RDP port
- A network scanner (Nmap) and a credential-cracking tool (Hydra or similar)
- A packet capture tool (Wireshark) for monitoring traffic
- Metasploit or a similar exploitation framework
- Admin credentials for the domain controller (if you want to simulate full domain compromise)
Step-by-Step
- Scan the network—Run Nmap on the attacker machine to discover live hosts and open ports. Example:
nmap -sV 192.168.1.0/24. Look for the laptop’s IP and note any open ports like 445 (SMB) or 3389 (RDP). - Identify a vulnerable service—Compare the service versions Nmap returns against known exploit databases (e.g., CVE listings). For a lab, you might intentionally run an older version of Samba or a weak RDP configuration.
- Exploit the initial foothold—Use Metasploit to launch an exploit against the vulnerable service. For example, if SMB is exposed, use the
ms17_010_eternalbluemodule (if you’re using a Windows 7 target) or a similar one for your lab. This gives you a shell on the laptop. - Escalate privileges on the laptop—Once you have a shell, check current user privileges with
whoamiandnet user. If you’re not admin, use a privilege escalation exploit (e.g., a kernel exploit or misconfigured service) to gain SYSTEM or admin rights. - Dump credentials—Use Mimikatz or a similar tool to extract plaintext passwords, hashes, and Kerberos tickets from memory. Run
privilege::debugandsekurlsa::logonpasswordsto capture credentials of any logged-in users. - Map the network—From the compromised laptop, run
ipconfig /allandarp -ato see the subnet and other devices. Usenet viewor a tool like BloodHound to discover domain controllers, file servers, and other high-value targets. - Move laterally—Use the stolen credentials to access other machines. For example, if you found a domain admin hash, use
psexecorwmicto execute commands on the domain controller remotely. Command:psexec \\DC-IP -u DOMAIN\admin -p hash cmd.exe(or use pass-the-hash with Mimikatz). - Gain domain admin—If you haven’t already, use the compromised credentials to log into the domain controller. Once you have domain admin, you can reset passwords, create backdoor accounts, or disable security controls.
- Establish persistence—Create a new admin account (e.g.,
net user hacker P@ssw0rd /addandnet localgroup administrators hacker /add) or install a remote access tool (RAT) that survives reboots. This ensures you keep access even if the initial exploit is patched. - Cover your tracks—Delete logs, clear event viewer entries, and remove temporary files. Use
wevtutil clto clear logs on Windows. This step is for realism in your lab; in a real attack, this is what makes detection harder.
Common Mistakes
- Not isolating the lab—if you use a real network, you’re breaking the law and risking real damage.
- Skipping privilege escalation—many exploits only give a low-privilege shell; you need admin to dump credentials.
- Using default credentials—real networks rarely have “admin/admin” but test labs often do; that makes the exercise unrealistic.
- Not checking for firewalls—Windows Firewall can block your lateral movement tools; you may need to disable it on the target (in your lab).
- Forgetting to capture the hash—pass-the-hash is more reliable than trying to crack passwords offline.
Tips
- Always use a dedicated virtual network (Host-Only in VirtualBox) to prevent accidental exposure.
- Keep your exploitation tools updated—old modules may not work on patched systems.
- Practice on purpose-built vulnerable VMs (like Metasploitable or DVWA) before trying on a Windows domain.
- Document every step—this helps you understand the attack chain and later write detection rules.
- Use a separate attacker machine with a different OS (e.g., Kali Linux) to mimic a real scenario.
Troubleshooting
If the exploit fails, first check that the target service is actually running and the version matches the exploit. Restart the target VM if needed. If you can’t get a shell, try a different exploit module or check if the firewall is blocking your connection. For lateral movement, if psexec fails, try using wmic or PowerShell remoting (Enter-PSSession) with the same credentials. If you can’t dump credentials, ensure you have admin rights on the laptop—run Mimikatz with SYSTEM privileges. If the domain controller rejects your hash, you may need to use a pass-the-ticket attack instead. Always verify that the target machine’s time is synchronized—Kerberos errors often come from clock skew.
Frequently Asked Questions
Is this legal to do on my own network?
Yes, if you own the network and have explicit permission. On any other network, it’s illegal and unethical.
How long does this typically take in a real environment?
In a well-patched network, it might take days or weeks. In a poorly configured one, minutes to hours. This guide assumes a vulnerable setup.
Can I do this without a domain controller?
Yes, but the “entire network” compromise is limited to workgroup machines. A domain makes it easier to control many machines at once.
What if the laptop is encrypted with BitLocker?
Full-disk encryption doesn’t stop an attack if the machine is already logged in. The attacker gets the decrypted data from memory.
How do I defend against this?
Patch promptly, use strong unique passwords, enable multi-factor authentication, segment your network, and monitor for unusual logins and lateral movement.
Why does the laptop matter more than a server?
Laptops are often less monitored, used by employees with access to sensitive data, and connect to multiple networks (home, VPN, office), making them a prime entry point.