We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a88126b commit 6a6b556Copy full SHA for 6a6b556
object_store/src/aws/credential.rs
@@ -233,8 +233,12 @@ impl<'a> AwsAuthorizer<'a> {
233
.append_pair("X-Amz-Expires", &expires_in.as_secs().to_string())
234
.append_pair("X-Amz-SignedHeaders", "host");
235
236
- // TODO: For S3, you must include the X-Amz-Security-Token query parameter in the URL if
+ // For S3, you must include the X-Amz-Security-Token query parameter in the URL if
237
// using credentials sourced from the STS service.
238
+ if let Some(ref token) = self.credential.token {
239
+ url.query_pairs_mut()
240
+ .append_pair("X-Amz-Security-Token", token);
241
+ }
242
243
// We don't have a payload; the user is going to send the payload directly themselves.
244
let digest = UNSIGNED_PAYLOAD;
0 commit comments