DeviceCookieAuthState
As a precondition to use the Device Recognition module in nevisAdapt, configure the AuthState DeviceCookieAuthState
in nevisAuth. For each login request, this AuthState checks whether a device cookie exists. If not, the AuthState creates a device cookie and sends this persistent device cookie with the request.
The technical name of the AuthState is ch.nevis.detect.authstate.DeviceCookieAuthState
. Integrate it in your login workflow, such that it is invoked at the beginning of the flow.
The following table lists the configuration properties of the AuthState.
Name | Type/unit | Default | Example | Description |
---|---|---|---|---|
secure | boolean | true | Flag for the cookie attribute secure . | |
httpOnly | boolean | true | Flag for the cookie attribute httpOnly . | |
cookieName | string | NADC | Name of the device cookie. See also the configuration attribute nevisadapt.cookie.name of the nevisAdapt plug-in. | |
cookieDomain | string | nevis.ch | Domain of the device cookie. | |
cookiePath | string | / | Path of the device cookie. | |
maxAgeInDays | int | 365 | Maximum age (in days) of the device cookie. |
Example configuration
<AuthState class="ch.nevis.detect.authstate.DeviceCookieAuthState" final="false" name="sso_authstate-adapt_DeviceCookie">
<ResultCond name="error" next="sso_authstate-realm_Authentication_Failed"/>
<ResultCond name="ok" next="sso_authstate-adapt_NevisAdapt"/>
<Response value="AUTH_ERROR"/>
<property name="cookieName" value="DEVICE_COOKIE"/>
<property name="cookieDomain" value="nevis.ch"/>
<property name="cookiePath" value="/"/>
<property name="maxAgeInDays" value="30"/>
</AuthState>