[ { "type": "post", "url": "/authentication/2ndfactor/u2f/sign", "title": "U2F Complete authentication", "name": "CompleteU2FAuthentication", "group": "Authentication", "version": "1.0.0", "success": { "fields": { "Success 204": [ { "group": "Success 204", "optional": false, "field": "status", "description": "

The U2F authentication succeeded.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "type": "none", "optional": false, "field": "error", "description": "

No authentication request has been provided.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

Complete authentication request of the U2F device.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Authentication", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } }, { "type": "get", "url": "/authentication/2ndfactor/u2f/sign_request", "title": "U2F Start authentication", "name": "StartU2FAuthentication", "group": "Authentication", "version": "1.0.0", "success": { "fields": { "Success 200": [ { "group": "Success 200", "optional": false, "field": "authentication_request", "description": "

The U2F authentication request.

" } ] } }, "error": { "fields": { "Error 401": [ { "group": "Error 401", "type": "none", "optional": false, "field": "error", "description": "

There is no key registered for user in session.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

Initiate an authentication request using a U2F device.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Authentication", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } }, { "type": "post", "url": "/authentication/1stfactor", "title": "LDAP authentication", "name": "ValidateFirstFactor", "group": "Authentication", "version": "1.0.0", "parameter": { "fields": { "Parameter": [ { "group": "Parameter", "type": "String", "optional": false, "field": "username", "description": "

User username.

" }, { "group": "Parameter", "type": "String", "optional": false, "field": "password", "description": "

User password.

" } ] } }, "success": { "fields": { "Success 204": [ { "group": "Success 204", "optional": false, "field": "status", "description": "

1st factor is validated.

" } ] } }, "error": { "fields": { "Error 401": [ { "group": "Error 401", "type": "none", "optional": false, "field": "error", "description": "

1st factor is not validated.

" } ], "Error 403": [ { "group": "Error 403", "type": "none", "optional": false, "field": "error", "description": "

Access has been restricted after too many authentication attempts

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

Verify credentials against the LDAP.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Authentication", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } }, { "type": "post", "url": "/authentication/2ndfactor/totp", "title": "TOTP authentication", "name": "ValidateTOTPSecondFactor", "group": "Authentication", "version": "1.0.0", "parameter": { "fields": { "Parameter": [ { "group": "Parameter", "type": "String", "optional": false, "field": "token", "description": "

TOTP token.

" } ] } }, "success": { "fields": { "Success 204": [ { "group": "Success 204", "optional": false, "field": "status", "description": "

TOTP token is valid.

" } ] } }, "error": { "fields": { "Error 401": [ { "group": "Error 401", "type": "none", "optional": false, "field": "error", "description": "

TOTP token is invalid.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

Verify TOTP token. The user is authenticated upon success.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Authentication", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } }, { "type": "get", "url": "/authentication/login", "title": "Serve login page", "name": "Login", "group": "Pages", "version": "1.0.0", "parameter": { "fields": { "Parameter": [ { "group": "Parameter", "type": "String", "optional": false, "field": "redirect", "description": "

Redirect to this URL when user is authenticated.

" } ] } }, "success": { "fields": { "Success 200": [ { "group": "Success 200", "type": "String", "optional": false, "field": "Content", "description": "

The content of the login page.

" } ] } }, "description": "

Create a user session and serve the login page along with a cookie.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Pages" }, { "type": "get", "url": "/authentication/logout", "title": "Server logout page", "name": "Logout", "group": "Pages", "version": "1.0.0", "parameter": { "fields": { "Parameter": [ { "group": "Parameter", "type": "String", "optional": false, "field": "redirect", "description": "

Redirect to this URL when user is deauthenticated.

" } ] } }, "success": { "fields": { "Success 301": [ { "group": "Success 301", "optional": false, "field": "redirect", "description": "

Redirect to the URL.

" } ] } }, "description": "

Deauthenticate the user and redirect him.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Pages" }, { "type": "get", "url": "/authentication/reset-password", "title": "Serve password reset form.", "name": "ServePasswordResetForm", "group": "Pages", "version": "1.0.0", "description": "

Serves password reset form that allow the user to provide the new password.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Pages", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } }, "parameter": { "fields": { "Parameter": [ { "group": "Parameter", "type": "String", "optional": false, "field": "identity_token", "description": "

The one-time identity validation token provided in the email.

" } ] } }, "success": { "fields": { "Success 200": [ { "group": "Success 200", "type": "String", "optional": false, "field": "content", "description": "

The content of the page.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "optional": false, "field": "AccessDenied", "description": "

Access is denied.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } } }, { "type": "get", "url": "/authentication/u2f-register", "title": "Serve U2F registration page", "name": "ServeU2FRegistrationPage", "group": "Pages", "version": "1.0.0", "description": "

Serves the U2F registration page that asks the user to touch the token of the U2F device.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Pages", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } }, "parameter": { "fields": { "Parameter": [ { "group": "Parameter", "type": "String", "optional": false, "field": "identity_token", "description": "

The one-time identity validation token provided in the email.

" } ] } }, "success": { "fields": { "Success 200": [ { "group": "Success 200", "type": "String", "optional": false, "field": "content", "description": "

The content of the page.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "optional": false, "field": "AccessDenied", "description": "

Access is denied.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } } }, { "type": "post", "url": "/authentication/2ndfactor/u2f/register", "title": "U2F Complete device registration", "name": "CompleteU2FRegistration", "group": "Registration", "version": "1.0.0", "success": { "fields": { "Success 204": [ { "group": "Success 204", "optional": false, "field": "status", "description": "

The U2F registration succeeded.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "type": "none", "optional": false, "field": "error", "description": "

Unexpected identity validation challenge.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

Complete U2F registration request.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Registration", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } }, { "type": "post", "url": "/authentication/new-totp-secret", "title": "Generate TOTP secret", "name": "GenerateTOTPSecret", "group": "Registration", "version": "1.0.0", "success": { "fields": { "Success 200": [ { "group": "Success 200", "type": "String", "optional": false, "field": "base32", "description": "

The base32 representation of the secret.

" }, { "group": "Success 200", "type": "String", "optional": false, "field": "ascii", "description": "

The ASCII representation of the secret.

" }, { "group": "Success 200", "type": "String", "optional": false, "field": "qrcode", "description": "

The QRCode of the secret in URI format.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "type": "String", "optional": false, "field": "error", "description": "

No user provided in the session or unexpected identity validation challenge in the session.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message

" } ] } }, "description": "

Generate a new TOTP secret and returns it.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Registration", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } }, { "type": "post", "url": "/authentication/reset-password", "title": "Request for password reset", "name": "RequestPasswordReset", "group": "Registration", "version": "1.0.0", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Registration", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } }, "success": { "fields": { "Success 204": [ { "group": "Success 204", "optional": false, "field": "status", "description": "

Identity validation has been initiated.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "optional": false, "field": "AccessDenied", "description": "

Access is denied.

" } ], "Error 400": [ { "group": "Error 400", "optional": false, "field": "InvalidIdentity", "description": "

User identity is invalid.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

This request issue an identity validation token for the user bound to the session. It sends a challenge to the email address set in the user LDAP entry. The user must visit the sent URL to complete the validation and continue the registration process.

" }, { "type": "post", "url": "/authentication/totp-register", "title": "Request TOTP registration", "name": "RequestTOTPRegistration", "group": "Registration", "version": "1.0.0", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Registration", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } }, "success": { "fields": { "Success 204": [ { "group": "Success 204", "optional": false, "field": "status", "description": "

Identity validation has been initiated.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "optional": false, "field": "AccessDenied", "description": "

Access is denied.

" } ], "Error 400": [ { "group": "Error 400", "optional": false, "field": "InvalidIdentity", "description": "

User identity is invalid.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

This request issue an identity validation token for the user bound to the session. It sends a challenge to the email address set in the user LDAP entry. The user must visit the sent URL to complete the validation and continue the registration process.

" }, { "type": "post", "url": "/authentication/u2f-register", "title": "Request U2F registration", "name": "RequestU2FRegistration", "group": "Registration", "version": "1.0.0", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Registration", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } }, "success": { "fields": { "Success 204": [ { "group": "Success 204", "optional": false, "field": "status", "description": "

Identity validation has been initiated.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "optional": false, "field": "AccessDenied", "description": "

Access is denied.

" } ], "Error 400": [ { "group": "Error 400", "optional": false, "field": "InvalidIdentity", "description": "

User identity is invalid.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

This request issue an identity validation token for the user bound to the session. It sends a challenge to the email address set in the user LDAP entry. The user must visit the sent URL to complete the validation and continue the registration process.

" }, { "type": "get", "url": "/authentication/totp-register", "title": "Serve TOTP registration page", "name": "ServeTOTPRegistrationPage", "group": "Registration", "version": "1.0.0", "description": "

Serves the TOTP registration page that displays the secret. The secret is a QRCode and a base32 secret.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Registration", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } }, "parameter": { "fields": { "Parameter": [ { "group": "Parameter", "type": "String", "optional": false, "field": "identity_token", "description": "

The one-time identity validation token provided in the email.

" } ] } }, "success": { "fields": { "Success 200": [ { "group": "Success 200", "type": "String", "optional": false, "field": "content", "description": "

The content of the page.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "optional": false, "field": "AccessDenied", "description": "

Access is denied.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } } }, { "type": "post", "url": "/authentication/new-password", "title": "Set LDAP password", "name": "SetLDAPPassword", "group": "Registration", "version": "1.0.0", "parameter": { "fields": { "Parameter": [ { "group": "Parameter", "type": "String", "optional": false, "field": "password", "description": "

New password

" } ] } }, "description": "

Set a new password for the user.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Registration", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } }, { "type": "get", "url": "/authentication/2ndfactor/u2f/register_request", "title": "U2F Start device registration", "name": "StartU2FRegistration", "group": "Registration", "version": "1.0.0", "success": { "fields": { "Success 200": [ { "group": "Success 200", "optional": false, "field": "authentication_request", "description": "

The U2F registration request.

" } ] } }, "error": { "fields": { "Error 403": [ { "group": "Error 403", "type": "none", "optional": false, "field": "error", "description": "

Unexpected identity validation challenge.

" } ], "Error 500": [ { "group": "Error 500", "type": "String", "optional": false, "field": "error", "description": "

Internal error message.

" } ] } }, "description": "

Initiate a U2F device registration request.

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Registration", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } }, { "type": "get", "url": "/authentication/verify", "title": "Verify user authentication", "name": "VerifyAuthentication", "group": "Verification", "version": "1.0.0", "success": { "fields": { "Success 204": [ { "group": "Success 204", "optional": false, "field": "status", "description": "

The user is authenticated.

" } ] } }, "error": { "fields": { "Error 401": [ { "group": "Error 401", "optional": false, "field": "status", "description": "

The user is not authenticated.

" } ] } }, "description": "

Verify that the user is authenticated, i.e., the two factors have been validated

", "filename": "src/lib/setup_endpoints.js", "groupTitle": "Verification", "header": { "fields": { "Header": [ { "group": "Header", "type": "String", "optional": false, "field": "Cookie", "description": "

Cookie containing 'connect.sid', the user session token.

" } ] } } } ]