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
5c6ce1d5
Commit
5c6ce1d5
authored
Mar 29, 2019
by
Tetiana Chupryna
Committed by
Nick Thomas
Mar 29, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve logical order
parent
e98fc829
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
3 deletions
+8
-3
ee/changelogs/unreleased/dast-location-fingerprint.yml
ee/changelogs/unreleased/dast-location-fingerprint.yml
+5
-0
ee/lib/gitlab/ci/parsers/security/dast.rb
ee/lib/gitlab/ci/parsers/security/dast.rb
+1
-1
ee/spec/lib/gitlab/ci/parsers/security/dast_spec.rb
ee/spec/lib/gitlab/ci/parsers/security/dast_spec.rb
+2
-2
No files found.
ee/changelogs/unreleased/dast-location-fingerprint.yml
0 → 100644
View file @
5c6ce1d5
---
title
:
Change order in dast location fingerprint
merge_request
:
10487
author
:
type
:
changed
ee/lib/gitlab/ci/parsers/security/dast.rb
View file @
5c6ce1d5
...
...
@@ -46,7 +46,7 @@ module Gitlab
end
def
generate_location_fingerprint
(
location
)
Digest
::
SHA1
.
hexdigest
(
"
#{
location
[
'path'
]
}
:
#{
location
[
'
param'
]
}
:
#{
location
[
'method
'
]
}
"
)
Digest
::
SHA1
.
hexdigest
(
"
#{
location
[
'path'
]
}
:
#{
location
[
'
method'
]
}
:
#{
location
[
'param
'
]
}
"
)
end
end
end
...
...
ee/spec/lib/gitlab/ci/parsers/security/dast_spec.rb
View file @
5c6ce1d5
...
...
@@ -24,8 +24,8 @@ describe Gitlab::Ci::Parsers::Security::Dast do
end
it
'generates expected location fingerprint'
do
expected1
=
Digest
::
SHA1
.
hexdigest
(
':
X-Content-Type-Options:GET
'
)
expected2
=
Digest
::
SHA1
.
hexdigest
(
'/:
X-Content-Type-Options:GET
'
)
expected1
=
Digest
::
SHA1
.
hexdigest
(
':
GET:X-Content-Type-Options
'
)
expected2
=
Digest
::
SHA1
.
hexdigest
(
'/:
GET:X-Content-Type-Options
'
)
expect
(
report
.
occurrences
.
first
[
:location_fingerprint
]).
to
eq
(
expected1
)
expect
(
report
.
occurrences
.
last
[
:location_fingerprint
]).
to
eq
(
expected2
)
...
...
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