Table of Contents

Secure Token Handler

Presentation

The Secure Token Handler is a special Handler that create a token for each request and send it to the protected application. The real user identifier is stored in a Memcached server and the protected application can the request the Memcached server to get user identifier.

This mechanism allows one to do SSO on application with an unsafe link between Handler and the application, but with a safe link with the Memcached server.

Configuration

Virtual host

Apache

Configure the virtual host like other protected virtual host but use Secure Token Handler instead of default Handler.

PerlModule Lemonldap::NG::Handler::Specific::SecureToken
<VirtualHost *:80>
       ServerName secure.example.com
 
       # Load SecureToken Handler
       PerlHeaderParserHandler Lemonldap::NG::Handler::Specific::SecureToken
 
       ...
 
</VirtualHost>

Nginx

This module uses Apache2 Filter and is not compatible with Nginx.

Handler parameters

SecureToken parameters are the following:

Due to Handler API change in 1.9, you need to set these attributes in lemonldap-ng.ini and not in Manager, for example:
[handler]
secureTokenMemcachedServers = 127.0.0.1:11211
secureTokenExpiration = 60
secureTokenAttribute = uid
secureTokenUrls = .*
secureTokenHeader = Auth-Token
secureTokenAllowOnError = 1