[rubygems/rubygems] Use better status for authentication failures

https://github.com/rubygems/rubygems/commit/ffa395411f
This commit is contained in:
David Rodríguez 2023-08-10 20:38:07 +02:00 committed by Hiroshi SHIBATA
parent 2e04336b67
commit c076ac8a5f
No known key found for this signature in database
GPG Key ID: F9CF13417264FAC2
2 changed files with 2 additions and 2 deletions

View File

@ -10,7 +10,7 @@ class CompactIndexStrictBasicAuthentication < CompactIndexAPI
# Only accepts password == "password"
unless env["HTTP_AUTHORIZATION"] == "Basic dXNlcjpwYXNz"
halt 403, "Authentication failed"
halt 401, "Authentication failed"
end
end
end

View File

@ -10,7 +10,7 @@ class EndpointStrictBasicAuthentication < Endpoint
# Only accepts password == "password"
unless env["HTTP_AUTHORIZATION"] == "Basic dXNlcjpwYXNz"
halt 403, "Authentication failed"
halt 401, "Authentication failed"
end
end
end