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

DNS Filter Anycast Cloud Timeout Adding 5-Second Latency to LAN DNS Queries

When FortiGate acts as a recursive LAN DNS server or forwarder with DNS Filtering enabled, synchronous Anycast FortiGuard rating lookups inject exactly 5,000ms latency spikes into local workstation queries during WAN jitter.

Technical Root Cause Analysis

The FortiOS dnsproxy daemon is responsible for intercepting DNS traffic on interface listeners or transparent transit policies. When a DNS Filter profile is attached, each new domain query is evaluated against FortiGuard Category databases.

In FortiOS versions 7.2.4 through 7.2.7, DNS Filter enforced synchronous cloud rating by default. If a workstation requested resolution for an uncached domain (e.g. api.github.com), dnsproxy held the inbound UDP client packet in an internal processing queue while dispatching a query to FortiGuard Anycast rating servers (UDP 8888 / HTTPS 443). On branch offices with satellite, cellular, or high-jitter WAN connections, or during regional Anycast BGP route flap, the cloud response failed to return within normal round-trip times. dnsproxy waited until the hardcoded 5,000ms rating-timeout expired before releasing the DNS response to the client, causing perceived web stalls, Active Directory login pauses, and timeout errors across the LAN.

[dnsproxy_filter] qname=api.github.com, type=A, id=0x41ab from 192.168.1.150:62104 [dnsproxy_filter] cloud lookup dispatched: server=208.91.112.196 (Anycast) [dnsproxy_filter] synchronous wait timer started (timeout=5000ms) ... (5000ms elapsed without FortiGuard ACK) ... [dnsproxy_filter] rating timed out (5002ms): fallback action=PERMIT [dnsproxy_filter] resolved via upstream forwarder 8.8.8.8 in 5014ms total RTT client 192.168.1.150 retransmitted query 2 times due to 5s delay

Affected Firmware & Blast Radius Matrix

FortiOS Branch Vulnerable Builds Confirmed Clean Build Status & Workaround
FortiOS 7.2 7.2.4 – 7.2.7 7.2.8+ Tune Asynchronous DNS rating
FortiOS 7.4 7.4.0 – 7.4.2 7.4.3+ Reduce rating-timeout to 1000ms
FortiOS 7.0 7.0.10 – 7.0.14 7.0.15+ Disable synchronous inspection

Platform Impact: Branch office and enterprise FortiGate firewalls acting as the primary DNS server / DHCP gateway for local LAN subnets with DNS filtering active.

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

Execute these commands to inspect dnsproxy worker queue depths, Anycast round-trip latencies, and check memory consumption:

Diagnostic Commands

# 1. Inspect live dnsproxy daemon statistics, queue depth, and drop counts
diagnose test application dnsproxy 1

# 2. Check FortiGuard server rating latency and packet loss
diagnose debug rating

# 3. View memory utilization of the dnsproxy process
diagnose sys top-mem 10 | grep dnsproxy

# 4. Dump dnsproxy DNS filter cache statistics
diagnose test application dnsproxy 2

Remediation & Workaround Steps (Teaser Preview)

Eliminate 5-second DNS latency spikes across your corporate LAN immediately:

Step 02: Switch DNS Filtering to Asynchronous Rating

Allow dnsproxy to return DNS resolutions immediately while rating classifications occur out-of-band.

🔒 Interactive CLI Available in Ferrite Runbook #04

Step 03: Reduce FortiGuard DNS Rating Timeout to 800ms

Clamp maximum cloud wait times from 5,000ms down to 800ms to prevent client UDP retry storms.

🔒 Interactive CLI Available in Ferrite Runbook #04

Step 04: Switch FortiGuard Rating Transport to HTTPS

Encapsulate rating queries inside TLS on port 443 to avoid ISP UDP rate-limiting on port 8888.

🔒 Interactive CLI Available in Ferrite Runbook #04
⚡ 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

Why do DNS queries pause for exactly 5 seconds before returning an answer?

In FortiOS 7.2.4–7.2.7, DNS Filter queries FortiGuard Anycast rating servers synchronously with a default 5-second (5,000ms) timeout. If WAN latency, packet loss, or Anycast server throttling delays the rating reply, dnsproxy holds the client query in memory until the 5-second timer expires before forwarding the cached or upstream DNS answer.

What is Asynchronous DNS Rating and how does it prevent latency?

Asynchronous DNS rating enables the FortiGate to immediately answer DNS requests from local cache or forward upstream without blocking the client. Meanwhile, the FortiGuard rating query executes in the background. If a domain is subsequently determined to be malicious, subsequent requests are blocked.

Does this issue affect environments using external DNS servers (like 8.8.8.8)?

Only if the FortiGate acts as the default DNS forwarder/server for LAN interfaces, or if a DNS Filter profile is applied to the firewall transit policy inspecting port 53 UDP/TCP traffic.