Initial mfa support (for internal users) #93591

Merged
Oleg-Komarov merged 46 commits from mfa into main 2024-08-29 11:44:06 +02:00
2 changed files with 8 additions and 5 deletions
Showing only changes of commit f5c1cdc15a - Show all commits

View File

@ -1,5 +1,5 @@
{% extends 'layout.html' %}
{% load pipeline static %}
{% load humanize pipeline static %}
{% block page_title %}
Multi-factor Authentication Setup
{% endblock %}
@ -48,7 +48,10 @@ Multi-factor Authentication Setup
{% endif %}
<ul>
{% for d in devices_per_category.totp %}
<li>{{ d.name }} <a class="btn btn-danger" href="{% url 'bid_main:mfa_delete_device' d.persistent_id %}"><i class="i-trash"></i></a></li>
<li>
{{ d.name }}
{% if d.last_used_at %}(Last used <abbr title="{{ d.last_used_at }}">{{ d.last_used_at|naturaltime }}</abbr>){% endif %}
<a class="btn btn-danger" href="{% url 'bid_main:mfa_delete_device' d.persistent_id %}"><i class="i-trash"></i></a></li>
{% endfor %}
</ul>
<a href="{% url 'bid_main:mfa_totp' %}" class="btn">Configure a new TOTP device</a>

View File

@ -72,10 +72,10 @@ INSTALLED_APPS = [
"django.contrib.staticfiles",
"django.contrib.sites",
"django.contrib.flatpages",
"django_otp",
"django_otp.plugins.otp_totp",
"django_otp.plugins.otp_static",
"django_agent_trust",
"django_otp",
"django_otp.plugins.otp_static",
"django_otp.plugins.otp_totp",
"oauth2_provider",
"pipeline",
"sorl.thumbnail",