Palo Alto Site-to-Site IPSec VPN
IKEv2 site-to-site IPSec VPN tunnel on Palo Alto PAN-OS. Generates IKE crypto profile, IPSec crypto profile, IKE gateway, IPSec tunnel, and tunnel interface.
What is it?
Palo Alto's IPSec VPN implementation uses the same two-phase approach as all IPSec: IKE Phase 1 negotiates the management channel, Phase 2 establishes the data tunnel. PAN-OS requires four objects: (1) IKE Crypto Profile (Phase 1 algorithms), (2) IPSec Crypto Profile (Phase 2 algorithms), (3) IKE Gateway (peer address and auth), and (4) IPSec Tunnel (links everything together on a tunnel interface). The tunnel interface is added to a dedicated VPN zone, and security policies control what traffic is allowed between the VPN zone and internal zones. The IKE version is not a detail: it changes which sub-tree of the IKE Gateway you configure ('protocol ikev1 ...' versus 'protocol ikev2 ...'), IKEv1 adds an exchange mode (main or aggressive) that IKEv2 does not have, and PAN-OS restricts AES-GCM for ESP and IKE fragmentation to IKEv2. Both ends must agree on the version — an IKEv2-only gateway facing an IKEv1-only peer never reaches Phase 1, and the log says only that no proposal was chosen.
When to use
- ·Site-to-site connectivity to branch offices over the internet
- ·Connecting to AWS, Azure, or GCP VPN Gateways
- ·Partner/vendor network connectivity where full SD-WAN is not justified
- ·Disaster recovery connectivity between primary and backup sites
- ·IKEv1 specifically: an old peer that does not speak IKEv2 at all, or a device whose IKEv2 implementation you do not trust. It still exists in the field and a tunnel that comes up beats a standard that does not
When NOT to use
- ·Remote user VPN — use GlobalProtect (SSL VPN) instead, which provides better user experience
- ·If both sites have Palo Alto firewalls — consider GlobalProtect Cloud Service or SD-WAN for better visibility
- ·Do not pick IKEv1 when the peer supports IKEv2. IKEv1 has no built-in liveness check (DPD is bolted on), no MOBIKE, a weaker rekey story, and it costs you AES-GCM for ESP and IKE fragmentation on PAN-OS
- ·Do not pick IKEv1 aggressive mode with a pre-shared key on a public address — it sends the identity and a PSK hash in the clear in the first exchange, which is offline-crackable. Aggressive mode exists for a peer with a dynamic IP, and even then main mode with a peer ID is usually possible
How it compares
Prerequisites
- →A dedicated VPN zone must exist (e.g., 'vpn-zone') before tunnel interface can be assigned
- →The virtual router must be configured to route traffic to the remote subnet via the tunnel interface
- →IKE Phase 1 and Phase 2 parameters must match exactly with the remote peer — including the IKE version. Confirm with the far end which version they are configured for before you generate this
- →AES-GCM for ESP and IKE fragmentation require IKEv2 on PAN-OS. On IKEv1, pick a CBC cipher plus an ESP authentication algorithm
- →PAN-OS 7.1 or later for IKEv2 on the IKE Gateway; 8.1 or later for IKEv2 fragmentation
- →Proxy IDs must be configured if the remote peer uses policy-based VPN (Cisco ASA, IOS)
- →NAT exemption rule needed if source NAT is configured for internet traffic
Config Generator
Verification commands
show vpn ike-saVerify IKE Phase 1 security association is established
ExpectedShows SA with peer IP, state 'established', and DH group. If empty, Phase 1 failed.
show vpn ipsec-saVerify IPSec Phase 2 tunnel and packet counters
ExpectedShows tunnel with encap/decap packet counts. Zero counts mean traffic isn't hitting the tunnel.
show vpn tunnelShow all IPSec tunnels and their state
ExpectedTunnel status should show 'active'. State 'init' means Phase 2 has not completed.
Debug commands
test vpn ike-sa gateway GW-<peer-ip>Initiate IKE negotiation to test Phase 1
Common mistakes & fixes
Further learning
Recommended books to go deeper on this topic.
Palo Alto Networks Firewall Deployment and Administration
Tom Piens · Packt · IPsec VPN on PAN-OS — IKEv1/v2, GlobalProtect, tunnel configuration
Cisco ASA: All-in-One Next-Gen Firewall, IPS, and VPN Services
Jazib Frahim, Omar Santos, Andrew Ossipov · Cisco Press · IKE phase 1 & 2 deep dive — concepts apply to all vendors