Two-Factor Authentication#

Two-Factor authentication (2FA) is configured using the django-allauth-2fa library which adapts django-otp to make it work with django-allauth.

When using Two-Factor Auth with Pegasus, a new section is added to the user profile for enabling & configuring the OTP (one-time password) devices for the user.

If a user has a Two-Factor device configured then they will be prompted for a token after logging in.

If you wish to force users to enable Two-Factor Auth on their account you can follow the example given in the django-allauth-2fa docs.