Module 4
Module 4
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Module overview
Topics Activities
• AWS shared responsibility model • AWS shared responsibility model activity
• AWS Identity and Access Management (IAM)
• Securing a new AWS account Demo
• Securing accounts • Recorded demonstration of IAM
• Securing data on AWS
• Working to ensure compliance
Lab
• Introduction to AWS IAM
Knowledge check
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 2
Module objectives
After completing this module, you should be able to:
• Recognize the shared responsibility model
• Identify the responsibility of the customer and AWS
• Recognize IAM users, groups, and roles
• Describe different types of security credentials in IAM
• Identify the steps to securing a new AWS account
• Explore IAM users and groups
• Recognize how to secure AWS data
• Recognize AWS compliance programs
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 3
Section 1: AWS shared responsibility
model
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS shared responsibility model
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 5
AWS responsibility: Security of the cloud
AWS responsibilities:
• Physical security of data centers
• Controlled, need-based access
AWS services
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 6
Customer responsibility: Security in the cloud
Customer responsibilities:
• Amazon Elastic Compute Cloud (Amazon
EC2) instance operating system
Customer data • Including patching, maintenance
• Applications
Applications, IAM • Passwords, role-based access, etc.
• Security group configuration
Operating system, network, and firewall configuration • OS or host-based firewalls
• Including intrusion detection or prevention
Network traffic systems
Client-side data Server-side
protection • Network configurations
encryption and encryption
(encryption, • Account management
data integrity (file system or
integrity,
authentication data) • Login and permission settings for each user
identity)
Customer-configurable
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 7
Service characteristics and security responsibility (1 of 2)
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 8
Service characteristics and security responsibility (2 of 2)
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 9
Activity: AWS
shared
responsibility
model
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 10
Activity: Scenario 1 of 2
Consider this deployment. Who is responsible – AWS or the customer?
AWS Cloud 1. Upgrades and patches to the 6. Oracle upgrades or patches
Virtual Private Cloud operating system on the EC2 If the Oracle instance runs
(VPC) instance? as an Amazon RDS instance?
2. Physical security of the data 7. Oracle upgrades or patches
center? If Oracle runs on an EC2
instance?
3. Virtualization infrastructure?
Amazon Simple Amazon Oracle 8. S3 bucket access
4. EC2 security group settings?
Storage Service EC2 instance configuration?
(Amazon S3) 5. Configuration of
applications that run on the
EC2 instance?
AWS Global Infrastructure
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 11
Activity: Scenario 1 of 2 Answers
Consider this deployment. Who is responsible – AWS or the customer?
AWS Cloud 1. Upgrades and patches to the 6. Oracle upgrades or patches
Virtual Private Cloud operating system on the EC2 If the Oracle instance runs
(VPC) instance? as an Amazon RDS instance?
• ANSWER: The customer • ANSWER: AWS
2. Physical security of the data 7. Oracle upgrades or patches
center? If Oracle runs on an EC2
Amazon Simple Amazon Oracle • ANSWER: AWS instance?
Storage Service EC2 instance • ANSWER: The customer
3. Virtualization infrastructure?
(Amazon S3) 8. S3 bucket access
• ANSWER: AWS
configuration?
AWS Global Infrastructure 4. EC2 security group settings? • ANSWER: The customer
• ANSWER: The customer
5. Configuration of
applications that run on the
EC2 instance?
• ANSWER: The customer
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 12
Activity: Scenario 2 of 2
Consider this deployment. Who is responsible – AWS or the customer?
Secure Shell
(SSH) keys 1. Ensuring that the AWS 6. Ensuring network isolation
Management Console is not between AWS customers'
AWS Command hacked? data?
AWS Line Interface 2. Configuring the subnet? 7. Ensuring low-latency
Management (AWS CLI) network connection between
Console 3. Configuring the VPC? the web server and the S3
Internet
gateway 4. Protecting against network bucket?
VPC
outages in AWS Regions? 8. Enforcing multi-factor
Subnet 5. Securing the SSH keys authentication for all user
logins?
Web server on
Amazon EC2
S3 bucket
with objects
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 13
Activity: Scenario 2 of 2 Answers
Consider this deployment. Who is responsible – AWS or the customer?
Secure Shell
(SSH) keys 1. Ensuring that the AWS 6. Ensuring network isolation
Management Console is not between AWS customers'
AWS Command hacked? data?
AWS Line Interface • ANSWER: AWS • ANSWER: AWS
Management (AWS CLI)
Console 2. Configuring the subnet? 7. Ensuring low-latency
Internet network connection between
• ANSWER: The customer
VPC gateway the web server and the S3
3. Configuring the VPC? bucket?
Subnet • ANSWER: The customer • ANSWER: AWS
4. Protecting against network 8. Enforcing multi-factor
outages in AWS Regions? authentication for all user
Web server on
• ANSWER: AWS logins?
Amazon EC2
• ANSWER: The customer
5. Securing the SSH keys
• ANSWER: The customer
S3 bucket
with objects
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 14
• AWS and the customer share security responsibilities:
Section 1 key • AWS is responsible for security of the cloud
takeaways • Customer is responsible for security in the cloud
• AWS is responsible for protecting the
infrastructure—including hardware, software, networking, and
facilities—that run AWS Cloud services
• For services that are categorized as infrastructure as a
service (IaaS), the customer is responsible for performing
necessary security configuration and management tasks
• For example, guest OS updates and security patches, firewall, security
group configurations
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 15
Section 2: AWS Identity and
Access Management (IAM)
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Identity and Access Management (IAM)
• Use IAM to manage access to AWS resources –
• A resource is an entity in an AWS account that you can work with
• Example resources; An Amazon EC2 instance or an Amazon S3 bucket
• Which resources can be accessed and what can the user do to the resource
• How resources can be accessed
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 18
Authenticate as an IAM user to gain access
When you define an IAM user, you select what types of access the user is permitted to use.
Programmatic access
• Authenticate using:
• Access key ID
• Secret access key AWS CLI AWS Tools
and SDKs
• Provides AWS CLI and AWS SDK access
Username and
password
MFA token
After the user or application is connected to the AWS account, what are they allowed to do?
EC2
Full
instances
acces
s
Read-
only S3 bucket
IAM user,
IAM group,
or IAM role
IAM policies
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 21
IAM: Authorization
• Assign permissions by creating an IAM policy.
Note: The scope of IAM service configurations is global. Settings apply across all AWS Regions.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 22
IAM policies
• An IAM policy is a document that defines permissions
• Enables fine-grained access control
• Two types of policies – identity-based and resource-based
• Identity-based policies – IAM entities
• Attach a policy to any IAM entity
• An IAM user, an IAM group, or an IAM role Attach to
IAM user
one of
• Policies specify:
• Actions that may be performed by the entity
IAM IAM group
• Actions that may not be performed by the entity policy
• A single policy can be attached to multiple entities
IAM role
• A single entity can have multiple policies attached to it
• Resource-based policies
• Attached to a resource (such as an S3 bucket)
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 23
IAM policy example
{
"Version": "2012-10-17", Explicit allow gives users access to a specific
"Statement":[{ DynamoDB table and…
"Effect":"Allow",
"Action":["DynamoDB:*","s3:*"],
"Resource":[
"arn:aws:dynamodb:region:account-number-without-hyphens:table/table-name",
"arn:aws:s3:::bucket-name",
"arn:aws:s3:::bucket-name/*"] …Amazon S3 buckets.
},
{ Explicit deny ensures that the users cannot use any other AWS
"Effect":"Deny", actions or resources other than that table and those buckets.
"Action":["dynamodb:*","s3:*"],
"NotResource":["arn:aws:dynamodb:region:account-number-without-hyphens:table/table-name”,
"arn:aws:s3:::bucket-name",
"arn:aws:s3:::bucket-name/*"]
}
] An explicit deny statement takes precedence
} over an allow statement.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 24
Resource-based policies
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 25
IAM permissions
How IAM determines permissions:
Implicit deny
Yes Yes
Deny Allow
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 26
IAM groups
• Permissions granted by attaching IAM policy Carlos Salazar Li Juan Zhang Wei
or policies to the group
Márcia Oliveira Mary Major John Stiles
• A user can belong to multiple groups
Richard Roe Li Juan
• There is no default group
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 27
IAM roles
• An IAM role is an IAM identity with specific permissions
• Similar to an IAM user
• Attach permissions policies to it
• Different from an IAM user IAM role
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 28
Example use of an IAM role
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 29
• IAM policies are constructed with JavaScript Object
Section 2 key Notation (JSON) and define permissions.
takeaways • IAM policies can be attached to any IAM entity.
• Entities are IAM users, IAM groups, and IAM roles.
• An IAM user provides a way for a person, application, or
service to authenticate to AWS.
• An IAM group is a simple way to attach the same
policies to multiple users.
• An IAM role can have permissions policies attached to it
and can be used to delegate temporary access to users
or applications.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 30
Recorded demo:
IAM
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 31
Section 3: Securing a new AWS
account
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS account root user access versus IAM access
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 34
Securing a new AWS account: MFA
Step 2: Enable multi-factor authentication (MFA).
• Require MFA for your account root user and for all IAM users.
• You can also use MFA to control access to AWS service APIs.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 36
Securing a new AWS account: Billing reports
Step 4: Enable a billing report, such as the AWS Cost and Usage Report.
• Billing reports provide information about your use of AWS resources and
estimated costs for that use.
• The AWS Cost and Usage Report tracks your AWS usage and provides estimated
charges associated with your AWS account, either by the hour or by the day.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 37
Optional: Securing a new AWS
account – Full walkthrough
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
IAM security status review
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 39
Activate MFA on the account root user
Custom
sign-in
link
MFA
activation
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 40
Activate MFA on account root user
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 41
MFA on account root user is activated
MFA MFA
activated
Setup
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 42
Create an individual IAM user (1 of 5)
IAM user
creation
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 43
Create an individual IAM user (2 of 5)
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 44
Create an individual IAM user (3 of 5)
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 45
Create an individual IAM user (4 of 5)
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 46
Create an individual IAM user (5 of 5)
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 47
IAM user creation successful
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 48
IAM Dashboard security status
Password
policy
creation
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 49
Set an IAM password policy
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 50
Security status checks completed
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 51
Best practices to secure an AWS account:
Section 3 key
• Secure logins with multi-factor authentication (MFA).
takeaways • Delete account root user access keys.
• Create individual IAM users and grant permissions
according to the principle of least privilege.
• Use groups to assign permissions to IAM users.
• Configure a strong password policy.
• Delegate using roles instead of sharing credentials.
• Monitor account activity by using AWS CloudTrail.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 52
Lab 1:
Introduction to
IAM
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 53
Lab 1: Tasks
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 54
Lab 1: Final product
Account
AWS account
Users Groups
user-2
Amazon EC2
read-only
Amazon EC2 – IAM inline IAM managed
access
View, start, and policy policy S3 read-
stop access only access
user-3 user-1
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 55
~ 40 minutes
Begin Lab 1:
Introduction to AWS
IAM
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 56
Lab debrief:
Key takeaways
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 57
Section 4: Securing accounts
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Organizations
• AWS Organizations enables you to consolidate multiple AWS
accounts so that you centrally manage them.
• Group AWS accounts into organizational units (OUs) and attach different
access policies to each OU.
• Use service control policies to establish control over the AWS services and
API actions that each AWS account can access
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 59
AWS Organizations: Service control policies
• Service control policies (SCPs) offer centralized control over accounts.
• Limit permissions that are available in an account that is part of an organization.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 60
AWS Key Management Service (AWS KMS)
AWS Key Management Service (AWS KMS) features:
• Enables you to create and manage encryption keys
• Enables you to control the use of encryption across AWS services and in your
applications.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 61
Amazon Cognito
Amazon Cognito features:
• Adds user sign-up, sign-in, and access control to your web and mobile
applications.
• Supports sign-in with social identity providers, such as Facebook, Google, and
Amazon; and enterprise identity providers, such as Microsoft Active Directory via
Security Assertion Markup Language (SAML) 2.0.
Amazon Cognito
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 62
AWS Shield
• AWS Shield features:
• Is a managed distributed denial of service (DDoS) protection service
• AWS Shield Standard enabled for at no additional cost. AWS Shield Advanced is
an optional paid service.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 63
Section 5: Securing data on AWS
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Encryption of data at rest
• Encryption encodes data with a secret key, which makes it unreadable
• Only those who have the secret key can decode the data
• AWS KMS can manage your secret keys
TLS encrypted
data traffic TLS or SSL
encrypted Amazon S3
Amazon EC2 Amazon EFS AWS Storage Gateway
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 66
Securing Amazon S3 buckets and objects
• Newly created S3 buckets and objects are private and protected by
default.
• When use cases require sharing data objects on Amazon S3 –
• It is essential to manage and control the data access.
• Follow the permissions that follow the principle of least privilege and consider using
Amazon S3 encryption.
• Tools and options for controlling access to S3 data include –
• Amazon S3 Block Public Access feature: Simple to use.
• IAM policies: A good option when the user can authenticate using IAM.
• Bucket policies
• Access control lists (ACLs): A legacy access control mechanism.
• AWS Trusted Advisor bucket permission check: A free feature.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 67
Section 6: Working to ensure
compliance
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS compliance programs
• Customers are subject to many different security and compliance regulations and requirements.
• AWS engages with certifying bodies and independent auditors to provide customers with detailed
information about the policies, processes, and controls that are established and operated by AWS.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 69
AWS Config
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 70
AWS Artifact
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 71
Section 6 key
• AWS security compliance programs provide
takeaways information about the policies, processes, and
controls that are established and operated by AWS.
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 72
Section 7: Additional security
services and resources
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Service Catalog
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 74
Selected additional security services
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 75
Module wrap-up
Module 4: AWS Cloud Security
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Module summary
In summary, in this module you learned how to:
• Recognize the shared responsibility model
• Identify the responsibility of the customer and AWS
• Recognize IAM users, groups, and roles
• Describe different types of security credentials in IAM
• Identify the steps to securing a new AWS account
• Explore IAM users and groups
• Recognize how to secure AWS data
• Recognize AWS compliance programs
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 77
Complete the knowledge check
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 78
Sample exam question
Which of the following is AWS's responsibility under the
AWS shared responsibility model?
Choice Response
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 79
Sample exam question answer
Which of the following is AWS's responsibility under the
AWS shared responsibility model?
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 80
Additional resources
• AWS Cloud Security: https://aws.amazon.com/security/
• AWS Security Resources: https://aws.amazon.com/security/security-learning/?cards-
top.sort-by=item.additionalFields.sortDate&cards-top.sort-
order=desc&awsf.Types=*all
• AWS Security Blog: https://aws.amazon.com/blogs/security/
• Security Bulletins : https://aws.amazon.com/security/security-bulletins/?card-
body.sort-by=item.additionalFields.bulletinId&card-body.sort-
order=desc&awsf.bulletins-flag=*all&awsf.bulletins-year=*all
• Vulnerability and Penetration testing: https://aws.amazon.com/security/penetration-
testing/
• AWS Well-Architected Framework – Security pillar: https:
//d1.awsstatic.com/whitepapers/architecture/AWS-Security-Pillar.pdf
• AWS documentation - IAM Best Practices: https:
//docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 81
Thank you
© 2022, Amazon Web Services, Inc. or its affiliates. All rights reserved. 82