Merge branch 'develop' into dev_aliyun

dev_cs
jingquan huang 6 years ago
commit bb87b9ef4c

@ -19,6 +19,10 @@ class GitsController < ApplicationController
result = false
if request.env["HTTP_AUTHORIZATION"] && request.env["HTTP_AUTHORIZATION"].split(" ").length == 2
username_password = Base64.decode64(request.env["HTTP_AUTHORIZATION"].split(" ")[1])
if username_password.split(":")[0].nil? || username_password.split(":")[1].nil?
result = false
else
input_username = username_password.split(":")[0].strip()
input_password = username_password.split(":")[1].strip()
uid_logger("git start auth: input_username is #{input_username}")
@ -60,6 +64,7 @@ class GitsController < ApplicationController
end
end
end
end
authenticate_or_request_with_http_basic do |username, password|
result

Loading…
Cancel
Save