| Description | This article describes a dial-up IPsec tunnel configuration using IKEv2 in which the user authenticates using user credentials and 2FA using FortiToken Mobile. |
| Scope | FortiGate. |
| Solution |
From CLI:
config user local edit "Test" set type password set two-factor fortitoken set fortitoken "FTKMxxxx" set email-to "xxxx@example.com" set next end
config user group edit "VPN_Users" set member "Test" next end
config vpn ipsec phase1-interface set type dynamic XnewPHTN66Y27Rw0dNH7zphxj1ZIhIEH05OVG6qHOZe9Jo2ZOnuOEWOKs0HuKbGMyYJ4bC0xd7NXG9Tn7bwOk1wYg==
Note: config vpn ipsec phase2-interface
config firewall policy
Note: Push notification over dial-up IKEv2 is supported only starting with FortiOS v7.2.8, v7.4.4, v7.6.0, and below FortiClient versions:
In some cases, when two-factor authentication is used for a dial-up tunnel but users are intermittently unable to connect or have to try multiple times before connecting, extending the IPsec negotiation timeout beyond the default 30 seconds may be necessary. This adjustment can prevent connection failures if additional time is required to enter the one-time password (OTP). config vpn ipsec phase1-interface edit Dialup_IKEv2 set negotiate-timeout 50 <----- Enter an integer value from <1> to <300> <----- Default = <30>. end
A dial-up IPsec connection with an IOS device will fail to connect when using FortiToken Multi-Factor Authentication, as it will not receive the Token push. As a workaround, include the Token in the password field while connecting.
The user will enter p@ssw0rd345678 when prompted for the password.
FortiClient Free version 7.4.8 presents the same behavior. To verify the behavior, run the following commands:
diagnose debug reset
To stop the debugs, run the following command:
diagnose debug disable
Without the workaround:
[913] update_auth_token_session-Token is needed ike V=root:0:vpn_car:114 EAP 9199965560835 result FNBAM_NEED_TOKEN
With the workaround:
[880] update_auth_token_session-2fa code has already been verified in concatenated password
Related documents: Technical Tip: IKEv2 Dial-up IPsec tunnel with Radius and FortiToken MFA |
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 2026 Fortinet, Inc. All Rights Reserved.