What a network administrator needs to know about VPNs
A VPN carries private traffic across a network you don't control. The administrator's job runs the full life cycle: plan it, configure it, prove it works, and keep it working. Read this briefing, then complete Parts A and B.
Site-to-site
Two gateways (routers or firewalls) protect whole networks. Users never run VPN software. Part A builds this with IPsec in tunnel mode.
Point-to-point
A one-to-one tunnel between exactly two endpoints, such as a home-office laptop and an office server. Part B builds this with WireGuard.
Remote access
Many individual users connect to one concentrator with a client app (IKEv2, SSL/TLS, OpenVPN). Covered in this briefing and the knowledge check.
Knowledge an administrator needs
Concepts
- VPN topologies: site-to-site, remote access (client-to-site), point-to-point (host-to-host), hub-and-spoke, full mesh, and dynamic multipoint (DMVPN).
- Tunnel vs transport mode: tunnel mode wraps the entire original packet in a new IP header (gateway to gateway). Transport mode protects only the payload and keeps the original header (host to host, or GRE over IPsec).
- Cryptography basics: symmetric ciphers (AES-GCM, AES-CBC, ChaCha20), integrity (HMAC-SHA-256/384), key exchange (Diffie-Hellman groups 14, 19, 20, 21), authentication (pre-shared keys vs. certificates/PKI).
- IPsec architecture: IKE phase 1 (IKE SA, management channel) and phase 2 (IPsec/child SAs that carry data), security parameter index (SPI), lifetimes and rekeying, perfect forward secrecy (PFS).
- Policy-based vs route-based VPNs: crypto ACLs ("interesting traffic") vs. virtual tunnel interfaces (VTI) with routing.
- Split vs full tunneling and their security and bandwidth trade-offs.
Supporting network knowledge
- IP addressing: non-overlapping private subnets at every site, wildcard masks, CIDR.
- NAT and NAT traversal: NAT exemption for VPN traffic, NAT-T over UDP 4500, why AH breaks behind NAT.
- Firewalls and ports: UDP 500/4500, ESP (IP 50), WireGuard UDP 51820, TLS 443.
- MTU and MSS: encryption overhead (50 to 80 bytes) causes fragmentation; adjust TCP MSS to around 1360.
- Identity: AAA, RADIUS (UDP 1812/1813), LDAP/Active Directory, SAML, multifactor authentication.
- Supporting services: DNS (split DNS for internal names), NTP (certificate validation and log timestamps), syslog/SIEM.
Skills an administrator must demonstrate
Plan
- Gather requirements: who connects, to what, how many users, required throughput and uptime.
- Choose the VPN type, protocol, and crypto suite that meet security policy and device support.
- Design addressing, routing, and which traffic is protected (split or full tunnel).
- Plan authentication, key and certificate management, and firewall/NAT changes.
Configure
- Build IKE/IPsec policies, keys, transform sets, crypto ACLs or tunnel interfaces from the CLI.
- Configure VPN on SOHO routers and firewalls through a web GUI.
- Generate and distribute keys (WireGuard), certificates (PKI), and client profiles.
- Open the right firewall ports and create NAT exemptions.
Test and troubleshoot
- Verify underlay reachability first, then the tunnel.
- Read SA tables (show crypto isakmp sa, wg show) and packet counters.
- Use debugs and packet captures to isolate phase 1, phase 2, routing, or firewall problems.
Maintain
- Rotate keys and renew certificates before expiration.
- Patch VPN firmware promptly; VPN gateways are a top target for attackers.
- Monitor tunnel state, logs, capacity, and failed logins; review access regularly.
- Document configurations, addressing, and change history.
SOHO vs. enterprise: what changes
| Area | Small office/home office (SOHO) | Enterprise |
|---|---|---|
| Typical use | A few remote workers, one small branch, or a home lab linked to the cloud | Many branches, thousands of remote users, partner (extranet) links, cloud VPCs |
| Devices | All-in-one router/firewall, a Linux host, or a NAS running WireGuard/OpenVPN | Dedicated firewalls/VPN concentrators, ISR/ASR routers, SD-WAN edges, cloud VPN gateways |
| Protocols | WireGuard, OpenVPN, IKEv2 built into the router | IPsec IKEv2 (route-based VTI, DMVPN), SSL/TLS remote access, ZTNA alongside VPN |
| Authentication | Pre-shared keys or key pairs, local accounts | Certificates (PKI), RADIUS/AD, SAML single sign-on, MFA, device posture checks |
| Availability | Single gateway, single ISP | Redundant gateways, dual ISPs, dead peer detection, dynamic routing over tunnels |
| Management | Web GUI, manual key exchange | Central management, templates, automation (Ansible/APIs), SIEM logging, change control |
| Skill emphasis | Port forwarding, dynamic DNS, NAT, basic key handling | Crypto policy design, routing, scale, HA, compliance (NIST, CMMC), incident response |
Common VPN protocols and ports
| Protocol | What it does | Ports / IP protocol | Where you'll see it | Status |
|---|---|---|---|---|
| IKEv2 | Negotiates keys and security associations for IPsec | UDP 500; UDP 4500 with NAT-T | Site-to-site, mobile clients | Recommended |
| IKEv1 | Older IPsec key exchange (main/aggressive mode) | UDP 500, 4500 | Legacy site-to-site (used in Part A because it's still common on exams and in the field) | Migrate to IKEv2 |
| ESP | Encrypts and authenticates IPsec data | IP protocol 50 (or inside UDP 4500) | All modern IPsec | Recommended |
| AH | Authenticates only, no encryption; breaks with NAT | IP protocol 51 | Rare, legacy | Avoid |
| SSL/TLS VPN | Remote access over HTTPS (Cisco Secure Client, GlobalProtect, FortiClient) | TCP 443, DTLS UDP 443 | Enterprise remote access | Common |
| OpenVPN | TLS-based, flexible, open source | UDP 1194 default (or TCP) | SOHO routers, small business | Common |
| WireGuard | Lean modern VPN: Curve25519, ChaCha20-Poly1305 | UDP 51820 default | SOHO, cloud, point-to-point (Part B) | Growing fast |
| L2TP/IPsec | Layer 2 tunnel protected by IPsec | UDP 1701 inside IPsec, UDP 500, 4500 | Older client VPNs | Legacy |
| GRE | Unencrypted tunnel that carries multicast and routing protocols | IP protocol 47 | GRE over IPsec, DMVPN | Pair with IPsec |
| PPTP | Broken MS-CHAPv2 authentication | TCP 1723 + GRE | Should not be found | Insecure, do not use |
| SSTP | Microsoft VPN over TLS | TCP 443 | Windows clients | Niche |
VPN life cycle: plan, configure, verify, maintain
- Gather requirements. Sites, users, applications, bandwidth, uptime, and compliance rules.
- Design addressing and topology. Confirm subnets don't overlap; pick site-to-site, remote access, or point-to-point.
- Select protocols and crypto. For example IKEv2, AES-256-GCM, SHA-256, DH group 14 or higher, PFS.
- Plan authentication. Pre-shared keys for labs and small sites; certificates and MFA for production.
- Prepare the edge. Allow UDP 500/4500 and ESP (or UDP 51820), add NAT exemptions, reserve static public IPs or dynamic DNS.
- Configure both ends with mirror-image parameters.
- Verify. Test underlay first, generate interesting traffic, check SAs, counters, and application access.
- Document and hand off. Diagrams, parameters (never the keys themselves), and a test record.
- Monitor and maintain. Log review, rekey and certificate renewals, firmware patches, capacity checks.
Command reference
Cisco IOS: policy-based IKEv1 site-to-site (Part A)
crypto isakmp policy 10 encryption aes 256 hash sha256 authentication pre-share group 14 lifetime 86400 crypto isakmp key MVCC-Lab-2026 address 198.51.100.1 crypto ipsec transform-set TS esp-aes 256 esp-sha256-hmac mode tunnel ip access-list extended VPN-TRAFFIC permit ip 10.1.1.0 0.0.0.255 10.2.2.0 0.0.0.255 crypto map VPN-MAP 10 ipsec-isakmp set peer 198.51.100.1 set transform-set TS match address VPN-TRAFFIC interface GigabitEthernet0/0 crypto map VPN-MAP
Cisco IOS: route-based IKEv2 with a virtual tunnel interface (enterprise)
crypto ikev2 proposal PROP encryption aes-cbc-256 integrity sha256 group 14 crypto ikev2 policy POL proposal PROP crypto ikev2 keyring KR peer BRANCH address 198.51.100.1 pre-shared-key MVCC-Lab-2026 crypto ikev2 profile PROF match identity remote address 198.51.100.1 255.255.255.255 authentication remote pre-share authentication local pre-share keyring local KR crypto ipsec profile IPSEC-PROF set transform-set TS set ikev2-profile PROF interface Tunnel0 ip address 172.16.0.1 255.255.255.252 ip tcp adjust-mss 1360 tunnel source GigabitEthernet0/0 tunnel destination 198.51.100.1 tunnel mode ipsec ipv4 tunnel protection ipsec profile IPSEC-PROF ip route 10.2.2.0 255.255.255.0 Tunnel0
Cisco verification and troubleshooting
show crypto isakmp sa ! phase 1 state: QM_IDLE = good, MM_NO_STATE = failing show crypto ipsec sa ! phase 2 SAs, encaps/decaps counters show crypto ikev2 sa ! IKEv2 equivalent show crypto map show crypto session detail debug crypto isakmp ! then generate traffic; undebug all when done clear crypto sa ! force renegotiation ping 10.2.2.1 source g0/1 ! source from the LAN so traffic matches the ACL
Linux: WireGuard (Part B)
sudo apt install wireguard umask 077; wg genkey | tee privatekey | wg pubkey > publickey sudo nano /etc/wireguard/wg0.conf sudo ufw allow 51820/udp sudo wg-quick up wg0 sudo wg show sudo systemctl enable wg-quick@wg0
Linux: strongSwan IPsec
sudo apt install strongswan strongswan-swanctl
sudo swanctl --load-all # load /etc/swanctl/swanctl.conf
sudo swanctl --initiate --child net-net
sudo swanctl --list-sas
sudo tcpdump -ni eth0 'udp port 500 or udp port 4500 or esp'
Windows client (PowerShell)
Add-VpnConnection -Name "Office" -ServerAddress "vpn.example.com" `
-TunnelType Ikev2 -AuthenticationMethod Eap -EncryptionLevel Required -SplitTunneling
Get-VpnConnection
rasdial "Office" # connect; rasdial "Office" /disconnect to drop
Test-NetConnection 10.2.2.10 -Port 443
Troubleshooting guide
| Symptom | Likely cause | What to check |
|---|---|---|
| No SA at all | No interesting traffic, crypto map not applied, peer unreachable | Ping the peer's public IP; confirm the map is on the outside interface; ping with a LAN source |
| MM_NO_STATE | Phase 1 mismatch, wrong pre-shared key, UDP 500 blocked | show crypto isakmp policy on both ends; debug crypto isakmp |
| QM_IDLE but no encrypted packets | Phase 2 mismatch: transform set, mode, or ACLs that don't mirror | show crypto ipsec sa; compare ACLs line by line |
| Encaps rise, decaps stay at 0 | Peer can't route the reply, peer NATs the traffic, or a firewall drops ESP | Peer routing table, NAT exemption, ESP/UDP 4500 rules |
| Ping works, web pages or file shares hang | MTU/fragmentation from encryption overhead | ip tcp adjust-mss 1360; ping with DF bit set |
| Tunnel drops at regular intervals | Lifetime, rekey, or dead peer detection mismatch | Lifetimes and DPD settings on both ends; logs at drop time |
| WireGuard: no "latest handshake" | Wrong public key, endpoint, port, or firewall | sudo wg show on both ends; ufw status |
| WireGuard: handshake but no ping | AllowedIPs doesn't cover the source or destination | AllowedIPs on both peers |
| Remote users connect but can't reach servers | Split-tunnel routes or internal DNS missing | Client route table, pushed DNS servers |
Glossary flip cards
Select a card to flip it.
Part A: IPsec site-to-site VPN in tunnel mode
The company's HQ and branch office each have a router connected to the internet. Your job is to protect all traffic between the two office LANs. Configure both routers so their settings mirror each other, then prove the tunnel works. Select a router in the diagram or the console tabs to switch devices.
Security policy for this tunnel
| Setting | Required value |
|---|---|
| Phase 1 (ISAKMP) policy | 10: AES-256, SHA-256, pre-shared key, DH group 14, lifetime 86400 s |
| Pre-shared key | MVCC-Lab-2026 |
| Phase 2 transform set | TS: esp-aes 256 esp-sha256-hmac, mode tunnel |
| Interesting-traffic ACL | VPN-TRAFFIC: HQ 10.1.1.0/24 to branch 10.2.2.0/24 (mirror it on R2) |
| Crypto map | VPN-MAP 10, applied to G0/0 on both routers |
Interfaces, IP addresses, and default routes are already configured.
Parameter comparison
Both peers must agree on every phase 1 and phase 2 setting. This table updates as you type.
Tasks
Tasks check themselves as you work. Use a hint only after you've tried.
Troubleshooting challenge
Once your tunnel is up, inject a hidden fault on one router. Find it using only show, debug, and ping, then fix it.
Inside the packet: tunnel mode vs. transport mode
This is the ping from PC-A to PC-B as it crosses the internet. Switch modes to compare what an eavesdropper on the ISP path can see.
Original packet
After IPsec ESP
Part B: WireGuard point-to-point VPN
An employee works from a home office behind a typical SOHO router. Build a dedicated one-to-one tunnel between the employee's laptop and the office VPN server vpn-gw. Each side generates a key pair and must hold the other side's public key. Click any key printed in the console to copy it.
Tunnel plan
| Setting | vpn-gw (server) | Laptop |
|---|---|---|
| Interface | wg0 | wg0 |
| Address | 10.10.0.1/24 | 10.10.0.2/24 |
| ListenPort | 51820 | (not needed) |
| [Peer] PublicKey | laptop's public key | vpn-gw's public key |
| [Peer] Endpoint | (learned automatically) | 203.0.113.10:51820 |
| [Peer] AllowedIPs | 10.10.0.2/32 | 10.10.0.1/32 |
| PersistentKeepalive | (not needed) | 25 (keeps the home NAT mapping open) |
The /32 AllowedIPs make this a true point-to-point link: each side sends and accepts only the single address of its partner.
Key exchange and readiness
Based on the saved wg0.conf files. Keys are shortened.
Tasks
Inside a WireGuard packet
The laptop's ping to 10.10.0.1 after it leaves the home router. NAT rewrote the outer source address; the inner packet is untouched and unreadable.
Like IPsec tunnel mode, WireGuard hides the inner addresses. Unlike IPsec, it always uses UDP, which passes through NAT easily, and it has no cipher negotiation: every peer uses ChaCha20-Poly1305, so there's nothing to mismatch except keys, addresses, and ports.
Knowledge check
Ten questions. Answer all, then check your answers to see explanations. Your score goes into the lab report.
Lab report
Fill in your details and reflections, then print or save as PDF to submit. Your typing is saved in this browser.