FortiGate Next Generation Firewall utilizes purpose-built security processors and threat intelligence security services from FortiGuard labs to deliver top-rated protection and high performance, including encrypted traffic.
The "No Session Match" will appear in debug flow logs when there is no session in the session table for that packet.

One possible reason is that the session was closed according to the "tcp-halfclose-timer" before all data had been sent for that session.

id=13 trace_id=101 func=resolve_ip_tuple_fast line=4299 msg="vd-root received a packet(proto=6,> from lan."
id=13 trace_id=101 func=vf_ip4_route_input line=1603 msg="find a route: gw- via lan"
id=13 trace_id=101 func=fw_forward_dirty_handler line=309 msg="no session matched"

This settings defines how many seconds the FortiGate unit should wait to close a session after one peer has sent a FIN packet but the other has not responded.

  • The valid range is from 1 to 86400 seconds.
  • By default in FortiOS 5.0,5.2 tcp-halfclose-timer is 120 seconds

config system global
set tcp-halfclose-timer <integer>

 The following steps show how to extend the TCP half-close timer for port 8888.

(1) Create a custom firewall service for TCP port 8888

Set the expected tcp-halfclose-timer for the new custom service.

config firewall service custom
    edit "TCP-8888"
        set tcp-portrange 8888
        set tcp-halfclose-timer 3600

2) Use this custom service in all relevant policies:

config firewall policy
   edit 55
       set srcintf "lan"
       set dstintf "port7"
       set srcaddr "all"
       set dstaddr "all"
       set action accept
       set schedule "always"
       set service "TCP-8888"
       set logtraffic all

The tcp-halfclose-timer will be applied to the session and therefore applied regardless of which end initiates the half-close.