Remove unwanted errorIf calls (#5621)

Remove errorIf call with a errSignatureMismatch error
This commit is contained in:
kannappanr
2018-03-09 00:51:05 -08:00
committed by GitHub
parent 889dd387f1
commit 380e0ddb57
2 changed files with 2 additions and 16 deletions

View File

@@ -123,17 +123,9 @@ func checkRequestAuthType(r *http.Request, bucket, policyAction, region string)
switch reqAuthType {
case authTypePresignedV2, authTypeSignedV2:
// Signature V2 validation.
s3Error := isReqAuthenticatedV2(r)
if s3Error != ErrNone {
errorIf(errSignatureMismatch, "%s", dumpRequest(r))
}
return s3Error
return isReqAuthenticatedV2(r)
case authTypeSigned, authTypePresigned:
s3Error := isReqAuthenticated(r, region)
if s3Error != ErrNone {
errorIf(errSignatureMismatch, "%s", dumpRequest(r))
}
return s3Error
return isReqAuthenticated(r, region)
}
if reqAuthType == authTypeAnonymous && policyAction != "" {