Table of Contents

REST

Authentication Users Password

Presentation

This backend can be used to delegate authentication to some webservices.

Configuration

In Manager, go in General Parameters > Authentication modules and choose REST for authentication, users and/or password modules.

Then, go in REST parameters and you just have to set REST URL to provide wanted services:

Module Parameter
Authentication level Authentication level for this module
Authentication Authentication URL
User database User data URL
Password confirmation Password confirmation URL
Password change Password change URL
You can then choose any other module for users and password.

REST Dialog

REST web services have just to respond with a “result” key in a JSON file. Auth/UserDB can add an “info” array that will be stored in session data (without reading “Exported variables”).

URL Query Response
Authentication URL JSON file: {“user”:$user,“password”:$password} JSON file: {“result”:true/false,“info”:{...}}
User data URL JSON file: {“user”:$user} JSON file: {“result”:true/false,“info”:{“uid”:“dwho”,...}}
Password confirmation URL JSON file: {“user”:$user,“password”:$password} JSON file: {“result”:true/false}
Password change URL JSON file: {“user”:$user,“password”:$password} JSON file: {“result”:true/false}
To have just one call, you can only set REST authentication, set datas in “info” key response and set Null as User Database.