first commit
This commit is contained in:
14
templates/mfa/webauthn/snippets/login_script.html
Executable file
14
templates/mfa/webauthn/snippets/login_script.html
Executable file
@@ -0,0 +1,14 @@
|
||||
{% include "mfa/webauthn/snippets/scripts.html" %}
|
||||
<form id="mfa_login" action="{% url 'mfa_login_webauthn' %}" method="post">
|
||||
{% csrf_token %}
|
||||
{{ redirect_field }}
|
||||
<input type="hidden" name="credential" id="mfa_credential">
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
allauth.webauthn.forms.loginForm({
|
||||
ids: {
|
||||
login: "passkey_login",
|
||||
credential: "mfa_credential",
|
||||
}
|
||||
})
|
||||
</script>
|
||||
4
templates/mfa/webauthn/snippets/scripts.html
Executable file
4
templates/mfa/webauthn/snippets/scripts.html
Executable file
@@ -0,0 +1,4 @@
|
||||
{% load i18n static %}
|
||||
<noscript>{% translate "This functionality requires JavaScript." %}"</noscript>
|
||||
<script type="text/javascript" src="{% static 'mfa/js/webauthn-json.js' %}"></script>
|
||||
<script type="text/javascript" src="{% static 'mfa/js/webauthn.js' %}"></script>
|
||||
Reference in New Issue
Block a user