Does anyone know if it is possible via SNMP to extract the "Comments" content from Fortigate Interface, do you know what OID checks this field?
I really appreciate any help you can provide.
to my knowledge there is no OID to get the comments field from a FortiGate interface; you can get VDOM and IP/subnet, but that's about it.
You can get the FortiGate MIB files from FortiGate GUI:https://docs.fortinet.com/document/fortigate/6.2.15/cookbook/608160/mib-filesYou will find all available traps and OIDs listed there.
While I don't see an OID for this, you could leverage the API. I'm on FOS 7.0 so if you are on a different version then your steps might be slightly different.
Follow these instructions to create an API user with a token (don't lose the token).
https://docs.fortinet.com/document/fortigate/7.0.13/administration-guide/399023/rest-api-administrat... (you can disable the PKI Group setting if you aren't using it)
Then using Curl or another method, issue this API call:
curl -X 'GET' \'https://<fgt_ip_fqdn_here>:<port_here>/api/v2/cmdb/system/interface?format=name%7Cdescription&vdom=root&access_token=<insert_your_api_token_here>' -H 'accept: application/json'
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2024 Fortinet, Inc. All Rights Reserved.