06 Encryption and Data Protection
06 Encryption and Data Protection
• Encryption at rest
• Encryption in transit
• Data protection considerations
SSL/TLS Object
Database
SSH
Filesystem
VPN/IPSEC Disk
Glacier
Secrets Manager
EBS AWS IAM
Encryption in transit
S3
Fully managed
keys
ELB EC2 Encryption in Process KMS
Certificate management
EMR Redshift
Availability Zone 1
VPC
S3 Server Side Client Side Encryption
Encryption (SSE-S3)
Subnet Subnet
S3 Server Side
Encryption with KMS
(SSE-KMS)
Availability Zone 1
VPC
OS Tools
Subnet Subnet
EBS
Encryption
Marketplace
Solution
Amazon Confidential AWS Security Workshop v5.1
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Encryption & Data Protection
Encryption at Rest – Databases
AWS Cloud
Availability Zone 1
Transparent RDS EBS
VPC Database Volume
Encryption (TDE) Encryption
Subnet Subnet
Client Side
Encryption
DynamoDB Redshift
Encryption Encryption
Amazon Confidential AWS Security Workshop v5.1
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Encryption & Data Protection
Encryption at Rest – Envelope Encryption Primer
Encrypted
Data in Storage
?
Symmetric Master Key Encrypted
Data Key Data Key
Client-side encryption
• You encrypt your data before data submitted to the service
• You supply encryption keys OR use keys in your AWS account
• Available clients:
• S3, EMR File System (EMRFS), DynamoDB, AWS Encryption SDK
Server-side encryption
• AWS encrypts data on your behalf after data is received by service
• Services with integrated encryption include S3, Snowball, EBS, RDS,
Amazon Redshift, WorkSpaces, Amazon Kinesis Firehose, CloudTrail, EMR,
DynamoDB, CodePipeline, AWS Secrets Manager, AWS Backup
Amazon Confidential AWS Security Workshop v5.1
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Encryption & Data Protection
Encryption at Rest – AWS Key Management Service
encryption
• Unique data key encrypts customer data
• KMS master keys encrypt data keys
Customer Master Customer Master Customer Master Customer Master
• KMS master keys never leave the KMS HSM Key (CMK) Key (CMK) Key (CMK) Key (CMK)
unencrypted
Benefits
Data Key Data Key Data Key Data Key
• Limits risk of compromised data key
• Better performance for encrypting large data
• Easier to manage small number of master
keys than millions of data keys
• Centralized access and audit of key activity S3 Object EBS Volume Redshift
Custom
Application
Cluster
Amazon Confidential AWS Security Workshop v5.1
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Encryption & Data Protection
Encryption at Rest – AWS Key Management Service
Auditing key usage with AWS CloudTrail
"RequestParameters":
"{"keyId":"2b42x363-1911-4e3a-8321-6b67329025ex”}”, … in reference to this key
"UserIdentity":
"{"arn":"arn:aws:iam:: 111122223333:user/User123"} … by this AWS user in this account
Export
Export your key material encrypted
under the public wrapping key
Your key management Your 256-bit key material
infrastructure encrypted with KMS public key
Import
Import the encrypted key material
under the KMS CMK key ID; set optional
Your key material protected in
expiration period
AWS KMS
Amazon Confidential AWS Security Workshop v5.1
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Encryption & Data Protection
Encryption at Rest – Ubiquitous Encryption
Encrypted
Encryption at Rest secrets management
Restrict Access
Glacier
Secrets Manager
EBS AWS IAM
Encryption in transit
S3
Fully managed
keys
ELB EC2 Encryption in Process KMS
Certificate management
EMR Redshift
Rotation Once every three years Once every three years Once a year automatically
automatically automatically through opt-in or
manually on-demand
Scope of Use Not limited to your AWS Limited to a specific AWS Controlled via KMS/IAM
account service within your AWS policies
account
50+ AWS
Services
Customers’
Custom
applications
clients using
via AWS SDKs
PKCS#11, JCE, CNG
VPC
• Dedicated access to HSM that complies • Highly available and durable key storage,
with government standards (e.g. FIPS management, and auditable solution
140-2 Level 3, Common Criteria) (FIPS 140-2 Level 2 HSM’s and support
• High-performance in-VPC cryptographic for FIPS 140-2 Level 2 endpoints)
acceleration • Easily encrypt your data across AWS
• You control your keys and the application services and within your own applications
software that uses them based on policies you define
• Supported applications: • Supported applications:
• Your custom software • Your custom software (AWS SDK)
• Third party software • Symmetric encryption
• Symmetric or asymmetric encryption • Integrated with multiple AWS services
How to use KMS and IAM to enable independent security controls for
encrypted data in S3
https://aws.amazon.com/blogs/security/how-to-use-kms-and-iam-
to-enable-independent-security-controls-for-encrypted-data-in-s3/
• You can browse, test, and buy encryption and key management solutions
via the AWS Marketplace
• Pricing models vary: pay-by-the-hour, monthly, or annual
• The software fees are simply added to your AWS bill
• Some solutions offer a bring-your-own-license option
Where keys are AWS KMS FIPS 140-2 AWS CloudHSM FIPS AWS CloudHSM FIPS Your network or EC2 Your network or EC2
generated and stored Level 2 HSM’s (with 140-2 Level 3 HSM’s 140-2 Level 3 HSM’s instance instance
level 3 for several
other categories)
Where keys are used AWS services or your AWS services or your AWS or your Your network or EC2 Your network or EC2
applications using the applications using the applications using the instance instance
AWS SDK’s AWS SDK’s HSM specific SDK
How to control key Policies you define; Policies you define; HSM-specific access Vendor-specific access You implement access
usage enforced by AWS enforced by AWS – controls controls controls
Only for keys made
available through KMS
Responsibility for AWS AWS (API’s) Customer Customer Customer
performance/scale Customer (Key Store)
APP WEB
? ?
? VPN
?
APP WEB
10.0.32.0/20 10.0.48.0/21
HTTPS HTTP
Encrypted Unencrypted
APP WEB
VPN
APP WEB
Incoming TLS
session
10.0.32.0/20 10.0.48.0/21
HTTPS HTTPS
Encrypted Encrypted
APP WEB
VPN
APP WEB
Incoming TLS
session
10.0.32.0/20 10.0.48.0/21
Encrypted Encrypted
APP WEB
VPN
APP WEB
Incoming TLS
session
10.0.32.0/20 10.0.48.0/21
Network Layer L4 – L7 L7 L4
https://docs.aws.amazon.com/elasticloadbalancing/latest/classic/elb-security-
policy-table.html
Amazon Confidential AWS Security Workshop v5.1
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Encryption & Data Protection
TLS Security Policies on ALB & NLB
https://docs.aws.amazon.com/elasticloadbalancing/latest/application/create-
https-listener.html#describe-ssl-policies
Amazon Confidential AWS Security Workshop v5.1
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Encryption & Data Protection
Encryption in Transit
https://aws.amazon.com/security/security-bulletins/
Amazon Confidential AWS Security Workshop v5.1
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Encryption & Data Protection
Encryption in Transit – TLS with Amazon ELB Recap
HTTPS HTTP
Encrypted Unencrypted
HTTPS HTTPS
Encrypted Encrypted
APP WEB
VPN
APP WEB
10.0.32.0/20 10.0.48.0/21
AWS Cloud
DB APP WEB
APP WEB
AWS Cloud
TLS terminates at the
VPC CloudFront Edge
DB APP WEB
Amazon
CloudFront
APP WEB
• Provision trusted SSL/TLS certificates from AWS for use with AWS
resources:
• Elastic Load Balancing
• Amazon CloudFront distributions