Cloud Software Group, Inc. EBX®
Documentation > Administration Guide > Installation & configuration
Navigation modeDocumentation > Administration Guide > Installation & configuration

User authentication

The /ebx-authentication servlet

The /ebx-authentication servlet is the central point handling the user authentication in EBX®. Its role is to:

Furthermore, depending on the configuration, it can also:

The authorization token

When the /ebx-authentication servlet successfully authenticates a user, it creates a token containing the authentication information and stores it in a session cookie.

This means that the authorization is shared between all the browser tabs:

Cookie properties

The cookie containing the token has the following properties:

HttpOnly

Not customizable. The cookie can't be read by javascript code in the browser.

Secure

Customizable via the property ebx.security.authorizationCookie.attribute.secure in ebx.properties. Defines if the cookie can be sent over HTTPS only, or if it can also be sent over HTTP.

SameSite

Customizable via the property ebx.security.authorizationCookie.attribute.sameSite in ebx.properties. Defines if the cookie can be sent when browsing from an external site.

Customizing the authentication process

By default, EBX® uses a built-in directory and built-in login page. It is strongly recommended to replace the built-in directory by a custom one.

Customizing the directory

While EBX® provides a built-in directory, it is strongly recommended to replace it:

  1. Create a class overriding Directory

  2. Create a class overriding DirectoryFactory

  3. Use the property ebx.directory.factory in ebx.properties to declare the factory.

Customizing the login page

While EBX® provides a built-in login page, it is possible to replace it. To do so, use the property ebx.security.loginPage.url in ebx.properties to declare the custom login page.

It is up to the custom login page to authenticate the user. Once the user is authenticated, he should be redirected to the /ebx-authentication/login page. Then, EBX® will call the Directory.authenticateUserFromHttpRequest method before creating an authorization token. The following points are required for this to work:

Note

When EBX® redirects the user to the custom login page, it also adds a resume query parameter to the URL. This resume query parameter contains an URL pointing to /ebx-authentication/login with some additional parameters and should be used in priority to redirect the user to /ebx-authentication/login after the authentication succeeds.

Documentation > Administration Guide > Installation & configuration