{% extends "base.html" %} {% block content %}

Test the authentication and authorization, with OpenID Connect and OAuth2 with different providers.

{% if not user %}

Log in with:

{% for provider in providers.values() %} {% else %}
There is no authentication provider defined. Hint: check the settings.yaml file.
{% endfor %}
{{ provider.hint }}
{% else %}

Hey, {{ user.name }}

{% if user.picture %} {% endif %}
{{ user.email }}
Provider: {{ auth_provider.name }}
{% if user.roles %}
Roles: {% for role in user.roles %} {{ role.name }} {% endfor %}
{% endif %} {% if access_token_scope %}
Scopes: {% for scope in access_token_scope.split(' ') %} {{ scope }} {% endfor %}
{% endif %} {% if auth_provider.account_url_template %} {% endif %}
{% endif %}
{% if resource_providers %}

{{ auth_provider.name }} provides these resources:

{% endif %}
{% if show_token and id_token_parsed %}

id token

{% for key, value in id_token_parsed.items() %}
{{ key }}
{{ value }}
{% endfor %}

access token

{% for key, value in access_token_parsed.items() %}
{{ key }}
{{ value }}
{% endfor %}

refresh token

{% for key, value in refresh_token_parsed.items() %}
{{ key }}
{{ value }}
{% endfor %}
{% endif %} {% endblock %}