mirror of
https://github.com/pgsty/minio.git
synced 2026-07-22 21:50:22 +03:00
signature: Use the client sent region if region is properly validated. (#2534)
A properly validated region string from the client should be once validated properly. Fixes #2521
This commit is contained in:
+1
-2
@@ -361,9 +361,8 @@ func doesSignatureMatch(hashedPayload string, r *http.Request, validateRegion bo
|
|||||||
if !isValidRegion(sRegion, region) {
|
if !isValidRegion(sRegion, region) {
|
||||||
return ErrInvalidRegion
|
return ErrInvalidRegion
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
region = sRegion
|
|
||||||
}
|
}
|
||||||
|
region = sRegion
|
||||||
|
|
||||||
// Extract date, if not present throw error.
|
// Extract date, if not present throw error.
|
||||||
var date string
|
var date string
|
||||||
|
|||||||
Reference in New Issue
Block a user