Table of Contents

Class CfnResourcePolicyProps

Namespace
Amazon.CDK.AWS.SecretsManager
Assembly
Amazon.CDK.AWS.SecretsManager.dll

Properties for defining a CfnResourcePolicy.

public class CfnResourcePolicyProps : ICfnResourcePolicyProps
Inheritance
CfnResourcePolicyProps
Implements
Inherited Members

Examples

// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.SecretsManager;

             var resourcePolicy;

             var cfnResourcePolicyProps = new CfnResourcePolicyProps {
                 ResourcePolicy = resourcePolicy,
                 SecretId = "secretId",

                 // the properties below are optional
                 BlockPublicPolicy = false
             };

Remarks

Constructors

CfnResourcePolicyProps()

public CfnResourcePolicyProps()

Properties

BlockPublicPolicy

Specifies whether to block resource-based policies that allow broad access to the secret.

public object? BlockPublicPolicy { get; set; }

Property Value

object

Remarks

By default, Secrets Manager blocks policies that allow broad access, for example those that use a wildcard for the principal.

Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-secretsmanager-resourcepolicy.html#cfn-secretsmanager-resourcepolicy-blockpublicpolicy

ResourcePolicy

A JSON-formatted string for an AWS resource-based policy.

public object ResourcePolicy { get; set; }

Property Value

object

Remarks

SecretId

The ARN or name of the secret to attach the resource-based policy.

public string SecretId { get; set; }

Property Value

string

Remarks