Created on
‎05-26-2025
02:56 AM
Edited on
‎05-26-2025
02:56 AM
By
Jean-Philippe_P
Description | This article describes the steps to configure and bind a static IP address to a designated username in an IKEv2 dialup IPsec scenario by using an external DHCP Server and FortiClient. |
Scope | FortiGate, FortiClient. |
Solution |
In certain scenarios, a specific Dialup IPsec client must receive a designated IP address from an external DHCP server. To accomplish this, DHCP Option 61 (Client Identifier) can be used, serving as the key identifier for binding the client to a static IP address.
Basic requirements for proper functionality:
Note:
Step 1: Enable the DHCP Proxy Feature on FortiGate:
config system settings
Step 2: Configure the Dialup IPsec Phase 1 and Phase 2 Interfaces:
config vpn ipsec phase1-interface
Step 3: Assign IP Addresses to the VTI (Virtual Tunnel Interface):
config system interface
Step 4: Configure Users, User Groups, and Firewall Policy:
config user local
config user group
config firewall policy
Step 5: Configure the FortiClient VPN Profile to Use IKEv2 and "Mode Config" for Address Assignment.
Step 6: Create the appropriate DHCP Scope using the IP Range defined in the dhcp-ra-giaddr setting: Note: Configuring a default gateway for the scope is not required.
On a Windows DHCP Server, the Client Identifier (Option 61) must be specified as a HEX value. Therefore, the username used by the client for authentication must be converted to HEX format. This information can be easily obtained by capturing the DHCP Request packet and analyzing it in Wireshark.
Important: Ensure that the Client Identifier HEX value includes the type field. Omitting it may cause the DHCP server to bypass the intended policy.
Example: fct_client1 = 6663745F636C69656E7431 in HEX format. By including the type byte, the HEX value becomes: 006663745F636C69656E7431.
Alternatively, address reservation can be used, which only requires the HEX-encoded username without the type byte.
Note: When using address reservation, the HEX-encoded username should be entered in the MAC address field.
If configured correctly, users authenticating via FortiClient will receive the IP address assigned by the DHCP server.
Steps for Troubleshooting:
Related articles: Troubleshooting Tip: Using the FortiOS built-in packet sniffer for capturing packets |
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 2025 Fortinet, Inc. All Rights Reserved.