Authentication
Advanced Session Upgrade
Plugin: nevisadmin-plugin-nevisauth
Serves as entry point for an authentication process which may be executed on demand.
Assign the pattern to a Authentication Realm using the reference On Demand.
An entry point for the configured Authentication Level is added to the nevisAuth configuration.
The process is triggered by services by assigning an Authorization Policy pattern using Additional Settings
which set the required Authentication Level.
Authentication Level
Define the authentication level that this flow produces on successful execution.
The step assigned to On Entry (or a subsequent step) must achieve at least this level.
Custom Condition
Enter a custom nevisAuth or EL expression.
If set the Authentication Level will not be used.
The step assigned to On Entry will be executed when the expression evaluates to true.
On Entry
Point to the first step of the authentication process.
Authentication Done
Plugin: nevisadmin-plugin-nevisauth
Completes an authentication flow.
The pattern may only be used as the last step within an authentication flow.
Use as explicit follow-up for patterns such as Generic Authentication Step and User Information
which do not add follow-up steps automatically.
Authentication Failed
Plugin: nevisadmin-plugin-nevisauth
Shows a GUI with the error message error_99.
When the GUI is shown, the session is terminated.
If HTTP Error Code is configured and the configured code is handled on the nevisProxy Virtual Host
then the GUI is not shown, and a static error page is presented instead.
The pattern may only be used as the last step within an authentication flow.
Use as explicit follow-up for patterns such as Generic Authentication Step and User Information
which do not add follow-up steps automatically.
HTTP Error Code
Enter a status code for error page produced by nevisAuth.
If not set the status code will be 200.
Note that the error page from nevisAuth will not be shown, when error handling is applied by nevisProxy.
nevisProxy replaces the body of the HTTP response, when there is a page for this status code,
uploaded to Hosted Resources of the Virtual Host, or to a HTTP Error Handling pattern.
Authentication Realm
Plugin: nevisadmin-plugin-nevisauth
This pattern configures authentication.
Assign this pattern to your applications as Authentication Realm,
or expose it as a SAML IDP or OAuth 2.0 Authorization Server / OpenID Provider.
Examples how to authenticate users can be found in the Concept & Configuration Guide.
The authentication processes are provided by a nevisAuth Instance which has to be assigned.
For rendering pages during authentication, a Login Renderer is used.
Initial Authentication Flow
The initial authentication flow starts with the assigned authentication step. To create a multistep flow, reference further steps from within the first assigned step.
The initial authentication flow is applied on first access, when the client does not have an authenticated session.
Every time a step within the flow executes successfully, the authentication level defined in that step is added to the authenticated session.
Session Upgrade Flows
Applications may be configured to trigger a session upgrade flow.
Here you assign the authentication steps which provide these session upgrade flows.
This mechanism also works when the realm is accessed via a SAML IDP.
The process of selecting and executing a flow is as follows:
An application's Authorization Policy specifies the required authentication level (2-9) which is needed to access the application.
Level 1 is not allowed here, as the session has at least level 1 after the user successfully completes the initial authentication flow.
Every time the user accesses the application, the policy is enforced as follows:
- If the authentication level of the current session is lower than the level required by the policy,
nevisAuth is invoked to execute a session upgrade flow - the one which provides the required level.
-
Only if the flow runs through successfully, the level reached is stored in the session and access is granted.
-
If the level of the session equals, or is higher than the required level, access is granted immediately.
-
Authentication steps assigned here are executed only if the required level (by policy) exactly matches the provided value in its
Authentication Levelproperty. For example, if level3is required, the authentication step directly providing that level is started.
It is possible, in a multistep flow, that the required authentication is reached only after the second step or later.
In this case, assign Advanced Session Upgrade as the first step.
In this step, you declare the level that should ultimately be reached by the flow.
The engine can then match the required level to the one provided by the flow,
even if it is not provided by the first authentication step in the flow.
When no flow can be determined the Default Session Upgrade Flow will be used instead.
Default Session Upgrade Flow
Assign an authentication step which should be invoked when a session upgrade is triggered
and none of the Session Upgrade Flows can be applied.
Unlock Flow
To support the unlock method assign a step here.
This method is triggered by nevisProxy in the following cases:
- after the session was locked due to timeout
- after the session was locked with a request containing the query parameter
?lock
This is an advanced configuration.
The unlock method is sometimes used in setups where nevisProxy acts as a reverse proxy in front of applications.
Logout Flow
The default logout behavior is as follows:
- the logout is invoked by a request to a protected application with query parameter
?logout. - nevisAuth receives a request with method
logout. The default implementation simply terminates the session and returns aGuidescriptor - a page is shown that informs the user that the logout is done.
- when the user clicks the
Continuebutton, they can log in again on the same URL.
To replace this behavior, assign a step here. The following step types are supported:
Logout: this step has settings that apply to the logout flowGeneric Authentication Step: in case you need a custom implementation
To offer the logout function to the user, you have to add a link to your applications.
When this realm is used through a SAML IDP, then customization of the logout flow is limited. This is because the SAML protocol defines how logouts are performed.
The only thing that you can customize in case of SAML is the URL to redirect to in case of IDP-initiated SAML logout,
after the SAML logout is done, and the process ends on the IDP side.
To do this, you have to assign a Logout pattern and configure a custom Redirect.
Application Access Tokens
Tokens assigned here may be created after successful completion of the Initial Authentication Flow.
To produce and forward a token to an application backend,
reference the same token from the application's Additional Settings property.
nevisAuth
Assign a nevisAuth Instance pattern.
Key Store
Define the key store to use for 2-way HTTPs connections from nevisProxy to nevisAuth.
If no pattern is assigned automatic key management will provide the required key material.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
Trust Store
Defines the trust store that nevisProxy uses to validate the nevisAuth HTTPs endpoint.
If no pattern is assigned automatic key management is used to provide the trust store.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
Hostname Validation
Enable to verify that the hostname on the certificate presented by nevisAuth matches the configured hostname in the nevisAuth Instance or nevisAuth Connector pattern.
Internal SecToken Trust Store
Defines the trust store nevisProxy uses for validating the signature of the NEVIS SecToken issued by nevisAuth.
If no pattern is assigned automatic key management is asked to provide the trust store.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
OriginalURL SecretKey
If set, the parameter OriginalUrl.Enable of the IdentityCreationFilter will be set to true and the parameter OriginalUrl.SecretKey to the configured value.
This parameter solves many issues with multiple tabs, multiple frames, and incorrect redirects after login.
Custom Parameters (IdentityCreationFilter)
Add custom init-param elements to each IdentityCreationFilter generated by this pattern.
Most realms generate only 1 IdentityCreationFilter named Authentication_<name>,
which is used to protect the application.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Examples:
| Key | Value |
|---|---|
| BodyReadSize | 64000 |
| InterceptionRedirect | Condition:ENV:HTTP_USER_AGENT:mozilla|Mozilla\ninitial\nnever |
| ClientCert | want |
Custom Parameters (SecurityRoleFilter)
Add custom init-param elements to the SecurityRoleFilter generated by this pattern.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Custom Parameters (Esauth4ConnectorServlet)
Add custom init-param elements to the Esauth4ConnectorServlet generated by this pattern.
That servlet is called Connector_<name>.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Examples:
| Key | Value |
|---|---|
| EnablePollTerminatedCalls | true |
Login Renderer
Choose a login renderer.
In Kubernetes deployments, assignment of a renderer is mandatory.
Assign either a nevisLogrend Instance or a Proxy Login Renderer pattern.
The renderer has to be compatible with the Default Template (see Login Template tab).
In classic VM deployments, a default login renderer will be created when no pattern is assigned.
In case of nevisLogrend, the instance will be called default and deployed on the same host as nevisProxy.
Key Store
Configure a key store to use for 2-way TLS connections to nevisLogrend.
If no pattern is assigned no key store will be created.
The connection will be either 1-way TLS or plain HTTP, depending on the URL of nevisLogrend.
This configuration does not apply when a Proxy Login Renderer is used.
Trust Store
Configure a trust store to use for TLS connections to nevisLogrend.
If no pattern is assigned an automatic trust store will be created.
This configuration does not apply when plain HTTP or the Proxy Login Renderer is used.
Hostname Validation
When enabled the server cert has to match the hostname of nevisLogrend.
This configuration does not apply when plain HTTP or the Proxy Login Renderer is used.
nevisLogrend / Application default.properties
Add or overwrite properties in the default.properties of the nevisLogrend Application.
This is an advanced setting. Use only when there is no other alternative and consider creating a support ticket with your use case.
Check Login Application Configuration for supported properties.
We recommend not overwriting any language related properties, as the languages have to be in sync with nevisAuth.
You can configure the supported languages on the nevisAuth Instance.
This setting requires that nevisLogrend is used for GUI rendering.
Check the help of Login Renderer for details.
Template Style
Choose a default template:
classic: default in releases before May 2025.modern: default since May 2025.proxy: a template for thenevisProxy Login Renderer.
The modern template is recommended for new setups.
Company Logo
Upload a logo to be displayed on the login page.
The logo file should have an appropriate size, e.g. 50x50 pixels.
Out of the box, this setting is supported by the modern template only.
If you use a different nevisLogrend template,
you can add the expression ${logo} to point to the uploaded file.
Download the modern template to see how the expression is used there.
Primary Color
Configure the primary color.
Out of the box, this setting is supported by the modern template only. It is used to color buttons.
If you use a different nevisLogrend template, you can add the expression ${primaryColor} in your CSS file.
Download the modern template to see how the expression is used there.
Border Radius
Configure the corder radius of the login box.
Out of the box, this setting is supported by the modern template only.
If you use a different nevisLogrend template, you can add the expression ${borderRadius} in your CSS file.
Download the modern template to see how the expression is used there.
Font Family
Configure the font family.
By default, this setting is supported by the modern template only.
If you use another template, you can reference the expression ${fontFamily} in your CSS file.
Check the modern template for an example of how the expression is applied.
The actual font used depends on the browser and operating system.
You can specify multiple font families, separated by commas, to provide fallbacks. The CSS files in the template append additional fonts to ensure all characters (even emojis) can be rendered.
This approach follows the idea described here: Bootstrap Native Font Stack.
Example values:
Arial, sans-serifHelvetica, Arial, sans-serifTimes New Roman, serif
Template Customization
Customize the rendering of login pages.
Download one of the default templates to get started.
nevisLogrend: Direct Mode
You can upload Velocity template files and resources to nevisLogrend.
Zip files will be extracted into the nevisLogrend application:
/var/opt/nevislogrend/<instance>/data/applications/<realm>
Flat files will be added to the following subdirectories:
webdata/template: Velocity templates (*.vm)webdata/resources: static resources (e.g. images, CSS, Javascript)
nevisLogrend: Expressions
In nevisLogrend templates you may use the following expressions:
| Expression | Description |
|---|---|
${form} | login form (form.vm) |
${lang.switch} | language switcher component (lang.vm) |
${lang.code} | current language code (i.e. en, de) |
${label.myLabel} | a label which must be translated via Custom Translations |
${resources} | path to static resources (e.g. CSS, images, Javascript) |
${resource:<name>} | path to static resource name with attached hash |
These expressions will be replaced with a corresponding Velocity snippet at generation time.
For instance, using the expression ${resource:bootstrap.min.css} with the modern template yields the following path:
${login.appDataPath}/resources/bootstrap.min.css?v=3f1c72e8.
Note that the expression ${login.appDataPath} is handled at runtime by nevisLogrend.
nevisProxy Login Renderer
nevisProxy provides a basic login renderer which can be used instead of nevisLogrend.
See Login Renderer for details.
For each enabled language (e.g. en) upload a file named <lang>_template.html.
The template must contain the placeholder NEVIS_AUTH_FORM.
If your templates require additional resources (e.g. CSS, images)
upload them as Hosted Resources on the nevisProxy virtual host.
nevisLogrend: Simple Mode
In simple cases you may not have to deal with Velocity template files.
To replace the outer HTML you can upload a file named template.html.
The template must contain the ${form} expression.
Here is a simple example:
<!DOCTYPE html>
<html lang="${lang.code}">
<head>
<title>${label.title}</title>
<link href="${resources}/bootstrap.min.css" rel="stylesheet" type="text/css">
<link href="${resources}/default.css" rel="stylesheet" type="text/css" media="all">
</head>
<body>
<header id="header" class="container-fluid">
<img class="logo center-block" src="${resources}/logo.png" alt="Company Logo">
</header>
<main id="content" class="container">
${form}
</main>
</body>
</html>
Customization Mode
Choose between:
-
additive: files uploaded asLogin Templatewill be added on top of the default.- Use this option when you want to add or replace files, but do not want to upload an entire template.
-
complete: only the files uploaded asLogin Templatewill be deployed.- Use this option when you want to provide the entire template.
Dynamic Template Selection
Configure how the login template is selected based on the request. Choose between:
disabled: The login template configured in this tab is used.OAuth client: select the login template based on the OAuth client ID.
The OAuth client variant requires that you fill out the Template Selection Rules table.
Template Mapping
When Template Selection is set to OAuth client, you have to define which login template to use for which OAuth client ID.
Fill out this table as follows:
- Key: The OAuth client ID.
- Value: Index within
Login Templates
Dynamic Templates
Assign additional login templates that are dynamically selected based on the request.
Check the Template Selection and Template Selection Rules settings for details.
This setting is ignored when Template Selection is disabled.
Default Translations
Choose between:
enabled- add translations for labels which are commonly used
(e.g. title or language.* labels in nevisLogrend, error.* labels in nevisAuth)
and which are provided by realm patterns (e.g. assigned authentication steps).
disabled- add only what has been uploaded viaCustom Translations.
If your translations are incomplete, users will see the untranslated labels.
Note that nevisAuth supports only 1 set of translations and the generation is cumulative.
Thus, if you have 1 nevisAuth Instance with multiple realms, and you want to leave out default labels,
then you have select disabled in all these realms.
Custom Translations
Labels are used to show text in the language of the user.
Which labels are used depends on the assigned steps.
Click Download Default Labels to retrieve the used labels and their translations.
Here you can overwrite the defaults and add your own translations or even add new labels,
which may be required when using a Custom Login Template or Generic Authentication Step.
Upload 1 file per language code. The file name should be labels_<code>.properties.
Check Languages on the nevisAuth Instance for enabled language codes.
The uploaded files must be UTF-8 encoded or special characters must be HTML encoded.
If you want to reuse existing text_<code>.properties and LitDict_<code>.properties files,
you have to merge them first, or set Translations Mode to separate.
By default, the patterns add several default labels and the labels configured here are added on top.
This is convenient as you only have to define labels that you want to add or overwrite.
However, this way you cannot remove labels. If you want to do that you have to set Default Translations to disabled
and then only the uploaded labels will be used.
The default login template uses the following labels:
title- used as browser page titlelanguage.<code>- used by language switch component
The default logout process of nevisAuth (which will be applied when no step is assigned to Logout)
has a confirmation GUI which uses the following labels:
logout.label- header of the logout confirmation GUIlogout.text- text shown to the usercontinue.button.label- label on the confirmation button
Translation Mode
Choose between:
combined- upload 1 file per language code namedlabels_<code>.properties.
The labels will be added to both nevisAuth and nevisLogrend.
Alternatively, you can upload a zip file called labels.zip containing these properties files.
separate- select only when you need different labels in nevisAuth and nevisLogrend.
The files must be called LitDict_<code>.properties for nevisAuth and text_<code>.properties for nevisLogrend.
Alternatively, you may upload zip file called LitDict.zip and text.zip containing these properties files.
Session Tracking
Choose between:
COOKIE: issue a session cookie.AUTHORIZATION_HEADER: track the session based on the value of the Authorization header.CUSTOM: track the session based on custom configuration. It generates an empty session filter which has to be replaced (see below).disabled: disable session tracking.
When CUSTOM is selected, an empty filter will be generated based on the name of the realm:
<filter>
<filter-name>SessionHandler_SSO</filter-name>
<filter-class>__REPLACE_USING_GENERIC__</filter-class>
</filter>
For the filter-class, a placeholder (REPLACE_USING_GENERIC) will be used and that placeholder has to be overwritten.
Another pattern must complete the session filter. For example, use Generic Virtual Host Context pattern with the following Filters and Mappings configuration:
<filter>
<filter-name>SessionHandler_SSO_RealmName</filter-name>
<filter-class>ch::nevis::nevisproxy::filter::session::SessionManagementFilter</filter-class>
<init-param>
<param-name>Identification</param-name>
<param-value>CUSTOM</param-value>
</init-param>
<init-param>
<param-name>Custom.RequiredIdentifiers</param-name>
<param-value>HEADER:Authorization</param-value>
</init-param>
<init-param>
<param-name>Servlet</param-name>
<param-value>LocalSessionStoreServlet</param-value>
</init-param>
</filter>
Session Cookie Name
Each realm has its own session cookie.
By default, this cookie will be called Session_<pattern-name>
Set this optional property to use a different name (e.g. ProxySession).
Note that each realm has its own session. However, if the same cookie name is configured for multiple realms running on the same host the sessions will be cleaned up together when the first session expires.
Session Cookie Same Site
In February 2020 Chrome 80 has been released which treats cookies without SameSite flag as Lax.
This change can break cross-domain use cases (e.g. SAML).
Thus, it is recommended to select None here.
If None is selected, and you have to support older browsers also check Cookie Same Site Relaxation.
If you do not expect any requests from other domains, you may also go for Lax or Strict as this increases security.
Session Cookie Same Site Relaxation (Experimental)
Some older browsers treat cookies with SameSite=None as Strict.
See this example bug report for Safari:
Bug 198181 - Cookies with SameSite=None or SameSite=invalid treated as Strict
Enable this feature to map a filter to the root location /* which evaluates the User-Agent request header
to remove SameSite=None for browsers which are known to be affected.
Session Cookie Validity Timeout
Configures the number of seconds a cookie is still valid after a new cookie is generated, for example, due to a successful login.
Increasing the value can help minimize the chance of session loss during a login or step-up with parallel requests.
Session Validation
A newline separated list of rules declaring attributes that must not change in the same session. A rule has the following syntax:
AUTH|ENV|CONST|PARAM|HEADER:<name of the attribute>:block|invalidate
block: the request will be blocked and403 (Forbidden)will be returnedinvalidate: the session will be invalidated and a new one will be created
nevisProxy Conditions are supported. See nevisProxy reference guide for details.
For instance, use the following configuration to terminate the session if the source IP changes:
ENV:REMOTE_ADDR:invalidate
Initial Session Timeout
Define the idle timeout of the initial session. The user must complete the authentication within this time.
Authenticated Session Timeout
Define the idle timeout of an authenticated session.
Max Session Lifetime
Define the maximum lifetime of an authenticated session. The session will be removed after that time even if active.
Update Session Timestamp Interval
Sets the minimum time interval between two updates of the session timestamp.
If the parameter is set to "0", the system will update the session timestamp each time a request accesses a session.
The Initial Session Timeout is used as Update Session Timestamp Interval if it is shorter than the duration configured here.
Custom Parameters (SessionManagementFilter)
Add custom init-param elements the SessionManagementFilter generated by this pattern.
Examples:
| Key | Value |
|---|---|
| Cookie.Persistent | true |
| Cookie.Path | /some/path |
Language Cookie Name
Enter a name of the cookie that nevisLogrend issues to remember the language of the user.
The same name will also be used in nevisAuth to determine the language.
Note that the language cookie name is an instance global configuration in nevisAuth. Enter the same value for all realms associated with the same nevisAuth instance.
Language Cookie Domain
Enter a domain for the cookie that nevisLogrend issues to remember the language of the user.
This setting should only be used when you want to issue a wildcard cookie
to share the language with other sub-domains (e.g. across multiple Virtual Host).
For instance, if you enter .example.com then
the cookie will also be sent to subdomain.example.com.
Reset Authentication Condition
In some setups it is required to adapt the resetAuthenticationCondition of the Domain.
You can configure a nevisAuth or EL expression here.
If the expression evaluates to true then the authentication flow is reset
and the request is dispatched from the beginning.
Authorization Policy
Plugin: nevisadmin-plugin-nevisauth
Assign the pattern to an application to enforce a session upgrade (stepup).
Define the session upgrade process in the realm used for initial authentication.
If the realm is a SAML Service Provider Realm,
define the upgrade flow in the realm
assigned to the SAML Identity Provider.
Required Roles
Optional setting to enforce authorization.
Callers need any of the specified roles to access.
Required roles defined for an application can be overridden for a sub-path by combining several Authorization Policy patterns for this application.
Required roles can also be inherited between patterns. See Required Roles Mode for details.
This setting requires assigning an Authentication Realm on the application pattern.
Usage examples:
-
Enforce required roles for an application: use an
Authorization Policypattern with theRequired Rolesto enforce and link it to the application viaAdditional Settings; -
Enforce required roles for some sub-paths of an application: use an
Authorization Policypattern with theRequired Rolesto enforce andApply only to sub-pathsset to the paths to protect. Link the pattern to the application viaAdditional Settings; -
Enforce some main required roles for an application and some specific required roles for some sub-paths: use two
Authorization Policypatterns, one with the mainRequired Rolesand no sub-path, and one with the specificRequired RolesandApply only to sub-pathsset to the paths where the specific required roles should apply. Link both patterns to the application viaAdditional Settings. -
Enforce some main required roles for an application and disable them for some sub-paths: use two
Authorization Policypatterns, one with the mainRequired Rolesand no sub-path, and one with noRequired RolesandApply only to sub-pathsset to the paths where no required roles should be enforced. Link both patterns to the application viaAdditional Settings. -
Enforce some required roles for an application and add some forbidden roles for some sub-paths: use two
Authorization Policypatterns, one with theRequired Rolesfor the application,Required Roles Modeset toself-contained, and no sub-path, and the other pattern with noRequired Roles,Required Roles Modeset toinherited, theForbidden Rolesfor the subpaths,Forbidden Roles Modeset toself-contained, andApply only to sub-pathsset to the paths where the forbidden roles should be enforced. Link both patterns to the application viaAdditional Settings.
Forbidden Roles
Optional setting to enforce authorization.
Callers must not have any of the specified roles to access.
Forbidden roles defined for an application can be overridden for a sub-path by combining several Authorization Policy patterns for this application.
Forbidden roles can also be inherited between patterns. See Forbidden Roles Mode for details.
This setting requires assigning an Authentication Realm on the application pattern.
Usage examples:
-
Enforce forbidden roles for an application: use an
Authorization Policypattern with theForbidden Rolesto enforce and link it to the application viaAdditional Settings; -
Enforce forbidden roles for some sub-paths of an application: use an
Authorization Policypattern with theForbidden Rolesto enforce andApply only to sub-pathsset to the paths to protect. Link the pattern to the application viaAdditional Settings; -
Enforce some main forbidden roles for an application and some specific forbidden roles for some sub-paths: use two
Authorization Policypatterns, one with the mainForbidden Rolesand no sub-path, and one with the specificForbidden RolesandApply only to sub-pathsset to the paths where the specific forbidden roles should apply. Link both patterns to the application viaAdditional Settings. -
Enforce some main forbidden roles for an application and disable them for some sub-paths: use two
Authorization Policypatterns, one with the mainForbidden Rolesand no sub-path, and one with noForbidden RolesandApply only to sub-pathsset to the paths where no forbidden roles should be enforced. Link both patterns to the application viaAdditional Settings. -
Enforce some forbidden roles for an application and add an authentication level for some sub-paths: use two
Authorization Policypatterns, one with theForbidden Rolesfor the application,Forbidden Roles Modeset toself-contained, and no sub-path, and the other pattern with noForbidden Roles,Forbidden Roles Modeset toinherited, theAuthentication Levelfor the subpaths,Authentication Level Modeset toself-contained, andApply only to sub-pathsset to the paths where the authentication level should be enforced. Link both patterns to the application viaAdditional Settings.
Authentication Level
The Authentication Level defines the strength of authentication.
Enter a number between 2 and 9 (including).
If the session is not yet at the configured level a session upgrade will be performed.
Level 1 is the weakest possible authentication.
By definition this level is reached by the initial authentication flow,
e.g. set by a username / password authentication step (e.g. LDAP Login).
Level 2 is the default level set by steps
which do second factor authentication (e.g. Test TAN).
Levels 3 to 9 are not used by default. These levels
may be used for additional session upgrade processes.
For the session upgrade to succeed there must be a step which set at least this level.
This step must be assigned to Session Upgrade Flow(s) in the Authentication Realm pattern.
In case the upgrade flow consists of multiple steps
and the level should be reached by a subsequent step
assign the Advanced Session Upgrade pattern instead.
The authentication level defined for an application can be overridden for a sub-path by combining several Authorization Policy patterns for this application.
The authentication level can also be inherited between patterns. See Authentication Level Mode for details.
This setting requires assigning an Authentication Realm on the application pattern.
Usage examples:
-
Enforce an authentication level for an application: use an
Authorization Policypattern with theAuthentication Levelto enforce and link it to the application viaAdditional Settings; -
Enforce an authentication level for some sub-paths of an application: use an
Authorization Policypattern with theAuthentication Levelto enforce andApply only to sub-pathsset to the paths to protect. Link the pattern to the application viaAdditional Settings; -
Enforce some main authentication level for an application and some specific authentication level for some sub-paths: use two
Authorization Policypatterns, one with the mainAuthentication Leveland no sub-path, and one with the specificAuthentication LevelandApply only to sub-pathsset to the paths where the specific authentication level should apply. Link both patterns to the application viaAdditional Settings. -
Enforce some main authentication level for an application and disable them for some sub-paths: use two
Authorization Policypatterns, one with the mainAuthentication Leveland no sub-path, and one with noAuthentication LevelandApply only to sub-pathsset to the paths where no authentication level should be enforced. Link both patterns to the application viaAdditional Settings. -
Enforce an authentication level for an application and add some required roles for some sub-paths: use two
Authorization Policypatterns, one with theAuthentication Levelfor the application,Authentication Level Modeset toself-contained, and no sub-path, and the other pattern with noAuthentication Level,Authentication Level Modeset toinherited, theRequired Rolesfor the subpaths,Required Roles Modeset toself-contained, andApply only to sub-pathsset to the paths where the required roles should be enforced. Link both patterns to the application viaAdditional Settings.
Apply only to sub-paths
Set to apply this pattern on some sub-paths only.
Sub-paths must be relative (e.g. not starting with /)
and will be appended to the frontend path(s) of the virtual host (/)
or applications this pattern is assigned to.
Sub-paths ending with / are treated as a prefix,
otherwise an exact filter-mapping will be created.
The following table provides examples to illustrate the behavior:
| Frontend Path | Sub-Path | Effective Filter Mapping |
|---|---|---|
/ | secure/ | /secure/* |
/ | accounts | /accounts |
/ | api/secure/ | /api/secure/* |
/ | api/accounts | /api/accounts |
/app/ | secure/ | /app/secure/* |
/app/ | accounts | /app/accounts |
/app/ | api/secure/ | /app/api/secure/* |
/app/ | api/accounts | /app/api/accounts |
Required Roles Mode
The Required Roles Mode defines which Required Roles are set for the current paths.
When combining several Authorization Policy patterns for an application, this setting allow inheriting the Required Roles from a more general pattern.
Choose one of:
self-contained: TheRequired Rolesdefined in this pattern are applied to the current paths. They override anyRequired Rolesset on parents paths. If noRequired Rolesare set in the current pattern, no required roles will be enforced for the current paths.inherited: TheRequired Rolesin this pattern is not used. Use this setting if you have anotherAuthorization Policypattern applied to a parent path to inherit the configuration from. For theRequired Rolesto be inherited from a particular parent, this setting has to be set todefault (self-contained)in the parent pattern (otherwise you may inherit a value from a grandparent).
Forbidden Roles Mode
The Forbidden Roles Mode defines which Forbidden Roles are set for the current paths.
When combining several Authorization Policy patterns for an application, this setting allow inheriting the Forbidden Roles from a more general pattern.
Choose one of:
self-contained: TheForbidden Rolesdefined in this pattern are applied to the current paths. They override anyForbidden Rolesset on parent paths. If noForbidden Rolesare set in the current pattern, no forbidden roles will be enforced for the current paths.inherited: TheForbidden Rolesin this pattern is not used. Use this setting if you have anotherAuthorization Policypattern applied to a parent path to inherit the configuration from. For theForbidden Rolesto be inherited from a particular parent, this setting has to be set todefault (self-contained)in the parent pattern (otherwise you may inherit a value from a grandparent).
Authentication Level Mode
The Authentication Level Mode defines which Authentication Level is set for the current paths.
When combining several Authorization Policy patterns for an application, this setting allow inheriting the Authorization Level from a more general pattern.
Choose one of:
self-contained: TheAuthentication Leveldefined in this pattern is applied to the current paths. They override anyAuthentication Levelset on parent paths. If noAuthentication Levelis set in the current pattern, no authentication level will be enforced for the current paths.inherited: TheAuthentication Levelin this pattern is not used. Use this setting if you have anotherAuthorization Policypattern applied to a parent path to inherit the configuration from. For theAuthentication Levelto be inherited from a particular parent, this setting has to be set todefault (self-contained)in the parent pattern (otherwise you may inherit a value from a grandparent).
Custom Parameters
Add custom init-param elements to the SecurityRoleFilter generated by this pattern.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
AuthState Patch
Plugin: nevisadmin-plugin-nevisauth
Patches AuthState elements generated by other patterns.
We recommend using this pattern only if there is no other alternative. Consider creating a ticket at Nevis with your requirements.
If you want to add a ResultCond element where the next points to an AuthState that is not yet part of any flow,
you can assign the pattern that generates this AuthState via Additional Steps.
Authentication Realm
Assign the authentication realm pattern that generates the AuthState elements that you want to patch.
Patch File
Upload an XML file containing patches for AuthState elements.
The name has to match an existing AuthState.
Check the esauth4.xml in the deployment preview to find out which elements exist.
You can change overwrite any other attribute of the AuthState,
such as class, final, and resumeState.
The following example shows the basic syntax:
<AuthState name="example-realm_example-state"
class="ch.nevis.esauth.auth.states.directResponse.DirectResponseState"
final="true" resumeState="false">
<Response value="AUTH_ERROR"/>
<property name="statusCode" value="401"/>
<property name="contentType" value="application/json"/>
<property name="content" value='{"status":"forbidden"}'/>
</AuthState>
The patches are generally additive. However, you can also remove child elements.
To remove a property, set an empty value:
<property name="example" value=""/>
Likewise, to remove a ResultCond element, leave the next attribute empty:
<ResultCond name="example" next=""/>
Additional Steps
Assign any steps that are referenced by your patches.
Credential Intelligence
Plugin: nevisadmin-plugin-nevisauth
This plugin provides a step that checks the password against the Have I Been Pwned database.
The Have I Been Pwned database is a collection of passwords that have been exposed in data breaches. The step checks the password against the database and returns a configurable warning if the password is found in the database.
If you are using labels, please make sure the following labels are available in the translation:
credential_intelligence.title, credential_intelligence.message, credential_intelligence.continue_button, credential_intelligence.change_password_button
You can find these labels in the translation file Authentication Realm > Translations > Custom Translations, within
the corresponding language files (e.g.: labels_en.properties).
Example setting:
credential_intelligence.title=Credential Intelligence
credential_intelligence.message=You should change your password.
credential_intelligence.continue_button=Continue
credential_intelligence.change_password_button=Change Password
On Continue
This is the default next authentication step.
Notification Type
- Password Change Optional (password-change-optional)
In the Password Change Optional mode, the user has the flexibility to decide whether to change their password or not. This mode provides an option to disregard the message if the user chooses to do so.
- Password Change Mandatory (password-change-mandatory)
In the Password Change Optional mode, the user is required to change their password. This mode does not provide an option to disregard the message, ensuring that the password change is mandatory.
Title
It is a text field to change the title of the pages.
The default value is exci.title, which is used for translation.
Message
It is a text field to change the message of the pages.
The default value is exci.message, which is used for translation.
Continue Button Label
It is a text field to change the change password button's label.
The default value is exci.continue_button, which is used for translation.
On Change Password
Text field to change the change password button's label.
The default value is exci.change_password_button which is used for translation.
Change Password Button Action
This pattern is used when the user presses the "Change Password" button. It defines the follow-up authentication step required to complete the password change process.
Pattern when using nevisIDM as identity provider: nevisIDM Change Password State
Timeout
The HTTP timeout setting determines the maximum amount of time (in seconds) that the system will wait for an HTTP response before timing out.
If the response times out in the given time, it will not halt and use On Continue as default.
Custom Input Field
Plugin: nevisadmin-plugin-nevisauth
A field to ask the user for some input and store the input in a variable.
Use the variable in subsequent authentication steps.
Label
Enter a text or litdict key to be displayed as label in front of the input field.
Source Variable
Enter a variable to populate the input field.
Use the syntax <scope>:<name>, where <scope> is one of:
sessnotesinargsrequest
Check your nevisAuth log with the log levels of Vars on INFO to find out which variables are available.
Target Variable
Enter <scope>:<name> of the variable which shall be set.
The following scopes are supported:
inargsnotessessorsession
For instance, enter notes:loginid to prefill the login form
which is produced by the nevisIDM Password Login pattern.
Optional
Input into the field is optional or mandatory.
Choose between:
optional- No input is required to the field.mandatory- Input is required to the field.
Custom Risk Score Weight Configuration
Plugin: nevisadmin-plugin-nevisadapt
Use the pattern for custom risk score weight configuration.
Every weight must be between 0 and 1 inclusive.
The higher the value the more impact the component has on the aggregate score.
Set the weight to 0 to disregard the analyzer completely.
Default values are the same as for Balanced configuration.
Geolocation Weight
Configuration of the risk score weight for the geolocation analyzer's risk score.
IP Weight
Configuration of the risk score weight for the ip analyzer's risk score.
IP Reputation Weight
Configuration of the risk score weight for the ip reputation analyzer's risk score.
IP Velocity Weight
Configuration of the risk score weight for the ip velocity analyzer's risk score.
Suspicious Country Weight
Configuration of the risk score weight for the suspicious country analyzer's risk score.
Device Cookie Weight
Configuration of the risk score weight for the device cookie analyzer's risk score.
Fingerprint Weight
Configuration of the risk score weight for the fingerprint analyzer's risk score.
Default Service
Plugin: nevisadmin-plugin-nevisproxy
Makes the configured Frontend Path(s) accessible
on the assigned Virtual Host(s) by mapping a DefaultServlet.
You can decorate the paths by assigning Additional Settings, for example,
to provide custom services using nevisProxy filters.
Note that if your request passes through the entire filter chain without being responded or redirected an error code 404 is returned.
The pattern is only to be used when there is no pattern for your use case. Whenever possible, use the following patterns instead:
Web Application,REST Service,SOAP Service: to make a backend application accessibleStandalone Authentication Flow: to provide an entry point for flows implemented in nevisAuthHosting Service: to host static resources
Virtual Host(s)
Assign a Virtual Host which shall serve as entry point.
Frontend Path(s)
The path(s) which shall be accessible on the assigned Virtual Host(s).
Additional Settings
Assign add-on patterns to customize the behavior of this service.
Example use cases:
Authorization Policyto enforce roles or an authentication level.URL Handlingto redirect or forward requests.HTTP Header Customizationto add, replace, or remove HTTP headers in requests or responses.
Dispatcher Button
Plugin: nevisadmin-plugin-nevisauth
Adds a button to an authentication GUI which takes the user to another step.
A typical use case is to add a signup button to a login screen.
Button Label
Enter a label for the text that shall be displayed on this button.
The following labels exist by default:
accept.button.labelcancel.button.labelcontinue.button.labellogin.button.labelreject.button.labelsignup.button.labelskip.button.labelsubmit.button.label
If you want to use another label, you have to define it by providing Translations in your realm pattern.
On Click
Assign an authentication step to continue with when the button is clicked.
Button Type
Select inline here to display the button as a link.
Inline Label
Enter a label to be displayed in front of the button.
This setting is used only when Button Type is set to inline.
Button Name
Enter the name of the button.
If not set, the sanitized name of the pattern will be used.
Button Value
Enter the value of the button element.
The default (true) is usually fine.
Change this setting only when you need a different value.
Dispatcher Step
Plugin: nevisadmin-plugin-nevisauth
Dispatch to other authentication steps based on nevisAuth expressions.
Condition(s)
Configure conditions.
The first column gives your condition a name.
The name must be unique and must be used in Transition(s).
In the second column enter an expression.
This may be a nevisAuth expression (${...}) or EL expression (#{...}).
See nevisAuth Technical Documentation for information about the expression syntax.
In EL expressions it is possible to reference variables from the inventory, an example can be found below.
All conditions will be evaluated and thus multiple conditions may apply.
In this case the combination of conditions in must be configured in Transition(s).
Examples:
| Key | Value |
|---|---|
| pwreset | ${request:currentResource:/pwreset:true} |
| sp | ${sess:ch.nevis.auth.saml.request.issuer:^SP$:true} |
| mfa | #{${var.mtanEnabled} or ${var.oathEnabled}} |
Transition(s)
Define how to dispatch based on conditions.
In the first column enter the transition. A transition may be:
- a condition
name - a comma-separated list of conditions
All conditions in the transition must match in order for the transition to be applicable. The most specific transition is chosen.
In the second column enter the position.
Position refers to the list of Conditional Step(s). The first step has position 1.
Examples:
| Transition | Position |
|---|---|
| pwreset | 1 |
| pwreset,mfa | 2 |
Conditional Step(s)
Assign the steps to be used for Transition(s).
Default Step
Assign the step to continue with if no transition matches.
Email Input Field
Plugin: nevisadmin-plugin-nevisauth
An input field for an email address. A basic syntax check will be performed.
The entered value will be stored in a session variable. Use the variable in subsequent authentication steps.
Label
Enter a text or litdict key to be displayed as label in front of the input field.
Source Variable
Enter a variable to populate the email input field.
Use the syntax <scope>:<name>, where <scope> is one of:
sessnotesinargsrequest
Check your nevisAuth log with the log levels of Vars on INFO to find out which variables are available.
Target Variable
Configure the variable where nevisAuth stores the user input.
Use the syntax <scope>:<name>, where <scope> is one of:
sessorsessionnotesinargs
In most cases, you will want to use the session scope so the stored value is available to any later authentication step.
However, the notes scope can be useful when you need the value only within the current request, because notes variables are cleared afterward.
For example, if the next authentication step is nevisIDM Password Login, you can set notes:loginid to prefill the login form.
Email Validation
Customize the email validation regular expression.
The regular expression will be used in a Groovy script
and thus the \ character will be escaped in the generated script.
Optional
Input into the field is optional or mandatory.
Choose between:
optional- No input is required to the field.mandatory- Input is required to the field.
Email TAN (eTAN)
Plugin: nevisadmin-plugin-nevisauth
Use to send a one-time code to a user via email.
You can use this pattern for email validation or authentication.
The defaults of this pattern work out-of-the-box when connected to On Success for nevisIDM Password Login.
If you have a different flow, you may have to adapt some settings.
For instance, you may have to adapt the Recipient to use the email from a different variable.
To configure the Gui or email content check the corresponding tabs.
On Success
Configure the step to execute after successful authentication. If no step is configured here the process ends and the user will be authenticated.
On Failure
Assign the step to execute in case no TAN code can be sent or all attempts had been exhausted.
The step will be executed in the following cases:
- the
Recipientcould not be determined - all attempts had been exhausted and the user has failed to authenticate
If no step is assigned then the authentication flow will be terminated
and an error GUI with label error_99 (System Problems) will be shown.
SMTP Server
The SMTP service for the sending the email code.
Choose between Sendgrid SMTP and a Generic SMTP patterns.
Buttons
Assign a Dispatcher Button to add a button which points to a different authentication step.
Sender
Sender email address.
Recipient
Enter a nevisAuth or EL expression for the recipient.
You have to ensure that this expression always resolves. There will be a system error if the expression does not produce an email address.
Examples:
${sess:ch.nevis.idm.User.email}
Subject
The subject for the email.
The default uses an expression which resolves a label.
This way the subject can be translated.
Body
The body of the email.
The default uses an expression which resolves a label.
This way the subject can be translated.
To keep things simple, the code is added with a second expression.
Gui Name
Change the name of the Gui element.
Change this only if you need the Gui name your login template to render the screen differently.
Gui Title
Change the Gui title.
We recommend entering a label here and providing translations for this label in the Authentication Realm.
Show Email
Configure if the email address shall be shown in the UI or not.
Select disabled to not show the email address.
The label etan.info will be used in this case.
Select enabled here to also show the email address.
In this case, a different label etan.info.email will be used.
Button Order
Choose primary to show the primary button before any additional buttons.
Choose reverse to display the primary button last.
Max Retries
The maximum retry attempts for each code.
When this threshold is reached, the behavior depends on Max Regenerations.
As long as Max Regenerations is not exhausted, a new code will be generated and sent to the user.
Once Max Regenerations is reached as well, the On Failure exit will be taken.
Max Regenerations
The maximum number of times a new code can be generated.
If the value is 1 or greater, a resend button will be added to the screen.
The button is shown only when there are still resends left.
When you configure 0 there will only be 1 code and thus there will be no resend button.
Note that when Max Retries is reached, a new code will be generated and sent automatically.
TAN Format
The format of the TAN code that the user has to enter.
| Option | Format | Testing Mode Code |
|---|---|---|
4 digits | 4 numbers [0-9] | 1111 |
5 digits | 5 numbers [0-9] | 11111 |
6 digits | 6 numbers [0-9] | 111111 |
4 letters | 4 upper case letters [A-Z] | AAAA |
5 letters | 5 upper case letters [A-Z] | AAAAA |
6 letters | 6 upper case letters [A-Z] | AAAAAA |
4 alphanumeric | 4 out of [0-9A-Z] | AAA1 |
5 alphanumeric | 5 out of [0-9A-Z] | AAAA1 |
6 alphanumeric | 6 out of [0-9A-Z] | AAAAA1 |
Testing Mode
Select enabled to not send any code to the user.
No email will be sent and no SMTP Server needs to be assigned.
The code that needs to be entered depends on the selected TAN Format (see Advanced Settings).
Authentication Level
Set an authentication level if authentication of this step is successful. The level is relevant only if there are is an Authorization Policy assigned to applications.
Button Order
Choose primary to show the primary button before any additional buttons.
Choose reverse to display the primary button last.
Generic Authentication Realm
Plugin: nevisadmin-plugin-nevisauth
Create a realm by providing the entire configuration as XML.
We recommend you use the higher level Authentication Realm instead.
Token patterns, for example, Nevis SecToken and JWT Token, are not supported.
To issue a token, add the required AuthState, for example, TokenAssemblerState, to the authentication flow,
and assign a HTTP Header Customization pattern to the application to ensure that the token is sent to the backend.
There are several ways to trigger a stepup:
- use
Authorization Policyto demand anAuthentication Level - use
Generic Application Settingsto map aSecurityRoleFilterwhich hasDynamicRoleAcquireset totrue
For rendering login pages during authentication the nevisLogrend component is used. nevisLogrend is deployed on the same hosts as nevisProxy.
Configuration
Upload an XML file containing AuthState elements.
Upload of a complete esauth4.xml is not supported.
The Domain element is optional.
-
If missing the element will be created. The
Entrymethodsauthenticateandstepupwill be set to the first providedAuthState. The methodlogoutis not set and thus the nevisAuth default behavior applies. -
If provided the
Domainmust come before allAuthStateelements. The attributesnameanddefaultare not supported and should be omitted. Attributes are sorted by name. TheEntryelements are sorted bymethod.
The AuthState linked to stepup should be able to dispatch the request.
For instance, you may have assigned an Authorization Policy to your application(s)
and thus you need a state which decides based on the request variable requiredRoles.
The following example dispatches level 2 into an AuthState named TAN
which provides authentication via mTAN:
<AuthState name="EntryDispatcher" class="ch.nevis.esauth.auth.states.standard.ConditionalDispatcherState" final="false">
<ResultCond name="nomatch" next="Authentication_Done"/>
<ResultCond name="level2" next="TAN"/> <!-- TAN state is expecetd to set authLevel="2" -->
<Response value="AUTH_ERROR">
<Arg name="ch.nevis.isiweb4.response.status" value="403"/>
</Response>
<property name="condition:level2" value="${request:requiredRoles:^2.*$:true}"/>
</AuthState>
The following expressions are supported:
${instance}: name of the nevisAuth instance${request_url}: generates a nevisAuth expression which returns the URL of the current request${realm}: name of the Realm (see below)${keystore}: name of theKeyStoreelement provided by this pattern. Assign a pattern toKey Objectsto add aKeyObjectinto thisKeyStore.
The name of AuthState elements is prefixed
with the sanitized name of the Realm (referred to as ${realm}).
The realm prefix must be added when using propertyRef to reference AuthStates
generated by other patterns (e.g. <propertyRef name="${realm}_SomeState"/>).
An exception is the AuthState which defines the nevisIDM connection
(as generated by nevisIdm Password Login or nevisIDM Connector for Generic Authentication).
Here the propertyRef must be defined as follows:
<propertyRef name="nevisIDM_Connector"/>
This pattern does not validate that labels are translated.
Translations can be provided on the Authentication Realm pattern.
Template Parameters
Define Template Parameters.
Examples:
smtp: smtp.siven.ch
These parameters can be used in your Configuration.
The expression formats are:
${param.<name>}:
namefound: parameter value is used.namemissing: expression is not replaced.
${param.<name>:<default value>}:
namefound: parameter value is used.namemissing: default value will be used.
In <default value> the character } must be escaped as \}.
Resources
In case your AuthState elements require additional configuration files or scripts upload them here.
Files uploaded here will be deployed into the conf directory of the nevisAuth instance.
Key Objects
Assign patterns to add KeyObject elements to the KeyStore provided by this pattern.
nevisAuth
Assign a nevisAuth Instance pattern.
Key Store
Define the key store to use for 2-way HTTPs connections from nevisProxy to nevisAuth.
If no pattern is assigned automatic key management will provide the required key material.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
Trust Store
Defines the trust store that nevisProxy uses to validate the nevisAuth HTTPs endpoint.
If no pattern is assigned automatic key management is used to provide the trust store.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
Hostname Validation
Enable to verify that the hostname on the certificate presented by nevisAuth matches the configured hostname in the nevisAuth Instance or nevisAuth Connector pattern.
Internal SecToken Trust Store
Defines the trust store nevisProxy uses for validating the signature of the NEVIS SecToken issued by nevisAuth.
If no pattern is assigned automatic key management is asked to provide the trust store.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
OriginalURL SecretKey
If set, the parameter OriginalUrl.Enable of the IdentityCreationFilter will be set to true and the parameter OriginalUrl.SecretKey to the configured value.
This parameter solves many issues with multiple tabs, multiple frames, and incorrect redirects after login.
Custom Parameters (IdentityCreationFilter)
Add custom init-param elements to each IdentityCreationFilter generated by this pattern.
Most realms generate only 1 IdentityCreationFilter named Authentication_<name>,
which is used to protect the application.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Examples:
| Key | Value |
|---|---|
| BodyReadSize | 64000 |
| InterceptionRedirect | Condition:ENV:HTTP_USER_AGENT:mozilla|Mozilla\ninitial\nnever |
| ClientCert | want |
Custom Parameters (SecurityRoleFilter)
Add custom init-param elements to the SecurityRoleFilter generated by this pattern.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Custom Parameters (Esauth4ConnectorServlet)
Add custom init-param elements to the Esauth4ConnectorServlet generated by this pattern.
That servlet is called Connector_<name>.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Examples:
| Key | Value |
|---|---|
| EnablePollTerminatedCalls | true |
Login Renderer
Choose a login renderer.
In Kubernetes deployments, assignment of a renderer is mandatory.
Assign either a nevisLogrend Instance or a Proxy Login Renderer pattern.
The renderer has to be compatible with the Default Template (see Login Template tab).
In classic VM deployments, a default login renderer will be created when no pattern is assigned.
In case of nevisLogrend, the instance will be called default and deployed on the same host as nevisProxy.
Key Store
Configure a key store to use for 2-way TLS connections to nevisLogrend.
If no pattern is assigned no key store will be created.
The connection will be either 1-way TLS or plain HTTP, depending on the URL of nevisLogrend.
This configuration does not apply when a Proxy Login Renderer is used.
Trust Store
Configure a trust store to use for TLS connections to nevisLogrend.
If no pattern is assigned an automatic trust store will be created.
This configuration does not apply when plain HTTP or the Proxy Login Renderer is used.
Hostname Validation
When enabled the server cert has to match the hostname of nevisLogrend.
This configuration does not apply when plain HTTP or the Proxy Login Renderer is used.
nevisLogrend / Application default.properties
Add or overwrite properties in the default.properties of the nevisLogrend Application.
This is an advanced setting. Use only when there is no other alternative and consider creating a support ticket with your use case.
Check Login Application Configuration for supported properties.
We recommend not overwriting any language related properties, as the languages have to be in sync with nevisAuth.
You can configure the supported languages on the nevisAuth Instance.
This setting requires that nevisLogrend is used for GUI rendering.
Check the help of Login Renderer for details.
Template Style
Choose a default template:
classic: default in releases before May 2025.modern: default since May 2025.proxy: a template for thenevisProxy Login Renderer.
The modern template is recommended for new setups.
Company Logo
Upload a logo to be displayed on the login page.
The logo file should have an appropriate size, e.g. 50x50 pixels.
Out of the box, this setting is supported by the modern template only.
If you use a different nevisLogrend template,
you can add the expression ${logo} to point to the uploaded file.
Download the modern template to see how the expression is used there.
Primary Color
Configure the primary color.
Out of the box, this setting is supported by the modern template only. It is used to color buttons.
If you use a different nevisLogrend template, you can add the expression ${primaryColor} in your CSS file.
Download the modern template to see how the expression is used there.
Border Radius
Configure the corder radius of the login box.
Out of the box, this setting is supported by the modern template only.
If you use a different nevisLogrend template, you can add the expression ${borderRadius} in your CSS file.
Download the modern template to see how the expression is used there.
Font Family
Configure the font family.
By default, this setting is supported by the modern template only.
If you use another template, you can reference the expression ${fontFamily} in your CSS file.
Check the modern template for an example of how the expression is applied.
The actual font used depends on the browser and operating system.
You can specify multiple font families, separated by commas, to provide fallbacks. The CSS files in the template append additional fonts to ensure all characters (even emojis) can be rendered.
This approach follows the idea described here: Bootstrap Native Font Stack.
Example values:
Arial, sans-serifHelvetica, Arial, sans-serifTimes New Roman, serif
Template Customization
Customize the rendering of login pages.
Download one of the default templates to get started.
nevisLogrend: Direct Mode
You can upload Velocity template files and resources to nevisLogrend.
Zip files will be extracted into the nevisLogrend application:
/var/opt/nevislogrend/<instance>/data/applications/<realm>
Flat files will be added to the following subdirectories:
webdata/template: Velocity templates (*.vm)webdata/resources: static resources (e.g. images, CSS, Javascript)
nevisLogrend: Expressions
In nevisLogrend templates you may use the following expressions:
| Expression | Description |
|---|---|
${form} | login form (form.vm) |
${lang.switch} | language switcher component (lang.vm) |
${lang.code} | current language code (i.e. en, de) |
${label.myLabel} | a label which must be translated via Custom Translations |
${resources} | path to static resources (e.g. CSS, images, Javascript) |
${resource:<name>} | path to static resource name with attached hash |
These expressions will be replaced with a corresponding Velocity snippet at generation time.
For instance, using the expression ${resource:bootstrap.min.css} with the modern template yields the following path:
${login.appDataPath}/resources/bootstrap.min.css?v=3f1c72e8.
Note that the expression ${login.appDataPath} is handled at runtime by nevisLogrend.
nevisProxy Login Renderer
nevisProxy provides a basic login renderer which can be used instead of nevisLogrend.
See Login Renderer for details.
For each enabled language (e.g. en) upload a file named <lang>_template.html.
The template must contain the placeholder NEVIS_AUTH_FORM.
If your templates require additional resources (e.g. CSS, images)
upload them as Hosted Resources on the nevisProxy virtual host.
nevisLogrend: Simple Mode
In simple cases you may not have to deal with Velocity template files.
To replace the outer HTML you can upload a file named template.html.
The template must contain the ${form} expression.
Here is a simple example:
<!DOCTYPE html>
<html lang="${lang.code}">
<head>
<title>${label.title}</title>
<link href="${resources}/bootstrap.min.css" rel="stylesheet" type="text/css">
<link href="${resources}/default.css" rel="stylesheet" type="text/css" media="all">
</head>
<body>
<header id="header" class="container-fluid">
<img class="logo center-block" src="${resources}/logo.png" alt="Company Logo">
</header>
<main id="content" class="container">
${form}
</main>
</body>
</html>
Customization Mode
Choose between:
-
additive: files uploaded asLogin Templatewill be added on top of the default.- Use this option when you want to add or replace files, but do not want to upload an entire template.
-
complete: only the files uploaded asLogin Templatewill be deployed.- Use this option when you want to provide the entire template.
Default Translations
Choose between:
enabled- add translations for labels which are commonly used
(e.g. title or language.* labels in nevisLogrend, error.* labels in nevisAuth)
and which are provided by realm patterns (e.g. assigned authentication steps).
disabled- add only what has been uploaded viaCustom Translations.
If your translations are incomplete, users will see the untranslated labels.
Note that nevisAuth supports only 1 set of translations and the generation is cumulative.
Thus, if you have 1 nevisAuth Instance with multiple realms, and you want to leave out default labels,
then you have select disabled in all these realms.
Custom Translations
Labels are used to provide human-readable text in the language of the user.
The language is extracted from the Accept-Language header
and the default login page template has a language selection.
Which labels are used depends on the assigned steps.
Click Download Default Labels to retrieve the labels used and their translations.
Here you can overwrite the defaults and add your own translations or even introduce new labels
which may be required when using a Custom Login Template or Generic Authentication Step patterns.
The name of uploaded files must end with the language code.
As the format is compatible you may upload existing text_<code>.properties files of nevisLogrend
or LitDict_<code>.properties of nevisAuth.
The encoding of uploaded files does not matter as long as all translations are HTML encoded.
The default login template uses the following labels:
title- used as browser page titlelanguage.<code>- used by language switch component
The default logout process of nevisAuth (which will be applied when no step is assigned to Logout)
produces a confirmation GUI which requires the following labels:
logout.label- header of the logout confirmation GUIlogout.text- text shown to the usercontinue.button.label- label on the confirmation button
Translation Mode
Choose between:
combined- upload 1 file per language code namedlabels_<code>.properties.
The labels will be added to both nevisAuth and nevisLogrend.
Alternatively, you can upload a zip file called labels.zip containing these properties files.
separate- select only when you need different labels in nevisAuth and nevisLogrend.
The files must be called LitDict_<code>.properties for nevisAuth and text_<code>.properties for nevisLogrend.
Alternatively, you may upload zip file called LitDict.zip and text.zip containing these properties files.
Session Tracking
Choose between:
COOKIE: issue a session cookie.AUTHORIZATION_HEADER: track the session based on the value of the Authorization header.CUSTOM: track the session based on custom configuration. It generates an empty session filter which has to be replaced (see below).disabled: disable session tracking.
When CUSTOM is selected, an empty filter will be generated based on the name of the realm:
<filter>
<filter-name>SessionHandler_SSO</filter-name>
<filter-class>__REPLACE_USING_GENERIC__</filter-class>
</filter>
For the filter-class, a placeholder (REPLACE_USING_GENERIC) will be used and that placeholder has to be overwritten.
Another pattern must complete the session filter. For example, use Generic Virtual Host Context pattern with the following Filters and Mappings configuration:
<filter>
<filter-name>SessionHandler_SSO_RealmName</filter-name>
<filter-class>ch::nevis::nevisproxy::filter::session::SessionManagementFilter</filter-class>
<init-param>
<param-name>Identification</param-name>
<param-value>CUSTOM</param-value>
</init-param>
<init-param>
<param-name>Custom.RequiredIdentifiers</param-name>
<param-value>HEADER:Authorization</param-value>
</init-param>
<init-param>
<param-name>Servlet</param-name>
<param-value>LocalSessionStoreServlet</param-value>
</init-param>
</filter>
Session Cookie Name
Each realm has its own session cookie.
By default, this cookie will be called Session_<pattern-name>
Set this optional property to use a different name (e.g. ProxySession).
Note that each realm has its own session. However, if the same cookie name is configured for multiple realms running on the same host the sessions will be cleaned up together when the first session expires.
Session Cookie Same Site
In February 2020 Chrome 80 has been released which treats cookies without SameSite flag as Lax.
This change can break cross-domain use cases (e.g. SAML).
Thus, it is recommended to select None here.
If None is selected, and you have to support older browsers also check Cookie Same Site Relaxation.
If you do not expect any requests from other domains, you may also go for Lax or Strict as this increases security.
Session Cookie Same Site Relaxation (Experimental)
Some older browsers treat cookies with SameSite=None as Strict.
See this example bug report for Safari:
Bug 198181 - Cookies with SameSite=None or SameSite=invalid treated as Strict
Enable this feature to map a filter to the root location /* which evaluates the User-Agent request header
to remove SameSite=None for browsers which are known to be affected.
Session Cookie Validity Timeout
Configures the number of seconds a cookie is still valid after a new cookie is generated, for example, due to a successful login.
Increasing the value can help minimize the chance of session loss during a login or step-up with parallel requests.
Session Validation
A newline separated list of rules declaring attributes that must not change in the same session. A rule has the following syntax:
AUTH|ENV|CONST|PARAM|HEADER:<name of the attribute>:block|invalidate
block: the request will be blocked and403 (Forbidden)will be returnedinvalidate: the session will be invalidated and a new one will be created
nevisProxy Conditions are supported. See nevisProxy reference guide for details.
For instance, use the following configuration to terminate the session if the source IP changes:
ENV:REMOTE_ADDR:invalidate
Initial Session Timeout
Define the idle timeout of the initial session. The user must complete the authentication within this time.
Authenticated Session Timeout
Define the idle timeout of an authenticated session.
Max Session Lifetime
Define the maximum lifetime of an authenticated session. The session will be removed after that time even if active.
Update Session Timestamp Interval
Sets the minimum time interval between two updates of the session timestamp.
If the parameter is set to "0", the system will update the session timestamp each time a request accesses a session.
The Initial Session Timeout is used as Update Session Timestamp Interval if it is shorter than the duration configured here.
Custom Parameters (SessionManagementFilter)
Add custom init-param elements the SessionManagementFilter generated by this pattern.
Examples:
| Key | Value |
|---|---|
| Cookie.Persistent | true |
| Cookie.Path | /some/path |
Custom Dependencies
In case your AuthState elements use custom classes upload the required JAR file(s) here.
Files uploaded here will be deployed into the lib directory of the nevisAuth instance.
Generic Authentication Service
Plugin: nevisadmin-plugin-nevisauth
Defines an authentication service which is exposed
on the given Frontend Path on the assigned Virtual Host.
Requests received on this path are forwarded to nevisAuth.
Use to import an existing configuration.
We recommend you implement complex self-service and registration processes in a dedicated application, for example, using the SOAP or REST API of nevisIDM.
The pattern can also provide authentication for applications exposed on nevisProxy,
see Generic Authentication Realm for details.
Virtual Host(s)
Assign a Virtual Host which shall serve
as entry point for this authentication service.
Frontend Path
Define a path to be mapped on the assigned virtual host.
Requests sent to this path will be forwarded to nevisAuth so that they can be handled by this authentication service.
Configuration
Enter AuthState elements as XML.
The Domain element is optional.
- If missing the element will be created. The
Entrymethods
authenticate and stepup will be set to the first provided AuthState.
The method logout is not set and thus the nevisAuth default behavior applies.
- If provided the
Domainmust come before allAuthStateelements.
The attributes name and default are not supported and should be omitted.
Attributes are sorted by name. The Entry elements are sorted by method.
The AuthState linked to stepup should be able to dispatch the request.
For instance, you may have assigned an Authorization Policy to your application(s)
and thus you need a state which decides based on the request variable requiredRoles.
The following example dispatches level 2 into an AuthState named TAN
which provides authentication via mTAN:
<AuthState name="EntryDispatcher" class="ch.nevis.esauth.auth.states.standard.ConditionalDispatcherState" final="false">
<ResultCond name="nomatch" next="Authentication_Done"/>
<ResultCond name="level2" next="TAN"/> <!-- TAN state is expected to set authLevel="2" -->
<Response value="AUTH_ERROR">
<Arg name="ch.nevis.isiweb4.response.status" value="403"/>
</Response>
<property name="condition:level2" value="${request:requiredRoles:^2.*$:true}"/>
</AuthState>
The following expressions are supported:
${instance}: name of the nevisAuth instance${request_url}: generates a nevisAuth expression which returns the URL of the current request${realm}: name of the Realm (see below)${service_url}: generates a nevisAuth expression which evaluates to true for requests received on the configuredFrontend Path${service.postfix}: in Kubernetes side-by-side deployment a postfix is added to service names. Use this expression when connecting to a service deployed against the same inventory.${keystore}: name of theKeyStoreelement provided by this pattern. Assign a pattern toKey Objectsto add aKeyObjectinto thisKeyStore.
The name of AuthState elements is prefixed
with the sanitized name of the Realm (referred to as ${realm}).
The realm prefix must be added when using propertyRef to reference AuthStates
generated by other patterns (e.g. <propertyRef name="${realm}_SomeState"/>).
An exception is the AuthState which defines the nevisIDM connection
(as generated by nevisIdm Password Login or nevisIDM Connector for Generic Authentication).
Here the propertyRef must be defined as follows:
<propertyRef name="nevisIDM_Connector"/>
This pattern does not validate that labels are translated.
Translations can be provided on the Authentication Realm pattern.
Template Parameters
Define Template Parameters.
Examples:
smtp: smtp.siven.ch
These parameters can be used in your Configuration.
The expression formats are:
${param.<name>}:
namefound: parameter value is used.namemissing: expression is not replaced.
${param.<name>:<default value>}:
namefound: parameter value is used.namemissing: default value will be used.
In <default value> the character } must be escaped as \}.
Resources
In case your AuthState elements require additional configuration files or scripts upload them here.
Files uploaded here will be deployed into the conf directory of the nevisAuth instance.
Key Objects
Assign patterns to add KeyObject elements to the KeyStore provided by this pattern.
nevisAuth
Assign a nevisAuth Instance pattern.
Key Store
Define the key store to use for 2-way HTTPs connections from nevisProxy to nevisAuth.
If no pattern is assigned automatic key management will provide the required key material.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
Trust Store
Defines the trust store that nevisProxy uses to validate the nevisAuth HTTPs endpoint.
If no pattern is assigned automatic key management is used to provide the trust store.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
Hostname Validation
Enable to verify that the hostname on the certificate presented by nevisAuth matches the configured hostname in the nevisAuth Instance or nevisAuth Connector pattern.
Internal SecToken Trust Store
Defines the trust store nevisProxy uses for validating the signature of the NEVIS SecToken issued by nevisAuth.
If no pattern is assigned automatic key management is asked to provide the trust store.
This requires that the nevisAuth Instance is part of this project and also uses automatic key management.
Automatic key management should be used for test setups only.
OriginalURL SecretKey
If set, the parameter OriginalUrl.Enable of the IdentityCreationFilter will be set to true and the parameter OriginalUrl.SecretKey to the configured value.
This parameter solves many issues with multiple tabs, multiple frames, and incorrect redirects after login.
Custom Parameters (IdentityCreationFilter)
Add custom init-param elements to each IdentityCreationFilter generated by this pattern.
Most realms generate only 1 IdentityCreationFilter named Authentication_<name>,
which is used to protect the application.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Examples:
| Key | Value |
|---|---|
| BodyReadSize | 64000 |
| InterceptionRedirect | Condition:ENV:HTTP_USER_AGENT:mozilla|Mozilla\ninitial\nnever |
| ClientCert | want |
Custom Parameters (SecurityRoleFilter)
Add custom init-param elements to the SecurityRoleFilter generated by this pattern.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Custom Parameters (Esauth4ConnectorServlet)
Add custom init-param elements to the Esauth4ConnectorServlet generated by this pattern.
That servlet is called Connector_<name>.
Multi-line values, as required for conditional configuration,
can be entered by replacing the line-breaks with \n.
Examples:
| Key | Value |
|---|---|
| EnablePollTerminatedCalls | true |
Login Renderer
Choose a login renderer.
In Kubernetes deployments, assignment of a renderer is mandatory.
Assign either a nevisLogrend Instance or a Proxy Login Renderer pattern.
The renderer has to be compatible with the Default Template (see Login Template tab).
In classic VM deployments, a default login renderer will be created when no pattern is assigned.
In case of nevisLogrend, the instance will be called default and deployed on the same host as nevisProxy.
Key Store
Configure a key store to use for 2-way TLS connections to nevisLogrend.
If no pattern is assigned no key store will be created.
The connection will be either 1-way TLS or plain HTTP, depending on the URL of nevisLogrend.
This configuration does not apply when a Proxy Login Renderer is used.
Trust Store
Configure a trust store to use for TLS connections to nevisLogrend.
If no pattern is assigned an automatic trust store will be created.
This configuration does not apply when plain HTTP or the Proxy Login Renderer is used.
Hostname Validation
When enabled the server cert has to match the hostname of nevisLogrend.
This configuration does not apply when plain HTTP or the Proxy Login Renderer is used.
nevisLogrend / Application default.properties
Add or overwrite properties in the default.properties of the nevisLogrend Application.
This is an advanced setting. Use only when there is no other alternative and consider creating a support ticket with your use case.
Check Login Application Configuration for supported properties.
We recommend not overwriting any language related properties, as the languages have to be in sync with nevisAuth.
You can configure the supported languages on the nevisAuth Instance.
This setting requires that nevisLogrend is used for GUI rendering.
Check the help of Login Renderer for details.
Template Style
Choose a default template:
classic: default in releases before May 2025.modern: default since May 2025.proxy: a template for thenevisProxy Login Renderer.
The modern template is recommended for new setups.
Company Logo
Upload a logo to be displayed on the login page.
The logo file should have an appropriate size, e.g. 50x50 pixels.
Out of the box, this setting is supported by the modern template only.
If you use a different nevisLogrend template,
you can add the expression ${logo} to point to the uploaded file.
Download the modern template to see how the expression is used there.
Primary Color
Configure the primary color.
Out of the box, this setting is supported by the modern template only. It is used to color buttons.
If you use a different nevisLogrend template, you can add the expression ${primaryColor} in your CSS file.
Download the modern template to see how the expression is used there.
Border Radius
Configure the corder radius of the login box.
Out of the box, this setting is supported by the modern template only.
If you use a different nevisLogrend template, you can add the expression ${borderRadius} in your CSS file.
Download the modern template to see how the expression is used there.
Font Family
Configure the font family.
By default, this setting is supported by the modern template only.
If you use another template, you can reference the expression ${fontFamily} in your CSS file.
Check the modern template for an example of how the expression is applied.
The actual font used depends on the browser and operating system.
You can specify multiple font families, separated by commas, to provide fallbacks. The CSS files in the template append additional fonts to ensure all characters (even emojis) can be rendered.
This approach follows the idea described here: Bootstrap Native Font Stack.
Example values:
Arial, sans-serifHelvetica, Arial, sans-serifTimes New Roman, serif
Template Customization
Customize the rendering of login pages.
Download one of the default templates to get started.
nevisLogrend: Direct Mode
You can upload Velocity template files and resources to nevisLogrend.
Zip files will be extracted into the nevisLogrend application:
/var/opt/nevislogrend/<instance>/data/applications/<realm>
Flat files will be added to the following subdirectories:
webdata/template: Velocity templates (*.vm)webdata/resources: static resources (e.g. images, CSS, Javascript)
nevisLogrend: Expressions
In nevisLogrend templates you may use the following expressions:
| Expression | Description |
|---|---|
${form} | login form (form.vm) |
${lang.switch} | language switcher component (lang.vm) |
${lang.code} | current language code (i.e. en, de) |
${label.myLabel} | a label which must be translated via Custom Translations |
${resources} | path to static resources (e.g. CSS, images, Javascript) |
${resource:<name>} | path to static resource name with attached hash |
These expressions will be replaced with a corresponding Velocity snippet at generation time.
For instance, using the expression ${resource:bootstrap.min.css} with the modern template yields the following path:
${login.appDataPath}/resources/bootstrap.min.css?v=3f1c72e8.
Note that the expression ${login.appDataPath} is handled at runtime by nevisLogrend.
nevisProxy Login Renderer
nevisProxy provides a basic login renderer which can be used instead of nevisLogrend.
See Login Renderer for details.
For each enabled language (e.g. en) upload a file named <lang>_template.html.
The template must contain the placeholder NEVIS_AUTH_FORM.
If your templates require additional resources (e.g. CSS, images)
upload them as Hosted Resources on the nevisProxy virtual host.
nevisLogrend: Simple Mode
In simple cases you may not have to deal with Velocity template files.
To replace the outer HTML you can upload a file named template.html.
The template must contain the ${form} expression.
Here is a simple example:
<!DOCTYPE html>
<html lang="${lang.code}">
<head>
<title>${label.title}</title>
<link href="${resources}/bootstrap.min.css" rel="stylesheet" type="text/css">
<link href="${resources}/default.css" rel="stylesheet" type="text/css" media="all">
</head>
<body>
<header id="header" class="container-fluid">
<img class="logo center-block" src="${resources}/logo.png" alt="Company Logo">
</header>
<main id="content" class="container">
${form}
</main>
</body>
</html>
Customization Mode
Choose between:
-
additive: files uploaded asLogin Templatewill be added on top of the default.- Use this option when you want to add or replace files, but do not want to upload an entire template.
-
complete: only the files uploaded asLogin Templatewill be deployed.- Use this option when you want to provide the entire template.
Default Translations
Choose between:
enabled- add translations for labels which are commonly used
(e.g. title or language.* labels in nevisLogrend, error.* labels in nevisAuth)
and which are provided by realm patterns (e.g. assigned authentication steps).
disabled- add only what has been uploaded viaCustom Translations.
If your translations are incomplete, users will see the untranslated labels.
Note that nevisAuth supports only 1 set of translations and the generation is cumulative.
Thus, if you have 1 nevisAuth Instance with multiple realms, and you want to leave out default labels,
then you have select disabled in all these realms.
Custom Translations
Labels are used to provide human-readable text in the language of the user.
The language is extracted from the Accept-Language header
and the default login page template has a language selection.
Which labels are used depends on the assigned steps.
Click Download Default Labels to retrieve the labels used and their translations.
Here you can overwrite the defaults and add your own translations or even introduce new labels
which may be required when using a Custom Login Template or Generic Authentication Step patterns.
The name of uploaded files must end with the language code.
As the format is compatible you may upload existing text_<code>.properties files of nevisLogrend
or LitDict_<code>.properties of nevisAuth.
The encoding of uploaded files does not matter as long as all translations are HTML encoded.
The default login template uses the following labels:
title- used as browser page titlelanguage.<code>- used by language switch component
The default logout process of nevisAuth (which will be applied when no step is assigned to Logout)
produces a confirmation GUI which requires the following labels:
logout.label- header of the logout confirmation GUIlogout.text- text shown to the usercontinue.button.label- label on the confirmation button
Translation Mode
Choose between:
combined- upload 1 file per language code namedlabels_<code>.properties.
The labels will be added to both nevisAuth and nevisLogrend.
Alternatively, you can upload a zip file called labels.zip containing these properties files.
separate- select only when you need different labels in nevisAuth and nevisLogrend.
The files must be called LitDict_<code>.properties for nevisAuth and text_<code>.properties for nevisLogrend.
Alternatively, you may upload zip file called LitDict.zip and text.zip containing these properties files.
Session Tracking
Choose between:
COOKIE: issue a session cookie.AUTHORIZATION_HEADER: track the session based on the value of the Authorization header.CUSTOM: track the session based on custom configuration. It generates an empty session filter which has to be replaced (see below).disabled: disable session tracking.
When CUSTOM is selected, an empty filter will be generated based on the name of the realm:
<filter>
<filter-name>SessionHandler_SSO</filter-name>
<filter-class>__REPLACE_USING_GENERIC__</filter-class>
</filter>
For the filter-class, a placeholder (REPLACE_USING_GENERIC) will be used and that placeholder has to be overwritten.
Another pattern must complete the session filter. For example, use Generic Virtual Host Context pattern with the following Filters and Mappings configuration:
<filter>
<filter-name>SessionHandler_SSO_RealmName</filter-name>
<filter-class>ch::nevis::nevisproxy::filter::session::SessionManagementFilter</filter-class>
<init-param>
<param-name>Identification</param-name>
<param-value>CUSTOM</param-value>
</init-param>
<init-param>
<param-name>Custom.RequiredIdentifiers</param-name>
<param-value>HEADER:Authorization</param-value>
</init-param>
<init-param>
<param-name>Servlet</param-name>
<param-value>LocalSessionStoreServlet</param-value>
</init-param>
</filter>
Session Cookie Name
Each realm has its own session cookie.
By default, this cookie will be called Session_<pattern-name>
Set this optional property to use a different name (e.g. ProxySession).
Note that each realm has its own session. However, if the same cookie name is configured for multiple realms running on the same host the sessions will be cleaned up together when the first session expires.
Session Cookie Same Site
In February 2020 Chrome 80 has been released which treats cookies without SameSite flag as Lax.
This change can break cross-domain use cases (e.g. SAML).
Thus, it is recommended to select None here.
If None is selected, and you have to support older browsers also check Cookie Same Site Relaxation.
If you do not expect any requests from other domains, you may also go for Lax or Strict as this increases security.
Session Cookie Same Site Relaxation (Experimental)
Some older browsers treat cookies with SameSite=None as Strict.
See this example bug report for Safari:
Bug 198181 - Cookies with SameSite=None or SameSite=invalid treated as Strict
Enable this feature to map a filter to the root location /* which evaluates the User-Agent request header
to remove SameSite=None for browsers which are known to be affected.
Session Cookie Validity Timeout
Configures the number of seconds a cookie is still valid after a new cookie is generated, for example, due to a successful login.
Increasing the value can help minimize the chance of session loss during a login or step-up with parallel requests.
Session Validation
A newline separated list of rules declaring attributes that must not change in the same session. A rule has the following syntax:
AUTH|ENV|CONST|PARAM|HEADER:<name of the attribute>:block|invalidate
block: the request will be blocked and403 (Forbidden)will be returnedinvalidate: the session will be invalidated and a new one will be created
nevisProxy Conditions are supported. See nevisProxy reference guide for details.
For instance, use the following configuration to terminate the session if the source IP changes:
ENV:REMOTE_ADDR:invalidate
Initial Session Timeout
Define the idle timeout of the initial session. The user must complete the authentication within this time.
Authenticated Session Timeout
Define the idle timeout of an authenticated session.
Max Session Lifetime
Define the maximum lifetime of an authenticated session. The session will be removed after that time even if active.
Update Session Timestamp Interval
Sets the minimum time interval between two updates of the session timestamp.
If the parameter is set to "0", the system will update the session timestamp each time a request accesses a session.
The Initial Session Timeout is used as Update Session Timestamp Interval if it is shorter than the duration configured here.
Custom Parameters (SessionManagementFilter)
Add custom init-param elements the SessionManagementFilter generated by this pattern.
Examples:
| Key | Value |
|---|---|
| Cookie.Persistent | true |
| Cookie.Path | /some/path |
Custom Dependencies
In case your AuthState elements use custom classes upload the required JAR file(s) here.
Files uploaded here will be deployed into the lib directory of the nevisAuth instance.
Frontend Path Settings
Assign add-on patterns to customize the Frontend Path.
Generic Authentication Step
Plugin: nevisadmin-plugin-nevisauth
Define an authentication step using XML elements as described in the nevisAuth reference guide.
An authentication step consists of one or multiple AuthState elements which belong together,
for example, username / password login against LDAP with enforced password change.
The name attribute of GuiElem elements must be unique within a Gui.
Configuration
Upload an XML file containing AuthState elements.
Example to illustrate the syntax:
<AuthState
name="${state.entry}"
class="ch.nevis.esauth.auth.states.standard.ThrottleSessionsState"
final="false">
<ResultCond name="ok" next="${state.done}" />
<Response value="AUTH_ERROR">
<Gui name="AuthErrorDialog"/>
</Response>
<property name="queryValue" value="${request:userId}" />
</AuthState>
See Standard authentication AuthStates and plug-ins for further examples.
The following expressions may be used:
${instance}: name of the nevisAuth instance.${request_url}: generates a nevisAuth expression which returns the URL of the current request${realm}: name of the Realm (see below)${state.entry}: use asnameto mark the firstAuthState.${state.done}: use asnextinResultCondelements to exit this step and continue withOn Success.${state.failed}: use asnextinResultCondelements to exit this step and continue withOn Failure.${state.exit.<index>}: use asnextinResultCondelements to exit this step and continue with anAdditional Follow-up Step(s). The index starts with1.${state.level}: must be used if anAuthentication Levelhas been defined. Use asauthLevelonResultCondelements which point to${state.done}.${keystore}: name of theKeyStoreelement provided by this pattern. Assign a pattern toKey Objectsto add aKeyObjectinto thisKeyStore.${service.postfix}: in Kubernetes side-by-side deployment a postfix is added to service names. Use this expression when connecting to a service deployed against the same inventory.${var.<name>}: insert the scalar variable<name>. This is an alternative to usingTemplate Parameters.
The name of AuthState elements is prefixed
with the sanitized name of the Realm (referred to as ${realm}).
The realm prefix must be added when using propertyRef to reference AuthStates
generated by other patterns (e.g. <propertyRef name="${realm}_SomeState"/>).
An exception is the add-on pattern nevisIDM Connector for Generic Authentication which does not set a prefix.
Here the propertyRef must be defined as follows:
<propertyRef name="nevisIDM_Connector"/>
This pattern does not validate that labels are translated.
Translations can be provided on the Authentication Realm pattern.
Template Parameters
Define Template Parameters.
The syntax is a multi-line String containing a YAML map (key-value pairs). Example:
smtp: smtp.siven.ch
doctype: "<!DOCTYPE html>"
counter: 1
As shown in the example above,
double quotes " need to be put around the value if the value contains special characters.
Parameters can be used in:
AuthState(s): direct inputAuthState(s): as file
The expression formats are:
${param.<name>}:
namefound: parameter value is used.namemissing: expression is not replaced.
${param.<name>:<default value>}:
namefound: parameter value is used.namemissing: default value will be used.
In <default value> the character } must be escaped as \}.
On Success
Use ${state.done} to continue with the assigned step.
If no step is assigned and ${state.done} is found an AuthState named <Realm>_Prepare_Done will be used instead.
On Failure
Use ${state.failed} to continue with the assigned step.
If no step is assigned and ${state.failed} is used an AuthState named <Realm>_Authentication_Failed is generated.
Custom Follow-up Steps
Assign follow-up steps.
The order of steps is relevant.
The first step in this list has index 1.
You may reference a step in the configuration
via the expression ${state.exit.<index>}.
Entry AuthState
Define the name of the first AuthState.
If not set the sanitized name of the pattern will be used.
The XML must contain an AuthState which has this name set,
or one that uses the expression ${state.entry} for the name.
Authentication Level
Optionally define an authentication level which will be set if the user has passed this step successfully.
Resources
Upload additional configuration files or scripts required by your AuthState configuration.
Uploaded files will be deployed into the conf directory of the nevisAuth instance.
Key Objects
This pattern adds a XML element KeyStore to esauth4.xml.
Each pattern referenced here creates an additional KeyObject
which will be added to this KeyStore as a child element.
Generic nevisAuth REST Service
Plugin: nevisadmin-plugin-nevisauth
Configures a nevisAuth REST service using the XML syntax described in the nevisAuth Technical Documentation.
The service is not exposed on a nevisProxy Virtual Host,
it is accessible on the assigned nevisAuth only.
The XML attribute path defines which requests are handled.
nevisAuth
Assign a nevisAuth Instance.
Configuration
As an alternative to direct configuration you can upload a file which contains the XML.
The file should contain RESTService elements only.
Uploading a complete esauth4.xml is not supported.
Template Parameters
Define Template Parameters.
Examples:
smtp: smtp.siven.ch
These parameters can be used in your Configuration.
The expression formats are:
${param.<name>}:
namefound: parameter value is used.namemissing: expression is not replaced.
${param.<name>:<default value>}:
namefound: parameter value is used.namemissing: default value will be used.
In <default value> the character } must be escaped as \}.
Generic nevisAuth Web Service
Plugin: nevisadmin-plugin-nevisauth
Configures a nevisAuth Web service using the XML syntax described in the nevisAuth Technical Documentation.
The service is not exposed on a nevisProxy Virtual Host,
it is accessible on the assigned nevisAuth only.
The XML attribute uri defines which requests are handled.
nevisAuth
Assign a nevisAuth Instance.
Configuration
The file should contain WebService elements only.
Uploading a complete esauth4.xml is not supported.
Template Parameters
Define Template Parameters.
Examples:
smtp: smtp.siven.ch
These parameters can be used in your Configuration.
The expression formats are:
${param.<name>}:
namefound: parameter value is used.namemissing: expression is not replaced.
${param.<name>:<default value>}:
namefound: parameter value is used.namemissing: default value will be used.
In <default value> the character } must be escaped as \}.
Generic SMTP
Plugin: nevisadmin-plugin-nevisauth
Set up the connection to a generic SMTP server for sending emails.
Assign the pattern to Email TAN (eTAN) as SMTP Server.
Supported protocols:
-
smtps— TLS from the start (typically port 465). Recommended. -
starttls— plain connection upgraded to TLS via STARTTLS (typically port 587). The SMTP server's CA certificate must be trusted by the nevisAuth Instance (Default Backend Trust Store). -
smtp— plain connection without TLS. Not recommended for production.
SMTP Protocol
Select the protocol of the SMTP server.
The default value smtps uses a TLS encrypted connection.
Note that the STARTTLS protocol is not supported by nevisAuth.
SMTP Server
Enter host:port of the SMTP server.
Check that you are using the correct port for the selected SMTP Protocol.
Also note that in some environments connections to port 25 are blocked, but most SMTP servers provide an alternative port.
SMTP User
If a username is required at the SMTP server enter it here.
SMTP Password
If a password is required at the SMTP server enter it here.
Generic Third-Party Authentication Realm
Plugin: nevisadmin-plugin-nevisauth
Assign the pattern to applications as Authentication Realm
to enforce authentication using a third-party authentication service.
Integration of a third-party authentication service usually consists of several steps:
-
Configure an
Authentication Filterwhich is mapped to applications to enforce authentication. The filter is expected to either trigger a redirect to a different path or perform a side-call. -
Provide a template for the
Roles Filter. The template is used to generate a filter in case anAuthorization Policyis assigned to an application.
Limitations of the pattern:
-
No support for session upgrades. In combination with nevisAuth you can demand a minimum
Authentication Levelfor an application. If the session is not yet at the desired level then a session upgrade is performed. -
No automatic support for sharing cookies between applications and the authentication service. However, you can configure this manually by configuring an
Authentication Applicationand assigning aCookie Customizationpattern toProtected Application SettingsandAuthentication Application Settings.
Authentication Filter
Define the filter that shall be application to applications to enforce authentication.
The following variables may be used:
${realm.id}- unique ID of this realm pattern${realm.name}- name of this realm pattern${auth.servlet}- name of the servlet of theAuthentication Application. May be used to perform a side-call.
Roles Filter
Define the filter that shall be application to applications to enforce the presence of certain roles.
The following expressions may be used:
${realm.id}- unique ID of this realm pattern${realm.name}- name of this realm pattern${auth.servlet}- name of the servlet of theAuthentication Application. May be used to perform a side-call.${filter.name}- a proposed filter name calculated from the required roles*{roles}- duplicates the entire line once for each role
Protected Application Settings
Assign add-on patterns to customize the behavior of applications protected by this realm.
A common case for redirect-based authentication is to assign a Cookie Customization here and to Authentication Application Settings
to share cookies between applications and the authentication application.
Authentication Application
Optionally assign an application which provides the authentication service and shall be exposed on the same virtual host as the applications.
Not required for federation-based authentication where the authentication service is hosted on another domain.
Additional Settings
Assign add-on patterns to customize the behavior of the Authentication Application.
Assigning these add-ons here may be more appropriate to have the complete authentication logic concentrated here.
Session Tracking
Choose between:
COOKIE: issue a session cookie.AUTHORIZATION_HEADER: track the session based on the value of the Authorization header.CUSTOM: track the session based on custom configuration. It generates an empty session filter which has to be replaced (see below).disabled: disable session tracking.
When CUSTOM is selected, an empty filter will be generated based on the name of the realm:
<filter>
<filter-name>SessionHandler_SSO</filter-name>
<filter-class>__REPLACE_USING_GENERIC__</filter-class>
</filter>
For the filter-class, a placeholder (REPLACE_USING_GENERIC) will be used and that placeholder has to be overwritten.
Another pattern must complete the session filter. For example, use Generic Virtual Host Context pattern with the following Filters and Mappings configuration:
<filter>
<filter-name>SessionHandler_SSO_RealmName</filter-name>
<filter-class>ch::nevis::nevisproxy::filter::session::SessionManagementFilter</filter-class>
<init-param>
<param-name>Identification</param-name>
<param-value>CUSTOM</param-value>
</init-param>
<init-param>
<param-name>Custom.RequiredIdentifiers</param-name>
<param-value>HEADER:Authorization</param-value>
</init-param>
<init-param>
<param-name>Servlet</param-name>
<param-value>LocalSessionStoreServlet</param-value>
</init-param>
</filter>
Session Cookie Name
By default, the session cookie will be called Session_<pattern-name>
Set this optional property to use a different name (e.g. ProxySession).
If the same name is configured for multiple realms on the same host then the sessions will be cleaned up together when the first session expires.
Session Cookie Same Site
In February 2020 Chrome 80 has been released which treats cookies without SameSite flag as Lax.
This change can break cross-domain use cases (e.g. SAML).
Thus, it is recommended to select None here.
If None is selected, and you have to support older browsers also check Cookie Same Site Relaxation.
If you do not expect any requests from other domains, you may also go for Lax or Strict as this increases security.
Session Cookie Same Site Relaxation (Experimental)
Some older browsers treat cookies with SameSite=None as Strict.
See this example bug report for Safari:
Bug 198181 - Cookies with SameSite=None or SameSite=invalid treated as Strict
Enable this feature to map a filter to the root location /* which evaluates the User-Agent request header
to remove SameSite=None for browsers which are known to be affected.
Session Cookie Validity Timeout
Configures the number of seconds a cookie is still valid after a new cookie is generated, for example, due to a successful login.
Increasing the value can help minimize the chance of session loss during a login or step-up with parallel requests.
Session Validation
A newline separated list of rules declaring attributes that must not change in the same session. A rule has the following syntax:
ENV|CONST|PARAM|HEADER:<name of the attribute>:block|invalidate
block: the request will be blocked and403 (Forbidden)will be returnedinvalidate: the session will be invalidated and a new one will be created
nevisProxy Conditions are supported. See nevisProxy reference guide for details.
For instance, use the following configuration to terminate the session if the source IP changes:
ENV:REMOTE_ADDR:invalidate
Initial Session Timeout
Define the idle timeout of the initial session. The user must complete the authentication within this time.
Authenticated Session Timeout
Defines the idle timeout of a nevisProxy session.
A nevisProxy session will be created only if required (e.g. to store application cookies).
Please set the timeout as low as possible to not increase the risk of session exhaustion attacks.
Max Session Lifetime
Define the maximum lifetime of a nevisProxy session. The session will be removed after that time even if active.
Update Session Timestamp Interval
Sets the minimum time interval between two updates of the session timestamp.
If the parameter is set to "0", the system will update the session timestamp each time a request accesses a session.
The Initial Session Timeout is used as Update Session Timestamp Interval if it is shorter than the duration configured here.
Custom Parameters (SessionManagementFilter)
Add custom init-param elements the SessionManagementFilter generated by this pattern.
Examples:
| Key | Value |
|---|---|
| Cookie.Persistent | true |
| Cookie.Path | /some/path |
Groovy Script Step
Plugin: nevisadmin-plugin-nevisauth
This step generates a nevisAuth ch.nevis.esauth.auth.states.scripting.ScriptState.
The GUI descriptor cannot be customized, unless you overwrite the response template in the Groovy script.
If script execution fails HTTP error code 403 is returned,
and the session will be terminated using AUTH_ERROR.
Groovy Script
Upload the Groovy script as a file.
Further information can be found in the nevisAuth Technical Documentation:
Use the expression ${service.postfix} to refer to Kubernetes services
deployed by this nevisAdmin 4 project.
The expression can always be used as it produces an empty String when the deployment is not a Kubernetes side-by-side deployment.
For instance, the following snippet declares a URL which points to the REST API
of a nevisIDM Instance that has been deployed as a Kubernetes service called idm:
def url = "https://idm${service.postfix}:8989/nevisidm/api"
You may use var expressions to insert values from inventory variables at generation time.
For instance, use ${var.<name>} to insert a variable called <name>.
If the variable is a scalar, the value will be returned as-is.
If the variable is a sequence, a Groovy list will be returned (start: [, end: ], separator: ,, String quote: ").
If your Groovy script fails to validate, see Script Validation.
Script Parameters
Set parameters for your Groovy script.
Enter the name of the parameter as Key.
The Value can be either:
- constant String value
- nevisAuth expression (
${...:...}) - an EL expression (
#{...}) - a reference to an inventory variable (
${var.<name>}). Such expressions are resolved during generation.
Parameters can then be used inside the Groovy script via the parameters map.
Example usage:
parameters.get('backend-url')
Script Validation
Choose between:
enabled- parse the Groovy script and run against mock objects.parse-only- only parse the Groovy script.disabled- the script is not validated.
The validation is not feature complete and thus there may false negatives.
For instance, import statements can make the validation fail as the corresponding classes
are usually not on the nevisAdmin 4 classpath. This case is quite common and thus
failed imports will be reported as info issues to not block deployment.
If your Groovy script produces warning or error issues
but is working inside nevisAuth please select disabled
and provide the script to Nevis Security so that we can improve the validation.
When set to enabled the following mock objects will be used for validation:
Map<String, String> parameters
Map<String, Object> inctx
Properties inargs
Map<String, Object> session
Properties outargs
Properties notes
Request request
Response response
Tracer LOG
On Success
Assign an authentication step which shall be executed
when the Groovy script sets the result ok.
response.setResult('ok')
If no step is assigned a default state will be added.
On Failure
Assign an authentication step which shall be executed
when the Groovy script sets the result error.
response.setResult('error')
If no step is assigned a default state will be added.
Custom Follow-up Step(s)
Assign follow-up steps.
For each step a transition (called ResultCond in esauth4.xml) is added.
The name of the transition depends on the position in the list.
For instance, if 2 steps are assigned the following transitions will be added:
exit.1exit.2
The Groovy script may trigger a certain transition by calling the method response.setResult
handing over the name of the transition.
Example:
response.setResult('exit.1')
Custom Class Path
Set the classPath attribute of the AuthState element.
Lines will be joined with :. Enter 1 path per line.
When set, the classLoadStrategy attribute will be set to PARENT_LAST.
Log Category
Use a different category for logging in your Groovy script.
Response Type
Choose between:
AUTH_ERROR: terminates the session.AUTH_CONTINUE: use to produce a response and continue with this state on next request.
Error Status Code
Set the status code for responses when the Response Type is set to AUTH_ERROR.
The default of 403 is backward compatible.
Note that we generally use 403 for unhandled error cases in authentication step patterns.
This is to avoid exposing the information that a certain case is not properly handled.
Depending on your case, a 500 or 400 may be a more appropriate choice.
Gui Elements
Add Gui elements to the Response.
For each line 1 Gui element will be generated.
Most authentication states have only 1 Gui element.
The format is key-value pairs. The key is used as name. The value is optional and used as label.
For instance, the line auth:title.login will produce the following Gui element:
<Gui name="auth" label="title.login"/>
Configuration of GuiElem elements is not supported.
You have to create them dynamically in your script.
Here is an example how to render a certain Gui and add GuiElem elements:
response.setGuiName('login')
response.addInfoGuiField('info', 'info.login', null)
JSON Response Step
Plugin: nevisadmin-plugin-nevisauth
A simple step that returns a JSON response.
JSON Response
Enter the JSON response.
Response Type
Use AUTH_CONTINUE to keep the current session and stay in state.
If and when the next request comes in, the On Continue exit will be taken.
Use AUTH_DONE to finish the current flow and establish an authenticated session.
In a classic reverse proxy scenario, the request will continue in the filter chain in nevisProxy, towards the calculated servlet. If the servlet points to an application the request will be forwarded.
Note that in some authentication scenarios (e.g. federation), there is no backend and thus a 404 error may occur,
unless the AUTH_DONE is handled.
For instance, there are certain AuthState classes that handle AUTH_DONE to fulfill their use case.
A prime example is the AuthorizationServer which is set up by the OAuth 2.0 Authorization Server / OpenID Provider pattern.
This one handles AUTH_DONE by completing the OAuth flow.
Use AUTH_ERROR to terminate the flow, removing the session.
Note that this type may also be used for successful execution, to remove the session.
On Continue
This exit will be taken when Response Type is set to AUTH_CONTINUE and the next request is received.
Status Code
Enter an appropriate status code for the HTTP response.
If not set the code will be set based on the selected Response Type:
AUTH_ERROR:401AUTH_DONE:200
Parameters
Define Parameters to be used in the JSON Response.
Examples:
backend-host: backend.siven.ch
The expression formats are:
${param.<name>}:
namefound: parameter value is used.namemissing: expression is not replaced.
${param.<name>:<default value>}:
namefound: parameter value is used.namemissing: default value will be used.
In <default value> the character } must be escaped as \}.
JWT Token
Plugin: nevisadmin-plugin-nevisauth
Assign to a realm using Application Access Tokens to allow the realm to produce a JWT token.
To issue a JWT token and propagate it to applications you also have to assign the pattern to
the corresponding Web Application, REST Service, or SOAP Service using Application Access Token.
The JWT token is sent in an HTTP header (default: Authorization) in the format Bearer <token>.
Token Type
The following types of JWT token are supported:
JWS: JSON Web Signature - usingHS256orHS512algorithmJWE: JSON Web Encryption - usingRSA-OAEP-256andA256GCMalgorithm
Note: in case asymmetric encryption is used, the x5t#S256 Certificate thumbprint header parameter will automatically be added
according to RFC 7515.
Token Algorithm
The following algorithms of JWT token are supported:
HS256orHS512: compatible withJWStoken typeRSA-OAEP-256: compatible withJWEtoken type
Secret
Enter a shared secret to be used for symmetric algorithms.
This is required for JWS because of the HS256 algorithm.
Signer Key Store
A Key Store is required when an asymmetric algorithm is used.
This is required for JWE because of the RSA-OAEP-256 algorithm.
Issuer
The issuer (iss) is an optional claim
which may be checked by applications receiving this token.
Subject
Enter a nevisAuth expression for the claim sub.
The default refers to the ID of the authenticated user.
Audience
The audience (aud) is an optional claim
which may be checked by applications receiving this token.