Fortigate Authentication 56
Fortigate Authentication 56
Fortigate Authentication 56
VERSION 5.6.2
FORTINET DOCUMENT LIBRARY
http://docs.fortinet.com
FORTINET VIDEO GUIDE
http://video.fortinet.com
FORTINET BLOG
https://blog.fortinet.com
CUSTOMER SERVICE & SUPPORT
https://support.fortinet.com
http://cookbook.fortinet.com/how-to-work-with-fortinet-support/
FORTIGATE COOKBOOK
http://cookbook.fortinet.com
FORTINET TRAINING SERVICES
http://www.fortinet.com/training
FORTIGUARD CENTER
http://www.fortiguard.com
FORTICAST
http://forticast.fortinet.com
FEEDBACK
Email: [email protected]
August 9, 2017
01-561-122870-20170809
TABLE OF CONTENTS
Change log 10
Introduction 11
Before you begin 11
How this guide is organized 11
Whats New in FortiOS 5.6 13
FortiOS 5.6.1 13
IPv6 RADIUS Support (309235, 402437, 439773) 13
Full certificate chain CRL checking (407988) 13
New option under user > setting to allow/forbid SSL renegotiation in firewall
authentication (386595) 14
New option to allow spaces in RADIUS DN format (422978) 14
Added LDAP filter when group-member-check is user-attr (403140) 14
Added Refresh button to the LDAP browser (416649) 14
Differentiate DN option for user authentication and membership searching (435791) 14
FTM Push when FAC is auth server (408273) 15
Non-blocking LDAP authentication (433700) 15
Manual certificate SCEP renewal (423997) 15
More detailed RADIUS responses shown in connectivity test (434303) 15
Firewall user authentication timeout range increased (378085) 16
FortiOS 5.6.0 16
FortiToken Mobile Push (397912, 408273, 399839, 404872) 16
Support V4 BIOS certificate (392960) 17
Support extendedKeyUsage for x.509 certificates (390393) 17
Administrator name added to system event log (386395) 18
Support RSA-4096 bit key-length generation (380278) 18
New commands added to config user ldap to set UPN processing method and filter
name (383561) 18
User authentication max timeout setting change (378085) 18
Changes to Authentication Settings > Certificates GUI (374980) 18
Password for private key configurable in both GUI and CLI (374593) 18
RADIUS password encoding (365145) 18
RSSO supports Delegated-IPv6-Prefix and Framed-IPv6-Prefix (290990) 19
Introduction to authentication 20
What is authentication? 20
Methods of authentication 20
Local password authentication 21
Server-based password authentication 21
Certificate-based authentication 21
Two-factor authentication 22
Types of authentication 22
Security policy authentication 23
VPN authentication 24
Single Sign-On authentication for users 25
User’s view of authentication 26
Web-based user authentication 26
VPN client-based authentication 26
FortiGate administrator’s view of authentication 27
General authentication settings 27
Authentication servers 29
FortiAuthenticator servers 29
RADIUS servers 29
Microsoft RADIUS servers 30
Configuring the FortiGate unit to use a RADIUS server 34
LDAP servers 36
Components and topology 36
LDAP directory organization 37
Configuring the FortiGate unit to use an LDAP server 39
Example — wildcard admin accounts - CLI 41
Example of LDAP to allow Dial-in through member-attribute - CLI 43
Troubleshooting LDAP 44
TACACS+ servers 45
POP3 servers 46
SSO servers 46
RSA ACE (SecurID) servers 48
Components 48
Configuring the SecurID system 48
Users and user groups 53
Users 53
Local and remote users 54
PKI or peer users 57
Two-factor authentication 57
Monitoring users 66
User groups 66
Firewall user groups 67
SSO user groups 71
Configuring Peer user groups 71
Viewing, editing and deleting user groups 71
SSL renegotiation in firewall authentication 72
Managing Guest Access 73
User’s view of guest access 73
Administrator’s view of guest access 73
Configuring guest user access 73
Creating guest management administrators 73
Creating guest user groups 73
Creating guest user accounts 74
Guest access in a retail environment 76
Creating an email harvesting portal 76
Creating the security policy 76
Fall-through authentication policies 77
Configuring authenticated access 79
Authentication timeout 79
Security authentication timeout 79
SSL VPN authentication timeout 79
Password policy 80
Configuring password minimum requirement policy 80
Password best practices 81
Maximum logon attempts and blackout period 82
Authentication protocols 82
Authentication in Captive Portals 83
Authentication in security policies 83
Enabling authentication protocols 83
Authentication replacement messages 84
Access to the Internet 86
Configuring authentication security policies 86
Identity-based policy 88
NTLM authentication 88
Kerberos authentication for explicit web and transparent web proxy users 89
Enhancements to Kerberos explicit and transparent web proxy 90
Transparent web-proxy Kerberos authentication 96
Certificate authentication 98
Restricting number of concurrent user logons 99
VPN authentication 99
Configuring authentication of SSL VPN users 99
Configuring authentication timeout 99
Configuring authentication of remote IPsec VPN users 100
Configuring authentication of PPTP VPN users and user groups 102
Configuring authentication of L2TP VPN users/user groups 102
Captive portals 104
Introduction to Captive portals 104
Configuring a captive portal 104
Exemption from the captive portal 106
Customizing captive portal pages 106
Changing images in portal messages 110
Modifying text in portal messages 111
Configuring disclaimer page for ethernet interface captive portals 111
Certificate-based authentication 112
What is a security certificate? 112
Certificates overview 113
Certificates and protocols 113
IPsec VPNs and certificates 115
Certificate types on the FortiGate unit 115
Certificate signing 115
BIOS certificate compatibility 116
Managing X.509 certificates 116
Generating a certificate signing request 117
Generating certificates with CA software 119
Obtaining and installing a signed server certificate from an external CA 120
Installing a CA root certificate and CRL to authenticate remote clients 120
ExtendedKeyUsage for x.509 certificates 121
Troubleshooting certificates 121
Online updates to certificates and CRLs 122
Backing up and restoring local certificates 124
Configuring certificate-based authentication 125
Authenticating administrators with security certificates 126
Authenticating SSL VPN users with security certificates 126
Authenticating IPsec VPN users with security certificates 127
Support for per-VDOM certificates 127
Example — Generate a CSR on the FortiGate unit 128
Example — Generate and Import CA certificate with private key pair on OpenSSL 129
Assumptions 130
Generating and importing the CA certificate and private key 130
Example — Generate an SSL certificate in OpenSSL 131
Assumptions 131
Generating a CA signed SSL certificate 131
Generating a self-signed SSL certificate 132
Import the SSL certificate into FortiOS 132
Single Sign-On using a FortiAuthenticator unit 134
User’s view of FortiAuthenticator SSO authentication 134
Users without FortiClient Endpoint Security - SSO widget 134
Users with FortiClient Endpoint Security - FortiClient SSO Mobility Agent 134
Administrator’s view of FortiAuthenticator SSO authentication 134
SSO widget 135
FortiClient SSO Mobility Agent 135
Configuring the FortiAuthenticator unit 135
Configuring the FortiGate unit 136
Adding a FortiAuthenticator unit as an SSO agent 136
Configuring an FSSO user group 136
Configuring security policies 137
Configuring the FortiClient SSO Mobility Agent 137
Viewing SSO authentication events on the FortiGate unit 137
Single Sign-On to Windows AD 138
Introduction to Single Sign-On with Windows AD 138
Configuring Single Sign On to Windows AD 138
Configuring LDAP server access 139
Configuring the LDAP Server as a Single Sign-On server 140
Creating Fortinet Single Sign-On (FSSO) user groups 141
Creating security policies 141
Enabling guest access through FSSO security policies 143
FortiOS FSSO log messages 143
Enabling authentication event logging 143
Testing FSSO 144
Troubleshooting FSSO 145
General troubleshooting tips for FSSO 145
Users on a particular computer (IP address) can not access the network 145
Guest users do not have access to network 145
Agent-based FSSO 147
Introduction to agent-based FSSO 147
Introduction to FSSO agents 148
FSSO for Microsoft Exchange Server 149
FSSO for Windows AD 149
FSSO for Citrix 152
FSSO for Novell eDirectory 152
FSSO security issues 153
FSSO NTLM authentication support 153
NTLM in a multiple domain environment 154
Agent installation 156
Collector agent installation 156
DC agent installation 157
Citrix TS agent installation 159
Novell eDirectory agent installation 160
Updating FSSO agents on Windows AD 160
Configuring the FSSO Collector agent for Windows AD 161
Configuring Windows AD server user groups 161
Configuring Collector agent settings 162
Selecting Domain Controllers and working mode for monitoring 165
Configuring Directory Access settings 166
Configuring the Ignore User List 167
Configuring FortiGate group filters 168
Configuring FSSO ports 169
Configuring alternate user IP address tracking 170
Viewing FSSO component status 170
Configuring the FSSO TS agent for Citrix 172
Configuring FSSO with Novell networks 173
Configuring the eDirectory agent 173
Adding an eDirectory server 175
Configuring a group filter 175
Configuring FSSO Advanced Settings 176
General Settings 176
Citrix/Terminal Server 177
Exchange Server 178
RADIUS Accounting 179
Configuring FSSO on FortiGate units 180
Configuring LDAP server access 180
Specifying your Collector agents or Novell eDirectory agents 182
Creating Fortinet Single Sign-On (FSSO) user groups 183
Creating security policies 184
Enabling guest access through FSSO security policies 185
FortiOS FSSO log messages 186
Enabling authentication event logging 186
Using filters 187
Testing FSSO 188
Troubleshooting FSSO 188
General troubleshooting tips for FSSO 188
Users on a particular computer (IP address) cannot access the network 189
Guest users do not have access to network 189
Can’t find the DCagent service 189
User logon events not received by FSSO Collector agent 190
Mac OS X users can’t access external resources after waking from sleep mode 190
SSO using RADIUS accounting records 191
User’s view of RADIUS SSO authentication 191
Configuration Overview 191
Configuring the RADIUS server 192
Creating the FortiGate RADIUS SSO agent 192
Selecting which RADIUS attributes are used for RSSO 193
Override SSO attribute 194
Configuring logging for RSSO 194
Defining local user groups for RADIUS SSO 194
Creating security policies 195
Example: webfiltering for student and teacher accounts 196
Monitoring authenticated users 199
Monitoring firewall users 199
Monitoring SSL VPN users 199
Monitoring IPsec VPN users 200
Monitoring users Quarantine 200
Examples and Troubleshooting 202
Firewall authentication example 202
Overview 202
Creating a locally-authenticated user account 203
Creating a RADIUS-authenticated user account 203
Creating user groups 204
Defining policy addresses 206
Creating security policies 207
LDAP Dial-in using member-attribute example 208
RADIUS SSO example 210
Assumptions 210
Topology 210
Configuring RADIUS 211
Configuring FortiGate regular and RADIUS SSO security policies 213
Testing 217
Troubleshooting 218
Change log
Change log
2017-10-05 Enhanced Kerberos section with in-depth information on how to configure transparent
web-proxy authentication.
Updated Kerberos section with information on explicit and transparent web proxy
2017-09-25
enhancements (since the release of FortiOS 5.6).
Welcome and thank you for selecting Fortinet products for your network protection.
Authentication servers describes external authentication servers, where a FortiGate unit fits into the topology,
and how to configure a FortiGate unit to work with that type of authentication server.
Users and user groups describes the different types of user accounts and user groups. Authenticated access to
resources is based on user identities and user group membership. Two-factor authentication methods, including
FortiToken, provide additional security.
Managing Guest Access explains how to manage temporary accounts for visitors to your premises.
Configuring authenticated access provides detailed procedures for setting up authenticated access in security
policies and authenticated access to VPNs.
Captive portals describes how to authenticate users through a web page that the FortiGate unit presents in
response to any HTTP request until valid credentials are entered. This can be used for wired or WiFi network
interfaces.
Single Sign-On using a FortiAuthenticator unit describes how to use a FortiAuthenticator unit as an SSO agent
that can integrate with external network authentication systems such as RADIUS and LDAP to gather user logon
information and send it to the FortiGate unit. Users can also log on through a FortiAuthenticator-based web portal
or the FortiClient SSO Mobility Agent.
Single Sign-On to Windows AD describes how to set up Single Sign-On in a Windows AD network by configuring
the FortiGate unit to poll domain controllers for information user logons and user privileges.
Agent-based FSSO describes how to set up Single Sign-On in Windows AD, Citrix, or Novell networks by
installing Fortinet Single Sign On (FSSO) agents on domain controllers. The FortiGate unit receives information
about user logons and allows access to network resources based on user group memberships.
SSO using RADIUS accounting records describes how to set up Single Sign-On in a network that uses RADIUS
authentication. In this configuration, the RADIUS server send RADIUS accounting records to the FortiGate unit
when users log on or off the network. The record includes a user group name that can be used in FortiGate
security policies to determine which resources each user can access.
The following section describes new authentication features added to FortiOS 5.6.0. and 5.6.1.
FortiOS 5.6.1
Note that while you can set the primary RADIUS server's IPv6 address, the source IP
address for communications to the RADIUS server cannot be configured as IPv6.
Syntax
New option under user > setting to allow/forbid SSL renegotiation in firewall authentication
(386595)
A new option auth-ssl-allow-renegotiation is now available under config user setting to
allow/forbid renegotiation. The default value is disable, where a session would be terminated by authd once
renegotiation is detected and this login would be recorded as failure. Other behavior follows regular auth settings.
Syntax
config user setting
set auth-ssl-allow-renegotiation {enable | disable}
end
Reverted default DN format to include spaces. Added a new CLI option ike-dn-format to allow the user to
select either with-space or no-space. Customers using the group-authentication option can select
the ike-dn-format setting to match the format used in their RADIUS user database.
Syntax
config user ldap
edit <name>
set group-filter ?
next
end
l group-filter is none by default, where the process is the same as before.
When group-filter is set, the LDAP filter takes effect for retrieving the group information.
In FortiOS 5.6.1, a Refresh button has been added in the LDAP browser. In the LDAP server dialog page, the
user can delete the DN field to browse the root level tree when clicking the Fetch DN button.
l group-member-check user-attr
For user attribute checking, a new attribute group-search-base is added, which indicates the starting point for
the group search. If the group-search-base is not set, binddn is used as the search base. Removed search-
type when group-member-check is user-attr.
l group-member-check group-object
For group object checking, the group names in user group match rule will be picked up as the group search base. If
there are multiple matching rules, each group name will trigger the ldapsearch query once.
l group-member-check posix-group-object
Changed group-object-search-base to group-search-base for posix-group-object group-
member-check.
To support non-blocking LDAP in fnbamd, we stopped using the openLDAP library in fnbamd, instead using only
liblber. Instead of using openLDAP, fnbamd will create its own event-driven connection with LDAP servers over
LDAP/LDAPS/STARTTLS, make it non-blocking, do CRL checking if necessary, and compose all LDAP requests
using liblber (including bind, unbind, search, password renewal, password query, send request and receive
response, and parse response). The whole process is done in one connection.
This doesn't change any openLDAP implementation but moves some data structure definitions and API
definitions from some internal header files to public header files.
Example
FG100D3G12807101 # diagnose test authserver radius-direct
<server_name or IP> <port no(0 default port)> <secret> <user> <password>
Syntax
config user group
set authtimeout <0 - 43200>
end
FortiOS 5.6.0
A new command has been added under config system ftm-push allowing you to configure the FortiToken
Mobile Push services server IP address and port number. The Push service is provided by Apple (APNS) and
Google (GCM) for iPhone and Android smartphones respectively. This will help to avoid tokens becoming locked
after an already enabled two-factor authentication user has been disabled. In addition, FortiOS supports
FTM Push when FortiAuthenticator is the authentication server.
CLI syntax
config system ftm-push
set server-ip <ip-address>
set server-port [1-65535] Default is 4433.
end
In addition, FTM Push is supported on administrator login and SSL VPN login for both iOS and Android. If an
SSL VPN user authenticates with their token, then logs out and attempts to reauthenticate again within a minute,
a new message will display showing "Please wait x seconds to login again." This replaces a previous
error/permission denied message.
The "x" value will depend on the calculation of how much time is left in the current time step.
CLI syntax
config system interface
edit <name>
set allowaccess ftm
next
end
l Fortinet_CA
l Fortinet_Sub_CA
l Fortinet_Factory
l Fortinet_CA_Backup
l Fortinet_Factory_Backup
When FortiOS connects to FortiGuard, FortiCloud, FortiManager, FortiAnalyzer, FortiSandbox as a client, the
new BIOS certificate Fortinet_Factory will be the default client certificate. When the server returns its certificate
(chain) back, FortiOS looks up the issuer of the server certificate and either keeps client certificate as is or
switches to the old BIOS certificate Fortinet_Factory_Backup. This process occurs in one handshake.
When FortiOS connects to FortiCare, the new BIOS certificate Fortinet_Factory is the only client certificate and
Server Name Indication (SNI) is set. There is no switchover of certificate during SSL handshake.
When FortiOS acts as a server when connected by FortiExtender, FortiSwitch, FortiAP, etc., Fortinet_Factory is
the default server certificate. FortiOS detects SNI in client hello, and if no SNI is found or if the CN in SNI is
different from the CN of Fortinet_CA, it switches to use the old Fortinet_Factory_Backup.
To implement this, a new CLI command has been added under log fortianalyzer setting to allow you
to specify the certificate used to communicate with FortiAnalyzer.
CLI syntax
config log fortianalyzer setting
New commands added to config user ldap to set UPN processing method and filter name
(383561)
Added two new commands to config user ldap allowing you to keep or strip domain string of UPN in the
token as well as the search name for this kind of UPN.
CLI syntax:
config user ldap
set account-key-processing
set account-key-name
end
Password for private key configurable in both GUI and CLI (374593)
FortiOS 5.4.1 introduced a feature that allowed you to export a local certificate and its private key in password
protected p12, and later import them to any device. This option to set password for private key was available only
in the CLI (when requesting a new certificate via SCEP or generating a CSR). This feature is now also
configurable through the GUI.
The new Password for private key option is available under System > Certificates when generating a new
CSR.
Certain RADIUS servers use ISO-8859-1 password encoding instead of others such as UTF-8. In these instances,
the server will fail to authenticate the user, if the user's password is using UTF-8.
CLI syntax
config user radius
edit <example>
set password-encoding <auto | ISO-8859-1>
end
This option will be skipped if the auth-type is neither auto nor pap.
Identifying users and other computers—authentication—is a key part of network security. This section describes
some basic elements and concepts of authentication.
l What is authentication?
l Methods of authentication
l Types of authentication
l User’s view of authentication
l FortiGate administrator’s view of authentication
What is authentication?
Businesses need to authenticate people who have access to company resources. In the physical world this may
be a swipe card to enter the building, or a code to enter a locked door. If a person has this swipe card or code,
they have been authenticated as someone allowed in that building or room.
Authentication is the act of confirming the identity of a person or other entity. In the context of a private computer
network, the identities of users or host computers must be established to ensure that only authorized parties can
access the network. The FortiGate unit enables controlled network access and applies authentication to users of
security policies and VPN clients.
Methods of authentication
FortiGate unit authentication is divided into three basic types: password authentication for people, certificate
authentication for hosts or endpoints, and two-factor authentication for additional security beyond just passwords.
An exception to this is that FortiGate units in an HA cluster and FortiManager units use password authentication.
Password authentication verifies individual user identities, but access to network resources is based on
membership in user groups. For example, a security policy can be configured to permit access only to the
members of one or more user groups. Any user who attempts to access the network through that policy is then
authenticated through a request for their username and password.
Local user accounts work well for a single-FortiGate installation. If your network has multiple FortiGate units that
will use the same accounts, the use of an external authentication server can simplify account configuration and
maintenance.
You can create local user accounts in the web-based manager under User & Device > User Definition. This
page is also used to create accounts where an external authentication server stores and verifies the password.
When you use an external authentication server to authenticate users, the FortiGate unit sends the user’s
entered credentials to the external server. The password is encrypted. The server’s response indicates whether
the supplied credentials are valid or not.
You must configure the FortiGate unit to access the external authentication servers that you want to use. The
configuration includes the parameters that authenticate the FortiGate unit to the authentication server.
l Create user accounts on the FortiGate unit, but instead of storing each user’s password, specify the server used to
authenticate that user. As with accounts that store the password locally, you add these users to appropriate user
groups.
l Add the authentication server to user groups. Any user who has an account on the server can be authenticated and
have the access privileges of the FortiGate user group. Optionally, when an LDAP server is a FortiGate user group
member, you can limit access to users who belong to specific groups defined on the LDAP server.
Certificate-based authentication
An RSA X.509 server certificate is a small file issued by a Certificate Authority (CA) that is installed on a computer
or FortiGate unit to authenticate itself to other devices on the network. When one party on a network presents the
certificate as authentication, the other party can validate that the certificate was issued by the CA. The
identification is therefore as trustworthy as the Certificate Authority (CA) that issued the certificate.
To protect against compromised or misused certificates, CAs can revoke any certificate by adding it to a
Certificate Revocation List (CRL). Certificate status can also be checked online using Online Certificate Status
Protocol (OCSP).
RSA X.509 certificates are based on public-key cryptography, in which there are two keys: the private key and the
public key. Data encrypted with the private key can be decrypted only with the public key and vice versa. As the
names suggest, the private key is never revealed to anyone and the public key can be freely distributed.
Encryption with the recipient’s public key creates a message that only the intended recipient can read. Encryption
with the sender’s private key creates a message whose authenticity is proven because it can be decrypted only
with the sender’s public key.
Server certificates contain a signature string encrypted with the CA’s private key. The CA’s public key is contained
in a CA root certificate. If the signature string can be decrypted with the CA’s public key, the certificate is genuine.
Certificate authorities
A certificate authority can be:
For administrators and for employee VPN users, the local CA based on a software application provides the
required security at low cost. You can generate and distribute certificates as needed. If an employee leaves the
organization, you can simply revoke their certificate.
FortiGate IPsec VPN users can install server and CA certificates according to the instructions for their IPsec VPN
client software. The FortiClient Endpoint Security application, for example, can import and store the certificates
required by VPN connections.
FortiGate units are also compatible with some Public Key Infrastructure systems. For an example of this type of
system, see RSA ACE (SecurID) servers on page 48.
Two-factor authentication
A user can be required to provide both something they know (their username and password combination) and
something they have (certificate or a random token code). Certificates are installed on the user’s computer.
Two-factor authentication is available for PKI users. For more information, see Certificate on page 58.
Another type of two-factor authentication is to use a randomly generated token (multi-digit number) along with
the username and password combination. One method is a FortiToken — a one time passcode (OTP) generator
that generates a unique code every 60 seconds. Others use email or SMS text messaging to deliver the random
token code to the user or administrator.
When one of these methods is configured, the user enters this code at login after the username and password
have been verified. The FortiGate unit verifies the token code after as well as the password and username. For
more information, see Two-factor authentication on page 57
Types of authentication
FortiOS supports two different types of authentication based on your situation and needs.
Security policy authentication is easily applied to all users logging on to a network, or network service. For
example if a group of users on your network such as the accounting department who have access to sensitive
data need to access the Internet, it is a good idea to make sure the user is a valid user and not someone trying to
send company secrets to the Internet. Security policy authentication can be applied to as many or as few users as
needed, and it supports a number of authentication protocols to easily fit with your existing network.
Virtual Private Network (VPN) authentication enables secure communication with hosts located outside the
company network, making them part of the company network while the VPN tunnel is operating. Authentication
applies to the devices at both ends of the VPN and optionally VPN users can be authenticated as well.
The user’s authentication expires if the connection is idle for too long, five minutes by default but that can be
customized.
Security policies are the mechanism for FSSO, NTLM, certificate based, and RADIUS SSO authentication.
FSSO
Fortinet Single Sign on (FSSO) provides seamless authentication support for Microsoft Windows Active Directory
(AD) and Novell eDirectory users in a FortiGate environment.
On a Microsoft Windows or Novell network, users authenticate with the Active Directory or Novell eDirectory at
logon. FSSO provides authentication information to the FortiGate unit so that users automatically get access to
permitted resources. See Introduction to agent-based FSSO on page 147.
NTLM
The NT LAN Manager (NTLM) protocol is used when the MS Windows Active Directory (AD) domain controller
can not be contacted. NTLM is a browser-based method of authentication.
The FSSO software is installed on each AD server and the FortiGate unit is configured to communicate with each
FSSO client. When a user successfully logs into their Windows PC (and is authenticated by the AD Server), the
FSSO client communicates the user's name, IP address, and group login information to the FortiGate unit. The
FortiGate unit sets up a temporary access policy for the user, so when they attempt access through the firewall
they do not need to re-authenticate. This model works well in environments where the FSSO client can be
installed on all AD servers.
In system configurations where it is not possible to install FSSO clients on all AD servers, the FortiGate unit must
be able to query the AD servers to find out if a user has been properly authenticated. This is achieved using the
NTLM messaging features of Active Directory and Internet Explorer.
Even when NTLM authentication is used, the user is not asked again for their username and password. Internet
Explorer stores the user’s credentials and the FortiGate unit uses NTLM messaging to validate them in the
Windows AD environment.
Note that if the authentication reaches the timeout period, the NTLM message exchange restarts. For more
information on NTLM, see NTLM authentication on page 88 and FSSO NTLM authentication support on page
153.
Certificates
Certificates can be used as part of a policy. All users being authenticated against the policy are required to have
the proper certificate. See Certificate-based authentication on page 112
RADIUS SSO
RADIUS Single Sign-On (RSSO) is a remote authentication method that does not require any local users to be
configured, and relies on RADIUS Start records to provide the FortiGate unit with authentication information.
That information identifies the user and user group, which is then matched using a security policy. See SSO using
RADIUS accounting records on page 191.
VPN authentication
Authentication involves authenticating the user. In IPsec VPNs authenticating the user is optional, but
authentication of the peer device is required.
The three ways to authenticate VPN peers are with a preshared key, RSA X.509 certificate, or a specific peer ID
value.
The simplest way for IPsec VPN peers to authenticate each other is through the use of a preshared key, also
called a shared secret. The preshared key is a text string used to encrypt the data exchanges that establish the
VPN tunnel. The preshared key must be six or more characters. The VPN tunnel cannot be established if the two
peers do not use the same key. The disadvantage of preshared key authentication is that it can be difficult to
securely distribute and update the preshared keys.
RSA X.509 certificates are a better way for VPN peers to authenticate each other. Each peer offers a certificate
signed by a Certificate Authority (CA) which the other peer can validate with the appropriate CA root certificate.
For more information about certificates, see Certificate-based authentication on page 112.
You can supplement either preshared key or certificate authentication by requiring the other peer to provide a
specific peer ID value. The peer ID is a text string configured on the peer device. On a FortiGate peer or
FortiClient Endpoint Security peer, the peer ID provided to the remote peer is called the Local ID.
It is possible to have an IPsec VPN in which remote peer devices authenticate using a common preshared key or
a certificate, but there is no attempt to identify the user at the remote peer. To add user authentication, you can
do one of the following:
SSL VPN access requires an SSL VPN security policy that permits access to members of your user group.
“Single Sign-On” means that users logged on to a computer network are authenticated for access to network
resources through the FortiGate unit without having to enter their username and password again. FortiGate units
directly provide Single Sign On capability for:
In combination with a FortiAuthenticator unit, the FortiGate unit can provide Single Sign-On capability that
integrates multiple external network authentication systems such as Windows Active Directory, Novell e-
Directory, RADIUS and LDAP. The FortiAuthenticator unit gathers user logon information from all of these
sources and sends it to the FortiGate unit.
Through the SSO feature, the FortiGate unit knows the username, IP address, and external user groups to which
the user belongs. When the user tries to access network resources, the FortiGate unit selects the appropriate
security policy for the destination. If the user belongs to one of the permitted user groups, the connection is
allowed.
From the user’s point of view, they see a request for authentication when they try to access a protected resource,
such as an FTP repository of intellectual property or simply access a website on the Internet. The way the request
is presented to the user depends on the method of access to that resource.
The user types a username and password and then selects Continue or Login. If the credentials are incorrect,
the authentication screen is redisplayed with blank fields so that the user can try again. When the user enters
valid credentials, access is granted to the required resource. In some cases, if a user tries to authenticate several
times without success, a message appears, such as: “Too many bad login attempts. Please try again in a few
minutes.” This indicates the user is locked out for a period of time. This prevents automated brute force password
hacking attempts. The administrator can customize these settings if required.
After a defined period of user inactivity (the authentication timeout, defined by the
FortiGate administrator), the user’s access expires. The default is 5 minutes. To
access the resource, the user will have to authenticate again.
FortiClient can store the username and password for a VPN as part of the configuration for the VPN connection
and pass them to the FortiGate unit as needed. Or, FortiClient can request the username and password from the
user when the FortiGate unit requests them.
SSL VPN is a form of VPN that can be used with a standard Web browser. There are two modes of SSL VPN
operation (supported in NAT/Route mode only):
After a defined period of user inactivity on the VPN connection (the idle timeout,
defined by the FortiGate administrator), the user’s access expires. The default is 30
minutes. To access the resource, the user will have to authenticate again.
Authentication is based on user groups. The FortiGate administrator configures authentication for security
policies and VPN tunnels by specifying the user groups whose members can use the resource. Some planning is
required to determine how many different user groups need to be created. Individual user accounts can belong to
multiple groups, making allocation of user privileges very flexible.
l a user whose username and password are stored on the FortiGate unit
l a user whose name is stored on the FortiGate unit and whose password is stored on a remote or external
authentication server
l a remote or external authentication server with a database that contains the username and password of each
person who is permitted access
The general process of setting up authentication is as follows:
Go to User & Device > Authentication Settings to configure authentication timeout, protocol support, and
authentication certificates.
When user authentication is enabled within a security policy, the authentication challenge is normally issued for
any of the four protocols (depending on the connection protocol):
When you enable user authentication within a security policy, the security policy user will be challenged to
authenticate. For user ID and password authentication, users must provide their user names and passwords. For
certificate authentication (HTTPS or HTTP redirected to HTTPS only), you can install customized certificates on
the unit and the users can also have customized certificates installed on their browsers. Otherwise, users will see
a warning message and have to accept a default Fortinet certificate.
Authentication Timeout Enter a length of time in minutes, from 1 to 4320 (72 hours). Authentication
timeout controls how long an authenticated firewall connection can be idle
before the user must authenticate again. The default value is 5.
Protocol Support Select the protocols to challenge during firewall user authentication.
Certificate If using HTTPS protocol support, select the local certificate to use for
authentication. Available only if HTTPS protocol support is selected.
FortiGate units support the use of external authentication servers. An authentication server can provide password
checking for selected FortiGate users or it can be added as a member of a FortiGate user group.
If you are going to use authentication servers, you must configure the servers before you configure FortiGate
users or user groups that require them.
Mac OS and iOS devices, including iPhones and iPads, can perform user
authentication with FortiOS units using RADIUS servers, but not with LDAP or
TACACS+ servers.
l FortiAuthenticator servers
l RADIUS servers
l LDAP servers
l TACACS+ servers
l POP3 servers
l SSO servers
l RSA ACE (SecurID) servers
FortiAuthenticator servers
FortiAuthenticator is an Authentication, Authorization, and Accounting (AAA) server, that includes a RADIUS
server, an LDAP server, and can replace the FSSO Collector Agent on a Windows AD network. Multiple FortiGate
units can use a single FortiAuthenticator for FSSO, remote authentication, and FortiToken management.
RADIUS servers
Remote Authentication and Dial-in User Service (RADIUS) is a broadly supported client-server protocol that
provides centralized authentication, authorization, and accounting functions. RADIUS clients are built into
gateways that allow access to networks such as Virtual Private Network servers, Network Access Servers (NAS),
as well as network switches and firewalls that use authentication. FortiGate units fall into the last category.
RADIUS servers use UDP packets to communicate with the RADIUS clients on the network to authenticate users
before allowing them access to the network, to authorize access to resources by appropriate users, and to
account or bill for those resources that are used. RADIUS servers are currently defined by RFC 2865 (RADIUS)
and RFC 2866 (Accounting), and listen on either UDP ports 1812 (authentication) and 1813 (accounting) or ports
1645 (authentication) and 1646 (accounting) requests. RADIUS servers exist for all major operating systems.
You must configure the RADIUS server to accept the FortiGate unit as a client. FortiGate units use the
authentication and accounting functions of the RADIUS server.
FortiOS does not accept all characters from auto generated keys from MS Windows
2008. These keys are very long and as a result RADIUS authentication will not work.
Maximum key length for MS Windows 2008 is 128 bytes. In older versions of FSAE, it
was 40 bytes.
The RADIUS server uses a “shared secret” key along with MD5 hashing to encrypt information passed between
RADIUS servers and clients, including the FortiGate unit. Typically only user credentials are encrypted. Additional
security can be configured through IPsec tunnels by placing the RADIUS server behind another VPN gateway.
RADIUS AVP
Name Description
Attribute type
1 Acct-Session-ID Unique number assigned to each start and stop record to make 44
it easy to match them, and to eliminate duplicate records.
Number of octets received from the port over the course of this
service being provided.
6 Acct-Input-Octets 42
Used to charge the user for the amount of traffic they used.
7 Acct-Output-Octets Number of octets sent to the port while delivering this service. 43
Used to charge the user for the amount of traffic they used.
9 Called-Station-Id Used to send the telephone number the user called as part of 30
the Access-Request packet.
11 Event-Timestamp Records the time that the event occurred on the NAS. The 55
timestamp is measured in seconds since January 1, 1970
00:00 UTC.
The following table describes the supported authentication events and the RADIUS attributes that are sent in the
RADIUS accounting message.
RADIUS Attributes
Authentication Method 1 2 3 4 5 6 7
Web X X X X
SSL-VPN X X X X X
http://<redirectserver>/index2.php/?login&post=http://192.168.200.1:1000/fgtau
th&magic=02050f889bc21644&usermac=54:26:96:16:a2:45&apmac=00:09:0f:b9:f4:c0&ap
ip=127.0.0.1&userip=192.168.200.2
http://FGT_IP_addr:1000/fgtauth
The magic text data, provided in the initial FortiGate request to the web server, contains the username, password
paramaters:
magic=00050c839182f095&username=<username>&password=<password>
Vendor-specific attributes
Vendor specific attributes (VSA) are the method RADIUS servers and client companies use to extend the basic
functionality of RADIUS. Some major vendors, such as Microsoft, have published their VSAs, however many do
not.
In order to support vendor-specific attributes (VSA), the RADIUS server requires a dictionary to define which VSAs
to support. This dictionary is typically supplied by the client or server vendor.
The FortiGate unit RADIUS VSA dictionary is supplied by Fortinet and is available through the Fortinet
Knowledge Base (http://kb.forticare.com) or through Technical Support. Fortinet’s dictionary for FortiOS 4.0 and
up is configured this way:
##
Fortinet’s VSA’s
#
VENDOR fortinet 12356
BEGIN-VENDOR fortinet
ATTRIBUTE Fortinet-Group-Name 1 string
ATTRIBUTE Fortinet-Client-IP-Address 2 ipaddr
ATTRIBUTE Fortinet-Vdom-Name 3 string
ATTRIBUTE Fortinet-Client-IPv6-Address 4 octets
ATTRIBUTE Fortinet-Interface-Name 5 string
ATTRIBUTE Fortinet-Access-Profile 6 string
#
# Integer Translations
#
END-VENDOR Fortinet
Note that using the Fortinet-Vdom-Name, users can be tied to a specific VDOM on the FortiGate unit. See the
documentation provided with your RADIUS server for configuration details.
User, user group, and captive portal authentication supports RADIUS CoA, when the back end authentication
server is RADIUS. The main use case of this feature is with external captive portal, where it can be used to
disconnect hotspot users when their time, credit, or bandwidth has been used up.
1. Set the name of the FortiAP connected to the FortiGate as a location identifier.
config system global
set alias <name>
There are three main parts to RBAC: role assignment, role authorization, and transaction authorization. Role
assignment is accomplished when someone in an organization is assigned a specific role by a manager or HR.
Role authorization is accomplished when a network administrator creates that user’s RADIUS account and
assigns them to the required groups for that role. Transaction authorization occurs when that user logs on and
authenticates before performing a task.
RBAC is enforced when FortiOS network users are remotely authenticated via a RADIUS server. For users to
authenticate, a security policy must be matched. That policy only matches a specific group of users. If VDOMs
are enabled, the matched group will be limited to a specific VDOM. Using this method network administrators can
separate users into groups that match resources, protocols, or VDOMs. It is even possible to limit users to
specific FortiGate units if the RADIUS servers serve multiple FortiOS units.
For more information on security policies, see Authentication in security policies on page 83.
CLI syntax
config user radius
edit <example>
set password-encoding <auto | ISO-8859-1>
end
This option will be skipped if the auth-type is neither auto nor pap.
A maximum of 10 remote RADIUS servers can be configured on the FortiGate unit. One or more servers must be
configured on FortiGate before remote users can be configured. To configure remote users, see Local and
remote users on page 54.
On the FortiGate unit, the default port for RADIUS traffic is 1812. Some RADIUS servers use port 1645. If this is
the case with your server, you can either:
l Re-configure the RADIUS server to use port 1812. See your RADIUS server documentation for more information on
this procedure.
or
l Change the FortiGate unit default RADIUS port to 1645 using the CLI:
config system global
set radius-port 1645
end
One wildcard admin account can be added to the FortiGate unit when using RADIUS authentication. This uses
the wildcard character to allow multiple admin accounts on RADIUS to use a single account on the FortiGate unit.
See Example — wildcard admin accounts - CLI on page 41.
Primary Server Name/IP Enter the domain name (such as fgt.exmaple.com) or the IP address of the
RADIUS server.
Primary Server Secret Enter the server secret key, such as radiusSecret. This can be a maximum
of 16 characters long.
Secondary Server Name/IP Optionally enter the domain name (such as fgt.exmaple.com) or the IP
address of the secondary RADIUS server.
Secondary Server Secret Optionally, enter the secondary server secret key, such as radiusSecret2.
This can be a maximum of 16 characters long.
Authentication Scheme If you know the RADIUS server uses a specific authentication protocol,
select it from the list. Otherwise select Use Default Authentication
Scheme. The Default option will usually work.
NAS IP/ Called Enter the IP address to be used as an attribute in RADIUS access requests.
Station ID
NAS-IP-Address is RADIUS setting or IP address of FortiGate interface
used to talk to RADIUS server, if not configured.
Include in every User When enabled this RADIUS server will automatically be included in all user
Group groups. This is useful if all users will be authenticating with the remote
RADIUS server.
For MAC OS and iOS devices to authenticate, you must use MS-CHAP-v2
authentication. In the CLI, the command is set auth-type ms_chap_v2.
3. Select OK.
For more information about RADIUS server options, refer to the FortiGate CLI Reference.
Troubleshooting RADIUS
To test the connection to the RADIUS server use the following command:
diagnose test authserver radius-direct <server_name or IP> <port number> <secret>
For the port number, enter -1 to use the default port. Otherwise enter the port number to check.
Test results show RADIUS server reachability, NAS client rejection, and invalid User/Password. Test also shows
RADIUS Attributes returned from the RADIUS server.
LDAP servers
Lightweight Directory Access Protocol (LDAP) is an Internet protocol used to maintain authentication data that
may include departments, people, groups of people, passwords, email addresses, and printers. LDAP consists of
a data-representation scheme, a set of defined operations, and a request/response network.
The scale of LDAP servers range from big public servers such as BigFoot and Infospace, to large organizational
servers at universities and corporations, to small LDAP servers for workgroups that may be using OpenLDAP.
This document focuses on the institutional and workgroup applications of LDAP.
When LDAP is configured and a user is required to authenticate the general steps are:
Binding
Binding is the step where the LDAP server authenticates the user. If the user is successfully authenticated,
binding allows the user access to the LDAP server based on that user’s permissions.
The FortiGate unit can be configured to use one of three types of binding:
If your LDAP server requires authentication to perform searches, use the regular type and provide values for
username and password.
Supported versions
The FortiGate unit supports LDAP protocol functionality defined in RFC 2251: Lightweight Directory Access
Protocol v3, for looking up and validating user names and passwords. FortiGate LDAP supports all LDAP servers
compliant with LDAP v3, including FortiAuthenticator. In addition, FortiGate LDAP supports LDAP over SSL/TLS,
which can be configured only in the CLI.
FortiGate LDAP does not support proprietary functionality, such as notification of password expiration, which is
available from some LDAP servers. FortiGate LDAP does not supply information to the user about why
authentication failed.
LDAP user authentication is supported for PPTP, L2TP, IPsec VPN, and firewall
authentication.
However, with PPTP, L2TP, and IPsec VPN, PAP (Packet Authentication Protocol) is
supported, while CHAP (Challenge Handshake Authentication Protocol) is not.
The top of the hierarchy is the organization itself. Usually this is defined as Domain Component (DC), a DNS
domain. If the name contains a dot, such as example.com, it is written as two parts separated by a comma:
dc=example,dc=com.
In this example, Common Name (CN) identifiers reside at the Organization Unit (OU) level, just below DC. The
Distinguished Name (DN) is ou=People,dc=example,dc=com.
In addition to the DN, the FortiGate unit needs an identifier for the individual person. Although the FortiGate unit
GUI calls this the Common Name (CN), the identifier you use is not necessarily CN. On some servers, CN is the
full name of a person. It might be more convenient to use the same identifier used on the local computer network.
In this example, User ID (UID) is used.
The output is lengthy, but the information you need is in the first few lines:
version: 2
#
# filter: (objectclass=*)
# requesting: ALL
dn: dc=example,dc=com
dc: example
objectClass: top
objectClass: domain
dn: ou=People,dc=example,dc=com
ou: People
objectClass: top
objectClass: organizationalUnit
...
dn: uid=tbrown,ou=People,dc=example,dc=com
uid: tbrown
cn: Tom Brown
In the output above, you can see tbrown (uid) and Tom Brown(cn). Also note the dn is ou=People,
dc=example, dc=com.
One or more servers must be configured on FortiGate before remote users can be configured. To configure
remote users, see Local and remote users on page 54.
To verify your Distinguished Name field is correct, you can select the Test button. If
your DN field entry is valid, you will see the part of the LDAP database it defines. If
your DN field entry is not valid, it will display an error message and return no
information.
For detailed information about configuration options for LDAP servers, see the Online Help on your FortiGate unit
or the FortiGate CLI Reference.
password-expiry-warning allows FortiOS to detect from the LDAP server when a password is expiring or
has expired using server controls or error codes.
password-renewal allows FortiOS to perform the online LDAP password renewal operations the LDAP server
expects.
On an OpenLDAP server, when a user attempts to logon with an expired password they are allowed to logon but
only to change their password.
When changing passwords on a Windows AD system, the connection must be SSL-protected.
CLI syntax:
config user ldap
set account-key-processing
set account-key-name
end
To see the users within the LDAP Server user group for the selected Distinguished Name, expand the
Distinguished Name in the LDAP Distinguished Name Query tree.
Non-blocking LDAP authentication
To support non-blocking LDAP authentication, fnbamd will create its own event-driven connection with LDAP
servers over LDAP/LDAPS/STARTTLS, make it non-blocking, do CRL checking if necessary, and compose all
LDAP requests using liblber (including bind, unbind, search, password renewal, password query, send request
and receive response, and parse response). The whole process is done in one connection.
This doesn't change any openLDAP implementation but moves some data structure definitions and API
definitions from some internal header files to public header files.
The initial benefit of wildcard admin accounts is fast configuration of the FortiGate unit’s administration account
to work with your LDAP network. The many to one ratio saves on effort, and potential errors.
The ongoing benefit is that as long as the users on the LDAP system belong to that group, and the test admin
user settings don’t change on the FortiGate unit, no other work is required. This point is important as it can help
avoid system updates or changes that would otherwise require changes to the LDAP administrator account
configuration. Even if a user is added to or removed from the LDAP group, no changes are required on the
FortiGate unit.
Two potential issues with wildcard admin accounts are that multiple users may be logged on to the same account
at the same time. This becomes an issue if they are changing the same information at the same time. The other
potential issue is that security is reduced because multiple people have login access for the same account. If
each user was assigned their own account, a hijacking of one account would not affect the other users.
Note that wildcard admin configuration also applies to RADIUS. When configuring for RADIUS, configure the
RADIUS server, and RADIUS user group instead of LDAP. When using web-based management, wildcard admin
is the only type of remote administrator account that does not require you to enter a password on account
creation. That password is normally used when the remote authentication server is unavailable during
authentication.
In this example, default values are used where possible. If a specific value is not mentioned, it is set to its default
value.
The dn used here is as an example only. On your network use your own domain name.
To configure the user group and add the LDAP server - CLI:
config user group
edit "ldap_grp"
set member "ldap"
config match
edit 1
set server-name "ldap_server"
set group-name "CN=GRP,OU=training,DC=example,DC=COM"
next
end
next
end
For troubleshooting, test that the admin account is operational, and see Troubleshooting LDAP on page 44.
In AD, the “Allow Dial-In” property is activated in the user properties, and this sets the msNPAllowDialin
attribute to “TRUE”.
This same procedure can be used for other member attributes, as your system requires.
Before configuring the FortiGate unit, the AD server must be configured and have the msNPAllowDialin
attribute set to “TRUE” for the users in question. If not, those users will not be able to properly authenticate.
The dn used here is as an example only. On your network use your own domain name.
Troubleshooting LDAP
The examples in this section use the values from the previous example.
'ldap_server' is not a valid ldap server name — an LDAP server by that name has not been
configured on the FortiGate unit, check your spelling.
authenticate 'netAdmin' against 'ldap_server' failed! — the user netAdmin does not
exist on ldap_server, check your spelling of both the user and sever and ensure the user has been configured
on the FortiGate unit.
Ensure the “Allow Dial-in” attribute is still set to “TRUE” and run the following CLI command. fnbamd is the
Fortinet non-blocking authentication daemon.
FGT# diag debug enable
FGT# diag debug reset
FGT# diag debug application fnbamd –1
FGT# diag debug enable
get_member_of_groups-val[0]='TRUE'
fnbamd_ldap_get_result-Auth accepted
fnbamd_ldap_get_result-Going to DONE state res=0
fnbamd_auth_poll_ldap-Result for ldap svr 192.168.201.3 is SUCCESS
fnbamd_auth_poll_ldap-Passed group matching
If the “Allow Dial-in” attribute is not set but it is expected, the last line of the above output will instead be:
fnbamd_auth_poll_ldap-Failed group matching
TACACS+ servers
When users connect to their corporate network remotely, they do so through a remote access server. As remote
access technology has evolved, the need for security when accessing networks has become increasingly
important. This need can be filled using a Terminal Access Controller Access-Control System (TACACS+) server.
TACACS+ is a remote authentication protocol that provides access control for routers, network access servers,
and other networked computing devices via one or more centralized servers. TACACS+ allows a client to accept a
username and password and send a query to a TACACS+ authentication server. The server host determines
whether to accept or deny the request and sends a response back that allows or denies the user access to the
network.
TACACS+ offers fully encrypted packet bodies, and supports both IP and AppleTalk protocols. TACACS+ uses
TCP port 49, which is seen as more reliable than RADIUS’s UDP protocol.
There are several different authentication protocols that TACACS+ can use during the authentication process:
Authentication protocols
Protocol Definition
default The default protocol configuration, Auto, uses PAP, MS-CHAP, and CHAP, in that
order.
POP3 servers
FortiOS can authenticate users who have accounts on POP3 or POP3s email servers. POP3 authentication can
be configured only in the CLI.
SSO servers
Novell and Microsoft Windows networks provide user authentication based on directory services: eDirectory for
Novell, Active Directory for Windows. Users can log on at any computer in the domain and have access to
resources as defined in their user account. The Fortinet Single Sign On (FSSO) agent enables FortiGate units to
authenticate these network users for security policy or VPN access without asking them again for their username
and password.
When a user logs in to the Windows or Novell domain, the FSSO agent sends to the FortiGate unit the user’s IP
address and the names of the user groups to which the user belongs. The FortiGate unit uses this information to
maintain a copy of the domain controller user group database. Because the domain controller authenticates
users, the FortiGate unit does not perform authentication. It recognizes group members by their IP address.
In the FortiOS FSSO configuration, you specify the server where the FSSO Collector agent is installed. The
Collector agent retrieves the names of the Novell or Active Directory user groups from the domain controllers on
the domains, and then the FortiGate unit gets them from the Collector agent. You cannot use these groups
directly. You must define FSSO type user groups on your FortiGate unit and then add the Novell or Active
Directory user groups to them. The FSSO user groups that you created are used in security policies and VPN
configurations to provide access to different services and resources.
FortiAuthenticator servers can replace the Collector agent when FSSO is using polling mode. The benefits of this
is that FortiAuthenticator is a stand-alone server that has the necessary FSSO software pre-installed. For more
information, see the FortiAuthenticator Administration Guide.
Lists all the collector agents’ lists that you have configured. On this page, you can create, edit or delete FSSO
agents. There are different types of FSSO agents, each with its own settings.
You can create a redundant configuration on your unit if you install a collector agent on
two or more domain controllers. If the current (or first) collector agent fails, the Fortinet
unit switches to the next one in its list of up to five collector agents.
Create New Creates a new agent. When you select Create New, you are automatically redirected
to the New page.
To remove multiple entries from the list, for each servers you want removed, select the
check box and then select Delete.
To remove all agents from the list, on the FSSO Agent page, select the check box at
the top of the check box column and then select Delete.
Password Enter the password for the account used to access the DC.
LDAP Server Select the check box and select an LDAP server to access the Directory Service.
Enable Polling Enable to allow the FortiGate unit to poll this DC.
Users/Groups A list of user and user group names retrieved from the DC.
Primary Agent
IP/Name
Enter the IP address or name of the Directory Service server where this SSO agent is
installed. The maximum number of characters is 63.
Secondary Agent
IP/Name
Password Enter the password for the collector agent. This is required only if you configured your
Fortinet Single Sign On Agent collector agent to require authenticated access.
LDAP Server Select the check box and select an LDAP server to access the Directory Service.
Users/Groups A list of user and user group names retrieved from the server.
SecurID is a two-factor system that uses one-time password (OTP) authentication. It is produced by the company
RSA. This system includes portable tokens carried by users, an RSA ACE/Server, and an Agent Host. In our
configuration, the FortiGate unit is the Agent Host.
Components
When using SecurID, users carry a small device or “token” that generates and displays a pseudo-random
password. According to RSA, each SecurID authenticator token has a unique 64-bit symmetric key that is
combined with a powerful algorithm to generate a new code every 60 seconds. The token is time-synchronized
with the SecurID RSA ACE/Server.
The RSA ACE/Server is the management component of the SecurID system. It stores and validates the
information about the SecurID tokens allowed on your network. Alternately the server could be an RSA SecurID
130 Appliance.
The Agent Host is the server on your network, in this case it is the FortiGate unit, that intercepts user logon
attempts. The Agent Host gathers the user ID and password entered from their SecurID token, and sends that
information to the RSA ACE/Server to be validated. If valid, a reply comes back indicating it is a valid logon and
the FortiGate unit allows the user access to the network resources specified in the associated security policy.
l to configure the RSA server and the RADIUS server to work with each other (see RSA server documentation)
l to configure the RSA SecurID 130 Appliance
or
l to configure the FortiGate unit as an Agent Host on the RSA ACE/Server
l to configure the FortiGate unit to use the RADIUS server
l to create a SecurID user group
l to configure a security policy with SecurID authentication
The following instructions are based on RSA ACE/Server version 5.1, or RSA SecurID 130 Appliance, and assume
that you have successfully completed all the external RSA and RADIUS server configuration steps listed above.
For this example, the RSA server is on the internal network, with an IP address of 192.128.100.100. The
FortiGate unit internal interface address is 192.168.100.3, RADIUS shared secret is fortinet123, RADIUS server
is at IP address 192.168.100.102.
IP Address 192.168.100.3
1. On the RSA ACE/Server computer, go to Start > Programs > RSA ACE/Server, and then Database
Administration - Host Mode.
2. On the Agent Host menu, select Add Agent Host.
3. Enter and save the following information.
Name FortiGate
Secondary Nodes Optionally enter other IP addresses that resolve to the FortiGate unit.
Name RSA
Name RSA_group
Type Firewall
To test this configuration, on your FortiGate unit use the CLI command:
diagnose test authserver radius RSA auto wloman 111111111
The series of 1s is the one time password that your RSA SecurID token generates and you enter.
l Security policy
l IPsec VPN XAuth
l PPTP VPN
l SSL VPN
The following sections assume the SecurID user group is called securIDgrp and has already been configured.
Unless otherwise states, default values are used.
Security policy
To use SecurID in a security policy, you must include the SecurID user group in a security policy. This procedure
will create a security policy that allows HTTP, FTP, and POP3 traffic from the internal interface to wan1. If
these interfaces are not available on your FortiGate unit, substitute other similar interfaces.
Schedule always
Action ACCEPT
NAT On
Shared Shaper On, if you want to either limit traffic or guarantee minimum bandwidth for
traffic that uses the SecurID security policy. Use the default shaper
guarantee-100kbps.
Log Allowed Traffic On, if you want to generate usage reports on traffic authenticated with this
policy.
4. Select OK.
The SecurID security policy is configured.
For more detail on configuring security policies, see the FortiOS Handbook FortiGate Fundamentals guide.
When creating an IPsec VPN using the wizard, under VPN > IPsec Wizard, select the SecurID User Group on
the Authentication page. Members of the SecurID group are required to enter their SecureID code to
authenticate.
PPTP VPN
PPTP VPN is configured in the CLI. In the PPTP configuration (config vpn pptp), set usrgrp to the
SecurID user group.
SSL VPN
You need to map the SecurID user group to the portal that will serve SecurID users and include the SecurID user
group in the Source User(s) field in the security policy.
1. Go to VPN > SSL-VPN Settings.
2. In Authentication/Portal Mapping, select Create New.
3. Enter
Users/Groups securIDgrp
4. Select OK.
FortiGate authentication controls system access by user group. By assigning individual users to the appropriate
user groups you can control each user’s access to network resources. The members of user groups are user
accounts, of which there are several types. Local users and peer users are defined on the FortiGate unit. User
accounts can also be defined on remote authentication servers.
This section describes how to configure local users and peer users and then how to configure user groups. For
information about configuration of authentication servers see Authentication servers on page 29.
l Users
l User groups
Users
A user is a user account consisting of username, password, and in some cases other information, configured on
the FortiGate unit or on an external authentication server. Users can access resources that require authentication
only if they are members of an allowed user group. There are several different types of user accounts with slightly
different methods of authentication:
Local user The username and password must match a user account stored on the FortiGate unit.
Authentication by FortiGate security policy.
The username must match a user account stored on the FortiGate unit and the
Remote user username and password must match a user account stored on the remote
authentication server. FortiOS supports LDAP, RADIUS, and TACACS+ servers.
Authentication A FortiGate user group can include user accounts or groups that exist on a remote
server user authentication server.
With Fortinet Single Sign On (FSSO), users on a Microsoft Windows or Novell network
can use their network authentication to access resources through the FortiGate unit.
FSSO user
Access is controlled through FSSO user groups which contain Windows or Novell user
groups as their members.
PKI or Peer user A Public Key Infrastructure (PKI) or peer user is a digital certificate holder who
authenticates using a client certificate. No password is required, unless two-factor
authentication is enabled.
IM users are not authenticated. The FortiGate unit can allow or block each IM user
IM Users name from accessing the IM protocols. A global policy for each IM protocol governs
access to these protocols by unknown users.
Guest Users Guest user accounts are temporary. The account expires after a selected period of
time.
Create New Creates a new user account. When you select Create New, you are automatically
redirected to the User Creation Wizard.
Modifies a user’s account settings. When you select Edit, you are automatically
Edit User
redirected to the Edit User page.
Delete Removes a user from the list. Removing the user name removes the authentication
configured for the user.
The Delete icon is not available if the user belongs to a user group.
To remove multiple local user accounts from within the list, on the User page, in each
of the rows of user accounts you want removed, select the check box and then select
Delete.
To remove all local user accounts from the list, on the User page, select the check box
in the check box column and then select Delete.
The user name. For a remote user, this username must be identical to the username
User Name
on the authentication server.
Type Local indicates a local user authenticated on the FortiGate unit. For remote users, the
type of authentication server is shown: LDAP, RADIUS, or TACACS+.
Two-factor
Indicates whether two-factor authentication is configured for the user.
Authentication
Ref. Displays the number of times this object is referenced by other objects. Select the
number to open the Object Usage window and view the list of referring objects. The
list is grouped into expandable categories, such as Firewall Policy. Numbers of objects
are shown in parentheses.
To view more information about the referring object, use the icons:
l View the list page for these objects – available for object categories. Goes
to the page where the object is listed. For example, if the category is User
Groups, opens User Groups list.
l Edit this object – opens the object for editing.
l View the details for this object – displays current settings for the object.
Local User Select to authenticate this user using a password stored on the FortiGate
unit.
Remote RADIUS User To authenticate this user using a password stored on an authentication
Remote TACACS+ User server, select the type of server and then select the server from the list. You
Remote LDAP User can select only a server that has already been added to the FortiGate unit
configuration.
Two-factor Authentication Select to enable two-factor authentication. Then select the Token
(FortiToken or FortiToken Mobile) for this user account. See Associating
FortiTokens with accounts on page 63.
User Group Select the user groups to which this user belongs.
6. Select Create.
To create a user with SMS two-factor authentication using FortiGuard messaging Service - CLI example:
config user local
edit user6
set type password
set passwd 3ww_pjt68dw
set two_factor sms
set sms-server fortiguard
set sms-phone 1365984521
end
Removing users
Best practices dictate that when a user account is no longer in use, it should be deleted. Removing local and
remote users from FortiOS involve the same steps.
If the user account is referenced by any configuration objects, those references must be removed before the user
can be deleted. See Removing references to users on page 57.
l a peer username
l the text from the subject field of the user’s certificate, or the name of the CA certificate used to validate the user’s
certificate
There are other configuration settings that can be added or modified for PKI authentication. For example, you
can configure the use of an LDAP server to check access rights for client certificates. For information about the
detailed PKI configuration settings, see the FortiGate CLI Reference.
Two-factor authentication
The standard logon requires a username and password. This is one factor authentication—your password is one
piece of information you need to know to gain access to the system.
Two factor authentication adds the requirement for another piece of information for your logon. Generally the two
factors are something you know (password) and something you have (certificate, token, etc.). This makes it
harder for a hacker to steal your logon information. For example if you have a FortiToken device, the hacker
would need to both use it and know your password to gain entry to your account.
Two-factor authentication is available on both user and admin accounts. But before you enable two-factor
authentication on an administrator account, you need to ensure you have a second administrator account
configured to guarantee administrator access to the FortiGate unit if you are unable to authenticate on the main
admin account for some reason.
l Certificate
l Email
l SMS
l FortiToken
Certificate
You can increase security by requiring both certificate and password authentication for PKI users. Certificates are
installed on the user’s computer. Requiring a password also protects against unauthorized use of that computer.
Optionally peer users can enter the code from their FortiToken instead of the certificate.
Email
Two-factor email authentication sends a randomly generated six digit numeric code to the specified email
address. Enter that code when prompted at logon. This token code is valid for 60 seconds. If you enter this code
after that time,it will not be accepted.
A benefit is that you do not require mobile service to authenticate. However, a potential issue is if your email
server does not deliver the email before the 60 second life of the token expires.
The code will be generated and emailed at the time of logon, so you must have email access at that time to be
able to receive the code.
1. Go to System > Advanced and enable Use Custom Eamil Server under Email Service.
2. Enter SMTP Server and Default Reply To address.
3. If applicable, enable Authentication and enter the SMTP User and Password to use.
4. Select a Security Mode, options are: None, SMTPS or STARTTLS.
5. Enter the Port number, the default is 25.
6. Select Apply.
1. To modify an administrator account, go to System > Administrators. To modify a user account go to User
& Device > User Definition.
2. Edit the user account.
3. Enable and enter the user’s Email Address.
4. Select Enable Two-factor Authentication.
5. Select Email based two-factor authentication.
6. Select OK.
SMS
SMS two-factor authentication sends the token code in an SMS text message to the mobile device indicated
when this user attempts to logon. This token code is valid for 60 seconds. If you enter this code after that time, it
will not be accepted. Enter this code when prompted at logon to be authenticated.
SMS two-factor authentication has the benefit that you do not require email service before logging on. A potential
issue is if the mobile service provider does not send the SMS text message before the 60 second life of the token
expires.
FortiGuard Messaging Service include four SMS Messages at no cost. If you need more, you should acquire a
license through support.fortinet.com or via customer service.
If you do not use the FortiGuard Messaging Service, you need to configure an SMS service.
1. To modify an:
If you have problems receiving the token codes via SMS messaging, contact your mobile provider to ensure you
are using the correct phone number format to receive text messages and that your current mobile plan allows text
messages.
FortiToken
FortiToken is a disconnected one-time password (OTP) generator. It is a small physical device with a button that
when pressed displays a six digit authentication code. This code is entered with a user’s username and password
as two-factor authentication. The code displayed changes every 60 seconds, and when not in use the LCD screen
is blanked to extend the battery life.
There is also a mobile phone application, FortiToken Mobile, that performs much the same function.
FortiTokens have a small hole in one end. This is intended for a lanyard to be inserted so the device can be worn
around the neck, or easily stored with other electronic devices. Do not put the FortiToken on a key ring as the
metal ring and other metal objects can damage it. The FortiToken is an electronic device like a cell phone and
must be treated with similar care.
Any time information about the FortiToken is transmitted, it is encrypted. When the FortiGate unit receives the
code that matches the serial number for a particular FortiToken, it is delivered and stored encrypted. This is in
keeping with the Fortinet’s commitment to keeping your network highly secured.
FortiTokens can be added to user accounts that are local, IPsec VPN, SSL VPN, and even Administrators. See
Associating FortiTokens with accounts on page 63.
A FortiToken can be associated with only one account on one FortiGate unit.
If a user loses their FortiToken, it can be locked out using the FortiGate so it will not be used to falsely access the
network. Later if found, that FortiToken can be unlocked on the FortiGate to allow access once again. See
FortiToken maintenance on page 65.
There are three tasks to complete before FortiTokens can be used to authenticate accounts:
When configured the FortiGate unit accepts the username and password, authenticates them either locally or
remotely, and prompts the user for the FortiToken code. The FortiGate then authenticates the FortiToken code.
When FortiToken authentication is enabled, the prompt field for entering the FortiToken code is automatically
added to the authentication screens.
Even when an Administrator is logging in through a serial or Telnet connection and their account is linked to a
FortiToken, that Administrator will be prompted for the token’s code at each login.
If you have attempted to add invalid FortiToken serial numbers, there will be no error
message. The serial numbers will simply not be added to the list.
Both FortiToken Mobile and physical FortiTokens store their encryption seeds on the
cloud, therefore you will only be able to register them to a single FortiGate or
FortiAuthenticator.
Because FortiToken-200CD seed files are stored on the CD, these tokens can be
registered on multiple FortiGates and/or FortiAuthenticators, but not simultaneously.
For mobile token, you receive the activation code in the license certificate once you
purchase a license. FortiOS include a license for two mobile token at no cost.
next
edit <serial_number2>
next
end
1. Ensure that your FortiToken serial number has been added to the FortiGate successfully, and its status is
Available.
2. Go to User & Device > User Definition, and edit the user account.
3. Select Email Address and enter user's email address.
4. Select Enable Two-factor Authentication.
5. Select the user's FortiToken serial number from the Token list.
6. Select OK.
For mobile token, click on Send Activation Code to be sent to the email address
configured previously. The user will use this code to activate his mobile token. An
Email Service has to be set under System > Advanced in order to send the
activation code.
1. Ensure that your FortiToken serial number has been added to the FortiGate successfully, and its status is
Available.
2. Go to System > Administrators, and edit the admin account.
This account is assumed to be configured except for two-factor authentication.
3. Select Email Address and enter admin's email address.
4. Select Enable Two-factor Authentication.
5. Select the user's FortiToken serial number from the Token list.
6. Select OK.
For mobile token, click on Send Activation Code to be sent to the email address
configured previously. The admin will use this code to activate his mobile token. An
Email Service has to be set under System > Advanced in order to send the
activation code.
The fortitoken keyword will not be visible until fortitoken is selected for the two-factor option.
Before a new FortiToken can be used, it may need to be synchronized due to clock
drift.
FortiToken maintenance
Once FortiTokens are entered into the FortiGate unit, there are only two tasks to maintain them — changing the
status,
Any user attempting to login using this FortiToken will not be able to authenticate.
To list the drift on all FortiTokens configured on this FortiGate unit - CLI:
# diag fortitoken info
FORTITOKEN DRIFT STATUS
FTK2000BHV1KRZCC 0 token already activated, and seed won't be returned
FTK2001C5YCRRVEE 0 token already activated, and seed won't be returned
FTKMOB4B94972FBA 0 provisioned
FTKMOB4BA4BE9B84 0 new
Total activated token: 0
Total global activated token: 0
Token server status: reachable
This command lists the serial number and drift for each FortiToken configured on this FortiGate unit. This
command is useful to check if it is necessary to synchronize the FortiGate and any particular FortiTokens.
FortiToken Mobile Push
A command under config system ftm-push allows you to configure the FortiToken Mobile Push services
server IP address and port number. The Push service is provided by Apple (APNS) and Google (GCM) for iPhone
and Android smartphones respectively. This will help to avoid tokens becoming locked after an already enabled
two-factor authentication user has been disabled. In addition, FortiOS supports FTM Push when
FortiAuthenticator is the authentication server.
CLI syntax
config system ftm-push
set server-ip <ip-address>
set server-port [1-65535] Default is 4433.
end
Note that the server-ip is the public IP address of the FortiGate interface that the FTM will call back to; it is
the IP address used by the FortiGate for incoming FTM calls.
In addition, FTM Push is supported on administrator login and SSL VPN login for both iOS and Android. If an
SSL VPN user authenticates with their token, then logs out and attempts to reauthenticate again within a minte, a
new message will display showing "Please wait x seconds to login again." This replaces a previous
error/permission denied message.
The "x" value will depend on the calculation of how much time is left in the current time step.
CLI syntax
config system interface
edit <name>
set allowaccess ftm
next
end
Monitoring users
To monitor user activity in the web-based manager, go to Monitor > Firewall User Monitor. The list of users
who are logged on is displayed with some information about them such as their user group, security policy ID,
how long they have been logged on, their IP address, traffic volume, and their authentication method as one of
FSSO, NTLM, or firewall (FW-auth).
From this screen you can de-authenticate all users who are logged on. The de-authenticate button is at the top
left of this screen.
To see information about banned users go to Monitor > Quarantine Monitor. Displayed information about
users who have been banned includes what application the triggered the ban (Application Protocol), the reason
for the ban (Cause or rule), Created, and when the ban expires.
Select settings bottom at the top right of the screen to adjust columns that are displayed for users, including what
order they are displayed in. This can be very helpful in locating information you are looking for.
Each column heading has a grey filter icon. Click on the filter icon to configure a filter for the data displayed in that
column. Each column has similar options including a field to enter the filtering information, a check box to select
the negative of the text in the field, and the options to add more fields, apply the filter, clear all filters, or cancel
without saving. To enter multiple terms in the field, separate each of them with a comma. To filter entries that
contain a specific prefix, use an * (asterisk).
For example, to create a filter to display only users with an IP address of 10.11.101.x who authenticated using
one of security policies five through eight, and who belong to the user group Accounting.
User groups
In most cases, the FortiGate unit authenticates users by requesting their username and password. The FortiGate
unit checks local user accounts first. If a match is not found, the FortiGate unit checks the RADIUS, LDAP, or
TACACS+ servers that belong to the user group. Authentication succeeds when a matching username and
password are found. If the user belongs to multiple groups on a server, those groups will be matched as well.
FortiOS does not allow username overlaps between RADIUS, LDAP, or TACACS+
servers.
There are four types of FortiGate user groups: Firewall, Fortinet Single Sign-On (FSSO), Guest, and RADIUS
Single Sign-On (RSSO) user groups.
SSL VPN access also requires a security policy where the destination is the SSL interface. For more information,
see the FortiOS Handbook SSL VPN guide.
VPN only if the username is a member of the allowed user group and the password matches the one stored on
the FortiGate unit.
A user group cannot be used as a dialup group if any member of the group is
authenticated using an external authentication server.
For more information, see the FortiOS Handbook IPsec VPN guide.
In this example, the members of accounting_group are User1 and all of the members of rad_
accounting_group on myRADIUS external RADIUS server.
config user group
edit accounting_group
set group-type firewall
set member User1 myRADIUS
config match
edit 0
set server-name myRADIUS
set group-name rad_accounting_group
end
end
Matching user group names from an external authentication server might not work if
the list of group memberships for the user is longer than 8000 bytes. Group names
beyond this limit are ignored.
server_name is the name of the RADIUS, LDAP, or TACACS+ server, but it must be a member of this group
first and must also be a configured remote server on the FortiGate unit.
group_name is the name of the group on the RADIUS, LDAP, or TACACS+ server such as “engineering” or
“cn=users,dc=test,dc=com”.
Before using group matching with TACACS+, you must first enable authentication. For example if you have a
configured TACACS+ server called myTACS, use the following CLI commands.
config user tacacs+
edit myTACS
set authorization enable
next
end
For more information about user group CLI commands, see the Fortinet CLI Guide.
This feature is available only in the CLI and is enabled by default. It applies to RADIUS, LDAP, and TACACS+
servers. The new command for this feature is auth-multi-group found in config user settings and
checks all groups a user belongs to for authentication.
If VDOMs are enabled, the global level user setting authtimeout is the default all VDOMs inherit. If VDOMs
are not enabled, user settings authtimeout is the default. The default timeout value is used when the
authtimeout keyword for a user group is set to zero.
Each type of timeout will be demonstrated using the existing user group example_group. Timeout units are
minutes. A value of zero indicates the global timeout is used.
When a user belongs to multiple groups in RADIUS groups, the group auth-timeout values are ignored. Instead
the global timeout value is used. The default value is 5 minutes, but it can be set from 1 to 43200 minutes (30
days).
config user setting
set auth-timeout-type idle-timeout
set auth-timeout 300
end
Idle timeout
The default type of timeout is idle timeout. When a user initiates a session, it starts a timer. As long as data is
transferred in this session, the timer continually resets. If data flow stops, the timer is allowed to advance until it
reaches its limit. At that time the user has been idle for too long, and the user is forced to re-authenticate before
traffic is allowed to continue in that session.
Hard timeout
Where the idle timeout is reset with traffic, the hard timeout is absolute. From the time the first session a user
establishes starts, the hard timeout counter starts. When the timeout is reached, all the sessions for that user
must be re-authenticated. This timeout is not affected by any event.
Session timeout
The session timeout works much like the hard timeout in that its an absolute timer that can not be affected by
events. However, when the timeout is reached existing sessions may continue but new sessions are not allowed
until re-authentication takes place.
You can specify FSSO user groups in security policies in the same way as you specify firewall user groups. FSSO
user groups cannot have SSL VPN or dialup IPsec VPN access.
For information about configuring FSSO user groups, see Creating Fortinet Single Sign-On (FSSO) user groups
on page 183. For complete information about installing and configuring FSSO, see Agent-based FSSO on page
147.
In the web-based manager, if you change the type of the group any members will be removed automatically.
This example adds user3 to Group1. Note that you must re-specify the full list of users:
Visitors to your premises might need user accounts on your network for the duration of their stay. If you are
hosting a large event such as a conference, you might need to create many such temporary accounts. The
FortiOS Guest Management feature is designed for this purpose.
A guest user account User ID can be the user’s email address, a randomly generated string, or an ID that the
administrator assigns. Similarly, the password can be administrator-assigned or randomly generated.
You can create many guest accounts at once using randomly-generated User IDs and passwords. This reduces
administrator workload for large events.
To set up guest user access, you need to create at least one guest user group and add guest user accounts.
Optionally, you can create a guest management administrator whose only function is the creation of guest
accounts in specific guest user groups. Otherwise, any administrator can do guest management.
Type Guest
Enable Batch Account Create multiple accounts automatically. When this is enabled:
Creation l User ID and Password are set to Auto-Generate.
l The user accounts have only User ID, Password, and Expiration
fields. Only the Expiration field is editable. If the expiry time is a
duration, such as “8 hours”, this is the time after first login.
l You can print the account information. Users do not receive email
or SMS notification.
See To create multiple guest user accounts automatically on page 75.
Default Expire Time Set the expire time. The administrator can change this for individual users.
Enable Sponsor If enabled, user form has Sponsor field. Select Required if required.
Enable Company If enabled, user form has Company field. Select Requiredif required.
Enable SMS If enabled, user is notified by SMS. Select whether FortiGuard Messaging
Service or a another SMS provider is used.
Send Send the user account information to a printer or to the guest. Depending on the group
settings and user information, the information can be sent to the user by email or
SMS.
Guest Groups Select the guest group to list. New accounts are added to this group.
The user ID. Depending on the guest group settings, this can be the user’s email
User ID
address, an ID that the administrator specified, or a randomly-generated ID.
Expires Indicates a duration such as “3 hours”. A duration on its own is relative to the present
time. Or, the duration is listed as “after first login.”
Some retail businesses such as coffee shops provide free Wi-Fi Internet access for their customers. For this type
of application, the FortiOS guest management feature is not required; the Wi-Fi access point is open and
customers do not need logon credentials. However, the business might want to contact its customers later with
promotional offers to encourage further patronage. Using an Email Collection portal, it is possible to collect
customer email addresses for this purpose. The security policy grants network access only to users who provide a
valid email address.
The first time a customer’s device attempts to use the Wi-Fi connection, FortiOS requests an email address,
which it validates. The customer’s subsequent connections go directly to the Internet without interruption.
In this example the freewifi Wi-Fi interface is modified to present an email collection captive portal.
config wireless-controller vap
edit freewifi
set security captive-portal
set portal-type email-collect
end
Schedule always
Service ALL
Action ACCEPT
NAT On
3. Select OK.
matched in the policy list, based on standard policy criteria, isn’t the only policy that can be matched.
Fall-through is intended to match users in different user groups with different policies. For example, consider an
organization with two user groups where one group requires a web filtering profile, while the other requires virus
scanning. In this example, you would edit two basic Internet access policies: policy 1 assigning User Group A
with a Web Filtering profile, and policy 2 assigning User Group B with an AntiVirus profile. Both policies are
also assigned to the same internal subnet, named subnet1.
In this configuration, all users from subnet1 will see an authentication prompt. If the user is found in User
Group A, the traffic is accepted by policy 1 and is filtered by the Web Filtering profile. If the user is found in
User Group B, the traffic is accepted by policy 2 and is virus scanned.
The fall-through feature is required for users to be matched with policy 2. Without the fall-through feature, traffic
would never be matched with policy 2.
When you have configured authentication servers, users, and user groups, you are ready to configure security
policies and certain types of VPNs to require user authentication.
l Authentication timeout
l Password policy
l Authentication protocols
l Authentication in Captive Portals
l Authentication in security policies
l Authentication replacement messages
l VPN authentication
Authentication timeout
An important feature of the security provided by authentication is that it is temporary—a user must re-
authenticate after logging out. Also if a user is logged on and authenticated for an extended period of time, it is a
good policy to have them re-authenticate at set periods. This ensures a user’s session is cannot be spoofed and
used maliciously for extended periods of time — re-authentication will cut any spoof attempts short. Shorter
timeout values are more secure.
1. Go to VPN > SSL-VPN Settings.
2. Under Idle Logout, make sure that Logout users when inactive for specified period is enabled and enter
the Inactive For value (seconds).
3. Select Apply.
Password policy
Password authentication is effective only if the password is sufficiently strong and is changed periodically. By
default, the FortiGate unit requires only that passwords be at least eight characters in length, but up to 128
characters is permitted. You can set a password policy to enforce higher standards for both length and complexity
of passwords. Password policies can apply to administrator passwords or IPsec VPN preshared keys.
To set a password policy in the web-based manager, go to System > Settings. In the CLI, use the config
system password-policy command.
Users usually create passwords composed of alphabetic characters and perhaps some numbers. Password policy
can require the inclusion of uppercase letters, lowercase letters, numerals or punctuation characters.
The following procedures show how to force administrator passwords to contain at least two uppercase, four
lower care, two digits, and one special character. Leave the minimum length at the default of eight characters.
1. Go to System > Settings.
2. Select Enable Password Policy.
3. Select Must Contain at Least.
4. Enter the following information:
Numbers 2
Special Characters 1
The change-4-characters option forces new passwords to change a minimum of four characters in the old
password. Changing fewer characters results in the new password being rejected. This option is only available in
the CLI.
As of FortiOS 5.4, a password policy can also be created for guest administrators. The following command shows
all possible commands, which are also available under config system password-policy.
config system password-policy
set status {enable | disable} Enable/disable password policy.
set apply-to {guest-admin-password} Guest admin to which this password policy applies.
set minimum-length <8-128> Minimum password length.
set min-lower-case-letter <0-128> Min. lowercase characters in password.
set min-upper-case-letter <0-128> Min. uppercase characters in password.
set min-non-alphanumeric <0-128> Min. non-alphanumeric characters in password.
set min-number <0-128> Min. numeric characters in password.
set change-4-characters {enable | disable} Enable/disable changing at least 4 characters for
new password.
set expire-status {enable | disable} Enable/disable password expiration.
set expire-day <1-999> Number of days before password expires.
set reuse-password {enable | disable} Enable/disable reuse of password.
end
Best practices dictate that password expiration also be enabled. This forces passwords to be changed on a
regular basis. You can set the interval in days. The more sensitive the information this account has access to, the
shorter the password expiration interval should be. For example 180 days for guest accounts, 90 days for users,
and 60 days for administrators.
Avoid:
To set a maximum of five failed authentication attempts before the blackout, using the following CLI command:
config user setting
set auth-invalid-max 5
end
To set the length of the blackout period to five minutes, or 300 seconds, once the maximum number of failed
logon attempts has been reached, use the following CLI command:
config user setting
set auth-blackout-time 300
end
Authentication protocols
When user authentication is enabled on a security policy, the authentication challenge is normally issued for any
of the four protocols, HTTP, HTTPS, FTP, and Telnet, which are dependent on the connection protocol. By
making selections in the Protocol Support list, the user controls which protocols support the authentication
challenge. The user must connect with a supported protocol first, so that they can subsequently connect with
other protocols.
For example, if you have selected HTTP, FTP, or Telnet, a username and password-based authentication occurs.
The FortiGate unit then prompts network users to input their security username and password. If you have
selected HTTPS, certificate-based authentication (HTTPS, or HTTP redirected to HTTPS only) occurs.
For certificate-based authentication, you must install customized certificates on the FortiGate unit and on the
browsers of network users. If you do not install certificates on the network user’s web browser, the network users
may see an SSL certificate warning message and have to manually accept the default FortiGate certificate. The
network user’s web browser may deem the default certificate as invalid.
When you use certificate authentication, if you do not specify any certificate when you create the security policy,
the global settings are used. If you specify a certificate, the per-policy setting will overwrite the global setting. For
more information about the use of certification authentication see Certificate-based authentication on page 112.
Network interfaces, including WiFi interfaces, can perform authentication at the interface level using a captive
portal — an HTML form that requests the user’s name and password. A captive portal is useful where all users
connecting to the network interface must authenticate. Optionally, on a WiFi interface, the captive portal can be
combined with a terms of service disclaimer to which the user must agree before gaining access. For more
information, see Captive portals on page 104.
Security policies control traffic between FortiGate interfaces, both physical interfaces and VLAN subinterfaces.
The firewall tries to match the session’s user or group identity, device type, destination, etcetera to a security
policy. When a match is found, the user connects to the requested destination. If no security policy matches, the
user is denied access.
A user who has not already been authenticated by a captive portal, FSSO, or RSSO can match only policies
where no user or user group is specified. If no such policy exists, the firewall requests authentication. If the user
can authenticate and the session can be matched to a policy, the user connects to the requested destination,
otherwise, the user is denied access.
Another authentication option is to redirect any attempts to authenticate using HTTP to a more secure channel
that uses HTTPS. This forces users to a more secure connection before entering their user credentials.
A replacement message is the body of a webpage containing a message about a blocked website message, a file
too large message, a disclaimer, or even a login page for authenticating. The user is presented with this message
instead of the blocked content.
Authentication replacement messages are the prompts a user sees during the security authentication process
such as login page, disclaimer page, and login success or failure pages. These are different from most
replacement messages because they are interactive requiring a user to enter information, instead of simply
informing the user of some event as other replacement messages do.
Replacement messages have a system-wide default configuration, a per-VDOM configuration, and disclaimers
can be customized for multiple security policies within a VDOM.
These replacement messages are used for authentication using HTTP and HTTPS. Authentication replacement
messages are HTML messages. You cannot customize the security authentication messages for FTP and Telnet.
The authentication login page and the authentication disclaimer include replacement tags and controls not found
on other replacement messages.
More information about replacement messages can be found in the config system replacemsg section of
the FortiOS CLI Reference.
Replacement message
Description
name (CLI name)
Login challenge page This HTML page is displayed if security users are required to answer a
(auth-challenge-page) question to complete authentication. The page displays the question and
includes a field in which to type the answer. This feature is supported by
RADIUS and uses the generic RADIUS challenge-access auth response.
Usually, challenge-access responses contain a Reply-Message attribute
that contains a message for the user (for example, “Please enter new
PIN”). This message is displayed on the login challenge page. The user
enters a response that is sent back to the RADIUS server to be verified.
The Login challenge page is most often used with RSA RADIUS server for
RSA SecurID authentication. The login challenge appears when the server
needs the user to enter a new PIN. You can customize the replacement
message to ask the user for a SecurID PIN.
This page prompts user to accept the displayed disclaimer when leaving
the captive portal to access Internet resources. It is displayed when the
captive portal type is Authentication and Disclaimer or Disclaimer
Disclaimer page Only.
Email token page The page prompting a user to enter their email token. See Email on page
(auth-email-token-page) 1.
FortiToken page The page prompting a user to enter their FortiToken code. See FortiToken
(auth-fortitoken-page) on page 60.
Keepalive page The HTML page displayed with security authentication keepalive is
(auth-keepalive-page) enabled using the following CLI command:
Replacement message
Description
name (CLI name)
The Disclaimer page replacement message does not re-direct the user to a
Login failed page redirect URL or the security policy does not include a redirect URL. When a
(auth-login-failed-page) user selects the button on the disclaimer page to decline access through
the FortiGate unit, the Declined disclaimer page is displayed.
Login page The authentication HTML page displayed when users who are required to
(auth-login-page) authenticate connect through the FortiGate unit using HTTP or HTTPS.
Declined disclaimer page The page displayed if a user declines the disclaimer page. See Disclaimer
(auth-reject-page) on page 87.
SMS Token page The page prompting a user to enter their SMS token. See SMS on page 59.
(auth-sms-token-page)
Access to HTTP, HTTPS, FTP and Telnet sites may require access to a domain name service. DNS requests do
not trigger authentication. You must configure a policy to permit unauthenticated access to the appropriate DNS
server, and this policy must precede the policy for Internet access. Failure to do this will result in the lack of a
DNS connection and a corresponding lack of access to the Internet.
Before creating a security policy, you need to configure one or more users or user groups. For more information,
see Users and user groups on page 53.
Creating the security policy is the same as a regular security policy except you must select the action specific to
your authentication method:
ACCEPT FSSO Agent or a security policy that specifies an Agent-based FSSO on page 147.
FSSO user group
Disclaimer
A WiFi or SSL captive portal can include a disclaimer message presented after the user authenticates. The user
must agree to the terms of the disclaimer to access network resources.
Changing the disclaimer in System > Replacement Messages is not the same as selecting to customize a
disclaimer used in a captive portal. The captive portal location is a customized disclaimer that inherits the default
format for the disclaimer message, but then can be customized for this portal.
When enabled, event logging records system events such as configuration changes, and authentication. To
configure event logging, go to Log & Report > Log Settings and enable Event Logging. Select the events
you want to log, such as User activity event.
When enabled, security logging will log security profile and security policy traffic.
You must enable logging within a security policy, as well as the options that are applied to a security policy, such
as security profiles features. Event logs are enabled within the Event Log page.
For more information on logging, see the FortiOS Log and Reporting guide.
For more information on specific types of log messages, see the FortiOS Log Message Reference.
You need to set the logging severity level to Notification when configuring a logging
location to record traffic log messages.
Identity-based policy
An identity-based policy (IBP) performs user authentication in addition to the normal security policy duties. If the
user does not authenticate, access to network resources is refused. This enforces Role Based Access Control
(RBAC) to your organization’s network and resources.
Identity-based policies also support Single Sign-On operation. The user groups selected in the policy are of the
Fortinet Single Sign-On (FSSO) type.
User authentication can occur through any of the following supported protocols, including: HTTP, HTTPS, FTP,
and Telnet. The authentication style depends on which of these protocols is included in the selected security
services group and which of those enabled protocols the network user applies to trigger the authentication
challenge.
For username and password-based authentication (HTTP, FTP, and Telnet) the FortiGate unit prompts network
users to enter their username, password, and token code if two-factor authentication is selected for that user
account. For certificate-based authentication, including HTTPS or HTTP redirected to HTTPS only, see
Certificate authentication on page 98.
With identity-based policies, the FortiGate unit allows traffic that matches the source and destination addresses,
device types, and so on. This means specific security policies must be placed before more general ones to be
effective.
When the identity-based policy has been configured, the option to customize authentication messages is
available. This allows you to change the text, style, layout, and graphics of the replacement messages associated
with this firewall policy. When enabled, customizing these messages follows the same method as changing the
disclaimer. See Disclaimer on page 87.
l NTLM authentication
l Certificate authentication
NTLM authentication
NT LAN Manager (NTLM) protocol can be used as a fallback for authentication when the Active Directory (AD)
domain controller is unreachable. NTLM uses the web browser to send and receive authentication information.
See "NTLM" and "FSSO NTLM authentication support".
To enable NTLM
1. Edit the policy in the CLI to enable NTLM. For example, if the policy ID is 4:
2. Go to Policy & Objects > IPv4 Policy and note the ID number of your FSSO policy.
3. The policy must have an FSSO user group as Source User(s). There must be at least one FSSO Collector agent
configured on the FortiGate unit.
config firewall policy
edit 4
set ntlm enable
end
<user_agent_string> is the name of the browser that is NTLM enabled. Examples of these values include
“MSIE”, “Mozilla” (which includes FireFox), and “Opera”.
Value strings can be up to 63 characters in length, and may not contain cross site scripting (XSS) vulnerability
characters such as brackets. The FortiGate unit prevents use of these characters to prevent exploit of cross site
scripting (XSS) vulnerabilities.
Kerberos authentication for explicit web and transparent web proxy users
Kerberos authentication is a method for authenticating both explicit web proxy and transparent web proxy users.
It has several advantages over NTLM challenge response:
CLI commands (config authentication rule, scheme, and setting) allow explicit proxy rules and
schemes to be created to separate user authentication (e.g. authentication rules and schemes used to match
conditions in order to identify users) from user authorization (proxy-based policies with users and/or user groups).
Note: As shown above, HTTP, FTP, and SOCKSv5 authentication protocols are supported for explicit proxy.
Authentication rules are used to receive user-identity, based on the values set for protocol and source address.
Having said this, if a rule fails to match based on source address, there will be no other attempt to match the rule,
however the next policy will be attempted. This occurs only when:
l there is an authentication rule, but no authentication method has been set (under config authentication
scheme; see below), so user identity cannot be found.
l the user is successfully matched in the rule, but fails to match the current policy.
Once a rule is positively matched through protocol and/or source address, it must also match the authentication
method specified (active-auth-method and sso-auth-method). These methods point to schemes, as
defined under config authentication scheme.
Combining authentication rules and schemes, granular control can be exerted over users and IPs, creating an
efficient process for users to successfully match a criteria before matching the policy.
A CLI command, under config firewall profile-protocol-options, allows HTTP policy checking
to be enable or disabled. When enabled, transparent traffic can be matched in a firewall policy and policy user
authentication can occur. In addition, separate SSL inspection policies can be created:
config firewall profile-protocol-options
edit <name>
set http-policy {enable|disable}
end
CLI commands, under config firewall proxy-policy, implement the Internet Service Database (ISDB)
as the webproxy matching factor, and override IP pool is also support:
config firewall proxy-policy
edit <name>
set proxy {explicit-web|transparent-web|ftp|wanopt}
set dstintf <dst-name>
set poolname <ip-pool-name>
end
Multiple port/port range support for explicit web and explicit FTP proxy
Multiple port numbers and/or ranges can be set for explicit proxy, specifically for HTTP/HTTPS and FTP. Go to
Network > Explicit Proxy and configure settings under Explicit Web Proxy and Explicit FTP Proxy, or
under config web-proxy explicit in the CLI Console.
1. General configuration
Add the FortiGate FQDN in to the Windows DNS domain, as well as in-addr.arpa
For Lab/Testing add the FortiGate Domain name and IP mapping in the hosts file
(windows/system32/drivers/etc/hosts). e.g., TESTFGT.TEST.COM 10.10.1.10
Use the ktpass command (found on Windows Servers and many domain workstations) to generate the Kerberos
keytab.
Example:
ktpass -princ HTTP/<domain name of test fgt>@realm -mapuser testfgt -pass <password> -
crypto all -ptype KRB5_NT_PRINCIPAL -out fgt.keytab
The ktpass on older Windows servers (i.e. 2003) may not support the “all” crypto
option.
Example:
ktpass -princ HTTP/[email protected] -mapuser testfgt -pass 12345678 -crypto all -
ptype KRB5_NT_PRINCIPAL -out fgt.keytab
The realm name is always presented in uppercase, and prefixed with the “@”
character.
Use the base64 command (available in most Linux distros) command to encode the fgt.keytab file. Any LF (Line
Feed) need to be deleted from the file.
Example:
base64 fgt.keytab > fgt.txt
Use Notepad++ or some native Linux text editor. Windows Notepad and Wordpad are
likely to introduce errors.
2. FortiGate configuration
2.5 Diagnostics
Once the keytab is imported, check that it has been properly decoded. The filename generated will be relatively
random, but should be clearly visible.
Artoo-Deetoo (root) # fnsysctl ls -la /tmp/kt
drwxr--r-- 2 0 0 Fri Dec 2 10:06:43 2016 60 .
drwxrwxrwt 22 0 0 Tue Dec 6 14:28:29 2016 3280 ..
-rw-r--r-- 1 0 0 Fri Dec 2 10:06:43 2016 392 1.0.89.keytab
If there is no file present, then the file hasn’t decoded. Check the file for line feeds and
try again.
Log on to the domain by using testuser, created in 1.2. Use the klist command to list ticket information. In the
below example, the client has received krbtgt, CIFS, and LDAP tickets. As there has been no interaction with the
FortiGate, there are no references to it.
C:\Users\glenk>klist Cached Tickets: (5)
C:\Users\glenk>klist
Cached Tickets: (5)
#0> Client: glenk @ home.local
Server: krbtgt/HOME.LOCAL @ HOME.LOCAL
KerbTicket Encryption Type: AES-256-CTS-HMAC-SHA1-96
Ticket Flags 0x60a00000 -> forwardable forwarded renewable pre_authent
Start Time: 12/6/2016 14:58:06 (local)
End Time: 12/7/2016 0:58:04 (local)
Renew Time: 12/13/2016 14:58:04 (local)
Session Key Type: AES-256-CTS-HMAC-SHA1-96
Set up web-proxy in browser through the FortiGate. This can be achieved via a PAC file or direct browser
configuration.
1. The client accesses the explicit proxy, but a HTTP 407 Proxy Authentication Required is returned.
2. As “Negotiate” is set, the client has knowledge of the KRBTGT, it requests a ticket from the KDC with a krb-tgs-
req message. This includes the REALM (HOME.LOCAL) in the reg-body section, and the provided instances
SNAME and service (in this case, HTTP/artoo-deetoo.home.local).
3. The KDC responds with a next KRB-TGS-REP.
This ticket is then available on the client.
4. The conversation between the client and the proxy continues, as the client responds with the Kerberos ticket in the
response.
The whole process takes less than a second to complete. The user should be visible as a FSSO logon in the
Web UI.
In the firewall policy level, transparent web-proxy is regarded as a special UTM. The HTTP/HTTPS traffic
matches the firewall policy first, then traffic is redirected to the web-proxy daemon. If the trasnparent web-proxy
feature is disabled, http-policy options in profile-protocol-options is used to enable transparent web-proxy feature.
IP-based
1. Captive portal and the captive portal port must be configured in transparent web-proxy for support of Kerberos
authentication:
config authentication setting
set captive-portal <fqdn-name>
set captive-portal-port "9998"
end
2. Authentication rule, scheme, and krb-keytab need to be configured for Kerberos authentication (note the
active-auth-method scheme referenced in the rule):
config authentication scheme
edit <kerberos-scheme>
set method negotiate
set negotiate-ntlm <enable>
set fsso-guest <disable>
next
end
The configuration is the same as for IP-based authentication, except ip-based is disabled in the authentication
rule:
config authentication rule
edit "kerberos-rules"
set status <enable>
set protocol <http>
set srcadrr "all"
set ip-based <disable>
set active-auth-method <kerberos-scheme>
next
Certificate authentication
You can configure certificate-based authentication for FortiGate administrators, SSL VPN users, and IPsec VPN
users. See Configuring certificate-based authentication on page 125.
Certificates are also inherent to the HTTPS protocol, where the browser validates the server’s identity using
certificates. A site certificate must be installed on the FortiGate unit and the corresponding Certificate Authority
(CA) certificate installed in the web browser.
To force the use of HTTPS, go to User & Device > Authentication Settings and select Redirect HTTP
Challenge to a Secure Channel (HTTPS).
While there are valid reasons for having multiple concurrent sessions open, hackers also do this to speed up their
malicious work. Often a hacker is making multiple attempts to gain access to the internal network or the admin
interface of the FortiGate unit, usually from different IP addresses to appear to the FortiGate unit as legitimate
users. For this reason, the more concurrent sessions a hacker has open at once, the faster they will achieve their
goal.
To help prevent this, you can disallow concurrent administrative access using the same administrator user name.
This allows only one session with the same username even if it is from the same IP.
VPN authentication
All VPN configurations require users to authenticate. Authentication based on user groups applies to:
l SSL VPNs
l PPTP and L2TP VPNs
l an IPsec VPN that authenticates users using dialup groups
l a dialup IPsec VPN that uses XAUTH authentication (Phase 1)
You must create user accounts and user groups before performing the procedures in this section. If you create a
user group for dialup IPsec clients or peers that have unique peer IDs, their user accounts must be stored locally
on the FortiGate unit. You cannot authenticate these types of users using a RADIUS or LDAP server.
Authentication through user groups is supported for groups containing only local users. To authenticate users
using a RADIUS or LDAP server, you must configure XAUTH settings. See Configuring XAuth authentication.
1. Configure the dialup users who are permitted to use this VPN. Create a user group with Type:Firewall and add
them to it.
For more information, see Users and user groups on page 53
2. Go to VPN > IPsec Wizard, select Remote Access, choose a name for the VPN, and enter the following
information.
Authentication Method List of authentication methods available for users. Select Preshared Key
and enter the preshared key.
User Group Select the user group that is to be allowed access to the VPN. The listed
user groups contain only users with passwords on the FortiGate unit.
XAuth can be used in addition to or in place of IPsec phase 1 peer options to provide access security through an
LDAP or RADIUS authentication server. You must configure a dialup user group whose members are all
externally authenticated.
1. Configure the users who are permitted to use this VPN. Create a user group and add the users to the group.
For more information, see "Users and user groups" on page 53.
2. Go to VPN > IPsec Wizard, select Remote Access, choose a name for the VPN, and enter the following
information.
Authentication Method List of authentication methods available for users. Select Preshared Key
and enter the preshared key.
User Group Select the user group that is to be allowed access to the VPN. The listed
user groups contain only users with passwords on the FortiGate unit.
Type Select PAP, CHAP, or AUTO. Use CHAP whenever possible. Use PAP
with all implementations of LDAP and with other authentication servers
that do not support CHAP, including some implementations of Microsoft
RADIUS. Use AUTO with the Fortinet Remote VPN Client and where the
authentication server supports CHAP but the XAuth client does not.
User Group Select the user group that is to have access to the VPN. The list of user
groups does not include any group that has members whose password is
stored on the FortiGate unit.
6. Select OK.
For more information about XAUTH configuration, see the IPsec VPN chapter of the FortiOS Handbook.
Some parameters specific to setting up the VPN itself are not shown here. For detailed information about
configuring IPsec VPNs, see the FortiOS Handbook IPsec VPN guide.
LDAP user authentication is supported for PPTP, L2TP, IPsec VPN, and firewall
authentication.
However, with PPTP, L2TP, and IPsec VPN, PAP (Packet Authentication Protocol) is
supported, while CHAP (Challenge Handshake Authentication Protocol) is not.
1. Configure the users who are permitted to use this VPN. Create a security user group and add them to it.
For more information, see Users and user groups on page 53.
2. Configure the PPTP VPN in the CLI as in this example.
config vpn pptp
set status enable
set sip 192.168.0.100
set eip 192.168.0.110
set usrgrp PPTP_Group
end
The sip and eip fields define a range of virtual IP addresses assigned to PPTP clients.
Configure a security policy. The source interface is the one through which the clients will connect. The source
address is the PPTP virtual IP address range. The destination interface and address depend on the network to
which the clients will connect. The policy action is ACCEPT.
LDAP user authentication is supported for PPTP, L2TP, IPsec VPN, and firewall
authentication.
However, with PPTP, L2TP, and IPsec VPN, PAP (Packet Authentication Protocol) is
supported, while CHAP (Challenge Handshake Authentication Protocol) is not.
1. Configure the users who are permitted to use this VPN. Create a user group and add them to it.
For more information, see Users and user groups on page 53.
3. Configure a security policy. The source interface is the one through which the clients will connect. The source
address is the L2TP virtual IP address range. The destination interface and address depend on the network to
which the clients will connect. The policy action is ACCEPT.
A captive portal is a convenient way to authenticate web users on wired or WiFi networks.
You can authenticate your users on a web page that requests the user’s name and password. Until the user
authenticates successfully, the authentication page is returned in response to any HTTP request. This is called a
captive portal.
After successful authentication, the user accesses the requested URL and can access other web resources, as
permitted by security policies. Optionally, the captive portal itself can allow web access to only the members of
specified user group.
The captive portal can be hosted on the FortiGate unit or on an external authentication server. You can configure
captive portal authentication on any network interface, including WiFi and VLAN interfaces.
When a captive portal is configured on a WiFi interface, the access point initially appears open. The wireless
client can connect to the access point with no security credentials, but sees only the captive portal authentication
page.
l Authentication — until the user enters valid credentials, no communication beyond the AP is permitted.
l Disclaimer + Authentication — immediately after successful authentication, the portal presents the disclaimer
page—an acceptable use policy or other legal statement—to which the user must agree before proceeding.
l Disclaimer Only — the portal presents the disclaimer page—an acceptable use policy or other legal statement—
to which the user must agree before proceeding. The authentication page is not presented.
l Email Collection — the portal presents a page requesting the user’s email address, for the purpose of contacting
the person in future. This is often used by businesses who provide free WiFi access to their customers. The
authentication page is not presented.
Captive portals are configured on network interfaces. On a physical (wired) network interface, you edit the
interface configuration in Network > Interfaces and set Security Mode to Captive Portal. A WiFi interface
does not exist until the WiFi SSID is created. You can configure a WiFi captive portal at the time that you create
the SSID. Afterwards, the captive portal settings will also be available by editing the WiFi network interface in
Network > Interfaces.
1. Go to Network > Interfaces and edit the interface to which the users connect.
2. In Security Mode select Captive Portal.
3. Enter
User Groups Select permitted user groups or select Use Groups from Policies, which
permits the groups specified in the security policy.
Exempt List Select exempt lists whose members will not be subject to captive portal
authentication.
Customize Portal Enable, then select Edit. See Customizing captive portal pages on page
Messages 106.
4. Select OK.
3. Enter
Portal Type The portal can provide authentication and/or disclaimer, or perform user
email address collection. See Introduction to Captive portals on page 104.
Exempt List Select exempt lists whose members will not be subject to captive portal
authentication.
Customize Portal Messages Click the link of the portal page that you want to modify. See "Captive
portals" on page 106.
4. Select OK.
These pages are defined in replacement messages. Defaults are provided. In the web-based manager, you can
modify the default messages in the SSID configuration by selecting Customize Portal Messages. Each SSID
can have its own unique portal content.
Typical modifications for this page would be to change the logo and modify some of the text.
You can change any text that is not part of the HTML code nor a special tag enclosed in double percent (%)
characters.
There is an exception to this rule. The line “Please enter your credentials to continue” is provided by the
%%QUESTION%% tag. You can replace this tag with text of your choice. Except for this item, you should not
remove any tags because they may carry information that the FortiGate unit needs.
l Login failed page—reports that the entered credentials were incorrect and enables the user to try again.
The Login failed page is similar to the Login page. It even contains the same login form. You can change any text
that is not part of the HTML code nor a special tag enclosed in double percent (%) characters.
There is an exception to this rule. The line “Firewall authentication failed. Please try again.” is provided by the
%%FAILED_MESSAGE%% tag. You can replace this tag with text of your choice. Except for this item, you should
not remove any tags because they may carry information that the FortiGate unit needs.
l Disclaimer page—is a statement of the legal responsibilities of the user and the host organization to which the
user must agree before proceeding.(WiFi or SSL VPN only)
l Declined disclaimer page—is displayed if the user does not agree to the statement on the Disclaimer page.
Access is denied until the user agrees to the disclaimer.
When configuring a captive portal through the CLI, you may set security-groups to a specific user group.
The result of this configuration will show an authentication form to users who wish to log in to the captive portal—
not a disclaimer page. If you do not set any security-groups in your configuration, an "Allow all" status will
be in effect, and the disclaimer page will be displayed for users.
The example CLI configuration below shows setting up a captive portal interface without setting security-groups,
resulting in a disclaimer page for users:
config system interface
edit "port1"
set vdom "root"
set ip 172.16.101.1 255.255.255.0
set allowaccess ping https ssh snmp http
set type physical
set explicit-web-proxy enable
set alias "LAN"
set security-mode captive-portal
set snmp-index 1
next
end
This section provides an overview of how the FortiGate unit verifies the identities of administrators, SSL VPN
users, or IPsec VPN peers using X.509 security certificates.
A security certificate is a small text file that is part of a third-party generated public key infrastructure (PKI) to help
guarantee the identity of both the user logging on and the web site they where they are logging in.
A certificate includes identifying information such as the company and location information for the web site, as
well as the third-party company name, the expiry date of the certificate, and the public key.
FortiGate units use X.509 certificates to authenticate single sign-on (SSO) for users. The X.509 standard has
been in use since before 2000, but has gained popularity with the Internet’s increased popularity. X.509 v3 is
defined in RFC 5280 and specifies standard formats for public key certificates, certificate revocation lists, and a
certification path validation algorithm. The unused earlier X.509 version 1 was defined in RFC 1422.
The main difference between X.509 and PGP certificates is that where in PGP anyone can sign a certificate, for
X.509 only a trusted authority can sign certificates. This limits the source of certificates to well known and
trustworthy sources. Where PGP is well suited for one-to-one communications, the X.509 infrastructure is
intended to be used in many different situations including one-to-many communications. Some common
filename extensions for X.509 certificates are listed below.
.pem Privacy Enhanced Mail (PEM) Base64 encoded DER certificate, that uses:
“-----BEGIN CERTIFICATE-----” and
“-----END CERTIFICATE-----”
.cer
Usually binary DER form, but Base64-encoded
.crt Security CERtificate
certificates are common too.
.der
.pfx personal information exchange (PFX) Older format. Came before PKCS#12. Usually today
data is in PKCS#12 format.
Certificates overview
Certificates play a major role in authentication of clients connecting to network services via HTTPS, both for
administrators and SSL VPN users. Certificate authentication is optional for IPsec VPN peers.
Public CA certificates found on the FortiGate are provided through firmware upgrades
and installations.
By default, the FortiGate unit uses a self-signed security certificate to authenticate itself to HTTPS clients. When
the certificate is offered, the client browser displays two security messages.
l The first message prompts users to accept and optionally install the FortiGate unit’s self-signed security certificate.
If the user does not accept the certificate, the FortiGate unit refuses the connection. When the user accepts the
certificate, the FortiGate login page is displayed, and the credentials entered by the user are encrypted before they
are sent to the FortiGate unit. If the user chooses to install the certificate, the prompt is not displayed again.
l Just before the FortiGate login page is displayed, a second message informs users that the FortiGate certificate
distinguished name differs from the original request. This message is displayed because the FortiGate unit
redirects the connection (away from the distinguished name recorded in the self-signed certificate) and can be
ignored.
Optionally, you can install an X.509 server certificate issued by a certificate authority (CA) on the FortiGate unit.
You can then configure the FortiGate unit to identify itself using the server certificate instead of the self-signed
certificate.
For more information, see the FortiOS Handbook SSL VPN guide.
After successful certificate authentication, communication between the client browser and the FortiGate unit is
encrypted using SSL over the HTTPS link.
Certificate-related protocols
There are multiple protocols that are required for handling certificates. These include the Online Certificate
Status Protocol (OCSP), Secure Certificate Enrollment Protocol (SCEP), and Server-based Certificate Validation
Protocol (SCVP).
Online Certificate Status Protocol (OCSP) allows the verification of X.509 certificate expiration dates. This is
important to prevent hackers from changing the expiry date on an old certificate to a future date.
Normally certificate revocation lists (CRLs) are used, but OCSP is an alternate method available. However a CRL
is a public list, and some companies may want to avoid the public exposure of their certificate structure even if it
is only invalid certificates.
The OSCP check on the certificate’s revocation status is typically carried out over HTTP with a request-response
format. The authority responding can reply with a status of good, revoked, or unknown for the certificate in
question.
Secure Certificate Enrollment Protocol (SCEP) is an automated method of signing up for certificates. Typically
this involves generating a request you send directly to the SCEP service, instead of generating a file request that
may or may not be signed locally.
Server-based Certificate Validation Protocol (SCVP) is used to trace a certificate back to a valid root level
certificate. This ensures that each step along the path is valid and trustworthy.
Local certificates
Local certificates are issued for a specific server, or web site. Generally they are very specific, and often for an
internal enterprise network. For example a personal web site for John Smith at www.example.com (such as
http://www.example.com/home/jsmith) would have its own local certificate.
These can optionally be just the certificate file, or also include a private key file and PEM passphrase for added
security.
For information about generating a certificate request, see Generating a certificate signing request on page 117.
For information about installing a local certificate, see Obtaining and installing a signed server certificate from an
external CA on page 120
Remote certificates
Remote certificates are public certificates without a private key. For dynamic certificate revocation, you need to
use an Online Certificate Status Protocol (OCSP) server. The OCSP is configured in the CLI only. Installed
Remote (OCSP) certificates are displayed in the Remote Certificates list. You can select Import to install a
certificate from the management PC.
CA root certificates
CA root certificates are similar to local certificates, however they apply to a broader range of addresses or to
whole company; they are one step higher up in the organizational chain. Using the local certificate example, a CA
root certificate would be issued for all of www.example.com instead of just the smaller single web page.
Certificate signing
The trust in a certificate comes from the authority that signs it. For example if VeriSign signs your CA root
certificate, it is trusted by everyone. While these certificates are universally accepted, it is cumbersome and
expensive to have all certificates on a corporate network signed with this level of trust.
With self-signed certificates nobody, except the other end of your communication, knows who you are and
therefore they do not trust you as an authority. However this level is useful for encryption between two points —
neither point may care about who signed the certificate, just that it allows both points to communicate. This is
very useful for internal networks and communications.
A general rule is that CA signed certificates are accepted and sometimes required, but it is easier to self-sign
certificates when you are able.
For more on the methods of certificate signing see Generating a certificate signing request on page 117.
BIOS V4 certificates:
l Fortinet_CA
l Fortinet_Sub_CA
l Fortinet_Factory
BIOS V3 certificates:
l Fortinet_CA_Backup
l Fortinet_Factory_Backup
When FortiOS connects to FortiGuard, FortiCloud, FortiManager, FortiAnalyzer, FortiSandbox as a client, the
BIOS certificate Fortinet_Factory will be the default client certificate. When the server returns its certificate
(chain) back, FortiOS looks up the issuer of the server certificate and either keeps client certificate as is or
switches to the BIOS certificate Fortinet_Factory_Backup. This process occurs in one handshake.
When FortiOS connects to FortiCare, the BIOS certificate Fortinet_Factory is the only client certificate and
Server Name Indication (SNI) is set. There is no switchover of certificate during SSL handshake.
When FortiOS acts as a server when connected by FortiExtender, FortiSwitch, FortiAP, etc., Fortinet_Factory is
the default server certificate. FortiOS detects SNI in client hello, and if no SNI is found or if the CN in SNI is
different from the CN of Fortinet_CA, it switches to use the Fortinet_Factory_Backup.
Managing security certificates is required due to the number of steps involved in both having a certificate request
signed, and then distributing the correct files for use.
You use the FortiGate unit or CA software such as OpenSSL to generate a certificate request. That request is a
text file that you send to the CA for verification, or alternately you use CA software to self-validate. Once
validated, the certificate file is generated and must be imported to the FortiGate unit before it can be used. These
steps are explained in more detail later in this section.
This section provides procedures for generating certificate requests, installing signed server certificates, and
importing CA root certificates and CRLs to the FortiGate unit.
For information about how to install root certificates, CRLs, and personal or group certificates on a remote client
browser, refer to your browser’s documentation.
When you generate a CSR, a private and public key pair is created for the FortiGate unit. The generated request
includes the public key of the FortiGate unit and information such as the FortiGate unit’s public static IP address,
domain name, or email address. The FortiGate unit’s private key remains confidential on the FortiGate unit.
After you submit the request to a CA, the CA will verify the information and register the contact information on a
digital certificate that contains a serial number, an expiration date, and the public key of the CA. The CA will then
sign the certificate, and you install the certificate on the FortiGate unit.
The Certificate Request Standard is a public key cryptography standard (PKCS) published by RSA, specifically
PKCS10 which defines the format for CSRs. This is defined in RFC 2986.
1. Go to System > Certificates.
2. Select Generate.
3. In the Certificate Name field, enter a unique meaningful name for the certificate request. Typically, this would be
the hostname or serial number of the FortiGate unit or the domain of the FortiGate unit such as example.com.
Do not include spaces in the certificate name. This will ensure compatibility of
a signed certificate as a PKCS12 file to be exported later on if required.
Prior to FortiOS 5.4, passwords for local certificates that were generated via either
SCEP or CLI could not have their passwords reset. Passwords can be set in the CLI
using the following command:
config vpn certificate local
edit <name>
set password <password>
next
end
4. Enter values in the Subject Information area to identify the FortiGate unit:
l If the FortiGate unit has a static IP address, select Host IPand enter the public IP address of the FortiGate
unit. If the FortiGate unit does not have a public IP address, use an email address (or fully qualified domain
l If you select E-Mail, enter the email address of the owner of the FortiGate unit.
5. Enter values in the Optional Information area to further identify the FortiGate unit.
Organization Unit Name of your department. You can enter a series of OUs up to a maximum
of 5. To add or remove an OU, use the plus (+) or minus (-) icon.
Locality (City) Name of the city or town where the FortiGate unit is installed.
State/Province Name of the state or province where the FortiGate unit is installed.
Subject Alternative Name Optionally, enter one or more alternative names for which the certificate is
also valid. Separate names with a comma. A name can be:
l e-mail address
l IP address
l URI
l DNS name (alternatives to the Common Name)
l directory name (alternatives to the Distinguished Name)
You must precede the name with the name type. Examples:
IP:1.1.1.1
email:[email protected]
email:[email protected]
URI:http://my.url.here/
Password for private key Option to export local certificate and its private key in password protected
p12.
9. Select OK.
10. The request is generated and displayed in the Local Certificates list with a status of PENDING.
11. Select the Download button to download the request to the management computer.
12. In the File Download dialog box, select Save and save the Certificate Signing Request on the local file system of
the management computer.
13. Name the file and save it on the local file system of the management computer.
The certificate request is ready for the certificate authority to be signed.
Server certificate
1. Generate a Certificate Signing Request (CSR) on the FortiGate unit.
2. Copy the CSR base-64 encoded text (PKCS10 or PKCS7) into the CA software and generate the certificate.
PKCS10 is the format used to send the certificate request to the signing authority. PKCS7 is the format the signing
authority can use for the newly signed certificate.
3. Export the certificate as a X.509 DER encoded binary file with .CER extension
4. Upload the certificate file to the FortiGate unit Local Certificates page (type is Certificate).
CA certificate
1. Retrieve the CA Certificate from the CA software as a DER encoded file.
2. Import the CA certificate file to the FortiGate unit at System > Certificates and select Import > Certificates.
PKI certificate
1. Generate a Certificate Signing Request (CSR) on the FortiGate unit.
2. Copy the CSR base-64 encoded text (PKCS#10 or PKCS#7) into the CA software and generate the certificate.
PKCS10 is the format used to send the certificate request to the signing authority. PKCS7 is the format the signing
authority can use for the newly signed certificate.
3. Export the certificate as a X.509 DER encoded binary file with .CER extension.
4. Install the certificate in the user’s web browser or IPsec VPN client as needed.
1. Using the web browser on the management computer, browse to the CA web site.
2. Follow the CA instructions for a base-64 encoded PKCS#10 certificate request and upload your certificate request.
3. Follow the CA instructions to download their root certificate and CRL.
When you receive the signed server certificate from the CA, install the certificate on the FortiGate unit.
1. On the FortiGate unit, go to System > Certificates and select Import > Local Certificates.
2. From Type, select Local Certificate.
3. Select Browse, browse to the location on the management computer where the certificate was saved, select the
certificate, and then select Open.
4. Select OK, and then select Return.
1. After you download the root certificate of the CA, save the certificate on the management computer. Or, you can
use online SCEP to retrieve the certificate.
2. On the FortiGate unit, go to System > Certificates and select Import > CA Certificates.
3. Do one of the following:
l To import using SCEP, select SCEP. Enter the URL of the SCEP server from which to retrieve the CA
certificate. Optionally, enter identifying information of the CA, such as the filename.
l To import from a file, select Local PC , then select Browse and find the location on the management
computer where the certificate has been saved. Select the certificate, and then select Open.
5. Select OK, and then select Return.
The system assigns a unique name to each CA certificate. The names are numbered consecutively (CA_Cert_1,
CA_Cert_2, CA_Cert_3, and so on).
A Certificate Revocation List (CRL) is a list of the CA certificate subscribers paired with certificate status
information. The list contains the revoked certificates and the reason(s) for revocation. It also records the
certificate issue dates and the CAs that issued them.
When configured to support SSL VPNs, the FortiGate unit uses the CRL to ensure that the certificates belonging
to the CA and remote peers or clients are valid. The CRL has an “effective date” and a “next update” date. The
interval is typically 7 days (for Microsoft CA). FortiOS will update the CRL automatically. Also, there is a CLI
command to specify an “update-interval” in seconds. Recommendation should be 24 hours (86400 seconds) but
depends on company security policy.
1. After you download the CRL from the CA web site, save the CRL on the management computer.
2. Go to System > Certificates and select Import > CRL.
3. Do one of the following:
l To import using an HTTP server, select HTTP and enter the URL of the HTTP server.
l To import using an LDAP server see this KB article.
l To import using an SCEP server, select SCEP and select the Local Certificate from the list. Enter the URL of
the SCEP server from which the CRL can be retrieved.
l To import from a file, select Local PC , then select Browse and find the location on the management
computer where the CRL has been saved. Select the CRL and then select Open.
5. Select OK, and then select Return.
The following CLI syntax can be entered to import a local certificate file:
execute vpn certificate local import tftp <file name> <tftp ip address> <file type> <Enter
for 'cer'>|<password for 'p12'>
For example:
execute vpn certificate local import tftp FGTF-extern.p12 10.1.100.253 p12 123456
The following CLI command is available under log fortianalyzer setting to allow you to specify the
certificate used to communicate with FortiAnalyzer.
CLI syntax
config log fortianalyzer setting
set certificate <name>
end
Troubleshooting certificates
There are times when there are problems with certificates — a certificate is seen as expired when its not, or it
can’t be found. Often the problem is with a third party web site, and not FortiOS. However, some problems can
be traced back to FortiOS such as DNS or routing issues.
l It really has expired based on the “best before” date in the certificate
l The FortiGate unit clock is not properly set. If the FortiGate clock is fast, it will see a certificate as expired before
the expiry date is really here.
l The requesting server clock is not properly set. A valid example is if your certificate is 2 hours from expiring, a server
more than two time zones away would see the certificate as expired. Otherwise, if the server’s clock is set wrongly it
will also have the same effect.
l The certificate was revoked by the issuer before the expiry date. This may happen if the issuer believes a certificate
was either stolen or misused. Its possible it is due to reasons on the issuer’s side, such as a system change or such.
In either case it is best to contact the certificate issuer to determine what is happening and why.
l The web site uses an unrecognized self-signed certificate. These are not secure because anyone can sign them. If
you accept self-signed certificates you do so at your own risk. Best practices dictate that you must confirm the ID of
the web site using some other method before you accept the certificate.
l The certificate is valid for a different domain. A certificate is valid for a specific location, domain, or sub-section of a
domain such as one certificate for support.example.com that is not valid for marketing.example.com. If
you encounter this problem, contact the webmaster for the web site to inform them of the problem.
l There is a DNS or routing problem. If the web site’s certificate cannot be verified, it will not be accepted. Generally
to be verified, your system checks with the third party certificate signing authority to verify the certificate is valid. If
you cannot reach that third party due to some DNS or routing error, the certificate will not be verified.
l Firewall is blocking required ports. Ensure that any firewalls between the requesting computer and the web site
allow the secure traffic through the firewall. Otherwise a hole must be opened to allow it through. This includes
ports such as 443 (HTTPS) and 22 (SSH).
Local certificates
In the config vpn certificate local command, you can specify automatic certificate renewal. The
relevant fields are:
scep-url <URL_str> The URL of the SCEP server. This can be HTTP or HTTPS. The
following options appear after you add the <URL_str>.
auto-regenerate-days <days_ How many days before expiry the FortiGate unit requests an
int> updated local certificate. The default is 0, no auto-update.
auto-regenerate-days-warning How many days before local certificate expiry the FortiGate
<days_int> generates a warning message. The default is 0, no warning.
CA certificates
In the config vpn certificate ca command, you can specify automatic certificate renewal. The
relevant fields are:
Variable Description
scep-url <URL_str> The URL of the SCEP server. This can be HTTP or HTTPS.
Variable Description
http-url <http_url> URL of the server used for automatic CRL certificate updates.
This can be HTTP or HTTPS.
scep-url <scep_url> URL of the SCEP CA server used for automatic CRL certificate
updates. This can be HTTP or HTTPS.
update-vdom <update_vdom> VDOM used to communicate with remote SCEP server for CRL
auto-update.
As an alternative, you can back up and restore the entire FortiGate configuration
through the System Information widget on the Dashboard of the web-based
manager. Look for [Backup] and [Restore] in the System Configuration row. The
backup file is created in a FortiGate-proprietary format.
This procedure exports a server (local) certificate and private key together as a password protected PKCS12 file.
The export file is created through a customer-supplied TFTP server. Ensure that your TFTP server is running and
accessible to the FortiGate unit before you enter the command.
l <cert_name> is the name of the server certificate; typing ? displays a list of installed server certificates.
l <exp_filename> is a name for the output file.
l <tftp_ip> is the IP address assigned to the TFTP server host interface.
3. Move the output file from the TFTP server location to the management computer for future reference.
execute vpn certificate local import tftp <file_name> <tftp_ip_address> <file_type> <Enter
for 'cer'>|<password for 'p12'>
For example:
execute vpn certificate local import tftp FGTF-extern.p12 10.1.100.253 p12 123456
To import separate server certificate and private key files - web-based manager
Use the following procedure to import a server certificate and the associated private key file when the server
certificate request and private key were not generated by the FortiGate unit. The two files to import must be
available on the management computer.
You can configure certificate-based authentication for FortiGate administrators, SSL VPN users, and IPsec VPN
users.
In Microsoft Windows 7, you can use the certificate manager to keep track of all the different certificates on your
local computer. To access certificate manager, in Windows 7 press the Windows key, enter “certmgr.msc” at the
search prompt, and select the displayed match. Remember that in addition to these system certificates, many
applications require you to register certificates with them directly.
To see FortiClient certificates, open the FortiClient Console, and select VPN. The VPN menu has options for My
Certificates (local or client) and CA Certificates (root or intermediary certificate authorities). Use Import on those
screens to import certificate files from other sources.
l Obtain a signed personal certificate for the administrator from a CA and load the signed personal certificate into the
web browser on the management computer according to the browser documentation.
l Install the root certificate and the CRL from the issuing CA on the FortiGate unit (see Installing a CA root certificate
and CRL to authenticate remote clients on page 120 ).
l Create a PKI user account for the administrator.
l Add the PKI user account to a firewall user group dedicated to PKI-authenticated administrators.
l In the administrator account configuration, select PKI as the account Type and select the User Group to which
the administrator belongs.
X.509 certificates can be used to authenticate IPsec VPN peers or clients, or SSL VPN clients. When configured
to authenticate a VPN peer or client, the FortiGate unit prompts the VPN peer or client to authenticate itself using
the X.509 certificate. The certificate supplied by the VPN peer or client must be verifiable using the root CA
certificate installed on the FortiGate unit in order for a VPN tunnel to be established.
1. Install a signed server certificate on the FortiGate unit and install the corresponding root certificate (and CRL)
from the issuing CA on the remote peer or client.
2. Obtain a signed group certificate from a CA and load the signed group certificate into the web browser used by
each user. Follow the browser documentation to load the certificates.
3. Install the root certificate and the CRL from the issuing CA on the FortiGate unit (see Installing a CA root
certificate and CRL to authenticate remote clients on page 120).
4. Create a PKI user for each SSL VPN user. For each user, specify the text string that appears in the Subject field of
the user’s certificate and then select the corresponding CA certificate.
5. Use the config user peergrp CLI command to create a peer user group. Add to this group all of the SSL
VPN users who are authenticated by certificate.
6. Go to Policy & Objects > IPv4 Policy.
7. Edit the SSL-VPN security policy.
8. Select the user group created earlier in the Source User(s) field.
9. Select OK.
The CA and local certificate configuration is available per-VDOM. When an admin uploads a certificate to a
VDOM, it will only be accessible inside that VDOM. When an admin uploads a certificate to global, it will be
accessible to all VDOMs and global.
There are factory default certificates such as Fortinet_CA_SSL, Fortinet_SSL, Fortinet_Wifi, and Fortinet_
Factory. These certificates are moved to per-VDOM and automatically generated when a new VDOM is created.
The Fortinet_Firmware certificate has been removed and all the attributes that use
Fortinet_Firmware now use Fortinet_Factory.
CLI Changes
range can be global or per-VDOM, if the certificate file is imported from global, it is a global certificate. If the
certificate file is imported from a VDOM, it is VDOM certificate.
l factory: The factory certificate file with FortiOS version, this includes: Fortinet_CA_SSL, Fortinet_SSL,
PositiveSSL_CA, Fortinet_Wifi, Fortinet_Factory.
l user: Certificate file imported by the user.
l fortiguard: Certificate file imported from FortiGuard.
config certificate local
edit Fortinet_Factory
set range {global | vdom}
set source {factory | user | fortiguard}
end
end
GUI Changes
Global and new VDOMs have the following factory default certificates:
These certificates are created automatically when a new VDOM is created, with every VDOM having its own
versions of these certificates.
This example follows all the steps required to create and install a local certificate on the FortiGate unit, without
using CA software.
The FortiGate unit is called myFortiGate60, and is located at 10.11.101.101 (a private IP address) and
http://myfortigate.example.com. Mr. John Smith ([email protected]) is the IT administrator
for this FortiGate unit, and the unit belongs to the Sales department located in Greenwich, London, England.
1. Go to System > Certificates.
2. Select Generate.
3. In the Certificate Name field, enter myFortiGate60.
Do not include spaces in the certificate name. This will ensure compatibility of a
signed certificate as a PKCS12 file to be exported later on if required.
Organization Example.com
State/Province London
Country England
e-mail [email protected]
This example explains how to generate a certificate using OpenSSL on MS Windows. OpenSSL is available for
Linux and Mac OS as well, however their terminology will vary slightly from what is presented here.
Assumptions
Before starting this procedure, ensure that you have downloaded and installed OpenSSL on Windows. One
source is: http://www.slproweb.com/products/Win32OpenSSL.html.
1. At the Windows command prompt, go to the OpenSSL bin directory. If you installed to the default location this will
be the command:
cd c:\OpenSSL-Win32\bin
2. Enter the following command to generate the private key. You will be prompted to enter your PEM pass phrase.
Choose something easy to remember such as fortinet123.
3. The following command will generate the certificate using the key from the previous step.
openssl req -new -x509 -days 3650 -extensions v3_ca -key fgtcapriv.key -out
fgtca.crt
This step generates an X509 CA certificate good for 10 years that uses the key generated in the
previous step. The certificate filename is fgtca.crt.
You will be prompted to enter information such as PEM Pass Phrase from the previous step, Country
Name, State, Organization Name, Organizational Unit (such as department name), Common Name
(the FQDN), and Email Address.
1. Go to System > Certificates.
2. Select Import > Local Certificate.
3. Select Certificate for Type.
Fields for Certificate file, Key file, and Password are displayed.
4. For Certificate file, enter c:\OpenSSL-Win32\bin\fgtca.crt.
5. For Key file, enter c:\OpenSSL-Win32\bin\fgtcapriv.key.
6. For Password, enter the PEM Pass Phrase you entered earlier, such as fortinet123.
7. Select OK.
The Certificate will be added to the list of Local Certificates and be ready for use. It will appear in the list as the
filename you uploaded — fgtca.You can add comments to this certificate to make it clear where its from and
how it is intended to be used. If you download the certificate from FortiOS, it is a .CER file.
It can now be used in Authenticating IPsec VPN users with security certificates on page 127, and Authenticating
SSL VPN users with security certificates on page 126.
This example explains how to generate a CA signed SSL certificate using OpenSSL on MS Windows. OpenSSL is
available for Linux and Mac OS as well, however their terminology will vary slightly from what is presented here.
Assumptions
l Before starting this procedure, ensure that you have downloaded and installed OpenSSL on MS Windows. One
download source is http://www.slproweb.com/products/Win32OpenSSL.html.
1. At the Windows command prompt, go to the OpenSSL bin directory. If you installed to the default location this will
be the following command:
cd c:\OpenSSL-Win32\bin
2. Enter the following command to generate the private key. You will be prompted to enter your PEM pass phrase.
Choose something easy to remember such as fortinet.
3. Create a certificate signing request for the SSL certificate. This step requires you to enter the information listed in
step 3 of the previous example — To generate the private key and certificate. You can leave the Challenge
Password blank.
Most Certificate Authorities will ignore the value that is set in the CSR and use
whatever value they are set to use in their configuration. This means that the client will
likely need to modify their openssl.conf file to use SHA-256 (or another SHA-2 variant).
4. Using the CSR from the previous step, you can now create the SSL certificate using the CA certificate that was
created in Example — Generate and Import CA certificate with private key pair on OpenSSL.
openssl x509 -req -days 365 -in fgtssl.csr -CA fgtca.crt -CAkey fgtcapriv.key -set_
serial 01 -out fgtssl.crt
This will generate an X.509 certificate good for 365 days signed by the CA certificate fgtca.crt.
1. At the Windows command prompt, go to the OpenSSL bin directory. If you installed to the default location this will
be the following command:
cd c:\OpenSSL-Win32\bin
2. Enter the following command to generate the private key. You will be prompted to enter your PEM pass phrase.
Choose something easy to remember such as fortinet.
These commands:
1. Go to System > Certificates.
2. Select Import > Local Certificate.
3. Select Certificate for Type.
Fields for Certificate file, Key file, and Password are displayed.
4. For Certificate file, enter c:\OpenSSL-Win32\bin\fgtssl.crt.
5. For Key file, enter c:\OpenSSL-Win32\bin\fgtssl.key.
6. For Password, enter the PEM Pass Phrase you entered, such as fortinet.
7. Select OK.
The SSL certificate you just uploaded can be found under System > Certificates under the name of the file you
uploaded — fgtssl.
end
The get command will display all the certificate’s information. If it is not there or the information is not correct,
you will need to remove the corrupted certificate (if it is there) and upload it again from your PC.
This assigns the fgtssl certificate as the SSL server certificate. For more information see the FortiOS Handbook
SSL VPN guide.
There are two different ways users can authenticate through a FortiAuthenticator unit.
User not logged in. Click Login to go to the FortiAuthenticator login page.
The SSO widget sets a cookie on the user’s browser. When the user browses to a page containing the login
widget, the FortiAuthenticator unit recognizes the user and updates its database if the user’s IP address has
changed. The user will not need to re-authenticate until the login timeout expires, which can be up to 30 days.
The FortiClient SSO Mobility Agent, a feature of FortiClient Endpoint Security v5.0, must be configured to
communicate with the appropriate FortiAuthenticator unit. After that, the agent automatically provides user name
and IP address information to the FortiAuthenticator unit for transparent authentication.
You can configure either or both of these authentication types on your network.
SSO widget
You need to configure the Single Sign-On portal on the FortiAuthenticator unit. Go to Fortinet SSO Methods >
SSO > Portal Services to do this. Copy the Embeddable login widget code for use on your organization’s
home page. Identity-based security policies on the FortiGate unit determine which users or groups of users can
access which network resources.
On the FortiAuthenticator unit, you need to select Enable FortiClient SSO Mobility Agent Service, optionally
select Enable Authentication and choose a Secret key. Go to Fortinet SSO Methods > SSO > General.
You need to provide your users the FortiAuthenticator IP address and secret key so that they can configure the
FortiClient SSO Mobility Agent on their computers. See Configuring the FortiGate unit on page 136.
The FortiAuthenticator unit can poll FortiGate units, Windows Active Directory, RADIUS servers, LDAP servers,
and FortiClients for information about user logon activity.
Enable Windows Active Select for integration with Windows Active Directory.
Directory domain
controllers
Enable Radius accounting Select if you want to use a Remote Radius server.
SSO clients
Enable FortiClient SSO Select both options to enable single sign-on by clients running FortiClient
Mobility Agent service Endpoint Security. Enter the Secret key. Be sure to use the same secret
key in the FortiClient Single Sign-On Mobility Agent settings.
Enable Authentication
5. Select OK.
For more information, see the FortiAuthenticator Administration Guide.
When you open the server, you can see the list of groups. You can use the groups in identity-based security
policies.
The user’s device must have at least FortiClient Endpoint Security v5.0 installed. Only two pieces of information
are required to set up the SSO Mobility Agent feature: the FortiAuthenticator unit IP address and the preshared
secret.
The user needs to know the FortiAuthenticator IP address and preshared secret to set up the SSO Mobility Agent.
Or, you could preconfigure FortiClient.
The FortiGate unit can authenticate users transparently and allow them network access based on their privileges
in Windows AD. This means that users who have logged on to the network are not asked again for their
credentials to access network resources through the FortiGate unit, hence the term “Single Sign-On”.
Introduced in FortiOS 5.0, Single Sign-On (SSO) support provided by FortiGate polling of domain controllers is
simpler than the earlier method that relies on agent software installed on Windows AD network servers. No
Fortinet software needs to be installed on the Windows network. The FortiGate unit needs access only to the
Windows AD global catalog and event log.
When a Windows AD user logs on at a workstation in a monitored domain, the FortiGate unit
l detects the logon event in the domain controller’s event log and records the workstation name, domain, and user,
l resolves the workstation name to an IP address,
l uses the domain controller’s LDAP server to determine which groups the user belongs to,
l creates one or more log entries on the FortiGate unit for this logon event as appropriate.
When the user tries to access network resources, the FortiGate unit selects the appropriate security policy for the
destination. The selection consist of matching the FSSO group or groups the user belongs to with the security
policy or policies that match that group. If the user belongs to one of the permitted user groups associated with
that policy, the connection is allowed. Otherwise the connection is denied.
On the FortiGate unit, security policies control access to network resources based on user groups. With Fortinet
Single Sign On, this is also true but each FortiGate user group is associated with one or more Windows AD user
groups. This is how Windows AD user groups get authenticated in the FortiGate security policy.
Fortinet Single Sign On sends information about Windows user logons to FortiGate units. If there are many users
on your Windows AD domains, the large amount of information might affect the performance of the FortiGate
unit.
To configure your FortiGate unit to operate with either a Windows AD or a Novell eDirectory FSSO install, you
l Configure LDAP access to the Windows AD global catalog. See Configuring LDAP server access on page 139.
l Configure the LDAP Server as a Single Sign-On server. See Configuring the LDAP Server as a Single Sign-On
server on page 140.
l Add Active Directory user groups to FortiGate FSSO user groups. See Creating Fortinet Single Sign-On (FSSO)
user groups on page 141.
l Create security policies for FSSO-authenticated groups. See Creating security policies on page 141.
l Optionally, specify a guest protection profile to allow guest access. See Enabling guest access through FSSO
security policies on page 143
The LDAP configuration on the FortiGate unit not only provides access to the LDAP server, it sets up the retrieval
of Windows AD user groups for you to select in FSSO. The LDAP Server configuration, found under User
& Device > LDAP Servers, includes a function to preview the LDAP server’s response to your distinguished
name query. If you already know the appropriate Distinguished Name (DN) and User DN settings, you may be
able to skip some of the following steps.
3. Select OK.
In this situation, Example.com is a company that has its employees and authentication servers on an internal
network. The FortiGate unit intercepts all traffic leaving the internal network and requires FSSO authentication to
access network resources on the Internet. The following procedure configures the security policy for FSSO
authentication. FSSO is installed and configured including the RADIUS server, FSSO Collector agent, and user
groups on the FortiGate
For the following procedure, the internal interface is port1 and the external interface connected to the Internet
is port2. There is an address group for the internal network called company_network. The FSSO user group
is called fsso_group, and the FSSO RADIUS server is fsso_rad_server.
Schedule always
Action ACCEPT
NAT ON
UTM Security Profiles ON for AntiVirus, IPS, Web Filter, and Email Filter, all using default
profiles.
3. Select OK.
4. Ensure the FSSO authentication policy is higher in the policy list than more general policies for the same
interfaces.
Here is an example of how this FSSO authentication policy is used. Example.com employee on the internal
company network logs on to the internal network using their RADIUS username and password. When that user
attempts to access the Internet, which requires FSSO authentication, the FortiGate authentication security policy
intercepts the session, checks with the FSSO Collector agent to verify the user’s identity and credentials, and
then if everything is verified the user is allowed access to the Internet.
To enable guest access in your FSSO security policy, add an identity-based policy assigned to the built-in user
group SSO_Guest_Users. Specify the services, schedule and UTM profiles that apply to guest users —
typically guests have access to a reduced set of services. See Creating security policies on page 141.
There are two types of FortiOS log messages — firewall and event. FSSO related log messages are generated
from authentication events. These include user logon and log off events, and NTLM authentication events. These
log messages are central to network accounting policies, and can also be useful in troubleshooting issues. For
more information on firewall logging, see Enabling security logging on page 87. For more information on logging,
see the FortiOS Handbook Logging and Reporting guide.
When VDOMs are enabled certain options may not be available, such as CPU and memory usage events. You
can enable event logs only when you are logged on to a VDOM; you cannot enable event logs globally.
To ensure you log all the events needed, set the minimum log level to Notification or Information. Firewall
logging requires Notification as a minimum. The closer to Debug level, the more information will be logged.
System activity event All system-related events, such as ping server failure and gateway status.
User activity event All administration events, such as user logins, resets, and configuration
updates.
3. Select Apply.
List of FSSO related log messages
For more information on logging, see the FortiOS Handbook Logging and Reporting guide.
Testing FSSO
Once FSSO is configured, you can easily test to ensure your configuration is working as expected. For additional
FSSO testing, see Troubleshooting FSSO on page 145.
1. Logon to one of the stations on the FSSO domain, and access an Internet resource.
2. Connect to the CLI of the FortiGate unit, and if possible log the output.
3. Enter the following command:diagnose debug authd fsso list
4. Check the output. If FSSO is functioning properly you will see something similar to the following:
----FSSO logons----
IP: 192.168.1.230 User: ADMINISTRATOR Groups: VLAD-AD/DOMAIN USERS
IP: 192.168.1.240 User: ADMINISTRATOR Groups: VLAD-AD/DOMAIN USERS
Total number of users logged on: 2
----end of FSSO logons----
The exact information will vary based on your installation.
5. Check the FortiGate event log, for FSSO-auth action or other FSSO related events with FSSO information in the
message field.
6. To check server connectivity, run the following commands from the CLI:
FGT# diagnose debug enable
FGT# diagnose debug authd fsso server-status
FGT# Server Name Connection Status
----------- -----------------
SBS-2003 connected
Troubleshooting FSSO
When installing, configuring, and working with FSSO some problems are quite common. A selection of these
problems follows including explanations and solutions.
l Ensure all firewalls are allowing the FSSO required ports through.
FSSO has a number of required ports that must be allowed through all firewalls or connections will fail. These include:
ports 139, 389 (LDAP), 445, 636 (LDAP).
l Ensure there is at least 64kbps bandwidth between the FortiGate unit and domain controllers. If there is insufficient
bandwidth, some FSSO information might not reach the FortiGate unit. The best solution is to configure traffic
shaping between the FortiGate unit and the domain controllers to ensure that the minimum bandwidth is always
available.
Users on a particular computer (IP address) can not access the network
Windows AD Domain Controller agent gets the username and workstation where the logon attempt is coming
from. If there are two computers with the same IP address and the same user trying to logon, it is possible for the
authentication system to become confused and believe that the user on computer_1 is actually trying to access
computer_2.
Windows AD does not track when a user logs out. It is possible that a user logs out on one computer, and
immediate logs onto a second computer while the system still believes the user is logged on the original
computer. While this is allowed, information that is intended for the session on one computer may mistakenly end
up going to the other computer instead. The result would look similar to a hijacked session.
Solutions
l Ensure each computer has separate IP addresses.
l Encourage users to logout on one machine before logging onto another machine.
l If multiple users have the same username, change the usernames to be unique.
l Shorten timeout timer to flush inactive sessions after a shorter time.
Solution
The group of the guest users was not included in a policy, so they do not fall under the guest account. To give
them access, associate their group with a security policy.
Additionally, there is a default group called SSO_Guest_Users. Ensure that group is part of an identity-based
security policy to allow traffic.
FortiOS can provide single sign-on capabilities to Windows AD, Citrix, Novell eDirectory, or, as of FortiOS 5.4,
Microsoft Exchange users with the help of agent software installed on these networks. The agent software sends
information about user logons to the FortiGate unit. With user information such as IP address and user group
memberships from the network, FortiGate security policies can allow authenticated network access to users who
belong to the appropriate user groups without requesting their credentials again.
For Windows AD networks, FortiGate units can provide SSO capability without agent software by directly polling
the Windows AD domain controllers. For information about this type of SSO, seeSingle Sign-On to Windows AD
on page 138.
Fortinet Single Sign-On (FSSO), through agents installed on the network, monitors user logons and passes that
information to the FortiGate unit. When a user logs on at a workstation in a monitored domain, FSSO
l detects the logon event and records the workstation name, domain, and user,
l resolves the workstation name to an IP address,
l determines which user groups the user belongs to,
l sends the user logon information, including IP address and groups list, to the FortiGate unit
l creates one or more log entries on the FortiGate unit for this logon event as appropriate.
When the user tries to access network resources, the FortiGate unit selects the appropriate security policy for the
destination. If the user belongs to one of the permitted user groups associated with that policy, the connection is
allowed. Otherwise the connection is denied.
FSSO can also provide NTLM authentication service for requests coming from
FortiGate. SSO is very convenient for users, but may not be supported across all
platforms. NTLM is not as convenient, but it enjoys wider support. See FSSO NTLM
authentication support on page 153.
eDirectory agent
The eDirectory agent is installed on a Novell network to monitor user logons and send the required information to
the FortiGate unit. It functions much like the Collector agent on a Windows AD domain controller.The agent can
obtain information from the Novell eDirectory using either the Novell API or LDAP.
The Collector can obtain user group information from the DC agent or optionally, a FortiGate unit can obtain
group information directly from AD using Lightweight Directory Access Protocol (LDAP).
On a Windows AD network, the FSSO software can also serve NT LAN Manager (NTLM) requests coming from
client browsers (forwarded by the FortiGate unit) with only one or more Collector agents installed. See FSSO
NTLM authentication support on page 153.
The CA is responsible for DNS lookups, group verification, workstation checks, and as mentioned FortiGate
updates of logon records. The FSSO Collector Agent sends Domain Local Security Group and Global Security
Group information to FortiGate units. The CA communicates with the FortiGate over TCP port 8000 and it listens
on UDP port 8002 for updates from the DC agents.
The FortiGate unit can have up to five CAs configured for redundancy. If the first on the list is unreachable, the
next is attempted, and so on down the list until one is contacted. See Configuring FSSO on FortiGate units on
page 180.
All DC agents must point to the correct Collector agent port number and IP address on domains with multiple
DCs.
A FortiAuthenticator unit can act much like a Collector agent, collecting Windows AD
user logon information and sending it to the FortiGate unit. It is particularly useful in
large installations with several FortiGate units. For more information, see the
FortiAuthenticator Administration Guide.
Support for the Exchange server is configured on the Back-end FSSO collector agent. For more information on
the collector agent, see Collector agent installation:
Server IP/Hostname Enter the IP address or the hostname of your exchange server.
Polling forwarded This option for scenarios when you do not want that CA polls the Exchange
event log Server logs directly. In this case you need to configure event log forwarding on
the Exchange server. Exchange event logs can be forwarded to any member
server. If you enable this, instead of the IP of the Exchange server configured in
the previous step, you must then configure the IP of this member server. CA will
then contact the member server.
Ignore Name Because CA will also check Windows log files for logon events and when a user
authenticates to Exchange Server there is also a logon event in Windows event
log, which CA will read and this will overwrite the Exchange Server logon event
(ESEventLog) on CA. So it is recommended to set the ignore list to the domain
the user belongs to.
To do so, enter the domain name in the Ignore Name field and select Add.
Installation Complex — Multiple installations: one Easy — Only Collector agent installation,
agent per DC plus Collector agent, no reboot required
requires a reboot
Network load Each DC agent requires minimum 64kpbs Increase polling period during busy period
bandwidth, adding to network load to reduce network load
DC Agent mode
DC Agent mode is the standard mode for FSSO. In DC Agent mode, a Fortinet authentication agent is installed
on each domain controller. These DC agents monitor user logon events and pass the information to the Collector
agent, which stores the information and sends it to the FortiGate unit.
The DC agent installed on the domain controllers is not a service like the Collector agent — it is a DLL file called
dcagent.dll and is installed in the Windows\system32 directory. It must be installed on all domain
controllers of the domains that are being monitored.
DC Agent mode provides reliable user logon information, however you must install a DC agent on every domain
controller. A reboot is needed after the agent is installed. Each installation requires some maintenance as well.
For these reasons it may not be possible to use the DC Agent mode.
Each domain controller connection needs a minimum guaranteed 64kpbs bandwidth to ensure proper FSSO
functionality. You can optionally configure traffic shapers on the FortiGate unit to ensure this minimum bandwidth
is guaranteed for the domain controller connections.
Polling mode
In Polling mode there are three options — NetAPI polling, Event log polling, and Event log using WMI. All share
the advantages of being transparent and agentless.
NetAPI polling is used to retrieve server logon sessions. This includes the logon event information for the
Controller agent. NetAPI runs faster than Event log polling but it may miss some user logon events under heavy
system load. It requires a query round trip time of less than 10 seconds.
Event log polling may run a bit slower, but will not miss events, even when the installation site has many users
that require authentication. It does not have the 10 second limit on NetAPI polling. Event log polling requires fast
network links. Event log polling is required if there are Mac OS users logging into Windows AD.
Event log using WMI polling: WMI is a Windows API to get system information from a Windows server, CA is a
WMI client and sends WMI queries for user logon events to DC, which in this case is a WMI server. Main
advantage in this mode is that CA does not need to search security event logs on DC for user logon events,
instead, DC returns all requested logon events via WMI. This also reduces network load between CA and DC.
In Polling mode, the Collector agent polls port 445 of each domain controller for user logon information every few
seconds and forwards it to the FortiGate unit. There are no DC Agents installed, so the Collector agent polls the
domain controllers directly.
A major benefit of Polling mode is that no FSSO DC Agents are required. If it is not possible to install FSSO DC
Agents on your domain controllers, this is the alternate configuration available to you. Polling mode results in a
less complex install, and reduces ongoing maintenance. The minimum permissions required in Polling mode are
to read the event log or call NetAPI.
Standard mode uses regular Windows convention: Domain\Username. Advanced mode uses LDAP convention:
CN=User, OU=Name, DC=Domain.
If there is no special requirement to use LDAP— best practices suggest you set up FSSO in Standard mode. This
mode is easier to set up, and is usually easier to maintain and troubleshoot.
Standard and advanced modes have the same level of functionality with the following exceptions:
l Users have to create Group filters on the Collector agent. This differs from Advanced mode where Group filters are
configured from the FortiGate unit. Fortinet strongly encourages users to create filters from CA.
l Advanced mode supports nested or inherited groups. This means that users may be a member of multiple
monitored groups. Standard mode does not support nested groups so a user must be a direct member of the group
being monitored.
Citrix users do not have unique IP addresses. When a Citrix user logs on, the TS agent assigns that user a range
of ports. By default each user has a range of 200 ports.
l detects the logon event by polling the eDirectory server and records the IP address and user ID,
l looks up in the eDirectory which groups this user belongs to,
l sends the IP address and user groups information to the FortiGate unit.
When the user tries to access network resources, the FortiGate unit selects the appropriate security policy for the
destination. If the user belongs to one of the permitted user groups, the connection is allowed.
For a Novell network, there is only one FSSO component to install — the eDirectory agent. In some cases, you
also need to install the Novell Client.
FSSO installation requires an account with network admin privileges. The security inherent in these types of
accounts helps ensure access to FSSO configurations is not tampered with.
User passwords are never sent between FSSO components. The information that is sent is information to identify
a user including the username, group or groups, and IP address.
NTLM uses base-64 encoded packets, and uses a unique randomly generated challenge nonce to avoid sending
user information and password between the client and the server.
In a Windows AD network, FSSO can also provide NTLM authentication service to the FortiGate unit. When the
user makes a request that requires authentication, the FortiGate unit initiates NTLM negotiation with the client
browser. The FortiGate unit does not process the NTLM packets itself. Instead, it forwards all the NTLM packets
to the FSSO service to process.
NTLM has the benefit of not requiring an FSSO agent, but it is not transparent to users, and the user’s web
browser must support NTLM.
The NTLM protocol protects the user’s password by not sending it over the network. Instead, the server sends the
client a random number that the client must encrypt with the hash value of the user's password. The server
compares the result of the client's encryption with the result of its own encryption. The two will match only if both
parties used the same password.
NTLM authentication
If the NTLM authentication with the Windows AD network is successful, and the user belongs to one of the groups
permitted in the applicable security policy, the FortiGate unit allows the connection but will require authentication
again in the future when the current authentication expires.
Fortinet has tested NTLM authentication with Internet Explorer and Firefox browsers.
But in case of multiple domains that are not in a forest, you need to create a trust relation between the domains.
If you do not want to have a trust relation between your multiple domains, you need to use FSAE 4.0 MR1 and
the DC agent needs to be installed once on each domain. Then you can use security policies to configure server
access.
In the figure below, three domains are shown connected to the FSSO Collector agent server. The Client logs on
to their local Domain Controller, which then sends the user logon event information to the Collector Agent. When
the Client attempts to access the Internet, the FortiGate unit contacts the Collector Agent for the logon
information, sees the Client is authenticated, and allows access to the Internet. There are multiple domains each
with a domain controller agent (DCagent) that sends logon information to the Collector agent. If the multiple
domains have a trust relationship, only one DCagent is required instead of one per domain.
5. The client sends a new GET-request with a header: Proxy-Authenticate: NTLM <authenticate
string>, where <authenticate string> is a NTLM Type 3 Authentication packet that contains:
If the authentication policy reaches the authentication timeout period, a new NTLM
handshake occurs.
Agent installation
After reading the appropriate sections of Introduction to agent-based FSSO on page 147 to determine which
FSSO agents you need, you can proceed to perform the necessary installations.
Ensure you have administrative rights on the servers where you are installing FSSO agents. It is best practice to
install FSSO agents using the built-in local administrator account. Optionally, you can install FSSO without an
admin account. See Installing FSSO without using an administrator account on page 158.
In Windows 2008 by default, you do not have administrative user rights if you are
logged on as a user other than as the built-in administrator, even if you were added to
the local Administrators group on the computer.
The FSSO installer first installs the Collector agent. You can then continue with installation of the DC agent, or
you can install it later by going to Start > Programs > Fortinet > Fortinet Single Sign On Agent >
Install DC Agent. The installer will install a DC agent on the domain controllers of all of the trusted domains in
your network.
1. Create an account with administrator privileges and a password that does not expire. See Microsoft Advanced
Server documentation for help with this task.
To use a non-admin read only account, see Installing FSSO without using an administrator account on page 158.
If you see an error such as Service Fortinet Single Sign On agent (service_FSAE)
failed to start, there are two possible reasons for this. Verify the user account you
selected has sufficient privileges to run the FSSO service. Also verify the computer
system you are attempting to install on is a supported operating system and version.
DC agent installation
The FSSO_Setup file contains both the Collector agent and DC Agent installers, but the DC Agent installer is also
available separately as either a .exe or .msi file named DCAgent_Setup.
1. If you have just installed the Collector agent, the FSSO - Install DC Agent wizard starts automatically. Otherwise,
go to Start > Programs > Fortinet > Fortinet Single Sign On Agent > Install DC Agent.
2. Select Next.
3. Read and accept the license agreement. Select Next.
4. Optionally, you can change the installation location. Select Next.
5. Enter the Collector agent IP address.
6. If the Collector agent computer has multiple network interfaces, ensure that the one that is listed is on your
network. The listed Collector agent listening port is the default. Only change this if the port is already used by
another service.
7. Select Next.
8. Select the domains to monitor and select Next.
9. If any of your required domains are not listed, cancel the wizard and set up the proper trusted relationship with the
domain controller. Then run the wizard again by going to Start > Programs > Fortinet >
Fortinet Single Sign On Agent > Install DC Agent.
10. Optionally, select users that you do not want monitored. These users will not be able to authenticate to FortiGate
units using FSSO. You can also do this later. See Configuring the FSSO Collector agent for Windows AD on page
161.
11. Select Next.
12. Optionally, clear the check boxes of domain controllers on which you do not want to install the DC Agent.
13. Select the Working Mode as DC Agent Mode. While you can select Polling Mode here, in that situation you
would not be installing a DC Agent. For more information, see DC Agent mode on page 150 and Polling mode on
page 151.
14. Select Next.
15. Select Yes when the wizard requests that you reboot the computer.
If you reinstall the FSSO software on this computer, your FSSO configuration is
replaced with default settings.
If you want to create a redundant configuration, repeat the Collector agent installation procedure on at least one
other Windows AD server.
When you start to install a second Collector agent, cancel the Install Wizard dialog
appears the second time. From the configuration GUI, the monitored domain
controller list will show your domain controllers un-selected. Select the ones you wish
to monitor with this Collector agent, and select Apply.
Before you can use FSSO, you need to configure it on both Windows AD and on the FortiGate units. Configuring
FSSO on FortiGate units on page 180 will help you accomplish these two tasks.
The following instructions for Windows 2003 are specific to the event log polling mode
only. Do not use this procedure with other FSSO configurations.
Windows 2003
There are two methods in Windows 2003 AD for installing FSSO without an admin account — add the non-admin
user to the security log list, and use a non-admin account with read-only permissions. A problem with the first
method is that full rights (read, write, and clear) are provided to the event log. This can be a problem when audits
require limited or no write access to logs. In those situations, the non-admin account with read-only permissions
is the solution.
To add the non-admin user account to the Windows 2003 security log list :
1. Go to Default Domain Controller Security Settings > Security Settings > User Rights Assignment >
Manage auditing and security log.
2. Add the user account to this list.
3. Repeat these steps on every domain controller in Windows 2003 AD.
A reboot is required.
To use a non-admin account with read-only permissions to install FSSO on Windows 2003:
The following procedure provides the user account specified with read only access to the Windows 2003 AD
Domain Controller Security Event Log which allows FSSO to function.
Windows 2008
In Windows 2008 AD, if you do not want to use the Domain Admin account then the user account that starts the
FSSO agent needs to be added to the Event Log Readers group.
When the user is added to the Event Log Readers group, that user is now allowed to have read only access to the
event log and this is the minimal rights required for FSSO to work.
1. On the Citrix server, create an account with administrator privileges and a password that does not expire. See
Citrix documentation for more information.
2. Log on to the account that you created in step 1.
3. Double-click the TSAgent_Setup installation file.
The Fortinet SSO Terminal Server Agent Setup Wizard starts.
4. Select Next.
5. Read and accept the license agreement. Select Next.
1. Create an account with administrator privileges and a password that does not expire. See Novell documentation
for more information.
2. Log on to the account that you created in step 1.
3. Double-click the FSSO_Setup_edirectory file to start the installation wizard.
4. Select Next.
5. Read and accept the license agreement. Select Next.
6. Optionally, change the installation location. Select Next.
7. Enter:
eDirectory Server
Use secure connection (SSL) Select to connect to the eDirectory server using SSL security.
Search Base DN Enter the base Distinguished Name for the user search.
eDirectory Authentication
Username Enter a username that has access to the eDirectory, using LDAP format.
8. Select Next.
9. Select Install. When the installation completes, select Finish.
For polling mode, since there are no DC agents you only need to upgrade the Collector. However in DCAgent
mode, each DC Agent must be updated as well.
1. Go to the system32 directory on all DC's and rename the dcagent.dll file to dcagent.dll.old.
This ensures the when the upgrade is pushed to the DC it does not overwrite the old file. If there are any problems
this makes it easy to revert to the old version.
2. Run the FSSO setup .exe file to update the collector. When this is completed, ignore any reboot message.
3. Go to Programs > Fortinet > Fortinet Single Sign On Agent > Install DC Agent and push the DC agent
out to all servers. All DC's will now need to be rebooted so that the new DLL file is loaded.
4. After the reboot, go to all DC’s and delete the dcagent.dll.old files.
On the FortiGate unit, security policies control access to network resources based on user groups. With Fortinet
Single Sign On, this is also true but each FortiGate user group is associated with one or more Windows AD user
groups. This is how Windows AD user groups get authenticated in the FortiGate security policy.
Fortinet Single Sign On sends information about Windows user logons to FortiGate units. If there are many users
on your Windows AD domains, the large amount of information might affect the performance of the FortiGate
units.
To avoid this problem, you can configure the Fortinet Single Sign On Collector agent to send logon information
only for groups named in the FortiGate unit’s security policies. See Configuring FortiGate group filters on page
168.
You can use existing Windows AD user groups for authentication to FortiGate units if you intend that all members
within each group have the same network access privileges.
Otherwise, you need to create new user groups for this purpose.
If you change a user’s group membership, the change does not take effect until the
user logs off and then logs on again.
The FSSO Agent sends only Domain Local Security Group and Global Security Group
information to FortiGate units. You cannot use Distribution group types for FortiGate
access. No information is sent for empty groups.
Refer to Microsoft documentation for information about creating and managing Windows AD user groups.
1. From the Start menu, select Programs > Fortinet > Fortinet Single Sign-On
Agent > Configure Fortinet Single Sign-On Agent.
2. Enter the following information.
Monitoring user logon events By default, this is enabled to automatically authenticate users as they
log on to the Windows domain. Disable the Monitor feature only if you
have a large network where this feature will slow responses too much.
Support NTLM authentication By default, this is enabled to facilitate logon of users who are
connected to a domain that does not have the FSSO DC Agent
installed. Disable NTLM authentication only if your network does not
support NTLM authentication for security or other reasons.
Listening ports You can change FSSO Collector Agent related port numbers if
necessary.
Logging
Log file size limit Enter the maximum size for the log file in MB. Default is 10.
(MB)
Log logon events in Record user login-related information separately from other
separate logs logs. The information in this log includes:
View Logon Events If Log logon events in separate logs is enabled, you can view user
login-related information.
Authentication
Require authenticated Select to require the FortiGate unit to authenticate before connecting
connection from to the Collector agent.
FortiGate
Password Enter the password that FortiGate units must use to authenticate. The
maximum password length is 16 characters. The default password is
“fortinetcanada”. It is highly recommended to modify this password.
Timers
Workstation verify Enter the interval in minutes at which the Fortinet Single Sign On
interval (minutes) Collector agent connects to client computers to determine whether the
user is still logged on. The default is every 5 minutes. The interval may
be increased if your network has too much traffic.
Note: This verification process creates security log entries on the client
computer.
If ports 139 or 445 cannot be opened on your network, set the interval
to 0 to prevent checking. See Configuring FSSO ports on page 169.
Dead entry timeout Enter the interval in minutes after which Fortinet Single Sign On Agent
interval purges information for user logons that it cannot verify. The default is
480 minutes (8 hours).
You can also prevent dead entry checking by setting the interval to 0.
IP address change Fortinet Single Sign On Agent periodically checks the IP addresses of
verify interval logged-in users and updates the FortiGate unit when user IP
addresses change. IP address verification prevents users from being
locked out if they change IP addresses, as may happen with DHCP
assigned addresses.
Cache expire in Fortinet Single Sign On Agent caches group information for logged-in
(minutes) users.
Enter the duration in minutes after which the cache entry expires. If
you enter 0, the cache never expires.
A long cache expire interval may result in more stale user group
information. This can be an issue when a user’s group information is
changed.
This affects all logged-in users, and may force them to re-logon.
3. You can select Save&Close now or leave the agent configuration window open to complete additional
configuration in the following sections.
To view the version and build number information for your FSSO Collector Agent
configuration, selecting the Fortinet icon in the upper left corner of the Collector agent
Configuration screen and select About Fortinet Single Sign On Agent
configuration.
When polling mode is selected, it will poll port 445 of the domain controller every few seconds to see who is
logged on.
1. From the Start menu select Programs > Fortinet Fortinet Single Sign-On Agent > Configure Fortinet
Single Sign On Agent.
2. In the Common Tasks section, select Show Monitored DCs.
3. Select Select DC to Monitor.
6. Select OK.
7. Select Close.
8. Select Save & Close.
l Standard — the FSSO Collector Agent receives group information from the Collector agent in the domain\user
format. This option is available on FortiOS 3.0 and later.
l Advanced — the FSSO Collector Agent obtains user group information using LDAP. The benefit of this method is
that it is possible to nest groups within groups. This is option is available on FortiOS 3.0 MR6 and later. The group
information is in standard LDAP format.
If you change AD access mode, you must reconfigure your group filters to ensure that
the group information is in the correct format.
1. From the Start menu select Programs > Fortinet > Fortinet Single Sign On Agent > Configure Fortinet
Single Sign On Agent.
2. In the Common Tasks section, select Set Directory Access Information.
The Set Directory Access Information dialog box opens.
3. From the AD access mode list, select either Standard or Advanced.
4. If you selected Advanced AD access mode, select Advanced Setting and configure the following settings and
then select OK:
AD server address Enter the address of your network’s global catalog server.
AD server port The default AD server port is 3268. This must match your server port.
BaseDN Enter the Base distinguished name for the global catalog. This is the point
in the tree that will be considered the starting point by default-See following
example.
Username If the global catalog accepts your Fortinet Single Sign On Agent agent’s
credentials, you can leave these fields blank. Otherwise, enter credentials
Password for an account that can access the global catalog.
BaseDN example
An example DN for Training Fortinet Canada is ou=training, ou=canada, dc=fortinet, dc=com. If
you set the BaseDN to ou=canada, dc=fortinet, dc=com then when Fortinet Single Sign On Agent is
looking up user credentials, it will only search the Canada organizational unit, instead of all the possible countries
in the company. Its a short cut to entering less information and faster searches.
However, you may have problems if you narrow the BaseDN too much when you have international employees
from the company visiting different offices. If someone from Fortinet Japan is visiting the Canada office in the
example above, their account credentials will not be matched because they are in ou=japan,
dc=fortinet, dc=com instead of the BaseDN ou=canada, dc=fortinet, dc=com. The easy solution
is to change the BaseDN to simply be dc=fortinet, dc=com. Then any search will check all the users in the
company.
1. From the Start menu select Programs > Fortinet > Fortinet Single Sign On Agent > Configure Fortinet
Single Sign On Agent.
2. In the Common Tasks section, select Set Ignore User List.
The current list of ignored users is displayed:
l select Add by OU, an Add Ignore Users by OU window is displayed, select an OU from the
directory tree, then select Add. All users under the selected OU will be added to the ignore user list.
4. Select OK.
The maximum number of Windows AD user groups allowed on a FortiGate depends on the model. Low end
models support 256 Windows AD user groups, where mid and high end models support 1024 groups. This is per
VDOM if VDOMs are enabled on the FortiGate unit.
You do not need to configure a group filter on the Collector agent if the FortiGate unit retrieves group information
from Windows AD using LDAP. In that case, the Collector agent uses the list of groups you selected on the
FortiGate unit as its group filter.
The filter list is initially empty. You need to configure filters for your FortiGate units using the Add function. At a
minimum, create a default filter that applies to all FortiGate units without a defined filter.
If no filter is defined for a FortiGate unit and there is no default filter, the Collector
agent sends all Windows AD group and user logon events to the FortiGate unit. While
this normally is not a problem, limiting the amount of data sent to the FortiGate unit
improves performance by reducing the amount of memory the unit uses to store the
group list and resulting logs.
1. From the Start menu select Programs > Fortinet > Fortinet Single Sign On Agent > Configure Fortinet
Single Sign On Agent.
2. In the Common Tasks section, select Set Group Filters.
The FortiGate Filter List opens. It has the following columns:
FortiGate SN The serial number of the FortiGate unit to which this filter applies.
Monitored Groups The Windows AD user groups that are relevant to the security policies on
this FortiGate unit.
3. Select Add to create a new filter. If you want to modify an existing filter, select it in the list and then select Edit.
4. Enter the following information and then select OK.
Default filter Select to create the default filter. The default filter applies to any FortiGate
unit that does not have a specific filter defined in the list.
FortiGate Serial Number Enter the serial number of the FortiGate unit to which this filter applies.
This field is not available if Default is selected.
Description Enter a description of this FortiGate unit’s role in your network. For
example, you could list the resources accessed through this unit. This field
is not available if Default is selected.
Monitor the following The Collector agent sends to the FortiGate unit the user logon information
groups for the Windows AD user groups in this list. Edit this list using the Add,
Advanced and Remove buttons.
Add In the preceding single-line field, enter the Windows AD domain name and
user group name, and then select Add. If you don’t know the exact name,
use the Advanced button instead.
The format of the entry depends on the AD access mode (see Configuring
Directory Access settings on page 166):
Standard: Domain\Group
Advanced Select Advanced, select the user groups from the list, and then select
Add.
If it is not feasible or acceptable to open TCP port 139 or 445, you can turn off Fortinet Single Sign On Agent
logoff detection. To do this, set the Collector agent workstation verify interval to 0. The FSSO Collector Agent
assumes that the logged on computer remains logged on for the duration of the Collector agent dead entry
timeout interval — by default this is eight hours.
This feature requires FSAE version 3.5.27 or later, Fortinet Single Sign On Agent any version, and FortiOS 3.0
MR7 or later.
1. On the computer where the Collector agent is installed, go to Start > Run.
2. Enter regedit or regedt32 and select OK.
The Registry Editor opens.
3. Find the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Fortinet\FSAE\collectoragent.
4. Set the supportFSAEauth value (dword) to 00000001.
If needed, create this new dword.
5. Close the Registry Editor.
6. From the Start menu select Programs > Fortinet > Fortinet Single Sign On Agent > Configure Fortinet
Single Sign On Agent.
7. Select Apply.
The Fortinet Single Sign On Agent service restarts with the updated registry settings.
1. From the Start menu select Programs > Fortinet > Fortinet Single Sign On Agent > Configure Fortinet
Single Sign On Agent.
2. In the Common Tasks section, select Show Service Status.
The Fortinet Single Sign On Collector agent Status window opens.
3. Optionally select Get NTLM statistics in the Status window to display NTLM information such as number of
messages received, processed, failed, in the queue.
1. From the Start menu select Programs > Fortinet > Fortinet Single Sign On Agent > Configure Fortinet
Single Sign On Agent.
2. In the Common Tasks section, select Show Monitored DCs.
For each DC Agent, the following information is displayed:
l IP address
l number of logon events received
l the last logon event
l when last logon was received
To change which DC agents are monitored or change the working mode for logon event monitoring, select Select
DC to Monitor
The FSSO TS agent works with the same FSSO Collector agent that is used for integration with Windows Active
Directory. Install the Collector agent first. Follow the Collector agent installation procedure in Collector agent
installation on page 156.
Fortinet SSO Collector Agent IP and Port needs to point to the current configured
listening port on the collector which is port 8002 by default. Though it may be
configured to a custom port.
You need to configure the eDirectory agent for it to communicate with eDirectory servers. You may have provided
some of this information during installation.
1. From the Start menu select Programs > Fortinet > eDirectory Agent > eDirectory Config Utility.
2. The eDirectory Agent Configuration Utility dialog opens. Enter the following information and select OK.
eDirectory Authentication
Username Enter a username that has access to the eDirectory, using LDAP format.
Listening port Enter the TCP port on which Fortinet Single Sign On Agent listens for
connections from FortiGate units. The default is 8000. You can change the
port if necessary.
Refresh interval Enter the interval in seconds between polls of the eDirectory server to
check for new logons. The default is 30 seconds.
Require authenticated Select to require the FortiGate unit to authenticate before connecting to
connection from FortiGate the eDirectory Agent.
Password Enter the password that FortiGate units must use to authenticate. The
maximum password length is 16 characters. The default password is
“FortinetCanada”.
User logon Info Search Select how the eDirectory agent accesses user logon information: LDAP or
Method Native (Novell API). LDAP is the default.
If you select Native, you must also have the Novell Client installed on the
PC.
Logging
Log file size limit (MB) Enter the maximum size for the log file in MB.
Dump Session List the currently logged-on users in the log file. This can be useful for
troubleshooting.
Log level Select Debug, Info, Warning or Error as the minimum severity level of
message to log or select None to disable logging.
Add Add an eDirectory server. See Adding an eDirectory server on page 175.
Set Group Filters... Select the user groups whose user logons will be reported to the FortiGate
unit. This is used only if user groups are not selected on the FortiGate unit.
1. In the eDirectory Agent Configuration Utility dialog box (see the preceding procedure, Configuring the eDirectory
agent), select Add.
2. The eDirectory Setup dialog box opens. Enter the following information and select OK:
Port If the eDirectory server does not use the default port 389, clear the
Default check box and enter the port number.
Use default credential Select to use the credentials specified in the eDirectory Configuration
Utility. See Configuring the eDirectory agent on page 173. Otherwise,
leave the check box clear and enter a username and Password below.
User name Enter a username that has access to the eDirectory, using LDAP format.
Use secure connection (SSL) Select to connect to the eDirectory server using SSL security.
Search Base DN Enter the base Distinguished Name for the user search.
If both the FortiGate LDAP configuration and the eDirectory agent group filter are present, the FortiGate user
group selections are used.
1. From the Start menu select Programs > Fortinet > eDirectory Agent > eDirectory Config Utility.
2. Select Set Group Filters.
3. Do one of the following:
l Enter group names, then select Add.
l Select Advanced, select groups, and then select Add.
4. Select OK.
Depending on your network topologies and requirement, you may need to configure advanced settings in the
FSSO Colloctor agent.To do so, from the Start menu, select Programs > Fortinet > Fortinet Single Sign-On
Agent > Configure Fortinet Single Sign-On Agent, then from the Common Tasks section, select
Advanced Settings.
This section include :
l General Settings
l Citrix/Terminal Server
l Exchange Server
l RADIUS Accounting
General Settings
In the General tab, enter the following information and select OK.
Worker thread count Number of threads started in the CA process. Default is128 on CA version
5.0.0241.
Maximum FortiGate
Number of FortiGates can be connected to the CA. Default is 64.
connections
Group look-up interval The interval in seconds to lookup users/groups. If an AD group membership
of currently logged on user, CA can detect this and update information on the
FortiGate. Enter 0 for no checking.
Event IDs to poll 0:Default set, it includes Kerberos authentication event logs : 672 for
Windows server 2003, 4768 for Windows server 2008 and 2012 and NTLM
authentication event logs : 680 for Windows server 2003, 4776 for Windows
server 2008 and 2012. 1: Extended set, it includes Kerberos service ticket
event logs : 673 for Windows server 2003, 4769 for Windows server 2008 and
2012. Service tickets are obtained whenever a user or computer accesses a
server on the network.
List the event ids separated by ";".
Optionally enable Use WMI to check user logoff for the collector agent to
Workstation Check
query whether users is still logged on.
Alternative DNS server(s)
Collector Agent uses the DNS server configured on the machine it is running
on by default. If CA should use another DNS server then one or more
alternative DNS server can be configured here.
Alternative workstation
suffix(es) If only host name is available CA uses the default domain suffix to build a
FQDN for DNS queries. In case CA should use a different suffix, it can be
configured as well.
Citrix/Terminal Server
In the Citrix/Terminal Server tab, enter the following information and select OK.
Support Citrix/Terminal Server When Citrix server are configured with VIP, CA can get user logon events
Virtual IP Environment from theses server. Citrix changed their interface and data format so version
of Citrix server is important.
Exchange Server
FSSO supports monitoring Microsoft Exchange Server. This is useful for situation that the user use the domain
account to access their email, but client device might or might not be in the domain. Support for Exchange server
is configured on the Back-end FSSO collector agent under Advanced Settings > Exchange Server.
Select Add and enter the following information and select OK.
Server IP/Hostname Enter the IP address or the hostname of your exchange server.
Polling forwarded event This option for scenarios when you do not want that CA polls the Exchange Server
log logs directly. In this case you need to configure event log forwarding on the
Exchange server. Exchange event logs can be forwarded to any member server.
If you enable this, instead of the IP of the Exchange server configured in the
previous step, you must then configure the IP of this member server. CA will then
contact the member server.
Because CA will also check Windows log files for logon events and when a user
authenticates to Exchange Server there is also a logon event in Windows event log,
which CA will read and this will overwrite the Exchange Server logon event (ES-
Ignore Name
EventLog) on CA. So it is recommended to set the ignore list to the domain the user
belongs to.
To do so, enter the domain name in the Ignore Name field and select Add.
RADIUS Accounting
A RADIUS server must be configured in your network to send accounting messages to the Collector Agent which
can be configured to work with most RADIUS-based accounting systems. In most cases, you only need to do the
following to your RADIUS accounting system:
l Add a user group name field to customer accounts on the RADIUS server so that the name is added to the RADIUS
Start record sent by the accounting system to the Collector Agent. User group names do not need to be added for
all users, only to the accounts of users who will use RADIUS Accounting feature on the Collector Agent.
l Configure your accounting system to send RADIUS Start records to the Collector Agent.
The Collocter Agent should be configured to listen for RADIUS accounting messages as following.
Listen port The port on which CA listens for RADIUS accounting messages. Default
RADIUS accounting is 1813, but if RADIUS server sends accounting
messages on different port, value can be configured here.
Default domain name This should be the AD domain for which this CA is configured. In this case
user name in RADIUS accounting message can be in simple format like
user1.
If this value is empty, then user name in RADIUS accounting message must
be in one of these formats user1@domain, Domain\user1 or
domain/user1.
CA will use user name and domain to query group membership of user. Client
IP address (Framed IP) should also be in RADIUS accounting message, so
that CA can forward user name, IP address and groups to the FortiGate.
l Configure any access to LDAP servers that might be necessary. Skip this step if you are using FSSO Standard
mode. See Configuring LDAP server access on page 180.
l Specify the Collector agent or Novell eDirectory agent that will provide user logon information. See Specifying your
Collector agents or Novell eDirectory agents on page 182.
l Add Active Directory user groups to FortiGate user groups. See Creating Fortinet Single Sign-On (FSSO) user
groups on page 183.
l Create security policies for FSSO-authenticated groups. See Creating security policies on page 184.
l Optionally, specify a guest security policy to allow guest access. See Enabling guest access through FSSO security
policies on page 185.
3. In the Common Name Identifier field, enter sAMAccountName.The default common name identifier is cn.
This is correct for most LDAP servers. However some servers use other identifiers such as uid.
4. In the Distinguished Name field, enter your organization distinguished name. In this example, Distinguished
Name is dc=techdoc,dc=local
5. Select Fetch DN, this will fetch the Windows AD directory.
Agent IP/Name Enter the IP address or the name of the server where this agent is installed.
Maximum name length is 63 characters.
If the TCP port used for FSSO is not the default, 8000, you can change the
setting in the CLI using the config user fsso command.
Password Enter the password for the Collector agent or eDirectory agent. For the
Collector agent, this is required only if you configured the agent to require
authenticated access.
5. For Novell eDirectory or Windows AD with Collector agent in Advanced AD access mode select the LDAP Server
you configured previously. See Configuring LDAP server access on page 180.
6. In Users/Groups, select the Users or Groups or Organizational Units tab and then select the users or groups
or OU that you want to monitor.
7. Select OK.
In this example, the SSO server name is techdoc and the LDAP server is LDAP.
config user fsso
edit techdoc
set ldap-server LDAP
set password <your_password>
set server 10.10.20.3
set port 8000
end
In this situation, Example.com is a company that has its employees and authentication servers on an internal
network. The FortiGate unit intercepts all traffic leaving the internal network and requires FSSO authentication to
access network resources on the Internet. The following procedure configures the security policy for FSSO
authentication. FSSO is installed and configured including the RADIUS server, FSSO Collector agent, and user
groups on the FortiGate
For the following procedure, the internal interface is port1 and the external interface connected to the Internet
is port2. There is an address group for the internal network called company_network. The FSSO user group
is called fsso_group, and the FSSO RADIUS server is fsso_rad_server.
Schedule always
Action ACCEPT
NAT ON
UTM Security Profiles ON for AntiVirus, IPS, Web Filter, and Email Filter, all using default
profiles.
3. Select OK.
4. Ensure the FSSO authentication policy is higher in the policy list than more general policies for the same
interfaces.
Here is an example of how this FSSO authentication policy is used. Example.com employee on the internal
company network logs on to the internal network using their RADIUS username and password. When that user
attempts to access the Internet, which requires FSSO authentication, the FortiGate authentication security policy
intercepts the session, checks with the FSSO Collector agent to verify the user’s identity and credentials, and
then if everything is verified the user is allowed access to the Internet.
As of FSSO 4.0 MR3, if a user belongs to multiple groups multiple then attempts to match the group are
attempted if applicable. Using the above example, when the attempt to match the group1 policy is made and
fails, the next policy with a group that test_user is a member of is attempted. In this case, the next policy is
matched and access is granted to the email server.
When configuring this example the only difference between the policies is the services that are listed and the
FSSO user group name.
Authenticating through multiple groups allows administrators to assign groups for specific services, and users
who are members of each group have access to those services. For example there could be an FTP group, an
email group, and a Telnet group.
To enable guest access in your FSSO security policy, add an identity-based policy assigned to the built-in user
group SSO_Guest_Users. Specify the services, schedule and protection profile that apply to guest users —
typically guests receive reduced access to a reduced set of services. Creating security policies on page 184
There are two types of FortiOS log messages — firewall and event. FSSO-related log messages are generated
from authentication events. These include user logon and log off events, and NTLM authentication events. These
log messages are central to network accounting policies, and can also be useful in troubleshooting issues. For
more information on firewall logging, see "Enabling security logging". For more information on logging, see the
FortiOS Handbook Log and Reporting guide.
When VDOMs are enabled certain options may not be available, such as CPU and memory usage events. You
can enable event logs only when you are logged on to a VDOM; you cannot enable event logs globally.
To ensure you log all the events need, set the minimum log level to Notification or Information. Firewall logging
requires Notification as a minimum. The closer to Debug level, the more information will be logged. While this
extra information is useful, you must
System activity event All system-related events, such as ping server failure and gateway status.
User activity event All administration events, such as user logins, resets, and configuration
updates.
3. Optionally you can enable any or all of the other logging event options.
4. Select Apply.
For more information on logging, see the FortiOS Handbook Log and Reporting guide.
Using filters
Logon events are detected by the FSSO CA by monitoring the Security Event logs. Additional logon event filters,
such as ServiceName and ServiceID, have been implemented so as to avoid instances of conflicting security
events, where existing FSSO logon user information could be overwritten and impact user connectivity.
1. User1 logs on to PC1 on 1.1.1.1, which is logged as a successful Kerberos logon event with an ID of 4769.
2. The FortiGate creates an authenticated FSSO user log entry for User1/1.1.1.1.
3. User1 then maps a network drive and uses credentials for User2 to logon to the same PC (PC1).
4. The FortiGate sees this as a separate logon to PC1 by a new user, User2. As a result, the log entry is updated to
User2/1.1.1.1.
5. If User2 is a member of a different user group to User1 (i.e. has different access permissions), User1 could lose
access to their network resources.
The new filter makes the CA ignore the event log created when User1 mapped a network drive, meaning that the
original entry for User1 will not be changed.
Testing FSSO
Once FSSO is configured, you can easily test to ensure your configuration is working as expected. For additional
FSSO testing, see Troubleshooting FSSO on page 188.
1. Logon to one of the stations on the FSSO domain, and access an Internet resource.
2. Connect to the CLI of the FortiGate unit, and if possible log the output.
3. Enter the following command:
diagnose debug authd fsso list
4. Check the output. If FSSO is functioning properly you will see something similar to the following:
----FSSO logons----
IP: 10.10.20.3 User: ADMINISTRATOR Groups: CN=FORTIOS WRITERS,CN=USERS,DC=TECHDOC,DC=LOCAL
Workstation: WIN2K8R2.TECHDOC.LOCAL MemberOf: FortiOS_Writers
IP: 10.10.20.7 User: TELBAR Groups: CN=FORTIOS WRITERS,CN=USERS,DC=TECHDOC,DC=LOCAL
Workstation: TELBAR-PC7.TECHDOC.LOCAL
Total number of logons listed: 2, filtered: 0
----end of FSSO logons----
The exact information will vary based on your installation.
5. Check the FortiGate event log, for FSSO-auth action or other FSSO related events with FSSO information in the
message field.
6. To check server connectivity, run the following commands from the CLI:
FGT# diagnose debug enable
FGT# diagnose debug authd fsso server-status
FGT# Server Name Connection Status Version
----------- ----------------- -------
techdoc connected FSSO 5.0.0241
Troubleshooting FSSO
When installing, configuring, and working with FSSO some problems are quite common. A selection of these
problems follows including explanations and solutions.
l Ensure all firewalls are allowing the FSSO required ports through.
FSSO has a number of required ports that must be allowed through all firewalls or connections will fail. These
include: ports 139, 389 (LDAP), 445, 636 (LDAP) 8000, and 8002.
l Ensure the Collector agent has at least 64kbps bandwidth to the FortiGate unit.
If not the Collector agent does not have this amount of bandwidth, information FSSO information may not reach
the FortiGate unit resulting in outages. The best solution is to configure traffic shaping between the FortiGate unit
and the Collector agent to ensure that minimum bandwidth is always available.
Windows AD does not track when a user logs out. It is possible that a user logs out on one computer, and
immediate logs onto a second computer while the system still believes the user is logged on the original
computer. While this is allowed, information that is intended for the session on one computer may mistakenly end
up going to the other computer instead. The result would look similar to a hijacked session.
Solutions
l Ensure each computer has separate IP addresses.
l Encourage users to logout on one machine before logging onto another machine.
l If multiple users have the same username, change the usernames to be unique.
l Shorten timeout timer to flush inactive sessions after a shorter time.
Solution
The group of the guest users was not included in a policy, so they do not fall under the guest account. To give
them access, associate their group with a security policy.
Additionally, there is a default group called SSO_Guest_Users. Ensure that group is part of an identity-based
security policy to allow traffic.
Instead DCagent is really dcagent.dll and is located in the Windows\system32 folder. This DLL file is
loaded when windows boots up and it intercepts all logon events processed by the domain controller to send
these events to the Collector agent (CA).
Solution
If polling mode is enabled, it is possible the polling interval is too large. Use a shorter polling interval to ensure the
collector agent is capturing all logon events.
If NetAPI polling mode is enabled, consider switching to Event logs or Event Logs using WMI polling as it provides
better accuracy.
Mac OS X users can’t access external resources after waking from sleep mode
When client computers running Mac OS X (10.6.X and higher) wake up from sleep mode, the user must
authenticate again to be able to access external resources. If the user does not re-authenticate, the user will
maintain access to internal web sites, but will be unable to access any external resources.
This issue is caused by Mac OS X not providing sufficient information to the FSSO. This results in the FortiGate
blocking access to the user because they cannot be authenticated.
Solution
The security settings on client computer(s) must be configured to require that a username and password be
entered when exiting sleep mode or screen saver. With this feature enabled in Mac OS X, the FortiGate will
receive the authentication information it requires to authenticate the user and allow them access.
Note that if the user reverts their settings to disable the password requirement, this will cause the issue to
reappear.
A FortiGate unit can authenticate users transparently who have already authenticated on an external RADIUS
server. Based on the user group to which the user belongs, the security policy applies the appropriate UTM
profiles. RADIUS SSO is relatively simple because the FortiGate unit does not interact with the RADIUS server, it
only monitors RADIUS accounting records that the server forwards (originating from the RADIUS client). These
records include the user’s IP address and user group.
After the initial set-up, changes to the user database, including changes to user group memberships, are made
on the external RADIUS server, not on the FortiGate unit.
Configuration Overview
1. If necessary, configure your RADIUS server. The user database needs to include user group information and the
server needs to send accounting messages.
2. Create the FortiGate RADIUS SSO agent.
3. Define local user groups that map to RADIUS groups.
4. Create a security policy which specifies the user groups that are permitted access.
You can configure FortiGate RSSO to work with most RADIUS-based accounting systems. In most cases, you
only need to do the following to your RADIUS accounting system:
l Add a user group name field to customer accounts on the RADIUS server so that the name is added to the RADIUS
Start record sent by the accounting system to the FortiOS unit. User group names do not need to be added for all
users, only to the accounts of users who will use RSSO feature on the FortiGate unit.
l Configure your accounting system to send RADIUS Start records to the FortiOS unit. You can send the RADIUS
Start records to any FortiGate network interface. If your FortiGate unit is operating with virtual domains (VDOMs)
enabled, the RADIUS Start records must be sent to a network interface in the management VDOM.
Note that while you can set the primary RADIUS server's IPv6 address, the source IP
address for communications to the RADIUS server cannot be configured as IPv6.
Syntax
Once you define a RADIUS SSO (RSSO) agent, the FortiGate unit will accept user logon information from any
RADIUS server that has the same shared secret. You can create only one RSSO agent in each VDOM.
Before you create the RSSO agent, you need to allow RADIUS accounting information on the interface that
connects to the RADIUS server.
1. Go to Network > Interfaces and edit the interface to which the RADIUS server connected.
2. Select Listen for RADIUS Accounting Messages.
3. Select OK.
The Endpoint block attribute can be used to block or allow a user. If the attribute value is set to the name of an
attribute that indicates whether to block or allow, FortiOS blocks or allows respectively all traffic from that user’s
IP address. The RSSO fields are visible only when rsso is set to enable.
The Prefix attributes allow for RSSO to provide a /56 prefix for DSL customers. All devices connected from the
same location (/56 per subscriber) can be mapped to the same profile without the need to create multiple /64 or
smaller entries.
Override SSO attribute
Prior to FortiOS 5.4, when receiving a new start message with a different group name for the same user, and a
different IP address such as for a roaming mobile device, the original process was to override all group name
information to the latest group name received from the latest start message.
You can disable this override when needed. The default behavior keeps the original design.
You cannot use RADIUS user groups directly in security policies. Instead, you create locally-defined user groups
on the FortiGate unit and associate each of them with a RADIUS user group.
This example creates an RSSO user group called RSSO-1 that is associated with RADIUS user group “student”.
config user group
edit RSSO-1
set group-type rsso
set sso-attribute-value student
end
RADIUS SSO uses regular identity-based security policies. The RSSO user group you specify determines which
users are permitted to use the policy. You can create multiple policies if user groups can have different UTM
features enabled, different permitted services, schedules, and so on.
Source User(s) Select the user groups you created for RSSO. See Defining local user
groups for RADIUS SSO on page 194.
Schedule as needed
Service as needed
Action ACCEPT
Security Profiles Select security profiles appropriate for the user group.
4. Select OK.
To ensure an RSSO-related policy is matched first, the policy should be placed higher in the security policy list
than more general policies for the same interfaces.
5. Select OK.
In this example, an internal network to Internet policy enables web access for members of a student group and
activates the appropriate UTM profiles.
config firewall policy
edit 0
set srcintf internal
set dstintf wan1
set srcaddr all
set dstaddr "all"
set action accept
set rsso enable
set groups "RSSO-student"
set schedule always
set service HTTP HTTPS
set nat enable
set utm-status enable
set av-profile students
set webfilter-profile students
set spamfilter-profile students
set dlp-sensor default
set ips-sensor default
set application-list students
set profile-protocol-options "default"
end
The following example uses RADIUS SSO to apply web filtering to students, but not to teachers. Assume that the
RADIUS server is already configured to send RADIUS Start and Stop records to the FortiGate unit. There are two
RADIUS user groups, students and teachers, recorded in the default attribute Class. The workstations are
connected to port1, port2 connects to the RADIUS server, and port3 connects to the Internet.
1. Go to Security Profiles > Web Filter and select Create New (the “+” button).
2. Enter the following and select OK.
Name student
FortiGuard Categories Enable. Right-click the Potentially Liable category and select Block.
Repeat for Adult/Mature Content and Security Risk.
Define local user groups associated with the RADIUS SSO user groups:
Name RSSO-students
Name RSSO-teachers
Schedule always
Action ACCEPT
NAT ON
3. Select OK.
Schedule always
Service ALL
Action ACCEPT
NAT ON
3. Select OK.
This section describes how to view lists of currently logged-in firewall and VPN users. It also describes how to
disconnect users.
You can de-authenticate a user by selecting the Delete icon for that entry.
You can filter the list of displayed users by selecting the funnel icon for one of the column titles or selecting Filter
Settings.
Optionally, you can de-authenticate multiple users by selecting them and then selecting De-authenticate.
You can monitor web-mode and tunnel-mode SSL VPN users by username and IP address.
To monitor SSL VPN users, go to Monitor > SSL-VPN Monitor. To disconnect a user, select the user and then
select the Delete icon.
The first line, listing the username and IP address, is present for a user with either a web-mode or tunnel-mode
connection. The Subsession line is present only if the user has a tunnel mode connection. The Description
column displays the virtual IP address assigned to the user’s tunnel-mode connection.
For more information about SSL VPN, see the FortiOS Handbook SSL VPN guide.
To list all of the SSL VPN sessions and their index numbers:
execute vpn sslvpn list
SSL-VPN sessions:
Index User Source IP Tunnel/Dest IP
0 user2 172.20.120.51 10.0.0.1
You can use the Index value in the following commands to disconnect user sessions:
To monitor IPsec VPN tunnels in the web-based manager, go to Monitor > IPsec Monitor. user names are
available only for users who authenticate with XAuth.
You can close a tunnel by selecting the tunnel and right click to select Bring Down.
For more information, see the FortiOS Handbook IPsec VPN guide.
The User Quarantine list shows all IP addresses and interfaces blocked by NAC quarantine. The list also shows
all IP addresses, authenticated users, senders, and interfaces blocked by Data Leak Prevention (DLP). The
system administrator can selectively release users or interfaces from quarantine or configure quarantine to expire
after a selected time period.
All sessions started by users or IP addresses on the User Quarantine list are blocked until the user or IP address is
removed from the list. All sessions to an interface on the list are blocked until the interface is removed from the
list.
You can configure NAC quarantine to add users or IP addresses to the User Quarantine list under the following
conditions:
l Users or IP addresses that originate attacks detected by IPS - To quarantine users or IP addresses that
originate attacks, enable and configure Quarantine in an IPS Filter.
l Users or IP addresses that are quarantined by Data Leak Prevention - In a DLP sensor select Quarantine
IP Address as the action to take.
For more information, see FortiOS Handbook Security Profiles guide.
Delete Removes the selected user or IP address from the User Quarantine list.
Remove All Removes all users and IP addresses from the User Quarantine list.
The FortiGate function that caused the user or IP address to be added to the User
Source
Quarantine list: IPS or Data Leak Prevention.
Created The date and time the user or IP address was added to the Banned User list.
The date and time the user or IP address will be automatically removed from the User
Expires Quarantine list. If Expires is Indefinite, you must manually remove the user or host
from the list.
This chapter provides an example of a FortiGate unit providing authenticated access to the Internet for both
Windows network users and local users.
Example configuration
Overview
In this example, there is a Windows network connected to Port 2 on the FortiGate unit and another LAN,
Network_1, connected to Port 3.
All Windows network users authenticate when they logon to their network. Members of the Engineering and Sales
groups can access the Internet without entering their authentication credentials again. The example assumes
that the Fortinet Single Sign On (FSSO) has already been installed and configured on the domain controller.
LAN users who belong to the Internet_users group can access the Internet after entering their username and
password to authenticate. This example shows only two users, User1 is authenticated by a password stored on
the FortiGate unit, User2 is authenticated on an external authentication server. Both of these users are referred
to as local users because the user account is created on the FortiGate unit.
Password hardtoguess
Enable Select.
Name OurRADIUSsrv
end
Creation of the user account is similar to the locally-authenticated account, except that you specify the RADIUS
authentication server instead of the user’s password.
Enable Select
Name ADserver
User DN cn=FSSO_Admin,cn=users,dc=office,dc=example,dc=com
Password set_a_secure_password
Name WinGroups
Password fortinet_canada
3. Select Apply & Refresh.
In a few minutes, the FortiGate unit downloads the list of user groups from the server.
Name FSSO_Internet_users
Name Internet_users
Type Firewall
Type Subnet
Interface Port 3
Type Subnet
Interface Port 2
Schedule always
Service ALL
NAT ON
3. Select OK.
Schedule always
Service ALL
NAT ON
3. Select OK.
In this example, users defined in MicroSoft Windows Active Directory (AD) are allowed to set up a VPN
connection simply based on an attribute that is set to TRUE, instead of based on their user group. In AD the
"Allow Dialin" property is activated in the user properties, and this sets the msNPAllowDialin attribute to
"TRUE".
This same procedure can be used for other member attributes, as your system requires.
To accomplish this with a FortiGate unit, member-attribute must be set. This can only be accomplished through
the CLI - the option is not available through the web-based manager.
Before configuring the FortiGate unit, ensure the AD server has the msNPAllowDialin attribute set to "TRUE"
for the users in question. If not, those users will not be able to authenticate.
Once these settings are in place, users that are a member of the ldap user group will be able to authenticate.
To ensure your settings are correct, here is the sample output from a diag debug command that shows the
authentication process.
When the "Allow Dial-in" attribute is set to "TRUE" the following will likely be in the output:
get_member_of_groups-Get the memberOf groups.
get_member_of_groups- attr='msNPAllowDialin', found 1 values
get_member_of_groups-val[0]='TRUE'
fnbamd_ldap_get_result-Auth accepted
fnbamd_ldap_get_result-Going to DONE state res=0
fnbamd_auth_poll_ldap-Result for ldap svr 192.168.201.3 is SUCCESS
fnbamd_auth_poll_ldap-Passed group matching
If the attribute is not set but it is expected, the following will likely be in the output:
get_member_of_groups-Get the memberOf groups.
get_member_of_groups- attr='msNPAllowDialin', found 1 values
get_member_of_groups-val[0]='FALSE'
fnbamd_ldap_get_result-Auth accepted
The only difference between these two outputs is the last line which is either passed or failed based on if the
member-attribute is set to the expected value or not.
A common RADIUS SSO topology involves a medium sized company network of users connecting to the Internet
through the FortiGate unit, and authenticating with a RADIUS server. RADIUS SSO authentication was selected
because it is fast and relatively easy to configure.
l Assumptions
l Topology
l Configuring RADIUS
l Configuring FortiGate regular and RADIUS SSO security policies
l Testing
Assumptions
l VDOMs are not enabled
l The admin super_admin administrator account will be used for all FortiGate unit configuration.
l Any other devices on the network do not affect the topology of this example, and therefore are not included.
l Anywhere settings are not described, they are assumed to be default values.
l A RADIUS server is installed on a server or FortiAuthenticator unit and uses default attributes.
l BGP is used for any dynamic routing.
l Authentication event logging under Log&Report has been configured.
Topology
Example.com has an office with 20 users on the internal network. These users need access to the Internet to do
their jobs. The office network is protected by a FortiGate-60C unit with access to the Internet through the wan1
interface, the user network on the internal interface, and all the servers are on the DMZ interface. This includes
an Ubuntu Linux server running FreeRADIUS. For this example only two users will be configured — Pat Lee with
an account name plee, or [email protected], and Kelly Green with an account name kgreen, or
[email protected].
Configuring RADIUS
Configuring RADIUS includes configuring the RADIUS server such as FreeRADIUS, a radius client on user’s
computers, and configuring users in the system. For this example the two users will be Pat Lee, and Kelly Green.
They belong to a group called exampledotcom_employees. When it is all configured, the RADIUS daemon
needs to started.
The users have a RADIUS client installed on their PCs that allows them to authenticate through the RADIUS
server.
FreeRADIUS can be found on the freeradius.org website. For any problems installing FreeRADIUS, see the
FreeRADIUS documentation.
1. Go to Network > Interfaces.
2. Select wan1 to edit.
3. Enter the following information and select OK.
Alias Internet
Comments Internet
Administrative Status Up
Alias Servers
Comments Servers
Administrative Status Up
Netmask 255.255.255.0
Administrative Status Up
Seq.
From -> To Type Schedule Description
No.
1 internal -> RADIUS SSO business hours Authenticate outgoing user traffic.
wan1
internal ->
4 regular always Allow users to access servers.
dmz
Seq.
From -> To Type Schedule Description
No.
5 any -> any deny always Implicit policy denying all traffic that
hasn’t been matched.
The RADIUS SSO policy must be placed at the top of the policy list so it is matched
first. The only exception to this is if you have a policy to deny access to a list of banned
users. In this case, that policy must go at the top so the RADIUS SSO does not
mistakenly match a banned user or IP address.
Schedules
Only one schedule needs to be configured — business_hours. This is a fairly standard Monday to Friday 8am
to 5pm schedule, or whatever days and hours covers standard work hours at the company.
Address groups
The following address groups need to be configured before the security policies.
Service groups
The following service groups need to be configured before the security policies. Note that the services listed are
suggestions and may include more or less as required.
The following security policy configurations are basic and only include logging, and default AV and IPS.
Schedule always
Service essential_network_services
Action ACCEPT
NAT ON
3. Select Create New, enter the following information, and select OK.
Schedule always
Service essential_server_services
Action ACCEPT
NAT ON
4. Select Create New, enter the following information, and select OK.
Schedule always
Service all
Action ACCEPT
NAT ON
Source User(s) Select the user groups you created for RSSO.
Schedule business_hours
Service ALL
Action ACCEPT
NAT ON
Security Profiles ON: AntiVirus, WebFilter, IPS, and Email Filter. In each case, select the
default profile.
4. Select OK.
5. To ensure an RSSO-related policy is matched first, the policy should be placed higher in the security policy list
than more general policies for the same interfaces.
6. Select OK.
Testing
Once configured, a user only needs to log on to their PC using their RADIUS account. After that when they
attempt to access an Internet website, the FortiGate unit will use their session information to get their RADIUS
information. Once the user is verified, they are allowed access to the website.
1. Have user 'plee' logon to their PC, and try to access an Internet website.
2. The FortiGate unit will contact the RADUS server for user plee’s information.
Once confirmed, plee will have access to the website.
Each step generates log entries that enable you to verify that each step was successful.
3. If a step is unsuccessful, confirm that your configuration is correct.
Troubleshooting
In the web-based manager, a good tool for troubleshooting is the packet counter column on the security policy
page at Policy & Objects > IPv4 Policy. This column displays the number of packets that have passed
through this security policy. Its value when you are troubleshooting is that when you are testing your configuration
(end to end connectivity, user authentication, policy use) watching the packet count for an increase confirms any
other methods you may be using for troubleshooting. It provides the key of which policy is allowing the traffic,
useful information if you expect a user to require authentication and it never happens.
This section addresses how to get more information from the CLI about users and user authentication attempts
to help troubleshoot failed authentication attempts.
diag firewall iprope list
Shows the IP that the computer connected from. This is useful to confirm authorization and VPN settings.
For more information on troubleshooting specific features, go to that section of this document. Most sections
have troubleshooting information at the end of the section. In addition to that information, see the FortiOS
Handbook Troubleshooting guide for general troubleshooting information.