|
| 1 | +{% extends "base.html" %} |
| 2 | +{% load humanize %} |
| 3 | +{% load widget_tweaks %} |
| 4 | +{% load static %} |
| 5 | +{% load url_filters %} |
| 6 | +{% load utils %} |
| 7 | + |
| 8 | +{% block content %} |
| 9 | +<div class="is-max-desktop mb-3"> |
| 10 | + <section class="mx-5"> |
| 11 | + <div class="is-flex" style="justify-content: space-between;"> |
| 12 | + <div> |
| 13 | + {{ page_obj.paginator.count|intcomma }} results |
| 14 | + </div> |
| 15 | + {% if is_paginated %} |
| 16 | + {% include 'includes/pagination.html' with page_obj=page_obj %} |
| 17 | + {% endif %} |
| 18 | + </div> |
| 19 | + </section> |
| 20 | +</div> |
| 21 | + |
| 22 | +<section class="section pt-0"> |
| 23 | + <div class="content"> |
| 24 | + <table class="table is-bordered is-striped is-narrow is-hoverable is-fullwidth"> |
| 25 | + <thead> |
| 26 | + <tr> |
| 27 | + <th style="width: 200px;">Advisory</th> |
| 28 | + <th style="width: 310px;">Source</th> |
| 29 | + <th style="width: 200px;">Date Published</th> |
| 30 | + <th>Summary</th> |
| 31 | + <th style="width: 310px;">Fixed in package version</th> |
| 32 | + </tr> |
| 33 | + </thead> |
| 34 | + |
| 35 | + <tbody> |
| 36 | + {% for advisory in page_obj %} |
| 37 | + <tr> |
| 38 | + <td> |
| 39 | + <a href="{{advisory.get_absolute_url}}"> |
| 40 | + {{advisory.avid }} |
| 41 | + </a> |
| 42 | + <br /> |
| 43 | + {% if advisory.alias|length != 0 %} |
| 44 | + Aliases: |
| 45 | + {% endif %} |
| 46 | + <br /> |
| 47 | + {% for alias in advisory.alias %} |
| 48 | + {% if alias.url %} |
| 49 | + <a href="{{ alias.url }}" target="_blank">{{ alias }}<i |
| 50 | + class="fa fa-external-link fa_link_custom"></i></a> |
| 51 | + <br /> |
| 52 | + {% else %} |
| 53 | + {{ alias }} |
| 54 | + <br /> |
| 55 | + {% endif %} |
| 56 | + {% endfor %} |
| 57 | + |
| 58 | + {% if advisory.secondary|length != 0 %} |
| 59 | + <p>Supporting advisories are listed below the primary advisory.</p> |
| 60 | + {% for secondary in advisory.secondary %} |
| 61 | + <a href="{{secondary.get_absolute_url}}"> |
| 62 | + {{secondary.avid }} |
| 63 | + </a> |
| 64 | + {% endfor %} |
| 65 | + {% endif %} |
| 66 | + </td> |
| 67 | + <td style="word-wrap: break-word; word-break: break-word;"> |
| 68 | + <a href={{advisory.url}} target="_blank">{{advisory.url}}</a> |
| 69 | + </td> |
| 70 | + <td style="word-wrap: break-word; word-break: break-word;"> |
| 71 | + {{advisory.date_published}} |
| 72 | + </td> |
| 73 | + <td style="word-wrap: break-word; word-break: break-word;"> |
| 74 | + {{ advisory.summary }} |
| 75 | + </td> |
| 76 | + <td style="word-wrap: break-word; word-break: break-all;"> |
| 77 | + {% with fixed=fixed_package_details|get_item:advisory.avid %} |
| 78 | + {% if fixed %} |
| 79 | + {% for item in fixed %} |
| 80 | + <section> |
| 81 | + <a href="/packages/v2/{{ item.pkg.purl|url_quote }}?search={{ item.pkg.purl }}" |
| 82 | + target="_self">{{ item.pkg.version }}</a> |
| 83 | + <br/> |
| 84 | + {% if item.pkg.is_vulnerable %} |
| 85 | + <span class="{{ item.pkg.is_vulnerable|yesno:'emphasis-vulnerable,emphasis-not-vulnerable' }}"> |
| 86 | + Vulnerable |
| 87 | + </span> |
| 88 | + {% else %} |
| 89 | + <span class="{{ item.pkg.is_vulnerable|yesno:'emphasis-vulnerable,emphasis-not-vulnerable' }}"> |
| 90 | + Not vulnerable |
| 91 | + </span> |
| 92 | + {% endif %} |
| 93 | + </section> |
| 94 | + {% endfor %} |
| 95 | + {% else %} |
| 96 | + <span class="emphasis-vulnerable">There are no reported fixed by versions.</span> |
| 97 | + {% endif %} |
| 98 | + {% endwith %} |
| 99 | + </td> |
| 100 | + </tr> |
| 101 | + {% empty %} |
| 102 | + <tr> |
| 103 | + <td colspan="3"> |
| 104 | + <span class="emphasis-not-vulnerable">This package is not known to be subject of any advisories.</span> |
| 105 | + </td> |
| 106 | + </tr> |
| 107 | + {% endfor %} |
| 108 | + </tbody> |
| 109 | + </table> |
| 110 | + </div> |
| 111 | + |
| 112 | +{% if is_paginated %} |
| 113 | + {% include 'includes/pagination.html' with page_obj=page_obj %} |
| 114 | +{% endif %} |
| 115 | +{% endblock %} |
| 116 | +</section> |
0 commit comments