Sitelet https://github.com/authomatic/authomatic/issues/97
Skip to content

Hands-on Django example with login, logout, @login_required() etcetera #97

Description

@dirkmoors

Hi,

In order to be able to use this in my Django Project, I need to be able to use the default Django decorator '@login_required()', which will redirect a user to a 'LOGIN_URL', while providing GET parameter 'next=/page-we-came-from/' after a successfull login has been performed. One the login has been performed, and the redirection to the page we came from has succeeded, the system should see the user as authenticated so every subsequent request to views carying the '@login_required()' decorator, should just succeed without requesting a new login.
Afterwards the user should also have the option to perform an explicit LOG OUT, which invalidates the accesstoken en will make the user login again when he wants to access a view decorated with @login_required().

Is this possible? Will this ever be possible with this library? (And how?)

Thanks in advance

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions