Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
90041b5b
Commit
90041b5b
authored
Oct 16, 2020
by
Savas Vedova
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Take into account empty strings
- Add changelog
parent
043c95a0
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
28 additions
and
1 deletion
+28
-1
ee/app/assets/javascripts/security_dashboard/components/vulnerability_list.vue
...ipts/security_dashboard/components/vulnerability_list.vue
+3
-1
ee/changelogs/unreleased/267513-fix-vendor-name-check.yml
ee/changelogs/unreleased/267513-fix-vendor-name-check.yml
+6
-0
ee/spec/frontend/security_dashboard/components/vulnerability_list_spec.js
.../security_dashboard/components/vulnerability_list_spec.js
+19
-0
No files found.
ee/app/assets/javascripts/security_dashboard/components/vulnerability_list.vue
View file @
90041b5b
...
...
@@ -102,7 +102,9 @@ export default {
return
Boolean
(
this
.
$listeners
[
'
sort-changed
'
]);
},
hasAnyScannersOtherThanGitLab
()
{
return
this
.
filteredVulnerabilities
.
some
(
v
=>
v
.
scanner
?.
vendor
!==
'
GitLab
'
);
return
this
.
filteredVulnerabilities
.
some
(
v
=>
v
.
scanner
?.
vendor
!==
'
GitLab
'
&&
v
.
scanner
?.
vendor
!==
''
,
);
},
notEnabledSecurityScanners
()
{
const
{
available
=
[],
enabled
=
[]
}
=
this
.
securityScanners
;
...
...
ee/changelogs/unreleased/267513-fix-vendor-name-check.yml
0 → 100644
View file @
90041b5b
---
title
:
Fix GitLab vendor name appearing accidentally in the security reports when
it's the only one
merge_request
:
45442
author
:
type
:
fixed
ee/spec/frontend/security_dashboard/components/vulnerability_list_spec.js
View file @
90041b5b
...
...
@@ -347,6 +347,25 @@ describe('Vulnerability list component', () => {
});
});
describe
(
'
when vendor name is not provided in the reports
'
,
()
=>
{
let
newVulnerabilities
;
beforeEach
(()
=>
{
newVulnerabilities
=
generateVulnerabilities
();
newVulnerabilities
=
newVulnerabilities
.
map
(
v
=>
({
...
v
,
scanner
:
{
vendor
:
''
}
}));
wrapper
=
createWrapper
({
props
:
{
vulnerabilities
:
newVulnerabilities
,
shouldShowReportType
:
true
,
},
});
});
it
(
'
should not render the vendor name
'
,
()
=>
{
expect
(
findVendorNames
().
exists
()).
toBe
(
false
);
});
});
describe
(
'
when there are other scanners in the report
'
,
()
=>
{
let
newVulnerabilities
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment