DataProtectionPolicy

class DataProtectionPolicy : KotlinCustomResource

Provides an SNS data protection topic policy resource

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.sns.Topic;
import com.pulumi.aws.sns.DataProtectionPolicy;
import com.pulumi.aws.sns.DataProtectionPolicyArgs;
import static com.pulumi.codegen.internal.Serialization.*;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var exampleTopic = new Topic("exampleTopic");
var exampleDataProtectionPolicy = new DataProtectionPolicy("exampleDataProtectionPolicy", DataProtectionPolicyArgs.builder()
.arn(exampleTopic.arn())
.policy(serializeJson(
jsonObject(
jsonProperty("Description", "Example data protection policy"),
jsonProperty("Name", "__example_data_protection_policy"),
jsonProperty("Statement", jsonArray(jsonObject(
jsonProperty("DataDirection", "Inbound"),
jsonProperty("DataIdentifier", jsonArray("arn:aws:dataprotection::aws:data-identifier/EmailAddress")),
jsonProperty("Operation", jsonObject(
jsonProperty("Deny", jsonObject(
))
)),
jsonProperty("Principal", jsonArray("*")),
jsonProperty("Sid", "__deny_statement_11ba9d96")
))),
jsonProperty("Version", "2021-06-01")
)))
.build());
}
}

Import

SNS Data Protection Topic Policy can be imported using the topic ARN, e.g.,

$ pulumi import aws:sns/dataProtectionPolicy:DataProtectionPolicy example arn:aws:sns:us-west-2:0123456789012:example

Properties

Link copied to clipboard
val arn: Output<String>

The ARN of the SNS topic

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val policy: Output<String>

The fully-formed AWS policy as JSON. For more information about building AWS IAM policy documents with this provider, see the AWS IAM Policy Document Guide.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val urn: Output<String>