FortiGate
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.
jdelafuente_FTNT
Article Id 346997
Description This article describes how to find out which policy IDs are being used for troubleshooting purposes.
Scope FortiGate.
Solution

In FortiOS GUI, access to Dashboard -> Fortiview Sessions. Place the mouse over the title of the first column, commonly 'source', and a gear icon will appear, select it, enable the Policy option, and select Apply.

 

Session_Monitor.png

The GUI will reload and a new column called Policy will appear on the right side of the table. Place the mouse over the title and drag it to the position that best suits the reading. Repeat this procedure for all the parameters.

  

Session_Monitor2.png

 

It is now possible to apply any type of filter and know which policy is currently used. Same as following in the forward logs to check policy ID and policy name information.

It is also possible to see this information when viewing the session table via the CLI. The policy ID is specified under 'policy_id=' as seen below.

 

cli session.PNG