{% extends base_template|default:"bastion/base.html" %} {% load i18n %} {% comment %} The opposite policy to login_failed.html, and deliberately so. Identity is already proven here, so there is no account to enumerate and no reason to be vague. Being vague at this point is the single most common usability failure in enterprise SSO: the person is told "access denied" and has no idea which account they used, which group they are missing, or who to ask. All three are on this page. Deployments that consider group names sensitive can substitute a generic phrase, but the specific version is the default, because the generic one is unusable. Sign-out is a POST. Django's LogoutView is POST-only, so an to it is a dead link. base_template is resolved per request by bastion.pages: admin/base_site.html where the admin is installed and routed, bastion/base.html otherwise. The admin-only blocks below are no-ops under the fallback base, because Django ignores a child block with no matching parent block. {% endcomment %} {% block title %}{% translate "Access denied" %}{% if site_title %} | {{ site_title }}{% endif %}{% endblock %} {% block content_title %}

{% translate "You are signed in, but you do not have access" %}

{% endblock %} {% block breadcrumbs %}{% endblock %} {% block nav-breadcrumbs %}{% endblock %} {% block usertools %}{% endblock %} {% block nav-global %}{% endblock %} {% block nav-sidebar %}{% endblock %} {% block content %}

{% blocktranslate trimmed %} Your sign-in worked. This account does not have permission to use this site. {% endblocktranslate %}

{% translate "You signed in as" %}
{{ identity }}
{% if missing_mfa %}
{% translate "What is missing" %}
{% translate "A second factor. This sign-in used one." %}
{% elif required_groups %}
{% translate "Access requires membership of" %}
{% for group in required_groups %} {{ group }}{% if not forloop.last %}, {% endif %} {% endfor %}
{% endif %}
{% translate "Reference" %}
{{ reference }}

{% translate "What to do next" %}

{% if missing_mfa %} {# The group is not the problem here, and saying it is sends the person to a service desk that will add them to one and change nothing. #} {% blocktranslate trimmed %} Sign out and sign in again using your second factor. If you have not set one up, your IT service desk can enrol you. Include the reference so they can find this sign-in. {% endblocktranslate %} {% elif required_groups %} {% blocktranslate trimmed %} Ask your IT service desk to add this account to the group listed above. Include the reference so they can find this sign-in. {% endblocktranslate %} {% else %} {% blocktranslate trimmed %} Ask your IT service desk to grant this account access. Include the reference so they can find this sign-in. {% endblocktranslate %} {% endif %}

{% if not missing_mfa %}

{% blocktranslate trimmed %} If you have a different work account that should have access, sign out and try that one. {% endblocktranslate %}

{% endif %} {% if logout_url %}
{% csrf_token %}
{% endif %} {% endblock %}