Ferritaas Incident Intelligence
Defect Intelligence Report Bug 0881903 Severity: High (P2)

IPsec Phase 2 Rekey Drops Offloaded ESP Packets on NP6Lite / SOC4

Hardware-accelerated IPsec VPN tunnels on FortiGate desktop firewalls powered by NP6Lite / SoC4 ASICs suffer intermittent 5–15 second packet loss bursts during Phase 2 SA rekeying due to premature hardware Security Association invalidation in np6lite_ipsec_sa_install.

Technical Root Cause Analysis

On FortiGate platforms incorporating the NP6Lite network processor (including SoC4 desktop units such as FG-40F, FG-60F, and FG-80F), IPsec cryptographic processing is offloaded to hardware SPU engines to achieve line-rate encrypted throughput.

When an IPsec Phase 2 Security Association (SA) lifetime expires, the Internet Key Exchange (IKE) daemon negotiates a new inbound and outbound Security Parameter Index (SPI) pair. In affected FortiOS builds, the driver routine np6lite_ipsec_sa_install() invalidates the previous inbound SPI in the ASIC lookup table immediately upon programming the new outbound SA. However, because the remote VPN peer continues transmitting trailing ESP packets using the old SPI during the standard rekey grace margin, the NP6Lite hardware fails to map the arriving packets. The ASIC silently drops incoming ESP traffic with the hardware drop counter ipsec_sa_not_found, creating a 5 to 15 second blackhole for real-time applications.

[spu/np6lite] np6lite_ipsec_sa_install: installing new outbound SPI 0x5a18d9f1 for tunnel 'CORP_DC_VPN' [spu/np6lite] ERROR: old inbound SPI 0x2e04a11b prematurely invalidated before inbound rekey margin window! [spu/np6lite] drop counter 'ipsec_sa_not_found' incremented (+1428 packets, rate 350 pps) ike 0:CORP_DC_VPN: IPsec SA rekey complete: SPI 0x5a18d9f1/0x3199ce01 (ESP) [spu/np6lite] tunnel offload restored after 8.4 seconds packet blackhole

Affected Firmware & Blast Radius Matrix

FortiOS Branch Vulnerable Builds Confirmed Clean Build Status & Workaround
FortiOS 7.2 7.2.2 – 7.2.6 7.2.7+ Disable npu-offload on phase2 or increase margin
FortiOS 7.4 7.4.0 – 7.4.1 7.4.2+ Upgrade recommended for branch IPsec nodes
FortiOS 7.0 Not Affected 7.0 Branch Clean Dual-SA overlapping lifetime supported in 7.0

Platform Impact: Affects NP6Lite and SoC4 hardware platforms (FG-40F, FG-60F, FG-61F, FG-80F, FG-81F, and FG-100E) running route-based or policy-based site-to-site IPsec tunnels.

Step 01: Free Verification CLI (Safe Read-Only)

Execute these diagnostic commands on the branch FortiGate to verify hardware offload status and check whether NP6Lite SA drop counters are incrementing during tunnel rekeys:

Diagnostic Commands

# 1. Query IPsec Phase 2 active SPI keys and hardware offload flags
diagnose vpn tunnel list name CORP_DC_VPN

# 2. Inspect NP6Lite cryptographic hardware processing statistics
diagnose npu np6lite ipsec-stats

# 3. Check ASIC hardware packet drop counters for unmapped SAs
diagnose npu np6lite drop

# 4. Monitor real-time IKE daemon Phase 2 negotiation status
diagnose vpn ike status

Remediation & Workaround Steps (Teaser Preview)

Follow the complete step-by-step remediation guide in the Ferrite interactive platform:

Step 02: Adjust Phase 2 Rekey Margin and Soft Lifetime

Tune keylife and rekey margin parameters to force earlier IKE Phase 2 negotiations before the hard lifetime expires.

🔒 Interactive CLI Available in Ferrite Runbook #07

Step 03: Temporarily Disable NPU Hardware Offload for Critical Tunnels

Disable npu-offload on VoIP or sensitive database tunnels to shift cryptography to the kernel CPU, which correctly maintains overlapping SAs.

🔒 Interactive CLI Available in Ferrite Runbook #07

Step 04: Deploy FortiOS 7.2.7+ or 7.4.2+ GA Maintenance Release

Upgrade to clean firmware containing dual-SA memory retention in the NP6Lite driver ring until confirmed transmission.

🔒 Interactive CLI Available in Ferrite Runbook #07
⚡ Ferrite Platform Superpowers

Execute the Complete Runbook with Live Browser Automation

Connect your FortiGate via browser console (Web Serial) or local SSH bridge, verify each command in real-time, generate ready-to-run Tera Term scripts, and export sanitized TAC dossiers.

Live Browser Automation Direct terminal connection with live step checkoff.
📟
1-Click Tera Term (.ttl) Generate scripts for air-gapped jumpboxes.
🛡️
Zero-Trust Scrubber Scrub serials and credentials in local browser RAM.
📄
TAC P1 Escalation Dossier Standardized evidence export with SHA-256 seal.

Frequently Asked Questions

What causes IPsec packet loss during Phase 2 rekey on NP6Lite / SoC4?

When an IPsec Phase 2 Security Association (SA) lifetime expires, IKE negotiates a new SPI pair. On NP6Lite hardware, np6lite_ipsec_sa_install purges the old inbound SA from the hardware lookup table the instant the new outbound SA is installed, rather than keeping both active during the transition margin. In-flight ESP packets arriving from the remote peer with the previous SPI hit an unmapped SA in hardware and are silently dropped.

Which models and traffic types are impacted?

Appliances utilizing the NP6Lite ASIC or SoC4 architecture (FG-40F, FG-60F, FG-61F, FG-80F, FG-81F, and FG-100E) are vulnerable. Voice-over-IP (VoIP), database synchronizations, and real-time streaming sessions experience audio dropouts, session resets, or latency spikes every time the Phase 2 lifetime expires (typically once per hour).

How can I mitigate packet loss without restarting the firewall?

Under 'config vpn ipsec phase2-interface', setting 'set npu-offload disable' routes encryption through the system kernel CPU, which correctly maintains overlapping SAs and eliminates drops until firmware upgrade.