SlideShare a Scribd company logo
1 of 35
 VPC (Virtual Private Cloud)
 Build a most commonly used network architecture with a
CloudFormation Template
 Entire Data Centre Networking Infrastructure in <20min
 AWS Organizations
 Architecting Governance and Security with multi-account strategy
 Immutable Architecture
 Security Control Policies: BL / WL
Master Account InfoSec Account
{"Version":"2012-10-
17","Statement":[{"Effect":"Allow","Action":"*","R
esource":"*"}]}
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"AWS": “arn:aws:iam::111111111111:root"
},
"Action": "sts:AssumeRole"
}
]
}
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "Stmt1499879069000",
"Effect": "Allow",
"Action": [
"sts:AssumeRole"
],
"Resource": [
“arn:aws:iam::222222222222:role/OrganizationAccountAccess
Role-InfoSec"
]
}
]
}
Trusting AccountTrusted Account
InfoSec Admin Group
1111-1111-1111 2222-2222-2222
OrganizationAccountAccessRole-InfoSec
Access Policy
Trust PolicyInline Policy Attached to a Group
https://cloudonaut.io
 Enables us to control who can do what in our AWS account
 Secure (deny) by default
 Global service
 https://alias.signin.aws.amazon.com/console
( redirected to a regional sign-in endpoint such as https://us-east-
2.signin.aws.amazon.com, resulting in a regional CloudTrail log entry
in the user's region's log )
 https://alias.signin.aws.amazon.com/console/s3
( AWS redirects you to the global sign-in endpoint at
https://signin.aws.amazon.com, resulting in a global CloudTrail log
entry )
 https://alias.signin.aws.amazon.com/console/ec2?region=ca-
central-1
(results in a CloudTrail log event in that region)
 Create individual users
 Grant least privilege
 Manage permissions with groups
 Restrict privileged access further with conditions
 Enable AWS CloudTrail to get logs of API calls
 Configure a strong password policy
 Rotate security credentials regularly.
 Enable MFA for privileged users
 Use IAM roles to share access
 Use IAM roles for Amazon EC2 instances
 Reduce or remove use of root
https://www.slideshare.net/AmazonWebServices/sec302-iam-best-practices-to-live-by
 A policy is a document that contains one or more permissions.
 Each permission describes actions that are allowed or not allowed
 Written in JSON
 User Based or Resource Based
 Managed Policies and Inline Policies
 Managed Policies:
 AWS managed policies
 Customer managed policies
 Managed Policies feature:
 Reusability
 Central change management
 Versioning and rolling back
 Delegating permissions management
 Automatic updates for AWS managed policies
 Inline Policies feature:
 Embedded into user/group/role
 Strict one to one relationship between a policy and the principal entity that
it’s attached
 What happens to a inline policy when we delete a principal entity that it’s
attached to?
Requests that are made by the AWS account root user are allowed for resources in that account.
IAM user in an account that is in an organization can use the intersection of the permissions allowed by
both Organizations SCPs and by the IAM permission policies
 Attached to a User, Group, or Role
 Policies DO NOT specify a Principal (User/Group/Role); it is implied
 Attached to a resource such as S3 Bucket or DynamoDB Table
 Policies DO specify a Principal (User/Group/Role)
 Policy describes what access is assigned to the principal
 Allows us to treat resources as a unit (i.e. project
 Allows us to autmatically enforce permissions when new resources are
created
 Supported services: EC2,VPC, EBS, RDS, SWS, Data Pipeline
Amazon Resource Names (ARNs) uniquely identify AWS resources. We require an ARN when you need to specify a resource unambiguously across all of AWS,
such as in IAM policies, Amazon Relational Database Service (Amazon RDS) tags, and API calls.
The following is the common Amazon Resource Name (ARN) format to identify any resources in AWS.
arn:partition:service:region:namespace:relative-id
General formats for ARNs; the specific components and values used depend on the AWS service.
arn:partition:service:region:account-id:resource
arn:partition:service:region:account-id:resourcetype/resource
arn:partition:service:region:account-id:resourcetype:resource
 <!-- Elastic Beanstalk application version -->
 arn:aws:elasticbeanstalk:us-east-1:123456789012:environment/My App/MyEnvironment
 <!-- IAM user name —>
 arn:aws:iam::123456789012:user/David

 <!-- Amazon RDS instance used for tagging -->
 arn:aws:rds:eu-west-1:123456789012:db:mysql-db

 <!-- Object in an Amazon S3 bucket -->
 arn:aws:s3:::my_corporate_bucket/exampleobject.png

 Paths in ARNs
 arn:aws:iam::123456789012:user/Development/product_1234/*
 "Resource":"arn:aws:iam::123456789012:user/*"
 "Resource":"arn:aws:iam::123456789012:group/*"

 http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-rds
 arn:aws:s3:::bucket_name
 arn:aws:s3:::bucket_name/key_name
 arn:aws:s3:::examplebucket/developers/design_info.doc
 arn:aws:s3:::examplebucket/*
 arn:aws:s3:::example?bucket/*
 arn:aws:s3:::bucket_name/developers/${aws:username}/
AWS assigns two unique IDs to each AWS account:
 An AWS account ID (123456789012)
 A canonical user ID - an obfuscated form of the AWS account ID
(79a59df900b949665d96a1e698fbacedfd6e09d98eacf8f8d5218e7cd47ef2b
e)
 You cannot use a wildcard to specify all users in the Principal element in
a resource-based policy or a role trust policy.
 You cannot use groups as principals in any policy.
 You can use wildcard characters (* and ?) within any ARN segment
 You can specify user/* to mean all users or group/* to mean all groups
 Effect - Required - specifies statements result is “Allow” or “Deny
 Principal - Required for Resource Policies only
 Action - Required - An AWS Service “Action” that statement applies to
 Resource - Required - An AWS object (ARN) that statement applies to.
 Condition - Optional
 Version policy element defines the version of the policy language
 Statement policy element is the main element for a policy
 Sid (Statement ID)
 Notprincipal (Effect: Allow with Notprincipal allows access to
anonymous (unauthenticated) uses; try not to use Notprincipal)
 Notaction
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": “Allow or Deny",
"Action": “some API action:*”,
“Resource": “some resource",
"Condition": {
“Key”: “Value”
}
}
]
}
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "ec2:*",
“Resource": "*",
"Condition": {
"StringEquals": { "ec2:ResourceTag/Project" : "Blue"
}
}
}
]
}
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "ec2:*",
"Resource": "*"
},
{
"Effect": "Deny",
"Action": "ec2:RunInstances",
"Resource": “arn:aws:ec2:*:123456789012:instance/*",
"Condition": {
"StringNotLikeIfExists": {
"ec2:InstanceType": [
"t2.*"
]
}
}
}
]
}
{
"Version": "2012-10-17",
"Statement": [
{
"Action": ["s3:ListBucket"],
"Effect": "Allow",
"Resource": ["arn:aws:s3:::mybucket"],
"Condition": {"StringLike": {"s3:prefix": ["${aws:username}/*"]}}
},
{
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Effect": "Allow",
"Resource": ["arn:aws:s3:::mybucket/${aws:username}/*"]
}
]
}
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:ListAllMyBuckets",
"s3:GetBucketLocation"
],
"Resource": "arn:aws:s3:::*"
},
{
"Effect": "Allow",
"Action": "s3:ListBucket",
"Resource": "arn:aws:s3:::<BUCKET-NAME>",
"Condition": {"StringLike": {"s3:prefix": [
"",
"home/",
"home/${aws:username}/*"
]}}
},
{
"Effect": "Allow",
"Action": "s3:*",
"Resource": [
"arn:aws:s3:::<BUCKET-NAME>/home/${aws:username}",
"arn:aws:s3:::<BUCKET-NAME>/home/${aws:username}/*"
]
}
]
}
 Log into your account -> Click User Name in navigation bar of the console
 Click Security Credentials
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "iam:GetAccountPasswordPolicy",
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "iam:ChangePassword",
"Resource": "arn:aws:iam::account-id-without-
hyphens:user/${aws:username}"
}
]
}
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:ListAllMyBuckets",
"s3:GetBucketLocation"
],
"Resource": "arn:aws:s3:::*"
},
{
"Effect": "Allow",
"Action": "s3:ListBucket",
"Resource": "arn:aws:s3:::BUCKET-NAME",
"Condition": {"StringLike": {"s3:prefix": [
"",
"home/",
"home/${aws:username}/"
]}}
},
{
"Effect": "Allow",
"Action": "s3:*",
"Resource": [
"arn:aws:s3:::BUCKET-NAME/home/${aws:username}",
"arn:aws:s3:::BUCKET-NAME/home/${aws:username}/*"
]
}
]
}
{
"Version": "2012-10-17",
"Statement":[{
"Effect":"Allow",
"Action":["ec2:RunInstances",
"ec2:StopInstances",
"ec2:StartInstances",
"ec2:TerminateInstances",
"ec2:Describe*"],
"Resource":"*"
},
{
"Effect":"Deny",
"NotAction":["ec2:RunInstances",
"ec2:StopInstances",
"ec2:StartInstances",
"ec2:TerminateInstances",
"ec2:Describe*"],
"Resource":"*"
}
]
}
 Write a policy granting minimal set of permissions
 Let default ‘Deny’ prevent access to everything else
 Create a test user
 Attach the policy to the test user
 Make API / CLI calls as the test user with Dry Run option
 Confirm that policy works as intended
 If errors out, use AWS STS Encoded Authorization Message API to
decode the error
 Tweak the policy
 Iterate
 An AWS identity with permission policies that determine what the
identity can and cannot do in AWS.
 Temporary privilege escalation
 Enable users to perform a task that they normally would not be able
to do (kind of like ‘sudo’ command)
 A user can only assume one Role at a time
 Roles can be passed to EC2 Instances
 Credentials passed through a role have pre-set expiration times
 Reduced the surface area of attack
 Temporary authentication credentials
 Auditable activity
 Automatically generated authentication credentials
 Limited privilege
 Any process or user running on the EC2 instance with access to the
instance metadata can access the credentials
 Instances with Role need to implement their own access control
measures if users will be logging into the instances
 Ask yourself: Do users need to log into the instances?
 After you create a role and grant your user permissions to switch to it,
you must provide the user with the role name and the account ID
number or account alias that contains the role. You can make things
easier for your users by sending them a link that is preconfigured with
the account ID and role name.
 You can see the role link on the final page of the Create Role wizard
or in the Role Summary page for any cross-account enabled role.
https://signin.aws.amazon.com/switchrole?account=YourAccountIDor
AliasHere&roleName=pathIfAny/YourRoleNameHere
 http://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail-
integration.html
 http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_ev
aluation-logic.html
 http://docs.aws.amazon.com/AmazonS3/latest/dev/s3-arn-format.html
 http://docs.aws.amazon.com/cli/latest/userguide/generate-cli-
skeleton.html
 http://docs.aws.amazon.com/sdk-for-javascript/v2/developer-
guide/working-with-json.html
 http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_ele
ments.html

More Related Content

What's hot

Containers and the Evolution of Computing
Containers and the Evolution of ComputingContainers and the Evolution of Computing
Containers and the Evolution of ComputingAmazon Web Services
 
Best Practices of IoT in the Cloud
Best Practices of IoT in the CloudBest Practices of IoT in the Cloud
Best Practices of IoT in the CloudAmazon Web Services
 
(DVO304) AWS CloudFormation Best Practices
(DVO304) AWS CloudFormation Best Practices(DVO304) AWS CloudFormation Best Practices
(DVO304) AWS CloudFormation Best PracticesAmazon Web Services
 
Zero to Sixty: AWS Elastic Beanstalk (DMG204) | AWS re:Invent 2013
Zero to Sixty: AWS Elastic Beanstalk (DMG204) | AWS re:Invent 2013Zero to Sixty: AWS Elastic Beanstalk (DMG204) | AWS re:Invent 2013
Zero to Sixty: AWS Elastic Beanstalk (DMG204) | AWS re:Invent 2013Amazon Web Services
 
AWS CloudTrail to Track AWS Resources in Your Account (SEC207) | AWS re:Inven...
AWS CloudTrail to Track AWS Resources in Your Account (SEC207) | AWS re:Inven...AWS CloudTrail to Track AWS Resources in Your Account (SEC207) | AWS re:Inven...
AWS CloudTrail to Track AWS Resources in Your Account (SEC207) | AWS re:Inven...Amazon Web Services
 
Mastering the AWS SDK for PHP (TLS306) | AWS re:Invent 2013
Mastering the AWS SDK for PHP (TLS306) | AWS re:Invent 2013Mastering the AWS SDK for PHP (TLS306) | AWS re:Invent 2013
Mastering the AWS SDK for PHP (TLS306) | AWS re:Invent 2013Amazon Web Services
 
(SEC302) Delegating Access to Your AWS Environment | AWS re:Invent 2014
(SEC302) Delegating Access to Your AWS Environment | AWS re:Invent 2014(SEC302) Delegating Access to Your AWS Environment | AWS re:Invent 2014
(SEC302) Delegating Access to Your AWS Environment | AWS re:Invent 2014Amazon Web Services
 
Log Analytics with Amazon Elasticsearch Service - September Webinar Series
Log Analytics with Amazon Elasticsearch Service - September Webinar SeriesLog Analytics with Amazon Elasticsearch Service - September Webinar Series
Log Analytics with Amazon Elasticsearch Service - September Webinar SeriesAmazon Web Services
 
DevOps for the Enterprise: Automated Testing and Monitoring
DevOps for the Enterprise: Automated Testing and Monitoring DevOps for the Enterprise: Automated Testing and Monitoring
DevOps for the Enterprise: Automated Testing and Monitoring Amazon Web Services
 
Deep Dive: Infrastructure as Code
Deep Dive: Infrastructure as CodeDeep Dive: Infrastructure as Code
Deep Dive: Infrastructure as CodeAmazon Web Services
 
AWS APAC Webinar Week - Securing Your Business on AWS
AWS APAC Webinar Week - Securing Your Business on AWSAWS APAC Webinar Week - Securing Your Business on AWS
AWS APAC Webinar Week - Securing Your Business on AWSAmazon Web Services
 
(SEC202) Closing the Gap: Moving Critical, Regulated Workloads to AWS | AWS r...
(SEC202) Closing the Gap: Moving Critical, Regulated Workloads to AWS | AWS r...(SEC202) Closing the Gap: Moving Critical, Regulated Workloads to AWS | AWS r...
(SEC202) Closing the Gap: Moving Critical, Regulated Workloads to AWS | AWS r...Amazon Web Services
 
AWS March 2016 Webinar Series - Best Practices for Managing Security Operatio...
AWS March 2016 Webinar Series - Best Practices for Managing Security Operatio...AWS March 2016 Webinar Series - Best Practices for Managing Security Operatio...
AWS March 2016 Webinar Series - Best Practices for Managing Security Operatio...Amazon Web Services
 
SEC302 Delegating Access to Your AWS Environment - AWS re: Invent 2012
SEC302 Delegating Access to Your AWS Environment - AWS re: Invent 2012SEC302 Delegating Access to Your AWS Environment - AWS re: Invent 2012
SEC302 Delegating Access to Your AWS Environment - AWS re: Invent 2012Amazon Web Services
 
Making connected apps with BaaS (Droidcon Bangalore 2014)
Making connected apps with BaaS (Droidcon Bangalore 2014)Making connected apps with BaaS (Droidcon Bangalore 2014)
Making connected apps with BaaS (Droidcon Bangalore 2014)Varun Torka
 
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...Amazon Web Services
 
Becoming an AWS Policy Ninja using AWS IAM - AWS Summit Tel Aviv 2017
Becoming an AWS Policy Ninja using AWS IAM - AWS Summit Tel Aviv 2017Becoming an AWS Policy Ninja using AWS IAM - AWS Summit Tel Aviv 2017
Becoming an AWS Policy Ninja using AWS IAM - AWS Summit Tel Aviv 2017Amazon Web Services
 
Aws iam best practices to live by
Aws iam best practices to live byAws iam best practices to live by
Aws iam best practices to live byJohn Varghese
 
Transparency and Auditing on AWS
Transparency and Auditing on AWSTransparency and Auditing on AWS
Transparency and Auditing on AWSAmazon Web Services
 

What's hot (20)

Containers and the Evolution of Computing
Containers and the Evolution of ComputingContainers and the Evolution of Computing
Containers and the Evolution of Computing
 
Best Practices of IoT in the Cloud
Best Practices of IoT in the CloudBest Practices of IoT in the Cloud
Best Practices of IoT in the Cloud
 
(DVO304) AWS CloudFormation Best Practices
(DVO304) AWS CloudFormation Best Practices(DVO304) AWS CloudFormation Best Practices
(DVO304) AWS CloudFormation Best Practices
 
Zero to Sixty: AWS Elastic Beanstalk (DMG204) | AWS re:Invent 2013
Zero to Sixty: AWS Elastic Beanstalk (DMG204) | AWS re:Invent 2013Zero to Sixty: AWS Elastic Beanstalk (DMG204) | AWS re:Invent 2013
Zero to Sixty: AWS Elastic Beanstalk (DMG204) | AWS re:Invent 2013
 
AWS CloudTrail to Track AWS Resources in Your Account (SEC207) | AWS re:Inven...
AWS CloudTrail to Track AWS Resources in Your Account (SEC207) | AWS re:Inven...AWS CloudTrail to Track AWS Resources in Your Account (SEC207) | AWS re:Inven...
AWS CloudTrail to Track AWS Resources in Your Account (SEC207) | AWS re:Inven...
 
Mastering the AWS SDK for PHP (TLS306) | AWS re:Invent 2013
Mastering the AWS SDK for PHP (TLS306) | AWS re:Invent 2013Mastering the AWS SDK for PHP (TLS306) | AWS re:Invent 2013
Mastering the AWS SDK for PHP (TLS306) | AWS re:Invent 2013
 
(SEC302) Delegating Access to Your AWS Environment | AWS re:Invent 2014
(SEC302) Delegating Access to Your AWS Environment | AWS re:Invent 2014(SEC302) Delegating Access to Your AWS Environment | AWS re:Invent 2014
(SEC302) Delegating Access to Your AWS Environment | AWS re:Invent 2014
 
Log Analytics with Amazon Elasticsearch Service - September Webinar Series
Log Analytics with Amazon Elasticsearch Service - September Webinar SeriesLog Analytics with Amazon Elasticsearch Service - September Webinar Series
Log Analytics with Amazon Elasticsearch Service - September Webinar Series
 
DevOps for the Enterprise: Automated Testing and Monitoring
DevOps for the Enterprise: Automated Testing and Monitoring DevOps for the Enterprise: Automated Testing and Monitoring
DevOps for the Enterprise: Automated Testing and Monitoring
 
Become an IAM Policy Ninja
Become an IAM Policy NinjaBecome an IAM Policy Ninja
Become an IAM Policy Ninja
 
Deep Dive: Infrastructure as Code
Deep Dive: Infrastructure as CodeDeep Dive: Infrastructure as Code
Deep Dive: Infrastructure as Code
 
AWS APAC Webinar Week - Securing Your Business on AWS
AWS APAC Webinar Week - Securing Your Business on AWSAWS APAC Webinar Week - Securing Your Business on AWS
AWS APAC Webinar Week - Securing Your Business on AWS
 
(SEC202) Closing the Gap: Moving Critical, Regulated Workloads to AWS | AWS r...
(SEC202) Closing the Gap: Moving Critical, Regulated Workloads to AWS | AWS r...(SEC202) Closing the Gap: Moving Critical, Regulated Workloads to AWS | AWS r...
(SEC202) Closing the Gap: Moving Critical, Regulated Workloads to AWS | AWS r...
 
AWS March 2016 Webinar Series - Best Practices for Managing Security Operatio...
AWS March 2016 Webinar Series - Best Practices for Managing Security Operatio...AWS March 2016 Webinar Series - Best Practices for Managing Security Operatio...
AWS March 2016 Webinar Series - Best Practices for Managing Security Operatio...
 
SEC302 Delegating Access to Your AWS Environment - AWS re: Invent 2012
SEC302 Delegating Access to Your AWS Environment - AWS re: Invent 2012SEC302 Delegating Access to Your AWS Environment - AWS re: Invent 2012
SEC302 Delegating Access to Your AWS Environment - AWS re: Invent 2012
 
Making connected apps with BaaS (Droidcon Bangalore 2014)
Making connected apps with BaaS (Droidcon Bangalore 2014)Making connected apps with BaaS (Droidcon Bangalore 2014)
Making connected apps with BaaS (Droidcon Bangalore 2014)
 
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
(DEV306) Building Cross-Platform Applications Using the AWS SDK for JavaScrip...
 
Becoming an AWS Policy Ninja using AWS IAM - AWS Summit Tel Aviv 2017
Becoming an AWS Policy Ninja using AWS IAM - AWS Summit Tel Aviv 2017Becoming an AWS Policy Ninja using AWS IAM - AWS Summit Tel Aviv 2017
Becoming an AWS Policy Ninja using AWS IAM - AWS Summit Tel Aviv 2017
 
Aws iam best practices to live by
Aws iam best practices to live byAws iam best practices to live by
Aws iam best practices to live by
 
Transparency and Auditing on AWS
Transparency and Auditing on AWSTransparency and Auditing on AWS
Transparency and Auditing on AWS
 

Similar to best aws training in bangalore

(SEC309) Amazon VPC Configuration: When Least Privilege Meets the Penetration...
(SEC309) Amazon VPC Configuration: When Least Privilege Meets the Penetration...(SEC309) Amazon VPC Configuration: When Least Privilege Meets the Penetration...
(SEC309) Amazon VPC Configuration: When Least Privilege Meets the Penetration...Amazon Web Services
 
Windsor AWS UG Deep dive IAM 2 - no json101
Windsor AWS UG   Deep dive IAM 2 - no json101Windsor AWS UG   Deep dive IAM 2 - no json101
Windsor AWS UG Deep dive IAM 2 - no json101Goran Karmisevic
 
AWS IAM policies in plain english
AWS IAM policies in plain english AWS IAM policies in plain english
AWS IAM policies in plain english Bogdan Naydenov
 
Mastering Access Control Policies
Mastering Access Control PoliciesMastering Access Control Policies
Mastering Access Control PoliciesAmazon Web Services
 
(SEC305) How to Become an IAM Policy Ninja in 60 Minutes or Less
(SEC305) How to Become an IAM Policy Ninja in 60 Minutes or Less(SEC305) How to Become an IAM Policy Ninja in 60 Minutes or Less
(SEC305) How to Become an IAM Policy Ninja in 60 Minutes or LessAmazon Web Services
 
Amazon Web Services Security
Amazon Web Services SecurityAmazon Web Services Security
Amazon Web Services SecurityJason Chan
 
Mastering Access Control Policies (SEC302) | AWS re:Invent 2013
Mastering Access Control Policies (SEC302) | AWS re:Invent 2013Mastering Access Control Policies (SEC302) | AWS re:Invent 2013
Mastering Access Control Policies (SEC302) | AWS re:Invent 2013Amazon Web Services
 
Best Practices for Managing Security Operations in AWS - AWS July 2016 Webina...
Best Practices for Managing Security Operations in AWS - AWS July 2016 Webina...Best Practices for Managing Security Operations in AWS - AWS July 2016 Webina...
Best Practices for Managing Security Operations in AWS - AWS July 2016 Webina...Amazon Web Services
 
AWS Incident Response Cheat Sheet.pdf
AWS Incident Response Cheat Sheet.pdfAWS Incident Response Cheat Sheet.pdf
AWS Incident Response Cheat Sheet.pdfChristopher Doman
 
Detective Controls: Gain Visibility and Record Change:
Detective Controls: Gain Visibility and Record Change: Detective Controls: Gain Visibility and Record Change:
Detective Controls: Gain Visibility and Record Change: Amazon Web Services
 
AWS Identity and Access Management and Consolidated Billing
AWS Identity and Access Management and Consolidated BillingAWS Identity and Access Management and Consolidated Billing
AWS Identity and Access Management and Consolidated BillingAmazon Web Services
 
The Future of Securing Access Controls in Information Security
The Future of Securing Access Controls in Information SecurityThe Future of Securing Access Controls in Information Security
The Future of Securing Access Controls in Information SecurityAmazon Web Services
 
Detective Controls: Gain Visibility and Record Change
Detective Controls: Gain Visibility and Record ChangeDetective Controls: Gain Visibility and Record Change
Detective Controls: Gain Visibility and Record ChangeAmazon Web Services
 
Deep Dive into AWS SAM: re:Invent 2018 Recap at the AWS Loft - San Francisco
Deep Dive into AWS SAM: re:Invent 2018 Recap at the AWS Loft - San FranciscoDeep Dive into AWS SAM: re:Invent 2018 Recap at the AWS Loft - San Francisco
Deep Dive into AWS SAM: re:Invent 2018 Recap at the AWS Loft - San FranciscoAmazon Web Services
 

Similar to best aws training in bangalore (20)

(SEC309) Amazon VPC Configuration: When Least Privilege Meets the Penetration...
(SEC309) Amazon VPC Configuration: When Least Privilege Meets the Penetration...(SEC309) Amazon VPC Configuration: When Least Privilege Meets the Penetration...
(SEC309) Amazon VPC Configuration: When Least Privilege Meets the Penetration...
 
Windsor AWS UG Deep dive IAM 2 - no json101
Windsor AWS UG   Deep dive IAM 2 - no json101Windsor AWS UG   Deep dive IAM 2 - no json101
Windsor AWS UG Deep dive IAM 2 - no json101
 
AWS IAM policies in plain english
AWS IAM policies in plain english AWS IAM policies in plain english
AWS IAM policies in plain english
 
Mastering Access Control Policies
Mastering Access Control PoliciesMastering Access Control Policies
Mastering Access Control Policies
 
(SEC305) How to Become an IAM Policy Ninja in 60 Minutes or Less
(SEC305) How to Become an IAM Policy Ninja in 60 Minutes or Less(SEC305) How to Become an IAM Policy Ninja in 60 Minutes or Less
(SEC305) How to Become an IAM Policy Ninja in 60 Minutes or Less
 
Amazon Web Services Security
Amazon Web Services SecurityAmazon Web Services Security
Amazon Web Services Security
 
Policy Ninja
Policy NinjaPolicy Ninja
Policy Ninja
 
Mastering Access Control Policies (SEC302) | AWS re:Invent 2013
Mastering Access Control Policies (SEC302) | AWS re:Invent 2013Mastering Access Control Policies (SEC302) | AWS re:Invent 2013
Mastering Access Control Policies (SEC302) | AWS re:Invent 2013
 
SID314_IAM Policy Ninja
SID314_IAM Policy NinjaSID314_IAM Policy Ninja
SID314_IAM Policy Ninja
 
Policy Ninja
Policy NinjaPolicy Ninja
Policy Ninja
 
Masting Access Control Policies
Masting Access Control PoliciesMasting Access Control Policies
Masting Access Control Policies
 
Best Practices for Managing Security Operations in AWS - AWS July 2016 Webina...
Best Practices for Managing Security Operations in AWS - AWS July 2016 Webina...Best Practices for Managing Security Operations in AWS - AWS July 2016 Webina...
Best Practices for Managing Security Operations in AWS - AWS July 2016 Webina...
 
AWS Incident Response Cheat Sheet.pdf
AWS Incident Response Cheat Sheet.pdfAWS Incident Response Cheat Sheet.pdf
AWS Incident Response Cheat Sheet.pdf
 
Detective Controls: Gain Visibility and Record Change:
Detective Controls: Gain Visibility and Record Change: Detective Controls: Gain Visibility and Record Change:
Detective Controls: Gain Visibility and Record Change:
 
AWS Identity and Access Management and Consolidated Billing
AWS Identity and Access Management and Consolidated BillingAWS Identity and Access Management and Consolidated Billing
AWS Identity and Access Management and Consolidated Billing
 
The Future of Securing Access Controls in Information Security
The Future of Securing Access Controls in Information SecurityThe Future of Securing Access Controls in Information Security
The Future of Securing Access Controls in Information Security
 
Detective Controls: Gain Visibility and Record Change
Detective Controls: Gain Visibility and Record ChangeDetective Controls: Gain Visibility and Record Change
Detective Controls: Gain Visibility and Record Change
 
Deep Dive into AWS SAM: re:Invent 2018 Recap at the AWS Loft - San Francisco
Deep Dive into AWS SAM: re:Invent 2018 Recap at the AWS Loft - San FranciscoDeep Dive into AWS SAM: re:Invent 2018 Recap at the AWS Loft - San Francisco
Deep Dive into AWS SAM: re:Invent 2018 Recap at the AWS Loft - San Francisco
 
Deep Dive into AWS SAM
Deep Dive into AWS SAMDeep Dive into AWS SAM
Deep Dive into AWS SAM
 
Becoming an IAM Policy Ninja
Becoming an IAM Policy NinjaBecoming an IAM Policy Ninja
Becoming an IAM Policy Ninja
 

Recently uploaded

Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxAnaBeatriceAblay2
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application ) Sakshi Ghasle
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting DataJhengPantaleon
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxsocialsciencegdgrohi
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsanshu789521
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfakmcokerachita
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Celine George
 

Recently uploaded (20)

Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application )
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha elections
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdf
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Staff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSDStaff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSD
 
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
 

best aws training in bangalore

  • 1.
  • 2.  VPC (Virtual Private Cloud)  Build a most commonly used network architecture with a CloudFormation Template  Entire Data Centre Networking Infrastructure in <20min
  • 3.  AWS Organizations  Architecting Governance and Security with multi-account strategy  Immutable Architecture  Security Control Policies: BL / WL
  • 4. Master Account InfoSec Account {"Version":"2012-10- 17","Statement":[{"Effect":"Allow","Action":"*","R esource":"*"}]} { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Principal": { "AWS": “arn:aws:iam::111111111111:root" }, "Action": "sts:AssumeRole" } ] } { "Version": "2012-10-17", "Statement": [ { "Sid": "Stmt1499879069000", "Effect": "Allow", "Action": [ "sts:AssumeRole" ], "Resource": [ “arn:aws:iam::222222222222:role/OrganizationAccountAccess Role-InfoSec" ] } ] } Trusting AccountTrusted Account InfoSec Admin Group 1111-1111-1111 2222-2222-2222 OrganizationAccountAccessRole-InfoSec Access Policy Trust PolicyInline Policy Attached to a Group
  • 6.  Enables us to control who can do what in our AWS account  Secure (deny) by default  Global service
  • 7.  https://alias.signin.aws.amazon.com/console ( redirected to a regional sign-in endpoint such as https://us-east- 2.signin.aws.amazon.com, resulting in a regional CloudTrail log entry in the user's region's log )  https://alias.signin.aws.amazon.com/console/s3 ( AWS redirects you to the global sign-in endpoint at https://signin.aws.amazon.com, resulting in a global CloudTrail log entry )  https://alias.signin.aws.amazon.com/console/ec2?region=ca- central-1 (results in a CloudTrail log event in that region)
  • 8.
  • 9.
  • 10.  Create individual users  Grant least privilege  Manage permissions with groups  Restrict privileged access further with conditions  Enable AWS CloudTrail to get logs of API calls  Configure a strong password policy  Rotate security credentials regularly.  Enable MFA for privileged users  Use IAM roles to share access  Use IAM roles for Amazon EC2 instances  Reduce or remove use of root https://www.slideshare.net/AmazonWebServices/sec302-iam-best-practices-to-live-by
  • 11.  A policy is a document that contains one or more permissions.  Each permission describes actions that are allowed or not allowed  Written in JSON  User Based or Resource Based  Managed Policies and Inline Policies  Managed Policies:  AWS managed policies  Customer managed policies  Managed Policies feature:  Reusability  Central change management  Versioning and rolling back  Delegating permissions management  Automatic updates for AWS managed policies  Inline Policies feature:  Embedded into user/group/role  Strict one to one relationship between a policy and the principal entity that it’s attached  What happens to a inline policy when we delete a principal entity that it’s attached to?
  • 12. Requests that are made by the AWS account root user are allowed for resources in that account. IAM user in an account that is in an organization can use the intersection of the permissions allowed by both Organizations SCPs and by the IAM permission policies
  • 13.  Attached to a User, Group, or Role  Policies DO NOT specify a Principal (User/Group/Role); it is implied
  • 14.  Attached to a resource such as S3 Bucket or DynamoDB Table  Policies DO specify a Principal (User/Group/Role)  Policy describes what access is assigned to the principal
  • 15.  Allows us to treat resources as a unit (i.e. project  Allows us to autmatically enforce permissions when new resources are created  Supported services: EC2,VPC, EBS, RDS, SWS, Data Pipeline
  • 16. Amazon Resource Names (ARNs) uniquely identify AWS resources. We require an ARN when you need to specify a resource unambiguously across all of AWS, such as in IAM policies, Amazon Relational Database Service (Amazon RDS) tags, and API calls. The following is the common Amazon Resource Name (ARN) format to identify any resources in AWS. arn:partition:service:region:namespace:relative-id General formats for ARNs; the specific components and values used depend on the AWS service. arn:partition:service:region:account-id:resource arn:partition:service:region:account-id:resourcetype/resource arn:partition:service:region:account-id:resourcetype:resource  <!-- Elastic Beanstalk application version -->  arn:aws:elasticbeanstalk:us-east-1:123456789012:environment/My App/MyEnvironment  <!-- IAM user name —>  arn:aws:iam::123456789012:user/David   <!-- Amazon RDS instance used for tagging -->  arn:aws:rds:eu-west-1:123456789012:db:mysql-db   <!-- Object in an Amazon S3 bucket -->  arn:aws:s3:::my_corporate_bucket/exampleobject.png   Paths in ARNs  arn:aws:iam::123456789012:user/Development/product_1234/*  "Resource":"arn:aws:iam::123456789012:user/*"  "Resource":"arn:aws:iam::123456789012:group/*"   http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html#arn-syntax-rds
  • 17.  arn:aws:s3:::bucket_name  arn:aws:s3:::bucket_name/key_name  arn:aws:s3:::examplebucket/developers/design_info.doc  arn:aws:s3:::examplebucket/*  arn:aws:s3:::example?bucket/*  arn:aws:s3:::bucket_name/developers/${aws:username}/
  • 18. AWS assigns two unique IDs to each AWS account:  An AWS account ID (123456789012)  A canonical user ID - an obfuscated form of the AWS account ID (79a59df900b949665d96a1e698fbacedfd6e09d98eacf8f8d5218e7cd47ef2b e)
  • 19.  You cannot use a wildcard to specify all users in the Principal element in a resource-based policy or a role trust policy.  You cannot use groups as principals in any policy.  You can use wildcard characters (* and ?) within any ARN segment  You can specify user/* to mean all users or group/* to mean all groups
  • 20.  Effect - Required - specifies statements result is “Allow” or “Deny  Principal - Required for Resource Policies only  Action - Required - An AWS Service “Action” that statement applies to  Resource - Required - An AWS object (ARN) that statement applies to.  Condition - Optional
  • 21.  Version policy element defines the version of the policy language  Statement policy element is the main element for a policy  Sid (Statement ID)  Notprincipal (Effect: Allow with Notprincipal allows access to anonymous (unauthenticated) uses; try not to use Notprincipal)  Notaction
  • 22. { "Version": "2012-10-17", "Statement": [ { "Effect": “Allow or Deny", "Action": “some API action:*”, “Resource": “some resource", "Condition": { “Key”: “Value” } } ] }
  • 23. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": "ec2:*", “Resource": "*", "Condition": { "StringEquals": { "ec2:ResourceTag/Project" : "Blue" } } } ] }
  • 24. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": "ec2:*", "Resource": "*" }, { "Effect": "Deny", "Action": "ec2:RunInstances", "Resource": “arn:aws:ec2:*:123456789012:instance/*", "Condition": { "StringNotLikeIfExists": { "ec2:InstanceType": [ "t2.*" ] } } } ] }
  • 25. { "Version": "2012-10-17", "Statement": [ { "Action": ["s3:ListBucket"], "Effect": "Allow", "Resource": ["arn:aws:s3:::mybucket"], "Condition": {"StringLike": {"s3:prefix": ["${aws:username}/*"]}} }, { "Action": [ "s3:GetObject", "s3:PutObject" ], "Effect": "Allow", "Resource": ["arn:aws:s3:::mybucket/${aws:username}/*"] } ] }
  • 26. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "s3:ListAllMyBuckets", "s3:GetBucketLocation" ], "Resource": "arn:aws:s3:::*" }, { "Effect": "Allow", "Action": "s3:ListBucket", "Resource": "arn:aws:s3:::<BUCKET-NAME>", "Condition": {"StringLike": {"s3:prefix": [ "", "home/", "home/${aws:username}/*" ]}} }, { "Effect": "Allow", "Action": "s3:*", "Resource": [ "arn:aws:s3:::<BUCKET-NAME>/home/${aws:username}", "arn:aws:s3:::<BUCKET-NAME>/home/${aws:username}/*" ] } ] }
  • 27.  Log into your account -> Click User Name in navigation bar of the console  Click Security Credentials { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": "iam:GetAccountPasswordPolicy", "Resource": "*" }, { "Effect": "Allow", "Action": "iam:ChangePassword", "Resource": "arn:aws:iam::account-id-without- hyphens:user/${aws:username}" } ] }
  • 28. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "s3:ListAllMyBuckets", "s3:GetBucketLocation" ], "Resource": "arn:aws:s3:::*" }, { "Effect": "Allow", "Action": "s3:ListBucket", "Resource": "arn:aws:s3:::BUCKET-NAME", "Condition": {"StringLike": {"s3:prefix": [ "", "home/", "home/${aws:username}/" ]}} }, { "Effect": "Allow", "Action": "s3:*", "Resource": [ "arn:aws:s3:::BUCKET-NAME/home/${aws:username}", "arn:aws:s3:::BUCKET-NAME/home/${aws:username}/*" ] } ] }
  • 30.  Write a policy granting minimal set of permissions  Let default ‘Deny’ prevent access to everything else  Create a test user  Attach the policy to the test user  Make API / CLI calls as the test user with Dry Run option  Confirm that policy works as intended  If errors out, use AWS STS Encoded Authorization Message API to decode the error  Tweak the policy  Iterate
  • 31.  An AWS identity with permission policies that determine what the identity can and cannot do in AWS.  Temporary privilege escalation  Enable users to perform a task that they normally would not be able to do (kind of like ‘sudo’ command)  A user can only assume one Role at a time  Roles can be passed to EC2 Instances  Credentials passed through a role have pre-set expiration times
  • 32.  Reduced the surface area of attack  Temporary authentication credentials  Auditable activity  Automatically generated authentication credentials  Limited privilege
  • 33.  Any process or user running on the EC2 instance with access to the instance metadata can access the credentials  Instances with Role need to implement their own access control measures if users will be logging into the instances  Ask yourself: Do users need to log into the instances?
  • 34.  After you create a role and grant your user permissions to switch to it, you must provide the user with the role name and the account ID number or account alias that contains the role. You can make things easier for your users by sending them a link that is preconfigured with the account ID and role name.  You can see the role link on the final page of the Create Role wizard or in the Role Summary page for any cross-account enabled role. https://signin.aws.amazon.com/switchrole?account=YourAccountIDor AliasHere&roleName=pathIfAny/YourRoleNameHere
  • 35.  http://docs.aws.amazon.com/IAM/latest/UserGuide/cloudtrail- integration.html  http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_ev aluation-logic.html  http://docs.aws.amazon.com/AmazonS3/latest/dev/s3-arn-format.html  http://docs.aws.amazon.com/cli/latest/userguide/generate-cli- skeleton.html  http://docs.aws.amazon.com/sdk-for-javascript/v2/developer- guide/working-with-json.html  http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_ele ments.html

Editor's Notes

  1. We’ll talk at AP level which equally applies to the actions in the console, CLI, or SDK. We’ll look at permissions needed for programmatic access and permissions required for the AWS console access. Frequent anti-pattern is to create a user and then bake user’s credentials in application so that application can access them (for example, in a file, Windows registry etc). Credentials are stored in source repos and never rotated. Is there an easy way to avoid the madness of hard-coded credentials??
  2. AWS Organizations service creates InfoSec Account and “OrganizationAccountAccessRole-InfoSec” role in the new SecInfo account. Admin in Master Account grants a group permission to call “OrganizationAccountAccessRole-SecInfo” role A user in Master Account requests access to the role STS returns roles credentials User switches role and becomes administrator in SecInfo Account When you create a role for cross-account access, you establish trust from the account that owns the role and the resources (trusting account) to the account that contains the users (trusted account). To do this, you specify the trusted account number as the Principal in the role's trust policy. That allows potentially any user in the trusted account to assume the role. To complete the configuration, the administrator of the trusted account must give specific groups or users in that account permission to switch to the role.
  3. IAM evaluates policies at run time
  4. Also can use account ID instead of alias
  5. Create a new account. Record account # and role name. Create an OU Move newly created account into the new OU. Create a new SCP and attach it to a new OU Create a group. Assign cloud_admin user to the group. Create an inline policy that allows the user to assume the role Demonstrate switching roles
  6. Inline - embedded into user/group /role; deleted with user/group/role; strict one to one relationship between a policy and the principal entity that it's attached
  7. Requests that are made by the AWS account root user are allowed for resources in that account. IAM user in an account that is in an organization can use the intersection of the permissions allowed by both Organizations SCPs and by the IAM permission policies
  8. http://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html  
  9. Partition: aws (or aws-cn in China) Service: s3 Don't specify region and namespace for S3 global service Bucket-name or a bucket-name/object-key or wild card  
  10. ou can also use the Amazon S3 ListBuckets API to return the canonical user ID. For more information, see GET Service Response Elements in the Amazon Simple Storage Service API Reference.
  11. We recommend that you set the Version element to 2012-10-17 for all policies.
  12. curl http://169.254.169.254/latest/meta-data/iam/security-credentials/myRole-S3-EC2 curl http://169.254.169.254/latest/meta-data/ <-must have slash Run - launch Start - starts stopped instance
  13. Programmatically access home folder http://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_variables.html
  14. Programmatically and in the Console
  15. a role does not have any credentials (password or access keys) associated with it. Instead, if a user is assigned to a role, access keys are created dynamically and provided to the user. Note that you can switch roles only when you sign in as an IAM user. You cannot switch roles when you sign in as the AWS account root user. • When you switch roles in the AWS Management Console, the console always uses your original credentials to authorize the switch. This applies whether you sign in as an IAM user, as a SAML-federated role, or as a web-identity federated role. For example, if you switch to RoleA, it uses your original user or federated role credentials to determine if you are allowed to assume RoleA. If you then try to switch to RoleB while you are using RoleA, it still uses your original user or federated role credentials to authorize your attempt to switch to RoleB, not the credentials for RoleA.