fix: return full authorization header in unsupported authorization type error
the unsupported authorization type error only echoed the algorithm back in ArgumentValue, while s3 returns the whole Authorization header there. the parse error now carries the raw header and the s3 error mapping uses it, which also lets the bats test skipped for #1705 run again. Fixes #2489
This commit is contained in:
1 parent
1b64a938ab
commit
8271bea5c1
5 files changed
+31
-6
No files matched your search
@@ -65,7 +65,7 @@ func Authentication_unsupported_signature_version(s *S3Conf) error {
|
||||
return err
|
||||
}
|
||||
|
||||
return checkHTTPResponseApiErr(resp, s3err.GetInvalidArgumentErr(s3err.InvalidArgAuthorizationType, "AWS2-HMAC-SHA1"))
|
||||
return checkHTTPResponseApiErr(resp, s3err.GetInvalidArgumentErr(s3err.InvalidArgAuthorizationType, authHdr))
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
@@ -54,9 +54,6 @@ export RUN_USERS=true
|
||||
|
||||
# tags: curl,ListBuckets,required-headers,Authorization,invalid-header
|
||||
@test "REST - invalid authorization scheme" {
|
||||
if [ "$DIRECT" != "true" ]; then
|
||||
skip "https://github.com/versity/versitygw/issues/1705"
|
||||
fi
|
||||
run list_buckets_check_authorization_scheme_error
|
||||
assert_success
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user