Class STSAssumeRoleAWSCredentials
- Namespace
- Amazon.SecurityToken
- Assembly
- AWSSDK.SecurityToken.dll
Credentials that are retrieved by invoking AWS Security Token Service AssumeRole or AssumeRoleWithSAML action.
[Obsolete("This class has been replaced by Amazon.Runtime.AssumeRoleAWSCredentials and Amazon.Runtime.StoredProfileFederatedCredentials, and will be removed in a future version.", false)]
public class STSAssumeRoleAWSCredentials : RefreshingAWSCredentials, IDisposable
- Inheritance
-
STSAssumeRoleAWSCredentials
- Implements
Constructors
STSAssumeRoleAWSCredentials(IAmazonSecurityTokenService, AssumeRoleRequest)
Instantiates STSAssumeRoleAWSCredentials which automatically assumes a specified role. The credentials are refreshed before expiration.
public STSAssumeRoleAWSCredentials(IAmazonSecurityTokenService sts, AssumeRoleRequest assumeRoleRequest)
Parameters
sts
IAmazonSecurityTokenServiceInstance of IAmazonSecurityTokenService that will be used to make the AssumeRole service call.
assumeRoleRequest
AssumeRoleRequestConfiguration for the role to assume.
STSAssumeRoleAWSCredentials(AssumeRoleWithSAMLRequest)
Instantiates STSAssumeRoleAWSCredentials which automatically assumes a specified SAML role. The credentials are refreshed before expiration.
public STSAssumeRoleAWSCredentials(AssumeRoleWithSAMLRequest assumeRoleWithSamlRequest)
Parameters
assumeRoleWithSamlRequest
AssumeRoleWithSAMLRequestConfiguration for the SAML role to assume.
Methods
Dispose()
Disposes of all managed and unmanaged resources.
public void Dispose()
Dispose(bool)
Implements the Dispose pattern
protected virtual void Dispose(bool disposing)
Parameters
disposing
boolWhether this object is being disposed via a call to Dispose or garbage collected.
GenerateNewCredentials()
Generate new credentials.
protected override RefreshingAWSCredentials.CredentialsRefreshState GenerateNewCredentials()
Returns
- CredentialsRefreshState