{% load i18n %} {% load static %} {% if attention.undecided_into_control or attention.outside_into_control or attention.expired or attention.review_due or attention.stale or attention.no_conduit or attention.outbound_only %}
{% trans "Needs attention" %}
{% endif %} {% if diagram.svg %}

{% trans "Diagram" %} {% blocktrans count n=diagram.zones %}{{ n }} zone{% plural %}{{ n }} zones{% endblocktrans %}, {% blocktrans count n=diagram.arrows %}{{ n }} arrow{% plural %}{{ n }} arrows{% endblocktrans %}{% if zones_not_drawn %}; {% blocktrans count n=zones_not_drawn %}{{ n }} zone without flows is not drawn{% plural %}{{ n }} zones without flows are not drawn{% endblocktrans %}{% endif %}

{{ diagram.svg }}
{{ diagram.data|json_script:"ot-map-data" }}
{% trans "One arrow per zone pair, from the side that acts to the side acted upon; a number is how many flows it carries when more than one, per colour. Red: not allowed or expired, amber: unknown, green: allowed. Heavy: at least one flow writes, controls or programs. Dashed: remote access. Dotted: the destination opens the connection itself (reverse connect, or both ends meet at a broker)." %}
{% elif not site %}
{% trans "Choose a site to see its diagram: the zones of all sites in one picture say nothing." %}
{% endif %}

{% trans "Flows into zones at Purdue level" %} ≤ {{ max_level }} {{ flows|length }} {% if filtered %}{% blocktrans with total=flows_total %}of {{ total }}, filtered{% endblocktrans %}{% endif %}

{% if flows %}
{% if show_site %}{% endif %} {% for f in flows %} {% if show_site %}{% endif %} {% endfor %}
#{% trans "Site" %}{% trans "From zone" %} {% trans "To zone" %} {% trans "Protocol / ports" %} {% trans "Access" %} {% trans "Through" %} {% trans "Remote access" %} {% trans "Allowed" %} {% trans "Last seen" %} {% trans "Evidence" %}
{{ forloop.counter }}{{ f.destination_zone.site|linkify|placeholder }}{{ f.source_zone|linkify }}{% if f.source_zone.purdue_level %} {% badge f.source_zone.purdue_level bg_color=f.source_zone.get_purdue_level_color %}{% endif %} {{ f.destination_zone|linkify }}{% if f.destination_zone.purdue_level %} {% badge f.destination_zone.purdue_level bg_color=f.destination_zone.get_purdue_level_color %}{% endif %} {{ f.get_protocol_display|placeholder }}{% if f.port_mappings %} {{ f.ports_short }}{% endif %} {% if f.connection != 'client-server' %}
{% badge f.get_connection_display bg_color=f.get_connection_color %} {% if f.broker_zone %}{% trans "in" %} {{ f.broker_zone|linkify }}{% endif %}
{% if f.topics %}
{{ f.topics|join:", " }}
{% endif %} {% endif %}
{% for value, label, color in f.get_access_display %}{% badge label bg_color=color %} {% empty %}{{ ''|placeholder }}{% endfor %} {% for hop in f.hops.all %}{{ hop.hop|linkify }}{% if not forloop.last %} → {% endif %}{% empty %}{{ ''|placeholder }}{% endfor %} {% checkmark f.remote_access %} {% badge f.get_allowed_display bg_color=f.get_allowed_color %} {% if f.is_expired %}{% trans "expired" %}{% endif %} {% if f.is_review_due %}{% trans "review due" %}{% endif %} {{ f.last_seen|date:"Y-m-d"|placeholder }} {% with lines=f.evidence_lines %} {% if lines.1 %}
{{ lines.0 }}
{{ lines.1|linebreaksbr }}
{% else %} {{ lines.0|placeholder }} {% endif %} {% endwith %}
{% else %}
{% if filtered %}{% trans "No flows match these filters." %}{% else %}{% trans "No flows into these zones." %}{% endif %}
{% endif %}