Book Image

AWS Security Cookbook

By : Heartin Kanikathottu
Book Image

AWS Security Cookbook

By: Heartin Kanikathottu

Overview of this book

As a security consultant, securing your infrastructure by implementing policies and following best practices is critical. This cookbook discusses practical solutions to the most common problems related to safeguarding infrastructure, covering services and features within AWS that can help you implement security models such as the CIA triad (confidentiality, integrity, and availability), and the AAA triad (authentication, authorization, and availability), along with non-repudiation. The book begins with IAM and S3 policies and later gets you up to speed with data security, application security, monitoring, and compliance. This includes everything from using firewalls and load balancers to secure endpoints, to leveraging Cognito for managing users and authentication. Over the course of this book, you'll learn to use AWS security services such as Config for monitoring, as well as maintain compliance with GuardDuty, Macie, and Inspector. Finally, the book covers cloud security best practices and demonstrates how you can integrate additional security services such as Glacier Vault Lock and Security Hub to further strengthen your infrastructure. By the end of this book, you'll be well versed in the techniques required for securing AWS deployments, along with having the knowledge to prepare for the AWS Certified Security – Specialty certification.
Table of Contents (12 chapters)

Key Management with KMS and CloudHSM

Encryption is the process of converting plaintext into ciphertext using a key. We can get the original plain text from the ciphertext using the same key, and this is referred to as decryption. AWS Key Management Service (KMS) helps us create and manage encryption keys while making use of shared hardware security modules (HSMs). CloudHSM is another service within AWS that allows us to manage encryption keys but uses dedicated HSMs for enhanced security. We will look at recipes for working with both AWS KMS and AWS CloudHSM within this chapter.

In this chapter, we will cover the following recipes:

  • Creating keys in KMS
  • Using keys with external key material
  • Rotating keys in KMS
  • Granting permissions programmatically with grants
  • Using key policies with conditional keys
  • Sharing customer-managed keys across accounts
  • Creating a CloudHSM cluster
  • Initializing...