{{ notification.title }}

--------------------------------------------------------------------------------
{% if notification.group == "NEW_VULNERABILITY" %}
Vulnerability ID:  {{ subject.vulnerability.vulnId }}
Vulnerability URL: {{ baseUrl }}/vulnerability/?source={{ subject.vulnerability.source }}&vulnId={{ subject.vulnerability.vulnId }}
Severity:          {{ subject.vulnerability.severity }}
Source:            {{ subject.vulnerability.source }}
Component:         {{ subject.component.toString }}
Component URL:     {{ baseUrl }}/component/?uuid={{ subject.component.uuid }}
Project:           {{ subject.component.project.name }}
Version:           {{ subject.component.project.version }}
Description:       {{ subject.component.project.description }}
Project URL:       {{ baseUrl }}/projects/{{ subject.component.project.uuid }}
{% if  notification.subject.affectedProjects|length > 1%}
--------------------------------------------------------------------------------

Other affected projects:
{% for affectedProject in notification.subject.affectedProjects %}{% if not (affectedProject.uuid == subject.component.project.uuid) %}
Project:           [{{ affectedProject.name }} : {{ affectedProject.version }}]
Project URL:       {{ baseUrl }}/projects/{{ affectedProject.uuid }}
{% endif %}{% endfor %}{% endif %}{% elseif notification.group == "NEW_VULNERABLE_DEPENDENCY" %}
Project:           {{ subject.component.project.toString }}
Project URL:       {{ baseUrl }}/projects/?uuid={{ subject.component.project.uuid }}
Component:         {{ subject.component.toString }}
Component URL:     {{ baseUrl }}/component/?uuid={{ subject.component.uuid }}

Vulnerabilities
{% for vulnerability in subject.vulnerabilities %}
Vulnerability ID:  {{ vulnerability.vulnId }}
Vulnerability URL: {{ baseUrl }}/vulnerability/?source={{ vulnerability.source }}&vulnId={{ vulnerability.vulnId }}
Severity:          {{ vulnerability.severity }}
Source:            {{ vulnerability.source }}
Description:
{{ vulnerability.description }}

{% endfor %}
{% elseif notification.group == "PROJECT_AUDIT_CHANGE" %}
Analysis Type:  Project Analysis
{% if subject.analysis is null %}{% for comment in subject.violationAnalysis.analysisComments %} {% if loop.last and comment.commenter is not null  %}
Commenter:         {{ comment.commenter}}{% endif %}{% endfor %}
Violation Analysis State:    {{ subject.violationAnalysis.analysisState }}
Suppressed:        {{ subject.violationAnalysis.suppressed }}
Policy:            {{ subject.policyViolation.policyCondition.Policy.name }}
Policy Violation State: {{ subject.policyViolation.policyCondition.Policy.violationState }}
Policy Condition:  subject == {{ subject.policyViolation.policyCondition.subject }} && value {{ subject.policyViolation.policyCondition.operator }} {{ subject.policyViolation.policyCondition.value }}
{% else %}{% for comment in subject.analysis.analysisComments %} {% if loop.last and comment.commenter is not null %}
Commenter:         {{ comment.commenter}}{% endif %}{% endfor %}
Analysis State:    {{ subject.analysis.analysisState }}
Suppressed:        {{ subject.analysis.suppressed }}
Vulnerability ID:  {{ subject.vulnerability.vulnId }}
Vulnerability URL: {{ baseUrl }}/vulnerability/?source={{ subject.vulnerability.source }}&vulnId={{ subject.vulnerability.vulnId }}
Severity:          {{ subject.vulnerability.severity }}
Source:            {{ subject.vulnerability.source }}
{% endif %}
Component:         {{ subject.component.toString }}
Component URL:     {{ baseUrl }}/component/?uuid={{ subject.component.uuid }}
Project:           {{ subject.component.project.toString }}
Description:       {{ subject.component.project.description }}
Project URL:       {{ baseUrl }}/projects/{{ subject.component.project.uuid }}
{% if  notification.subject.affectedProjects|length > 1%}
--------------------------------------------------------------------------------

Other affected projects:
{% for affectedProject in notification.subject.affectedProjects %}{% if not (affectedProject.uuid == subject.component.project.uuid) %}
Project:           [{{ affectedProject.name }} : {{ affectedProject.version }}]
Project URL:       {{ baseUrl }}/projects/{{ affectedProject.uuid }}
{% endif %}{% endfor %}{% endif %}{% elseif notification.group == "BOM_CONSUMED" %}
Project:           {{ subject.project.name }}
Version:           {{ subject.project.version }}
Description:       {{ subject.project.description }}
Project URL:       {{ baseUrl }}/projects/{{ subject.project.uuid }}
{% elseif notification.group == "BOM_PROCESSED" %}
Project:           {{ subject.project.name }}
Version:           {{ subject.project.version }}
Description:       {{ subject.project.description }}
Project URL:       {{ baseUrl }}/projects/{{ subject.project.uuid }}
{% elseif notification.group == "BOM_PROCESSING_FAILED" %}
Project:           {{ subject.project.name }}
Version:           {{ subject.project.version }}
Description:       {{ subject.project.description }}
Project URL:       {{ baseUrl }}/projects/{{ subject.project.uuid }}

--------------------------------------------------------------------------------

Cause:
{{ subject.cause }}
{% elseif notification.group == "VEX_CONSUMED" %}
Project:           {{ subject.project.name }}
Version:           {{ subject.project.version }}
Description:       {{ subject.project.description }}
Project URL:       {{ baseUrl }}/projects/{{ subject.project.uuid }}
{% elseif notification.group == "VEX_PROCESSED" %}
Project:           {{ subject.project.name }}
Version:           {{ subject.project.version }}
Description:       {{ subject.project.description }}
Project URL:       {{ baseUrl }}/projects/{{ subject.project.uuid }}
{% elseif notification.group == "POLICY_VIOLATION" %}
Project:           {{ subject.project.name }}
Version:           {{ subject.project.version }}
Description:       {{ subject.project.description }}
Project URL:       {{ baseUrl }}/projects/{{ subject.project.uuid }}
{% else %}
Level:     {{ notification.level }}
Scope:     {{ notification.scope }}
Group:     {{ notification.group }}
{% endif %}
--------------------------------------------------------------------------------

{{ notification.content }}

--------------------------------------------------------------------------------

{{ timestamp }}
