Ensure EFS file systems are encrypted with Customer Managed Keys (CMK) for improved security.
Rule | EFS file systems should be encrypted with CMK |
Framework | CISA-cyber-essentials |
Severity | ✔ Medium |
EFS File Systems Encryption with CMK for CISA-Cyber Essentials
Description:
Encryption is a crucial security measure to protect sensitive data from unauthorized access. In the context of Amazon Elastic File System (EFS), encrypting the file systems using AWS Key Management Service's (KMS) Customer Master Key (CMK) enhances data security, ensuring compliance with the CISA-Cyber Essentials framework.
Troubleshooting Steps (if applicable):
If you encounter issues while encrypting EFS file systems with CMK, follow these troubleshooting steps:
Necessary Codes (if applicable):
Here is an example of the code snippet to encrypt an EFS file system with a CMK:
aws efs create-file-system --performance-mode generalPurpose --kms-key-id <CMK_Key_ID>
Step-by-Step Guide for Remediation:
Identify the CMK: Determine the Customer Master Key (CMK) to be used for encrypting the EFS file system. If you don't have a CMK, you can create one using the AWS Key Management Service (KMS).
Grant Permissions: Ensure that the IAM role or user associated with the EFS file system has the necessary permissions to access and use the CMK. This can be done by updating the Key Policy associated with the CMK.
Encrypt the EFS File System: Use the AWS CLI or AWS Management Console to create a new EFS file system, specifying the CMK to be used for encryption. If using the AWS CLI, you can execute the following command:
aws efs create-file-system --performance-mode generalPurpose --kms-key-id <CMK_Key_ID>
Replace
<CMK_Key_ID>
with the actual Key ID of the CMK to be used.Verify Encryption: Once the EFS file system is created, you can verify if it is encrypted with the desired CMK. You can check the Encryption key ID associated with the file system using the AWS CLI:
aws efs describe-file-systems --file-system-id <EFS_FileSystem_ID>
Replace
<EFS_FileSystem_ID>
with the actual File System ID of your EFS.Ensure that the "KmsKeyId" property matches the Key ID of the CMK you specified during the creation of the EFS file system.
Conclusion:
Encrypting EFS file systems with CMK provides an additional layer of security and helps fulfill the encryption requirements outlined in the CISA-Cyber Essentials framework. By following the provided troubleshooting steps and using the respective codes, you can effectively encrypt your EFS file systems using CMK.