Firewall admins can try stopping this behavior with some options to alleviate the load on the firewall NPU in the following ways: Â TCP sessions: The recommendation is to inject delay on the firewall policy level. This ensures the firewall gets more time to handle TCP sessions:
 config firewall policy
edit <policy id>
 set delay-tcp-npu-session enable
next
end  Â
ESP packets: There are 2 commands under global and under the IPsec tunnel configuration itself that can help reduce or eliminate this issue. The first is to disable the HMAC offloading to the NPU while the second is to force fragmentation on the the IPsec tunnel: Â
config system global
  set ipsec-hmac-offload disable
end
config vpn ipsec phase1-interface
  edit <tunnel name>
    set ip-fragmentation pre-encapsulation
 next
end
Prevent fragmentation by configuring TCP MSS clamping either on the firewall policy or directly on the interface. This helps reduce ESP packet overhead and applies to all traffic entering and exiting the IPsec tunnel.
Firewall Policy MSS clamping:
config firewall policy
edit <policy_id>
set tcp-mss-sender 1360
set tcp-mss-receiver 1360
end
Interface MTU/MSS clamping:
config system interface
edit "<vpn_interface_name>"
set mtu-override enable
set mtu 1400
set tcp-mss 1360
next
end
Note: Anti-replay can affect the traffic through the tunnel, which may lead to ESP packets being dropped. Having the same anti-replay setting on both the local and peer IPsec is recommended.
The discarded packets will be logged with the following message in the Event Log: 'Invalid ESP packet detected (replayed packet)'.
config vpn ipsec phase2-interface
  edit <phase2-name>
    set replay <enable | disable>
  next
end
|