VPN Tunnel formation fails with "IKEv2 SA negotiation is failed likely due to pre-shared key mismatch" - Pre-shared Key mismatch

VPN Tunnel formation fails with "IKEv2 SA negotiation is failed likely due to pre-shared key mismatch" - Pre-shared Key mismatch

25754
Created On 08/02/22 20:52 PM - Last Modified 02/21/24 21:43 PM


Symptom


  • VPN Tunnel not coming up or went down
  • System Logs display the following logs
    •  "IKEv2 SA negotiation is failed likely due to pre-shared key mismatch"
    • "IKE protocol notification message received: received notify type AUTHENTICATION_FAILED"
    • "authentication failure"
Note: This Pre-shared Key mismatch is not visible in a packet capture, Use CLI commands and check both sides' configurations manually.

Web UI
Navigate to Network > IKE Gateway > edit IKE Gateway > type Pre-shared Key
Web GUI showing pre-shared key for IKE Gateway

System Logs
Navigate to Monitor > System Logs
System Logs for pre-shared key mismatch

Wireshark: The Pre-shared Key is not visible in Wireshark

ikemgr.log: Run the command "less mp-log ikemgr.log" on both peers and look for the following errors

022-06-27 16:41:27.702 -0700  [PWRN]: {    1:     }: [500] - [500]:0x55fd12d47780 received notify type AUTHENTICATION_FAILED
2022-06-27 16:41:25.697 -0700  [PERR]: {    1:     }: [500] - [500]:0x7fe60c0240a0 authentication failure
2022-06-27 16:41:25.697 -0700  [INFO]: {    1:     }: [500] - [500]:0x7fe60c0240a0 authentication result: failure


Environment


  • Palo Alto Firewalls
  • Supported PAN-OS
  • IPSec VPN Tunnel


Cause


This issue occurs when the two VPN peers have a mismatch in Pre-shared Key

Resolution


  1. Configure both sides of the VPN to have a matching Pre-shared Key.
    • Delete the existing pre-shared key on both firewalls.
    • Retype the pre-shared key on both firewalls (case sensitive).
    • one can type the pre-shared key to a notepad and copy/paste it to WebUI or CLI of both firewalls.
Web GUI showing matching pre-shared key good
 
  1. Perform a Commit
  2. Run the below commands a couple times each on both the VPN peer firewall CLIs to get them to freshly initiate and form:
>clear vpn ike-sa gateway <name>
>clear vpn ipsec-sa tunnel <name>

 


Actions
  • Print
  • Copy Link

    https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA14u000000wlDXCAY&lang=en_US&refURL=http%3A%2F%2Fknowledgebase.paloaltonetworks.com%2FKCSArticleDetail

Choose Language