mirror of https://github.com/minio/minio.git
Satisfy `aws:SecureTransport` policy behind reverse proxy
This commit is contained in:
parent
380233d646
commit
61bd861a42
|
@ -125,10 +125,15 @@ func getConditionValues(r *http.Request, lc string, cred auth.Credentials) map[s
|
|||
authtype = "POST"
|
||||
}
|
||||
|
||||
secureTransport := r.TLS != nil
|
||||
if forwardedScheme := handlers.GetSourceScheme(r); forwardedScheme != "" {
|
||||
secureTransport = forwardedScheme == "https"
|
||||
}
|
||||
|
||||
args := map[string][]string{
|
||||
"CurrentTime": {currTime.Format(time.RFC3339)},
|
||||
"EpochTime": {strconv.FormatInt(currTime.Unix(), 10)},
|
||||
"SecureTransport": {strconv.FormatBool(r.TLS != nil)},
|
||||
"SecureTransport": {strconv.FormatBool(secureTransport)},
|
||||
"SourceIp": {handlers.GetSourceIPRaw(r)},
|
||||
"UserAgent": {r.UserAgent()},
|
||||
"Referer": {r.Referer()},
|
||||
|
|
Loading…
Reference in New Issue