{# R54.4 (Hani #1 2026-11-10): Attack type and Risk from NEXXVU AI, the Analyse button and the explanation popup - the same pieces on Security events › Suspicious addresses and a device's Suspicious visitors. Proposed only: nothing is blocked from an analysis. #} {% macro headers() %}Attack type {{ fresh_tag("security:analyse") }} {{ fresh_tag("security:analyse-refresh") }}Risk{% endmacro %} {% macro refresh(address, a=None) -%} {# R84.4a (Hani #1 2026-11-17): "add analyse button under attack-type column or a refresh pictogram" - one click, no menu #} {%- if a is none or not a.pending %}{% if ai_can(session) and ai_public(address) %}{% set r = ai_ready() %}{% if r.ok %}
{% else %}{% endif %}{% endif %}{% endif %} {%- endmacro %} {% macro queued(a) -%}{{ 'Queued' ~ ((' (' ~ a.position ~ ({1: 'st', 2: 'nd', 3: 'rd'}.get(a.position if a.position < 20 else a.position % 10, 'th')) ~ ')') if a.position else '') if a.state == 'queued' else 'Analysing…' }}{%- endmacro %} {% macro cells(a, address, key) -%} {% if not a %}Not analysed {%- elif a.pending %} {{ queued(a) }} {%- elif a.state == 'failed' %}Not analysed {%- else %}{% if not a.agreed %} models disagree{% endif %}{% endif %} {{ refresh(address, a) }} {% if a and not a.pending and a.state != 'failed' %}{{ a.risk_label }}{% else %}—{% endif %} {%- endmacro %} {% macro button(address, ready, origin) -%} {% if ready.ok %}
{% if origin %}{% endif %}
{%- else %}{% endif %} {%- endmacro %} {% macro bulk_button(ready) -%} {%- endmacro %} {% macro answers(a) -%} {# alpha.348: what each model said, when they did not agree #} {% if not a.agreed and a.answers %}{% for model, v in a.answers.items() %}
{{ model }} said
{% if v.attack %}Attack: {{ v.attack_type or 'type not named' }} · risk {{ v.risk }}{% else %}No attack{% endif %} · {{ ((v.confidence or 0) * 100)|round|int }} % sure{% if v.reason %}
{{ v.reason }}{% endif %}
{% endfor %} {% elif a.undecided %}
Each model
Not kept for this analysis (made before alpha.348). Analyse again to see what each one says.
{% endif %} {%- endmacro %} {% macro dialog(a, address, key) -%} {% if a and not a.pending %}

Analysis of {{ address }}

{% if a.state == 'failed' %}

{{ a.detail or 'The analysis did not finish.' }}

{% else %}
Attack type
{{ a.type_label }}
Risk
{{ a.risk_label }} · confidence {{ (a.confidence * 100)|round|int }} %
{% if a.attack_technique %}
MITRE ATT&CK
{{ a.attack_technique }}
{% endif %} {% if a.capec %}
CAPEC
{{ a.capec }}
{% endif %}
Why
{{ a.reason or '—' }}
Models
{{ a.models|join(' and ') or '—' }} · {{ 'both agreed' if a.agreed else 'they did not agree: review it yourself' }}
{{ answers(a) }}
Lines sent
{{ a.lines }} · {{ a.seconds|round(1) }} s · {{ (a.analysed_at or '')[:16]|replace('T', ' ') }} UTC, asked by {{ a.requested_by }}
{% endif %}

Proposed only: NEXXVU never blocks, trusts or changes anything because of an analysis. The answer comes from this Portal's own AI Gateway and local models; the lines were this address's own requests and log lines.

{% endif %} {%- endmacro %} {% macro inline(a, address, button=True) -%} {# R54.5: the analysis beside an address on every other security table (no extra column: rows built by scripts keep their columns); the attack type opens the full explanation on the address page. #} {% if a %}
{% if a.pending %} {{ queued(a) }} {%- elif a.state == 'failed' %}Not analysed {%- else %}{{ a.type_label }} {{ a.risk_label }}{% if not a.agreed %} models disagree{% endif %}{% endif %}{% if button %} {{ refresh(address, a) }}{% endif %}{% elif button and ai_public(address) and ai_can(session) %}
{{ refresh(address) }}{% endif %} {%- endmacro %} {% macro watcher(analyses) -%} {% if analyses and analyses.values()|selectattr('pending')|list %}

The AI Gateway is analysing {{ analyses.values()|selectattr('pending')|list|length }} address{{ '' if analyses.values()|selectattr('pending')|list|length == 1 else 'es' }}, one after another; this list updates by itself.

{% endif %} {%- endmacro %} {# R84.4c (Hani #1 2026-11-17): which rule already drops the attack, and where - the address's own lines replayed against every firewall rule in the background (rule_coverage); no AI is needed for this step. #} {% macro rule_header() %}Rule {{ fresh_tag("security:rule-coverage") }}{% endmacro %} {% macro rule_cell(c, address, d=None) -%} {% if not ai_public(address) %}— {%- elif not c or c.state == 'checking' %}Checking… {%- elif c.state == 'covered' %}{% set r = c.rules[0] %}Covered
{{ r.name }}{% if c.rules|length > 1 %} +{{ c.rules|length - 1 }}{% endif %}
{{ r.where }} · {{ r.mode }} {%- elif c.state == 'not_covered' %}Not covered{% if c.hints and not (d and d.outcome and d.state != 'proposed') %} {% endif %}{% if d and d.outcome and d.state != 'proposed' %}
{{ 'why no draft' if 'no draft' in d.outcome or 'too wide' in d.outcome else 'AI defence' }}AI defence: {{ d.outcome }}{% if 'too wide' in d.outcome %}
The text these lines share is also in normal traffic, so a rule on that text alone would block too much. NEXXVU then tries a repeat-visitor rule (the same address many times within minutes); when your own or normal addresses reach that count too, nothing is drafted.{% endif %}{% if d.outcome.startswith('no draft') or 'too wide' in d.outcome %}
NEXXVU looks again in 7 days; you can still block the address yourself.{% endif %}{% if c.hints %}
{{ c.hints|join(' ') }}{% endif %}
{% elif not (d and d.state == 'proposed') %}
why no draftNo draft yet. AI defence drafts a rule only for an address the local AI judged an attack (medium or high risk), within about 15 minutes of that verdict. Without one (not analysed, undecided or low risk) nothing is drafted: press ↻ beside the attack type to analyse it.{% endif %}{% if d and d.state == 'proposed' %}
draft waiting{% endif %} {%- else %}No lines{% endif %} {%- endmacro %}