Port 500/4500: IPsec IKE (Internet Key Exchange for IPsec VPNs)
What port 500/4500 (UDP) does, the security risks of leaving it open, and how to secure and test it.
| Port | 500/4500 |
|---|---|
| Transport | UDP |
| Service | Internet Key Exchange for IPsec VPNs (IPsec IKE) |
| Encrypted | Yes |
What is port 500/4500?
IPsec VPNs use UDP 500 to negotiate keys (IKE) and UDP 4500 when NAT is in the path (NAT traversal). The encrypted data itself uses ESP (IP protocol 50).
Common uses
- Site-to-site VPNs between offices and to the cloud
- Remote access VPNs
Security risks
- Weak pre-shared keys that can be cracked
- Old IKEv1 aggressive mode leaking information
- Unpatched VPN gateways
How to secure port 500/4500
- Use IKEv2 with strong encryption and long, random pre-shared keys or certificates
- Limit VPN peers to known IP addresses for site-to-site tunnels
- Patch VPN gateways promptly
How to check if port 500 is open
| Where | Command |
|---|---|
| Scan from another machine | nmap -sU -p 500 <host> |
| Linux (what is listening) | sudo ss -tulpn | grep :500 |
| Windows (what is listening) | netstat -ano | findstr :500 |
Only scan systems you own or have permission to test.
Related ports
Frequently asked questions
What is port 500/4500 used for?
Port 500/4500 (UDP) is used by Internet Key Exchange for IPsec VPNs (IPsec IKE). IPsec VPNs use UDP 500 to negotiate keys (IKE) and UDP 4500 when NAT is in the path (NAT traversal).
Is it safe to open port 500/4500?
Only if the service needs to be reached and is configured securely. Use IKEv2 with strong encryption and long, random pre-shared keys or certificates.
How do I check if port 500/4500 is open?
From another computer, run nmap -p 500 followed by the host address with -sU for UDP. On the server itself, ss -tulpn on Linux or netstat -ano on Windows shows whether anything is listening on 500.
Learn more: TCP, UDP and ports explained and firewall basics.