Skip to content

Commit d1ef112

Browse files
Rishi-garg03Rishi-source
authored andcommitted
Improved UI for severity details
Signed-off-by: Rishi Garg <rishigarg2503@gmail.com>
1 parent 432a7d4 commit d1ef112

File tree

1 file changed

+103
-81
lines changed

1 file changed

+103
-81
lines changed

vulnerabilities/templates/vulnerability_details.html

Lines changed: 103 additions & 81 deletions
Original file line numberDiff line numberDiff line change
@@ -409,97 +409,119 @@
409409
<div class="tab-div content" data-content="severities-vectors">
410410
{% for severity_vector in severity_vectors %}
411411
{% if severity_vector.vector.version == '2.0' %}
412-
Vector: {{ severity_vector.vector.vectorString }} Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
413-
<table class="table is-bordered is-striped is-narrow is-hoverable is-fullwidth gray-header-border">
414-
<tr>
415-
<th>Exploitability (E)</th>
416-
<th>Access Vector (AV)</th>
417-
<th>Access Complexity (AC)</th>
418-
<th>Authentication (Au)</th>
419-
<th>Confidentiality Impact (C)</th>
420-
<th>Integrity Impact (I)</th>
421-
<th>Availability Impact (A)</th>
422-
</tr>
423-
<tr>
424-
<td>{{ severity_vector.vector.exploitability|cvss_printer:"high,functional,unproven,proof_of_concept,not_defined" }}</td>
425-
<td>{{ severity_vector.vector.accessVector|cvss_printer:"local,adjacent_network,network" }}</td>
426-
<td>{{ severity_vector.vector.accessComplexity|cvss_printer:"high,medium,low" }}</td>
427-
<td>{{ severity_vector.vector.authentication|cvss_printer:"multiple,single,none" }}</td>
428-
<td>{{ severity_vector.vector.confidentialityImpact|cvss_printer:"none,partial,complete" }}</td>
429-
<td>{{ severity_vector.vector.integrityImpact|cvss_printer:"none,partial,complete" }}</td>
430-
<td>{{ severity_vector.vector.availabilityImpact|cvss_printer:"none,partial,complete" }}</td>
431-
</tr>
432-
</table>
412+
<div class="mb-4">
413+
Score: <strong>{{ severity_vector.vector.baseScore }}</strong> -
414+
Vector: <strong>{{ severity_vector.vector.vectorString }}</strong>
415+
<a href="https://www.first.org/cvss/v2/guide" target="_blank" class="has-tooltip-multiline has-tooltip-black" data-tooltip="Learn more about CVSS v2.0">
416+
<i class="fa fa-info-circle"></i>
417+
</a>
418+
- Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
419+
<table class="table is-bordered is-striped is-narrow is-hoverable is-fullwidth gray-header-border mt-2">
420+
<tr>
421+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the current state of exploit techniques or code availability.">Exploitability (E)</th>
422+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric reflects how the vulnerability is exploited.">Access Vector (AV)</th>
423+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the complexity of the attack required.">Access Complexity (AC)</th>
424+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the number of times an attacker must authenticate.">Authentication (Au)</th>
425+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the impact on confidentiality.">Confidentiality Impact (C)</th>
426+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the impact to integrity.">Integrity Impact (I)</th>
427+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the impact to availability.">Availability Impact (A)</th>
428+
</tr>
429+
<tr>
430+
<td>{{ severity_vector.vector.exploitability|cvss_printer:"high,functional,unproven,proof_of_concept,not_defined" }}</td>
431+
<td>{{ severity_vector.vector.accessVector|cvss_printer:"local,adjacent_network,network" }}</td>
432+
<td>{{ severity_vector.vector.accessComplexity|cvss_printer:"high,medium,low" }}</td>
433+
<td>{{ severity_vector.vector.authentication|cvss_printer:"multiple,single,none" }}</td>
434+
<td>{{ severity_vector.vector.confidentialityImpact|cvss_printer:"none,partial,complete" }}</td>
435+
<td>{{ severity_vector.vector.integrityImpact|cvss_printer:"none,partial,complete" }}</td>
436+
<td>{{ severity_vector.vector.availabilityImpact|cvss_printer:"none,partial,complete" }}</td>
437+
</tr>
438+
</table>
439+
</div>
440+
433441
{% elif severity_vector.vector.version == '3.1' or severity_vector.vector.version == '3.0'%}
434-
Vector: {{ severity_vector.vector.vectorString }} Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
435-
<table class="table is-bordered is-striped is-narrow is-hoverable is-fullwidth gray-header-border">
436-
<tr>
437-
<th>Attack Vector (AV)</th>
438-
<th>Attack Complexity (AC)</th>
439-
<th>Privileges Required (PR)</th>
440-
<th>User Interaction (UI)</th>
441-
<th>Scope (S)</th>
442-
<th>Confidentiality Impact (C)</th>
443-
<th>Integrity Impact (I)</th>
444-
<th>Availability Impact (A)</th>
445-
</tr>
446-
<tr>
447-
<td>{{ severity_vector.vector.attackVector|cvss_printer:"network,adjacent_network,local,physical"}}</td>
448-
<td>{{ severity_vector.vector.attackComplexity|cvss_printer:"low,high" }}</td>
449-
<td>{{ severity_vector.vector.privilegesRequired|cvss_printer:"none,low,high" }}</td>
450-
<td>{{ severity_vector.vector.userInteraction|cvss_printer:"none,required"}}</td>
451-
<td>{{ severity_vector.vector.scope|cvss_printer:"unchanged,changed" }}</td>
452-
<td>{{ severity_vector.vector.confidentialityImpact|cvss_printer:"high,low,none" }}</td>
453-
<td>{{ severity_vector.vector.integrityImpact|cvss_printer:"high,low,none" }}</td>
454-
<td>{{ severity_vector.vector.availabilityImpact|cvss_printer:"high,low,none" }}</td>
455-
</tr>
442+
<div class="mb-4">
443+
Score: <strong>{{ severity_vector.vector.baseScore }}</strong> -
444+
Vector: <strong>{{ severity_vector.vector.vectorString }}</strong>
445+
<a href="https://www.first.org/cvss/v3.1/specification-document" target="_blank" class="has-tooltip-multiline has-tooltip-black" data-tooltip="Learn more about CVSS v3.1">
446+
<i class="fa fa-info-circle"></i>
447+
</a>
448+
- Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
449+
<table class="table is-bordered is-striped is-narrow is-hoverable is-fullwidth gray-header-border mt-2">
450+
<tr>
451+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric reflects the context by which vulnerability exploitation is possible.">Attack Vector (AV)</th>
452+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric describes the conditions beyond the attacker's control that must exist.">Attack Complexity (AC)</th>
453+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric describes the level of privileges an attacker must possess.">Privileges Required (PR)</th>
454+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric captures the requirement for user participation.">User Interaction (UI)</th>
455+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric captures whether a vulnerability impacts resources beyond its security scope.">Scope (S)</th>
456+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the impact to confidentiality.">Confidentiality (C)</th>
457+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the impact to integrity.">Integrity (I)</th>
458+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the impact to availability.">Availability (A)</th>
459+
</tr>
460+
<tr>
461+
<td>{{ severity_vector.vector.attackVector|cvss_printer:"network,adjacent_network,local,physical"}}</td>
462+
<td>{{ severity_vector.vector.attackComplexity|cvss_printer:"low,high" }}</td>
463+
<td>{{ severity_vector.vector.privilegesRequired|cvss_printer:"none,low,high" }}</td>
464+
<td>{{ severity_vector.vector.userInteraction|cvss_printer:"none,required"}}</td>
465+
<td>{{ severity_vector.vector.scope|cvss_printer:"unchanged,changed" }}</td>
466+
<td>{{ severity_vector.vector.confidentialityImpact|cvss_printer:"high,low,none" }}</td>
467+
<td>{{ severity_vector.vector.integrityImpact|cvss_printer:"high,low,none" }}</td>
468+
<td>{{ severity_vector.vector.availabilityImpact|cvss_printer:"high,low,none" }}</td>
469+
</tr>
456470
</table>
471+
</div>
472+
457473
{% elif severity_vector.vector.version == '4' %}
458-
Vector: {{ severity_vector.vector.vectorString }} Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
459-
<table class="table is-bordered is-striped is-narrow is-hoverable is-fullwidth gray-header-border">
460-
<tr>
461-
<th>Attack Vector (AV)</th>
462-
<th>Attack Complexity (AC)</th>
463-
<th>Attack Requirements (AT)</th>
464-
<th>Privileges Required (PR)</th>
465-
<th>User Interaction (UI)</th>
474+
Score: <strong>{{ severity_vector.vector.baseScore }}</strong> -
475+
Vector: <strong>{{ severity_vector.vector.vectorString }}</strong>
476+
<a href="https://www.first.org/cvss/v4.0/specification-document" target="_blank" class="has-tooltip-multiline has-tooltip-black" data-tooltip="Learn more about CVSS v4.0">
477+
<i class="fa fa-info-circle"></i>
478+
</a>
479+
- Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
480+
<table class="table is-bordered is-striped is-narrow is-hoverable is-fullwidth gray-header-border mt-2">
481+
<tr>
482+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric reflects the context by which vulnerability exploitation is possible.">Attack Vector (AV)</th>
483+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric describes the conditions beyond the attacker's control that must exist.">Attack Complexity (AC)</th>
484+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric describes the attack requirements that must be gathered.">Attack Requirements (AT)</th>
485+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric describes the level of privileges an attacker must possess.">Privileges Required (PR)</th>
486+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric captures the requirement for user participation.">User Interaction (UI)</th>
466487

467-
<th>Vulnerable System Impact Confidentiality (VC)</th>
468-
<th>Vulnerable System Impact Integrity (VI)</th>
469-
<th>Vulnerable System Impact Availability (VA)</th>
488+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the confidentiality impact on the vulnerable system.">VS Impact Confidentiality (VC)</th>
489+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the integrity impact on the vulnerable system.">VS Impact Integrity (VI)</th>
490+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the availability impact on the vulnerable system.">VS Impact Availability (VA)</th>
470491

471-
<th>Subsequent System Impact Confidentiality (SC)</th>
472-
<th>Subsequent System Impact Integrity (SI)</th>
473-
<th>Subsequent System Impact Availability (SA)</th>
474-
</tr>
475-
<tr>
476-
<td>{{ severity_vector.vector.attackVector|cvss_printer:"network,adjacent,local,physical"}}</td>
477-
<td>{{ severity_vector.vector.attackComplexity|cvss_printer:"low,high" }}</td>
478-
<td>{{ severity_vector.vector.attackRequirement|cvss_printer:"none,present" }}</td>
479-
<td>{{ severity_vector.vector.privilegesRequired|cvss_printer:"none,low,high" }}</td>
480-
<td>{{ severity_vector.vector.userInteraction|cvss_printer:"none,passive,active"}}</td>
492+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the confidentiality impact on the subsequent system.">SS Impact Confidentiality (SC)</th>
493+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the integrity impact on the subsequent system.">SS Impact Integrity (SI)</th>
494+
<th class="has-tooltip-multiline has-tooltip-black" data-tooltip="This metric measures the availability impact on the subsequent system.">SS Impact Availability (SA)</th>
495+
</tr>
496+
<tr>
497+
<td>{{ severity_vector.vector.attackVector|cvss_printer:"network,adjacent,local,physical"}}</td>
498+
<td>{{ severity_vector.vector.attackComplexity|cvss_printer:"low,high" }}</td>
499+
<td>{{ severity_vector.vector.attackRequirement|cvss_printer:"none,present" }}</td>
500+
<td>{{ severity_vector.vector.privilegesRequired|cvss_printer:"none,low,high" }}</td>
501+
<td>{{ severity_vector.vector.userInteraction|cvss_printer:"none,passive,active"}}</td>
481502

482-
<td>{{ severity_vector.vector.vulnerableSystemImpactConfidentiality|cvss_printer:"high,low,none" }}</td>
483-
<td>{{ severity_vector.vector.vulnerableSystemImpactIntegrity|cvss_printer:"high,low,none" }}</td>
484-
<td>{{ severity_vector.vector.vulnerableSystemImpactAvailability|cvss_printer:"high,low,none" }}</td>
503+
<td>{{ severity_vector.vector.vulnerableSystemImpactConfidentiality|cvss_printer:"high,low,none" }}</td>
504+
<td>{{ severity_vector.vector.vulnerableSystemImpactIntegrity|cvss_printer:"high,low,none" }}</td>
505+
<td>{{ severity_vector.vector.vulnerableSystemImpactAvailability|cvss_printer:"high,low,none" }}</td>
485506

486-
<td>{{ severity_vector.vector.subsequentSystemImpactConfidentiality|cvss_printer:"high,low,none" }}</td>
487-
<td>{{ severity_vector.vector.subsequentSystemImpactIntegrity|cvss_printer:"high,low,none" }}</td>
488-
<td>{{ severity_vector.vector.subsequentSystemImpactAvailability|cvss_printer:"high,low,none" }}</td>
489-
</tr>
507+
<td>{{ severity_vector.vector.subsequentSystemImpactConfidentiality|cvss_printer:"high,low,none" }}</td>
508+
<td>{{ severity_vector.vector.subsequentSystemImpactIntegrity|cvss_printer:"high,low,none" }}</td>
509+
<td>{{ severity_vector.vector.subsequentSystemImpactAvailability|cvss_printer:"high,low,none" }}</td>
510+
</tr>
490511
</table>
491512
{% elif severity_vector.vector.version == 'ssvc' %}
492-
<hr/>
493-
Vector: {{ severity_vector.vector.vectorString }} Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
494-
<hr/>
513+
<hr/>
514+
Vector: {{ severity_vector.vector.vectorString }} Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
515+
- Found at <a href="{{ severity_vector.origin }}" target="_blank">{{ severity_vector.origin }}</a>
516+
<hr/>
495517
{% endif %}
496-
{% empty %}
497-
<tr>
498-
<td>
499-
There are no known vectors.
500-
</td>
501-
</tr>
502-
{% endfor %}
518+
{% empty %}
519+
<tr>
520+
<td>
521+
There are no known vectors.
522+
</td>
523+
</tr>
524+
{% endfor %}
503525
</div>
504526

505527

0 commit comments

Comments
 (0)