Skip to main content
srajeswaran
Staff
Staff
Oct 8, 2026 12:55 PM UTC

Technical Tip: Understanding the difference between Client ID and Custom Tracking ID in FortiWeb traffic logs

Description

This article describes the difference between the 'Client ID' and 'Custom Tracking ID' fields in FortiWeb traffic logs and explains why a Client ID may be present while the Custom Tracking ID is 'none'.

Scope

FortiWeb.

Solution

FortiWeb traffic logs can display both 'Client ID' and 'Custom Tracking ID'. These fields represent different tracking mechanisms and should not be considered interchangeable.

  • Client ID: An identifier used by FortiWeb to track a client. In the example below, FortiWeb's 'cookiesession1' cookie is used to maintain client identification.

  • Custom Tracking ID: An identifier generated according to the match conditions configured in a Custom Tracking policy. In this example, the tracking condition uses an application session cookie.


The following lab setup demonstrates the behavior:

d5cfcf2e.png


  1. Configure Custom Tracking using an application session cookie.


The backend application uses a cookie named 'LABSESSION' to maintain authenticated sessions.

Configure a Custom Tracking policy to match this cookie:

config waf custom-tracking policy
    edit "1"
        set tracking-timeout 60
        config match-condition
            edit 1
                set match-target request-cookie
                set target-name LABSESSION
                set target-value-type regular
                set target-value-regex [A-Za-z0-9_-]+
            next
        end
    next
end


Associate the Custom Tracking policy with an inline Web Protection Profile:

config waf web-protection-profile inline-protection
    edit "LAB_WAF_Profile"
        set custom-tracking-policy 1
    next
end


Apply the profile to the existing server policy:

config server-policy policy
    edit "LAB_HTTP_Policy"
        set web-protection-profile LAB_WAF_Profile
    next
end


  1. Verify traffic logs when both cookies are present.


In this LAB, two clients access a backend web application through FortiWeb operating in Reverse Proxy mode.

  • Client 1: 10.135.3.37.

  • Client 2: 10.135.3.38.

  • FortiWeb virtual server: 10.120.3.197:8080.

  • Backend web server: 10.117.3.35:5000.


Both clients access the same authenticated application session using the same 'LABSESSION' cookie. The FortiWeb traffic logs show:

Original Source:     10.135.3.37
URL:                 /session-info
Client ID:           0840FB0BA6EE5A0B4C7CD360B76CF6B28F87
Custom Tracking ID:  EHjiAih09WJserhselmpL9Ow6CZIRwDmfqqUd9FNo9E=
Return Code:         200


Original Source:     10.135.3.38
URL:                 /session-info
Client ID:           0840FB0BA6EE5A0B4C7CD360B76CF6B28F87
Custom Tracking ID:  EHjiAih09WJserhselmpL9Ow6CZIRwDmfqqUd9FNo9E=
Return Code:         200


Both identifiers remain unchanged despite the different source IP addresses.

  1. Verify traffic logs when the application session cookie is absent.


A subsequent request is sent with FortiWeb's 'cookiesession1' cookie but without the application's 'LABSESSION' cookie.

The traffic log shows:

Original Source:     10.135.3.38
URL:                 /session-info
Client ID:           0840FB0BA6EE5A0B4C7CD360B76CF6B28F87
Custom Tracking ID:  none
Return Code:         200


The Client ID remains unchanged, while the Custom Tracking ID is 'none' because the request does not match the configured Custom Tracking condition.

This confirms that a request can retain its FortiWeb Client ID independently of the configured Custom Tracking policy.

  1. Compare the observed behavior.


Test scenario

Client ID

Custom Tracking ID

Same application session cookie, different source IPs

Same

Same

Different application session cookies, same source IP

Different

Different

Same application session cookie, different User-Agents

Same

Same

FortiWeb 'cookiesession1' present, application session cookie absent

Retained

none


Note: The 'Client ID' and 'Custom Tracking ID' fields represent different tracking mechanisms and should not be considered interchangeable.

A populated 'Client ID' does not necessarily indicate that a request matches the configured Custom Tracking policy. When the configured tracking condition is not matched, the 'Custom Tracking ID' field may display 'none' even though the 'Client ID' remains available.

    Risk and Resilience in the Age of AI. An OT Thought Leadership Summit for Houston's Critical Infrastructure Leaders. Date: Thursday, December 3, 2026. Time: 8:30 am - 1:30 pm (CT). Location: The Westin Houston, Memorial City | 945 Gessner Road, Houston, TX 77024