commit
a2896cc39d
3 changed files with 20 additions and 2 deletions
|
@ -13,7 +13,11 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.vulnerability-priority-view-element.High,
|
.vulnerability-priority-view-element.High,
|
||||||
.vulnerability-priority-view-element.Critical,
|
.vulnerability-priority-view-element.Critical {
|
||||||
.vulnerability-priority-view-element.Defcon1 {
|
|
||||||
color: #D64456;
|
color: #D64456;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.vulnerability-priority-view-element.Defcon1 {
|
||||||
|
color: black;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
|
@ -18,6 +18,13 @@
|
||||||
|
|
||||||
<!-- Normal View -->
|
<!-- Normal View -->
|
||||||
<div ng-show="!showingHistory">
|
<div ng-show="!showingHistory">
|
||||||
|
<div class="co-alert co-alert-danger" ng-if="hasDefcon1">
|
||||||
|
One or more of your tags has an <strong>extremely critical</strong> vulnerability which should be addressed immediately:
|
||||||
|
<a href="{{ vuln.Link }}" ng-repeat="(key, vuln) in defcon1" style="margin-left: 10px;" target="_blank">
|
||||||
|
{{ vuln.ID }}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="co-check-bar">
|
<div class="co-check-bar">
|
||||||
<span class="cor-checkable-menu" controller="checkedTags">
|
<span class="cor-checkable-menu" controller="checkedTags">
|
||||||
<div class="cor-checkable-menu-item" item-filter="allTagFilter">
|
<div class="cor-checkable-menu-item" item-filter="allTagFilter">
|
||||||
|
|
|
@ -36,6 +36,8 @@ angular.module('quay').directive('repoPanelTags', function () {
|
||||||
$scope.showingHistory = false;
|
$scope.showingHistory = false;
|
||||||
$scope.tagsPerPage = 25;
|
$scope.tagsPerPage = 25;
|
||||||
$scope.imageVulnerabilities = {};
|
$scope.imageVulnerabilities = {};
|
||||||
|
$scope.defcon1 = {};
|
||||||
|
$scope.hasDefcon1 = false;
|
||||||
|
|
||||||
var setTagState = function() {
|
var setTagState = function() {
|
||||||
if (!$scope.repository || !$scope.selectedTags) { return; }
|
if (!$scope.repository || !$scope.selectedTags) { return; }
|
||||||
|
@ -173,6 +175,11 @@ angular.module('quay').directive('repoPanelTags', function () {
|
||||||
};
|
};
|
||||||
|
|
||||||
resp.data.Vulnerabilities.forEach(function(v) {
|
resp.data.Vulnerabilities.forEach(function(v) {
|
||||||
|
if (VulnerabilityService.LEVELS[v.Priority].index == 0) {
|
||||||
|
$scope.defcon1[v.ID] = v;
|
||||||
|
$scope.hasDefcon1 = true;
|
||||||
|
}
|
||||||
|
|
||||||
if (VulnerabilityService.LEVELS[v.Priority].index < highest.index) {
|
if (VulnerabilityService.LEVELS[v.Priority].index < highest.index) {
|
||||||
highest = {
|
highest = {
|
||||||
'Priority': v.Priority,
|
'Priority': v.Priority,
|
||||||
|
|
Reference in a new issue