amazon-iam

Understanding IAM policies

本秂侑毒 提交于 2019-12-25 00:34:46
问题 I recently ran into a problem with IAM policies while using Code-Build. And I am trying to understand the difference between the following 2 policies and check if there are any security implications of using version 2 over version 1. Version 1 doesn't work, so I decided to go with version 2. But why does version 2 work and why doesn't version 1 doesn't work? Version 1 only gives access to the CodePipeline resource and allows to read and write to S3 bucket object. However Version 2 gives

How to only allow AWS IoT subscriptions to topics under Cognito user id (sub)?

ぃ、小莉子 提交于 2019-12-24 19:13:37
问题 I want my backend to be able to directly send messages to authenticated users. Which means I need to limit the users to only subscribe on topics under their own identifiers. Ideally, to my currently limited understanding, I would have a policy that has the user sub as a variable: { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "iot:Connect", "iot:Publish", "iot:Receive", "iot:GetThingShadow", "iot:UpdateThingShadow", "iot:DeleteThingShadow" ], "Resource": "*" }, {

Get AWS IAM policy Access Advisor records from CLI or SDK

混江龙づ霸主 提交于 2019-12-24 01:24:26
问题 I'm reviewing IAM policies and roles that haven't been used in the last N number of days. In the console I can easily view recent usage under Access Advisor. I'd like to get the same in an automated way, but I can't find any documentation on getting this using CLI or SDK. Is this possible? 回答1: It is now available, check the link below https://aws.amazon.com/about-aws/whats-new/2018/12/iam_access_advisor_apis/ 回答2: Netflix has a tool called Aardvark to scrape the Access Advisor data from the

Get AWS IAM policy Access Advisor records from CLI or SDK

吃可爱长大的小学妹 提交于 2019-12-24 01:21:07
问题 I'm reviewing IAM policies and roles that haven't been used in the last N number of days. In the console I can easily view recent usage under Access Advisor. I'd like to get the same in an automated way, but I can't find any documentation on getting this using CLI or SDK. Is this possible? 回答1: It is now available, check the link below https://aws.amazon.com/about-aws/whats-new/2018/12/iam_access_advisor_apis/ 回答2: Netflix has a tool called Aardvark to scrape the Access Advisor data from the

What is the proper way to deploy a multi-region CloudFormation stack that includes global resources?

点点圈 提交于 2019-12-24 00:57:04
问题 I have a cloudformation stack template that includes regional resources (lambdas, api, topics, etc.) and global resources (user, policies, route53, cloudfront, dynamodb global tables, etc.) and want to deploy it to multiple region in the same AWS account. I can't directly deploy this stack template in multiple region because global resources will already exist after the first creation. I know I could split everything in two separate stack templates but I would prefer to avoid this and keep

AWS: Restricting IAM User to Specific Folder in S3 Bucket

一个人想着一个人 提交于 2019-12-24 00:54:17
问题 So I've been trying to define a policy to restrict a group of IAM users to a particular folder in an S3 bucket with no success. I've riffed off the policy outlined in this blog post. http://blogs.aws.amazon.com/security/post/Tx1P2T3LFXXCNB5/Writing-IAM-policies-Grant-access-to-user-specific-folders-in-an-Amazon-S3-bucke Specifically I'm using the following: { "Version":"2012-10-17", "Statement": [ { "Sid": "AllowUserToSeeBucketListInTheConsole", "Action": ["s3:ListAllMyBuckets", "s3

AccessDeniedException on aws when i'm trying to raise a support ticket

烈酒焚心 提交于 2019-12-24 00:35:44
问题 i just referred to this question AmazonServiceException: User is not authorized to perform: dynamodb:DescribeTable Status Code: 400; Error Code: AccessDeniedException which has similar error. but it doesn't help me. I'm getting this error when i try to raise a support ticket: Invalid Input User: arn:aws:iam::44324457964845364:user/testetest is not authorized to perform: support: (Service: AWSSupport; Status Code: 400; Error Code: AccessDeniedException; Request ID: 65dq34fedq234rde9

Policy enforcing S3 standard storage class

家住魔仙堡 提交于 2019-12-23 20:32:58
问题 Is there a way to define a S3 bucket policy to enforce standard storage class? I want to prevent users from creating objects with reduced redundancy storage class. 回答1: You can now use a condition in an S3 bucket policy to constrain the creation of S3 objects (using PutObject ) to specific storage classes. The current version of the AWS documentation has an example - Restrict object uploads to objects with a specific storage class. Suppose Account A owns a bucket and the account administrator

having trouble displaying an image uploaded to Amazon s3 by fine-uploader

﹥>﹥吖頭↗ 提交于 2019-12-23 20:21:34
问题 I am now trying to set up fineuploader-s3 to show an image of the file successfully uploaded on the aws server, as was done on the example page here: http://fineuploader.com/#s3-demo I am (still) using the code at https://github.com/Widen/fine-uploader-server/blob/master/php/s3/s3demo.php, and I’ve added uploadSuccess: { endpoint: "s3demo.php?success" } to the fine-uploader instance in my javascript file, so that the temporary link should be generated by the function in the s3demo.php file. I