Skip to main content
farhanahmed
Staff
Staff
January 10, 2025

Technical Tip: How to use fqdn as local-id in VPN Manager

  • January 10, 2025
  • 0 replies
  • 478 views
Description This article describes how to use fqdn as a local ID for tunnels in VPN Manager.
Scope FortiManager, VPN Manager, FortiGate.
Solution

In VPN Community settings local id type can be set to use fqdn:

 

VPN Manager -> Select the VPN Community > Edit (or create new) -> Advanced-Options -> localid-type > Select 'fqdn':

 

1.png

 

When adding a Gateway to the community, it gives the option to set the local id which now allows to set fqdn:

 

1.png


Local ID for existing gateways can be changed by VPN Manager -> Select the Community -> 'Right Click' and select 'Configure Gateways':

 

1.png

 

Then Select a gateway -> Select Edit -> Set/change the Local ID:

 

1.png 

Installing config to the FortiGate shows the localid and the type set to fqdn:

 

1.png

 

The same result can be achieved using API:

 

  • Update existing VPN Community:
 
{
    "method": "update",
    "params": [
        {
            "data": [
                {
                    "name": "{{COMMUNITY_NAME}}",
                    "localid-type": "fqdn"
                }
            ],
            "url": "/pm/config/adom/{{ADOM}}/obj/vpnmgr/vpntable"
        }
    ],
    "session": "{{session}}",
    "id": 1
}
 
  • Add localid for a device:

 

{
    "method": "update",
    "params": [
        {
            "data": {
                "id": 4,
                "vpntable": "{{COMMUNITY_NAME}}",
                "localid": "{{LOCAL_ID}}"
            },
            "url": "pm/config/adom/{{ADOM}}/obj/vpnmgr/node"
        }
    ],
    "id": "1",
    "session": "{{session}}"
}
 
  • In the API Request above the 'id:4' indicates the ID of the existing which can be obtained using a GET request to fetch data of existing nodes (devices/gateways).

 

{
    "method": "get",
    "params": [
        {
            "url": "/pm/config/adom/{{ADOM}}/obj/vpnmgr/node"
        }
    ],
    "session": "{{session}}",
    "id": 1
}

 
1.png