canaille-globuzma/canaille/templates/oidc/admin/token_view.html

95 lines
3.9 KiB
HTML
Raw Normal View History

{% extends theme('base.html') %}
2021-12-05 17:52:34 +00:00
{% import 'fomanticui.html' as sui %}
2020-08-26 14:27:08 +00:00
2023-02-03 17:43:13 +00:00
{% block script %}
<script src="/static/js/copy.js"></script>
{% endblock %}
2020-08-26 14:27:08 +00:00
{% block content %}
2021-12-20 22:57:27 +00:00
<div class="loginform">
<h3 class="ui top attached header">
{% trans %}View a token{% endtrans %}
</h3>
2020-10-31 17:22:24 +00:00
2021-12-20 22:57:27 +00:00
<div class="ui attached clearing segment">
2022-02-03 08:51:04 +00:00
<table class="ui celled striped table">
<tr>
<td>{{ _("Issue date") }}</td>
<td>{{ token.issue_date }}</td>
</tr>
<tr>
<td>{{ _("Client") }}</td>
<td>
<a href="{{ url_for("oidc.clients.edit", client_id=token_client.client_id) }}">
2022-10-17 15:49:52 +00:00
{{ token_client.client_name }}
2022-02-03 08:51:04 +00:00
</a>
</td>
</tr>
<tr>
<td>{{ _("Subject") }}</td>
<td>
<a href="{{ url_for("account.profile_edition", username=token_user.uid[0]) }}">
2022-02-03 08:51:04 +00:00
{{ token_user.name }} - {{ token_user.uid[0] }}
</a>
</td>
</tr>
<tr>
<td>{{ _("Scope") }}</td>
<td>
<ul class="ui list">
{% for scope in token.scope %}
<li class="item">{{ scope }}</li>
{% endfor %}
</ul>
</td>
</tr>
<tr>
<td>{{ _("Audience") }}</td>
<td>
<ul class="ui list">
{% for client in token_audience %}
<li class="item">
<a href="{{ url_for("oidc.clients.edit", client_id=client.dn) }}">
2022-10-17 15:49:52 +00:00
{{ client.client_name }}
2022-02-03 08:51:04 +00:00
</a>
</li>
{% endfor %}
</ul>
</td>
</tr>
<tr>
<td>{{ _("Revokation date") }}</td>
<td>{% if token.revokation_date %}{{ token.revokation_date }}{% endif %}</td>
</tr>
<tr>
<td>{{ _("Lifetime") }}</td>
<td>{{ token.lifetime }}</td>
</tr>
<tr>
<td>{{ _("Token type") }}</td>
<td>{{ token.type }}</td>
</tr>
<tr>
<td>{{ _("Access token") }}</td>
2023-02-03 17:43:13 +00:00
<td class="ui fluid action input">
<input type="text" value="{{ token.access_token }}" readonly class="copy-text" id="access-token" data-copy="access-token">
<button class="ui primary right labeled icon button copy-button" data-copy="access-token">
<i class="copy icon"></i>
{% trans %}Copy{% endtrans %}
</td>
</tr>
2022-02-03 08:51:04 +00:00
2023-02-03 17:43:13 +00:00
<tr>
<td>{{ _("Refresh token") }}</td>
<td class="ui fluid action input">
<input type="text" value="{{ token.refresh_token }}" readonly class="copy-text" id="refresh-token" data-copy="refresh-token">
<button class="ui primary right labeled icon button copy-button" data-copy="refresh-token">
<i class="copy icon"></i>
{% trans %}Copy{% endtrans %}
</td>
</tr>
</table>
</div>
</div>
2020-08-26 14:27:08 +00:00
{% endblock %}