使用 PowerShell 检索 AWS SNS 的加密状态

Retrieve the encryption state of AWS SNS with PowerShell

我调查了所有可检索 SNS 主题是否加密的 AWS SNS PowerShell Cmdlet,但我可以看到从

检索到的任何属性
Get-SNSTopicAttribute

涉及题目的加密配置。有解决办法吗?

解决方法是检查响应是否包含 KmsMasterKeyId 属性。因为,您必须输入有效的 CMK ARN。

例如:

请注意,当 SNS 未加密时,KmsMasterKeyId 属性 会丢失。