Class CfnSAMLProvider
- All Implemented Interfaces:
IInspectable,ISAMLProviderRef,IEnvironmentAware,ITaggable,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
The SAML provider resource that you create with this operation can be used as a principal in an IAM role's trust policy. Such a policy can enable federated users who sign in using the SAML IdP to assume the role. You can create an IAM role that supports Web-based single sign-on (SSO) to the the console or one that supports API access to AWS .
When you create the SAML provider resource, you upload a SAML metadata document that you get from your IdP. That document includes the issuer's name, expiration information, and keys that can be used to validate the SAML authentication response (assertions) that the IdP sends. You must generate the metadata document using the identity management software that is used as your organization's IdP.
This operation requires Signature Version 4 .
For more information, see Enabling SAML 2.0 federated users to access the the console and About SAML 2.0-based federation in the IAM User Guide .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.iam.*;
CfnSAMLProvider cfnSAMLProvider = CfnSAMLProvider.Builder.create(this, "MyCfnSAMLProvider")
.addPrivateKey("addPrivateKey")
.assertionEncryptionMode("assertionEncryptionMode")
.name("name")
.privateKeyList(List.of(SAMLPrivateKeyProperty.builder()
.keyId("keyId")
.timestamp("timestamp")
.build()))
.removePrivateKey("removePrivateKey")
.samlMetadataDocument("samlMetadataDocument")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnSAMLProvider.static interfaceContains the private keys for the SAML provider.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.interfaces.iam.ISAMLProviderRef
ISAMLProviderRef.Jsii$Default, ISAMLProviderRef.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnSAMLProvider(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnSAMLProvider(software.amazon.jsii.JsiiObjectRef objRef) CfnSAMLProvider(software.constructs.Construct scope, String id) Create a newAWS::IAM::SAMLProvider.CfnSAMLProvider(software.constructs.Construct scope, String id, CfnSAMLProviderProps props) Create a newAWS::IAM::SAMLProvider. -
Method Summary
Modifier and TypeMethodDescriptionstatic StringarnForSAMLProvider(ISAMLProviderRef resource) Specifies the new private key from your external identity provider.Specifies the encryption setting for the SAML provider.Returns the Amazon Resource Name (ARN) for the specifiedAWS::IAM::SAMLProviderresource.The unique identifier assigned to the SAML provider.getName()The name of the provider to create.The private key metadata for the SAML provider.The Key ID of the private key to remove.An XML document generated by an identity provider (IdP) that supports SAML 2.0.A reference to a SAMLProvider resource.getTags()Tag Manager which manages the tags for this resource.A list of tags that you want to attach to the new IAM SAML provider.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidsetAddPrivateKey(String value) Specifies the new private key from your external identity provider.voidsetAssertionEncryptionMode(String value) Specifies the encryption setting for the SAML provider.voidThe name of the provider to create.voidsetPrivateKeyList(List<Object> value) The private key metadata for the SAML provider.voidsetPrivateKeyList(IResolvable value) The private key metadata for the SAML provider.voidsetRemovePrivateKey(String value) The Key ID of the private key to remove.voidsetSamlMetadataDocument(String value) An XML document generated by an identity provider (IdP) that supports SAML 2.0.voidsetTagsRaw(List<CfnTag> value) A list of tags that you want to attach to the new IAM SAML provider.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.interfaces.IEnvironmentAware
getEnvMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnSAMLProvider
protected CfnSAMLProvider(software.amazon.jsii.JsiiObjectRef objRef) -
CfnSAMLProvider
protected CfnSAMLProvider(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnSAMLProvider
@Stability(Stable) public CfnSAMLProvider(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable CfnSAMLProviderProps props) Create a newAWS::IAM::SAMLProvider.- Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties.
-
CfnSAMLProvider
@Stability(Stable) public CfnSAMLProvider(@NotNull software.constructs.Construct scope, @NotNull String id) Create a newAWS::IAM::SAMLProvider.- Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.
-
-
Method Details
-
arnForSAMLProvider
@Stability(Stable) @NotNull public static String arnForSAMLProvider(@NotNull ISAMLProviderRef resource) - Parameters:
resource- This parameter is required.
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrArn
Returns the Amazon Resource Name (ARN) for the specifiedAWS::IAM::SAMLProviderresource. -
getAttrSamlProviderUuid
The unique identifier assigned to the SAML provider. -
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getSamlProviderRef
A reference to a SAMLProvider resource.- Specified by:
getSamlProviderRefin interfaceISAMLProviderRef
-
getTags
Tag Manager which manages the tags for this resource. -
getAddPrivateKey
Specifies the new private key from your external identity provider. -
setAddPrivateKey
Specifies the new private key from your external identity provider. -
getAssertionEncryptionMode
Specifies the encryption setting for the SAML provider. -
setAssertionEncryptionMode
Specifies the encryption setting for the SAML provider. -
getName
The name of the provider to create. -
setName
The name of the provider to create. -
getPrivateKeyList
The private key metadata for the SAML provider.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnSAMLProvider.SAMLPrivateKeyProperty> -
setPrivateKeyList
The private key metadata for the SAML provider. -
setPrivateKeyList
The private key metadata for the SAML provider. -
getRemovePrivateKey
The Key ID of the private key to remove. -
setRemovePrivateKey
The Key ID of the private key to remove. -
getSamlMetadataDocument
An XML document generated by an identity provider (IdP) that supports SAML 2.0. The document includes the issuer's name, expiration information, and keys that can be used to validate the SAML authentication response (assertions) that are received from the IdP. You must generate the metadata document using the identity management software that is used as your organization's IdP. -
setSamlMetadataDocument
An XML document generated by an identity provider (IdP) that supports SAML 2.0. The document includes the issuer's name, expiration information, and keys that can be used to validate the SAML authentication response (assertions) that are received from the IdP. You must generate the metadata document using the identity management software that is used as your organization's IdP. -
getTagsRaw
A list of tags that you want to attach to the new IAM SAML provider. -
setTagsRaw
A list of tags that you want to attach to the new IAM SAML provider.
-