in account B with attached role in account B. I need just to adjust S3 policy with ec2 role arn and actions?
Bucket policy will need to allow the foreign principal and identity policy in account b will need to allow access. Proving you've got no SCPs or permission boundaries preventing it
‘’’json { "Version": "2012-10-17", "Statement": [ { "Action": [ "s3:GetObject", "s3:ListBucket" ], "Effect": "Allow", "Resource": [ "arn:aws:s3:::my-bucket", "arn:aws:s3:::my-bucket/*" ], "Principal": { "AWS": [ "arn:aws:iam::ACCOUNT-B:role/my-ec2-role" ] } } ] } ‘’’
I’ll try with this
Won't work
I can’t change role to ec2 instance too
How can I achieve it without changing the ec2 role
I'm uploading a object from Account B to Account A, but when I try read the object it reject any action. Account A has S3 with server side KMS
Обсуждают сегодня