linotp.controllers package

This is the controller module. The controllers provide the Web API to communicate with LinOTP. You can use the following controllers:

linotp.controllers.admin

API to manage the tokens

linotp.controllers.audit

to search the audit trail

linotp.controllers.auth

to do authentication tests

linotp.controllers.error

to display errors

linotp.controllers.gettoken

to retrieve OTP values

linotp.controllers.maintenance

for internal maintenance purposes

linotp.controllers.manage

the Web UI

linotp.controllers.monitoring

for system monitoring

linotp.controllers.openid

the openid interface

linotp.controllers.ocra

Ocra token API

linotp.controllers.selfservice

the selfservice UI

linotp.controllers.system

to configure the system

linotp.controllers.tools

to access various tools

linotp.controllers.u2f

U2F token API

linotp.controllers.userservice

user API, used by selfservice frontend

linotp.controllers.validate

for authenticating / OTP checking

Additionally there is a new set of controllers accessible under /api/v2, providing the same functionality as some of the previous controllers, but with a more RESTful interface:

linotp.controllers.tokens

API to manage tokens

linotp.controllers.realms

API to manage realms

linotp.controllers.resolvers

API to manage resolvers and look up users

class linotp.controllers.BaseController(name, install_name='', **kwargs)

Bases: Blueprint

BaseController class - will be called with every request

before_handler()

Call derived controller’s legacy __before__ method if it exists

This method is called before each request is processed.

default_url_prefix = ''

Suggested URL to access this controller.

The URL at which this controller will be available depends on a number of factors. These are, in order of priority: 1. Any explicit path in the

settings ENABLE_CONTROLLER or DISABLE_CONTROLLER = ControllerName:PATH

  1. The controller’s base_url_prefix setting

  2. The name of the controller

jwt_check()

Check whether the current request needs to be authenticated using JWT, and if so, whether it contains a valid JWT access token. The login name from the access token is then stored in g.authUser for the benefit of lib.user.getUserFromRequest().

jwt_exempt = False
parse_requesting_user()

load the requesting user

The result is placed into request_context[‘RequestUser’]

property request_params

Submodules