以下是GetRoleInput
用作GetRole()
函数输入以获取 aws 角色的结构
type GetRoleInput struct {
RoleName *string `min:"1" type:"string" required:"true"`
}
以下是用于通过调用方法GetGroupInput
获取 aws 组的结构GetGroup()
type GetRoleInput struct {
RoleName *string `min:"1" type:"string" required:"true"`
}
现在以下是GetPolicyInput
为了获取 IAM 托管策略
type GetPolicyInput struct {
PolicyArn *string `min:"20" type:"string" required:"true"`
}
在GetPolicyInput
中,与前两种情况不同,使用 PolicyArn 代替 policyName。所以问题是
- 为什么 PolicyArn 用于托管策略?策略名称不能识别策略吗?
- 如果我们有带有 aws API 的 policyName,有没有办法获取 policyArn。