28 lines
1.3 KiB
HTML
28 lines
1.3 KiB
HTML
{%- extends 'login/authforms.html' -%}
|
|
{% block pagetitle %}Login{% endblock %}
|
|
{% block pagetype %}login{% endblock %}
|
|
{% block template_config %}
|
|
{% set root_scope.js = false %}
|
|
{% set root_scope.include_user_css = false %}
|
|
{% set root_scope.include_seo = false %}
|
|
{% set root_scope.include_cf_2fa_verify = false %}
|
|
{% endblock %}
|
|
{% block content %}
|
|
<div id="login-form">
|
|
<h2>Two-step login</h2>
|
|
<p class="text-muted mb-md-5">To login, please enter the 6-digit verification code generated in your authenticator app.</p>
|
|
{% if failed %}{{macros.alert('Invalid verification code. Please try again.', true)}}{% endif %}
|
|
</div>
|
|
<form action="/login" method="post" class="mt-md-3" id="login">
|
|
<input hidden name="username" value="{{v.username}}">
|
|
<input hidden name="redirect" value="{{redirect}}">
|
|
<input hidden name="time" value="{{time}}">
|
|
<input hidden name="hash" value="{{hash}}">
|
|
<label for="2fa_token" class="mt-3">Your verification code</label>
|
|
<input autocomplete="off" class="form-control" id="2fa_token" name="2fa_token" type="number" pattern="[0-9]" inputmode="numeric" placeholder="6-digit code">
|
|
<small><a href="/lost_2fa">Lost your 2FA device?</a></small>
|
|
<button type="submit" class="btn btn-primary login w-100 mt-3" id="login_button">Sign in</button>
|
|
</form>
|
|
<script defer src="{{'js/login_2fa.js' | asset}}"></script>
|
|
{% endblock %}
|