niikawa@niikawa2:~$ aws ec2 describe-instances --region ap-northeast-1;date
An error occurred (UnauthorizedOperation) when calling the DescribeInstances operation: You are not authorized to perform this operation. User: arn:aws:iam::11111111111:user/niikawa is not authorized to perform: ec2:DescribeInstances with an explicit deny in an identity-based policy
Fri Jan 24 00:08:48 JST 2025
niikawa@niikawa2:~$ aws s3api create-bucket --bucket niikawa-test-bucket1 --region ap-northeast-1 --create-bucket-configuration LocationConstraint=ap-northeast-1;date
An error occurred (AccessDenied) when calling the CreateBucket operation: User: arn:aws:iam::11111111111:user/niikawa is not authorized to perform: s3:CreateBucket on resource: "arn:aws:s3:::niikawa-test-bucket1" with an explicit deny in an identity-based policy
Fri Jan 24 00:08:59 JST 2025
niikawa@niikawa2:~$ aws s3 cp s3://niikawa-test/index.html /tmp;date
fatal error: An error occurred (403) when calling the HeadObject operation: Forbidden
Fri Jan 24 00:09:14 JST 2025
aws s3 ls コマンド、dateコマンドを実行します。結果は、AccessDenied となり、アクセスは拒否されました。
niikawa@niikawa2:~$ aws s3 ls;date
An error occurred (AccessDenied) when calling the ListBuckets operation: User: arn:aws:iam::11111111111:user/niikawa is not authorized to perform: s3:ListAllMyBuckets with an explicit deny in an identity-based policy
Fri Jan 24 00:09:24 JST 2025