lino.core.auth.utils

Utilities for authentication. Adapted from django.contrib.auth.

(This module's source code is available here.)

Classes

AnonymousUser(*args, **kwargs)

A singleton class whose instance will be assigned to the user attribute of anonymous incoming requests, similar to Django's approach.

class lino.core.auth.utils.AnonymousUser(*args, **kwargs)

Bases: lino.utils.SimpleSingleton

A singleton class whose instance will be assigned to the user attribute of anonymous incoming requests, similar to Django's approach.

See also lino.core.site.Site.anonymous_user_type.

is_authenticated = False

This is always False. See also lino.modlib.users.User.is_authenticated.

get_preferences()

Return the preferences of this user. The returned object is a lino.core.userprefs.UserPrefs object.