django-sqrl-2/sqrl/templates/admin/auth/user/sqrl_manage.html

89 lines
3.3 KiB
HTML
Raw Permalink Normal View History

2019-09-02 02:03:23 -05:00
{% extends "admin/base_site.html" %}
{% load i18n admin_static %}
{% load sqrl %}
{% block title %}Manage SQRL{% endblock %}
{% block content_title %}<h1>Manage SQRL</h1>{% endblock %}
{% block extrahead %}{{ block.super }}
<script src="{% static 'sqrl/sqrl.js' %}"></script>
{% endblock %}
{% block extrastyle %}
{{ block.super }}
<link rel="stylesheet" type="text/css" href="{% static 'admin/css/forms.css' %}"/>
<link rel="stylesheet" type="text/css" href="{% static 'admin/sqrl.css' %}"/>
{% endblock %}
{% block userlinks %}
{% url 'django-admindocs-docroot' as docsroot %}
{% if docsroot %}
<a href="{{ docsroot }}">{% trans 'Documentation' %}</a> /
{% endif %}
{% trans 'Manage SQRL' %} /
<a href="{% url 'admin:logout' %}">{% trans 'Log out' %}</a>
{% endblock %}
{% block breadcrumbs %}
<div class="breadcrumbs">
<a href="{% url 'admin:index' %}">{% trans 'Home' %}</a>
&rsaquo; {% trans 'Manage SQRL' %}
</div>
{% endblock %}
{% block content %}
<div id="content-main">
{% if not user.sqrl_identity %}
<p>
You dont have SQRL identity associated with your account yet.
Please use SQRL link/QR code below to associate SQRL identity with your account.
</p>
{% else %}
<p>
Congratulations! You already have SQRL identity associated with your account.
If you would like to either change or delete existing SQRL identity
associated with your account, you can do that by selecting appropriate
option in your SQRL client and then using the SQRL link/QR code below.
</p>
<p>
<strong>Note:</strong> For both changing or deleting your SQRL identity,
you will need to load your SQRL rescue code.
</p>
<p>
<strong>Caution:</strong> Normally it is not advised to change or delete
your SQRL identity. Usually these operations are only required when
SQRL identity is compromised.
</p>
{% endif %}
2019-09-04 21:08:57 -05:00
{% sqrl as sqrl_session %}
{% if sqrl_session.sqrl_url %}
2019-09-02 02:03:23 -05:00
<fieldset class="module aligned">
<div class="sqrl-wrap">
SQRL Login
2019-09-04 21:08:57 -05:00
<a href="{{ sqrl_session.sqrl_url }}">
<div id="sqrl-qr" data-sqrl="{{ sqrl_session.sqrl_url }}"></div>
2019-09-02 02:03:23 -05:00
</a>
<a href="https://www.grc.com/sqrl/sqrl.htm">What is SQRL?</a>
{# redirect to manage page after successful SQRL transaction #}
<input type="hidden" name="next" value="{% url 'admin-sqrl_manage' %}">
</div>
</fieldset>
2019-09-04 21:08:57 -05:00
<form method="get" action="{{ sqrl_session.sqrl_url }}" class="sqrl">
2019-09-02 02:03:23 -05:00
<div class="submit-row">
2019-09-04 21:08:57 -05:00
<input type="hidden" name="nut" value="{{ sqrl_session.nut.nonce }}">
2019-09-02 02:03:23 -05:00
<input type="submit" value="Manage SQRL" class="default" style="float: left;">
</div>
</form>
{% else %}
<p><strong>You are not connected on a secure connection. For your safety, SQRL login is disabled. It is advised that you do not log into this website at all until you are connected via a HTTPS connection.</strong></p>
{% endif %}
2019-09-02 02:03:23 -05:00
</div>
{% endblock %}