{% extends '@WebProfiler/Profiler/layout.html.twig' %} {% block page_title 'Security' %} {% block toolbar %} {% if collector.tokenClass %} {% set is_authenticated = collector.enabled and collector.authenticated %} {% set color_code = is_authenticated ? '' : 'yellow' %} {% else %} {% set color_code = collector.enabled ? 'red' : '' %} {% endif %} {% set icon %} {{ include('@Security/Collector/icon.svg') }} {{ collector.user|default('n/a') }} {% endset %} {% set text %} {% if collector.tokenClass %}
Logged in as {{ collector.user }}
Authenticated {{ is_authenticated ? 'Yes' : 'No' }}
{% if collector.tokenClass != null %}
Token class {{ collector.tokenClass|abbr_class }}
{% endif %} {% if collector.logoutUrl %}
Actions Logout
{% endif %} {% elseif collector.enabled %}
You are not authenticated.
{% else %}
The security is disabled.
{% endif %} {% endset %} {{ include('@WebProfiler/Profiler/toolbar_item.html.twig', { link: profiler_url, status: color_code }) }} {% endblock %} {% block menu %} {{ include('@Security/Collector/icon.svg') }} Security {% endblock %} {% block panel %}

Security Token

{% if collector.tokenClass %}
{{ collector.user == 'anon.' ? 'Anonymous' : collector.user }} Username
{{ include('@WebProfiler/Icon/' ~ (collector.authenticated ? 'yes' : 'no') ~ '.svg') }} Authenticated
{% if collector.supportsRoleHierarchy %} {% endif %} {% if collector.tokenClass %} {% endif %}
Property Value
Roles {{ collector.roles is empty ? 'none' : collector.roles|yaml_encode }} {% if not collector.authenticated and collector.roles is empty %}

User is not authenticated probably because they have no roles.

{% endif %}
Inherited Roles {{ collector.inheritedRoles is empty ? 'none' : collector.inheritedRoles|yaml_encode }}
Token class {{ collector.tokenClass }}
{% elseif collector.enabled %}

There is no security token.

{% else %}

The security component is disabled.

{% endif %} {% endblock %}