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
d4bd245a
Commit
d4bd245a
authored
Mar 07, 2018
by
Kim "BKC" Carlbäcker
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
naming things
parent
1ae7af1e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
lib/gitlab/workhorse.rb
lib/gitlab/workhorse.rb
+2
-2
No files found.
lib/gitlab/workhorse.rb
View file @
d4bd245a
...
...
@@ -10,7 +10,7 @@ module Gitlab
INTERNAL_API_CONTENT_TYPE
=
'application/vnd.gitlab-workhorse+json'
.
freeze
INTERNAL_API_REQUEST_HEADER
=
'Gitlab-Workhorse-Api-Request'
.
freeze
NOTIFICATION_CHANNEL
=
'workhorse:notifications'
.
freeze
ALLOWED_ACTIONS
=
%w[git_receive_pack git_upload_pack info_refs]
.
freeze
ALLOWED_
GIT_HTTP_
ACTIONS
=
%w[git_receive_pack git_upload_pack info_refs]
.
freeze
# Supposedly the effective key size for HMAC-SHA256 is 256 bits, i.e. 32
# bytes https://tools.ietf.org/html/rfc4868#section-2.6
...
...
@@ -18,7 +18,7 @@ module Gitlab
class
<<
self
def
git_http_ok
(
repository
,
is_wiki
,
user
,
action
,
show_all_refs:
false
)
raise
"Unsupported action:
#{
action
}
"
unless
ALLOWED_ACTIONS
.
include?
(
action
.
to_s
)
raise
"Unsupported action:
#{
action
}
"
unless
ALLOWED_
GIT_HTTP_
ACTIONS
.
include?
(
action
.
to_s
)
project
=
repository
.
project
repo_path
=
repository
.
path_to_repo
...
...
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