amazon-iam

aws CAPABILITY_AUTO_EXPAND console web codepipeline with cloudformation

元气小坏坏 提交于 2019-12-04 06:52:40
I am trying to complete a codepipeline with the cloudformation service and this error is generated. It must be said that the separate cloudformation service works well. The complete error is: JobFailed Requires capabilities: [CAPABILITY_AUTO_EXPAND] (Service: AmazonCloudFormation; Status Code: 400; Error Code: InsufficientCapabilitiesException; Request ID: 1a977102-f829-11e8-b5c6-f7cc8454c4d0) The solutions I have is to add the CAPABILITY_AUTO_EXPAND --capabilities parameter but that only applies to CLI and my case is by web console. Ran into the same problem, I could not find a way to do it

AWS IAM Show only untagged EC2 instances

末鹿安然 提交于 2019-12-04 06:10:26
问题 I'm attempting to introduce a guest IAM policy to restrict the access to the EC2 instances. I'm trying to reach that, the guest policy shows only that instances, which is not tagged with 'Department' or tagged with 'Department = Guest'. Here is the policy, that I made for this: Policy: { "Version": "2012-10-17", "Statement": [ { "Sid": "VisualEditor0", "Effect": "Allow", "Action": [ "ec2:Describe*" ], "Resource": "*", "Condition": { "StringEquals": { "ec2:ResourceTag/Department": "Guest" },

Amazon S3 Bucket and Folder Policy for IAM access?

匆匆过客 提交于 2019-12-04 05:54:38
Do you have a problem understanding S3 IAM Policies and Directives ? Can't quite wrap your head around their documentation ? I did. I had a situation where I had to lock out several IAM users from a particular folder, and several buckets, except one, and most of their solutions and example solutions were about as clear as mud as far as I was concerned. After scouring the web and not finding what I was looking for I came upon a resource ( http://blogs.aws.amazon.com/security/post/Tx1P2T3LFXXCNB5/Writing-IAM-policies-Grant-access-to-user-specific-folders-in-an-Amazon-S3-bucke ) that was clear

How to create a new user in AWS

可紊 提交于 2019-12-04 05:35:11
I'm trying to figure out how to create a new user with AWS APIs for Java, but i can't figure out what i need to do. So far i managed to write this code that gives me a CreateUserRequest, a CreateAccessKeyRequest and a BasicAWSCredentials with all the fields filled. I just can't figure out what to do next. Do I have to use CreateUserResult? How? CreateUserRequest user = new CreateUserRequest("userName"); CreateAccessKeyRequest key = new CreateAccessKeyRequest(); BasicAWSCredentials cred = new BasicAWSCredentials("access", "secret"); key.withUserName(user.getUserName()); key

Can an aws IAM policy dynamically refer to the logged in username?

徘徊边缘 提交于 2019-12-04 04:26:21
问题 I am trying to write an IAM policy which will control access to EC2 instances. All EC2 instances will have a custom tag called username and only if the tag value matches the logged in user's user name, will that user have access to that EC2 instance. This is what I came up with: { "Version": "2012-10-12", "Statement": [ { "Effect": "Allow", "Action": "ec2:*", "Resource": "*", "Condition": { "StringEquals": { "ec2:ResourceTag/username": "arn:aws:iam::account-number-without-hyphens:user

How can I control user access to Amazon DynamoDB data via IAM?

末鹿安然 提交于 2019-12-04 00:33:45
Does AWS Identity and Access Management (IAM) provide a way so that a user can only edit or delete the items in an Amazon DynamoDB table he added before? Steffen Opel This became possible after AWS added Fine-Grained Access Control for Amazon DynamoDB , which facilitates AWS Identity and Access Management (IAM) policies to regulate access to items and attributes stored in DynamoDB tables . The introductory blog post illustrates the outstanding granularity of this feature and resulting simplifications for many real world use cases: Horizontal - You can selectively hide or expose specific

How do I use Boto3 to launch an EC2 instance with an IAM role?

牧云@^-^@ 提交于 2019-12-04 00:24:57
I can not figure out how to launch an EC2 instance in Boto3 with a specified IAM role. Here is some sampe code of how I have been able to successfully create an instance so far: import boto3 ec2 = boto3.resource('ec2', region_name='us-west-2') ec2.create_instances(ImageId='ami-1e299d7e', InstanceType='t2.micro',\ MinCount=1, MaxCount=1, SecurityGroupIds=['Mysecuritygroup'], KeyName='mykeyname') Note : Some Boto3 versions accept either Arn or Name but all versions accept Name . I suggest using the role name only. IamInstanceProfile={ 'Arn': 'string', 'Name': 'string' } If your profile name is

What permissions does django-storages require for an s3 IAM user?

試著忘記壹切 提交于 2019-12-03 16:48:54
问题 As the question asks, what are the minimum required permissions for a locked down s3 IAM user to use django-storages successfully? At the present time I've used something like { "Statement": [ { "Effect": "Allow", "Action": ["s3:ListAllMyBuckets"], "Resource": "arn:aws:s3:::*" }, { "Effect": "Allow", "Action": ["s3:ListBucket", "s3:GetBucketLocation", "s3:ListBucketMultipartUploads", "s3:ListBucketVersions"], "Resource": "arn:aws:s3:::bucket-name" }, { "Effect": "Allow", "Action": ["s3:

Cognito/IAM Policies & S3 Get Object

本小妞迷上赌 提交于 2019-12-03 16:13:26
I'm trying to integrate S3 and Cognito into my iOS App, so far not successfully. I believe the error is connected to my IAM Policy for Auth and Unauth users. So here's my policy: { "Version": "2012-10-17", "Statement": [{ "Effect":"Allow", "Action":"cognito-sync:*", "Resource":["arn:aws:cognito-sync:us-east-1:XXXXXXXXXXXX:identitypool/${cognito-identity.amazonaws.com:aud}/identity/${cognito-identity.amazonaws.com:sub}/*"] }, { "Effect":"Allow", "Action": "s3:*", "Resource": ["arn:aws:s3:::my_bucket", "arn:aws:s3:::my_bucket/*"] } ] } here is where I call S3: AWSS3GetObjectRequest

How enable access to AWS STS AssumeRole

和自甴很熟 提交于 2019-12-03 15:18:24
问题 I am getting an error when calling to assume role method of STS. It says that the user is not authorized to perform sts:AsumeRole on resource xxx . I did the following: I created a role to access to S3 bucket. I ran a test over policy simulator and works fine I created a new group, and in it, i created a new policy that enables all sts actions, over all resources. I ran a test with the policy simulator, to sts assume role, pointing to the ARN of role created at step one; and it works fine I