Difference between revisions of "AppSuite:ExternalLoginPage"

(Move to https://documentation.open-xchange.com/)
(Setting custom login as logout location)
 
(One intermediate revision by one other user not shown)
Line 19: Line 19:
 
Users can still access the original product login site. If this is not wanted the following Apache  
 
Users can still access the original product login site. If this is not wanted the following Apache  
 
configuration for your VirtualHost can be used to redirect all requests to your custom login page:
 
configuration for your VirtualHost can be used to redirect all requests to your custom login page:
 +
 +
before 7.8.0:
  
 
  RewriteEngine On
 
  RewriteEngine On
Line 31: Line 33:
 
</pre>
 
</pre>
 
Note: you need to have the right syntax (like leading spaces) in the .yml file.
 
Note: you need to have the right syntax (like leading spaces) in the .yml file.
 +
 +
It is possible to have different login pages for different domains, just add another section with a different host: <mydomain.com> line.
  
 
== Setting custom login as logout location ==
 
== Setting custom login as logout location ==
Line 43: Line 47:
  
 
in '''/opt/open-xchange/etc/as-config.yml'''. This setting takes effect for example if an autologin session is expired. as-config.yml itself defines settings in dependence of the hostname configured for the Open-Xchange access.
 
in '''/opt/open-xchange/etc/as-config.yml'''. This setting takes effect for example if an autologin session is expired. as-config.yml itself defines settings in dependence of the hostname configured for the Open-Xchange access.
 +
 +
If both settings are defined for a user, io.ox/core//customLocations/logout will be used.

Latest revision as of 10:59, 8 July 2019

How to set up an external login page for App Suite

Who should read this document

This document is written for web developers who would like to create a custom login mask for the OX App Suite. The login mask can reside on an external server i. e., not directly located in the domain of the Open-Xchange machines. It is also intended for administrators who install and maintain Open-Xchange services.


HTML

The Open-Xchange HTTP API (Form login) has a function to create a session from external.

The full detailed explanation how the HTML form is used and errors can be handled can be found here:

OX Session Formlogin

Redirect to custom login

Users can still access the original product login site. If this is not wanted the following Apache configuration for your VirtualHost can be used to redirect all requests to your custom login page:

before 7.8.0:

RewriteEngine On
RewriteRule ^/appsuite/signin /custom-login.html [R]

Since 7.8.0 it can be configured directly in /opt/open-xchange/etc/as-config.yml

# Override certain settings
default:
    host: all
    loginLocation: 'http://example.com/appsuite/mycustomlogin.html'

Note: you need to have the right syntax (like leading spaces) in the .yml file.

It is possible to have different login pages for different domains, just add another section with a different host: <mydomain.com> line.

Setting custom login as logout location

If users should be directed to the custom login form after logout from App Suite the following property can be set globally somewhere in /opt/open-xchange/etc/settings/. Either create a new properties file or add the option in any existing one. For more complex setups e.g. with different brands please check out how to set this property in context or user scope which is explained here.

io.ox/core//customLocations/logout=https://login.example.com

For cases where only one custom login page exists for all users it's also recommended to set

logoutLocation: 'https://login.example.com/'

in /opt/open-xchange/etc/as-config.yml. This setting takes effect for example if an autologin session is expired. as-config.yml itself defines settings in dependence of the hostname configured for the Open-Xchange access.

If both settings are defined for a user, io.ox/core//customLocations/logout will be used.