Ce produit n'est pas pris en charge par le site Datadog que vous avez sélectionné. ().
Cette page n'est pas encore disponible en français, sa traduction est en cours. Si vous avez des questions ou des retours sur notre projet de traduction actuel, n'hésitez pas à nous contacter.
Amazon EFS file systems must be encrypted at rest using an AWS KMS customer-managed key (CMK) to protect stored data from unauthorized access and to enable customer-controlled key rotation, access policies, and audit logging.
In CloudFormation, ensure resources of type AWS::EFS::FileSystem have Encrypted set to true and specify KmsKeyId referencing a customer-managed AWS KMS key (ARN, alias, or Ref to an AWS::KMS::Key). Resources with Encrypted missing or set to false, or without a valid KmsKeyId that points to a customer-managed CMK, will be flagged.
Secure configuration example:
MyEfs:Type:AWS::EFS::FileSystemProperties:Encrypted:trueKmsKeyId:!Ref MyKmsKeyMyKmsKey:Type:AWS::KMS::KeyProperties:Description:"Customer-managed CMK for EFS encryption"
Compliant Code Examples
AWSTemplateFormatVersion:"2010-09-09"Description:"Create EFS system and Mount Targets for test VPC"Parameters:VPC:Type:StringDescription:The VPC identityDefault:vpc-IDSubnetID1:Type:StringDescription:The subnet where to launch the serviceDefault:subnet-IDSubnetID2:Type:StringDescription:the subnet where to Launch the serviceDefault:subnet-IDSubnetID3:Type:StringDescription:The subnet where to launch the serviceDefault:subnet-IDSubnetID4:Type:StringDescription:the subnet where to Launch the serviceDefault:subnet-IDResources:EFSKMSKey:Type:AWS::KMS::KeyProperties:Description:"An example CMK with KMS"KeyPolicy:Version:"2012-10-17"Id:"efs-default-key1"Statement:- Sid:"Allow administration of the key"Effect:"Allow"Principal:AWS:"arn:aws:iam::999999999999:user/roger"Action:- "kms:Create*"- "kms:Describe*"- "kms:Enable*"- "kms:List*"- "kms:Put*"- "kms:Update*"- "kms:Revoke*"- "kms:Disable*"- "kms:Get*"- "kms:Delete*"- "kms:ScheduleKeyDeletion"- "kms:CancelKeyDeletion"Resource:"*"- Sid:"Allow use of the key"Effect:"Allow"Principal:AWS:"arn:aws:iam::999999999999:user/roger"Action:- "kms:DescribeKey"- "kms:Encrypt"- "kms:Decrypt"- "kms:ReEncrypt*"- "kms:GenerateDataKey"- "kms:GenerateDataKeyWithoutPlaintext"Resource:"*"EFSSecurityGroup:Type:"AWS::EC2::SecurityGroup"Properties:GroupDescription:"security group for the prod EFS"GroupName:"test-EFS-SG"VpcId:!Ref VPCSecurityGroupIngress:- SourceSecurityGroupId:sg-IDDescription:"servers to connect to efs"FromPort:2049IpProtocol:"tcp"ToPort:2049Tags:- Key:EnvironmentValue:prod- Key:NameValue:test-VPC-EFS-SG- Key:ProjectValue:ITEngineeringEFSFileSystem01:Type:AWS::EFS::FileSystemProperties:BackupPolicy:Status:ENABLEDEncrypted:falseKmsKeyId:!Ref EFSKMSKeyLifecyclePolicies:- TransitionToIA:AFTER_60_DAYSPerformanceMode:generalPurposeThroughputMode:burstingFileSystemTags:- Key:EnvironmentValue:prod- Key:NameValue:test-VPC-EFS- Key:ProjectValue:ITEngineeringMountTarget1:Type:AWS::EFS::MountTargetProperties:FileSystemId:!Ref EFSFileSystem01IpAddress:"*.*.*.*"SecurityGroups:- !Ref EFSSecurityGroupSubnetId:!Ref SubnetID1MountTarget2:Type:AWS::EFS::MountTargetProperties:FileSystemId:!Ref EFSFileSystem01IpAddress:"*.*.*.*"SecurityGroups:- !Ref EFSSecurityGroupSubnetId:!Ref SubnetID2MountTarget3:Type:AWS::EFS::MountTargetProperties:FileSystemId:!Ref EFSFileSystem01IpAddress:"*.*.*.*"SecurityGroups:- !Ref EFSSecurityGroupSubnetId:!Ref SubnetID3MountTarget4:Type:AWS::EFS::MountTargetProperties:FileSystemId:!Ref EFSFileSystem01IpAddress:"*.*.*.*"SecurityGroups:- !Ref EFSSecurityGroupSubnetId:!Ref SubnetID4Outputs:EFS:Description:The created EFSValue:!Ref EFSFileSystem01EFSMountTarget1:Description:The EFS MountTarget1Value:!Ref MountTarget1EFSMountTarget2:Description:The EFS MountTarget2Value:!Ref MountTarget2EFSMountTarget3:Description:The EFS MountTarget3Value:!Ref MountTarget3EFSMountTarget4:Description:The EFS MountTarget4Value:!Ref MountTarget4
Non-Compliant Code Examples
AWSTemplateFormatVersion:"2010-09-09"Description:"Create EFS system and Mount Targets for test VPC"Parameters:VPC:Type:StringDescription:The VPC identityDefault:vpc-IDSubnetID1:Type:StringDescription:The subnet where to launch the serviceDefault:subnet-IDSubnetID2:Type:StringDescription:the subnet where to Launch the serviceDefault:subnet-IDSubnetID3:Type:StringDescription:The subnet where to launch the serviceDefault:subnet-IDSubnetID4:Type:StringDescription:the subnet where to Launch the serviceDefault:subnet-IDResources:EFSKMSKey:Type:AWS::KMS::KeyProperties:Description:"An example CMK with KMS"KeyPolicy:Version:"2012-10-17"Id:"efs-default-key1"Statement:- Sid:"Allow administration of the key"Effect:"Allow"Principal:AWS:"arn:aws:iam::999999999999:user/roger"Action:- "kms:Create*"- "kms:Describe*"- "kms:Enable*"- "kms:List*"- "kms:Put*"- "kms:Update*"- "kms:Revoke*"- "kms:Disable*"- "kms:Get*"- "kms:Delete*"- "kms:ScheduleKeyDeletion"- "kms:CancelKeyDeletion"Resource:"*"- Sid:"Allow use of the key"Effect:"Allow"Principal:AWS:"arn:aws:iam::999999999999:user/roger"Action:- "kms:DescribeKey"- "kms:Encrypt"- "kms:Decrypt"- "kms:ReEncrypt*"- "kms:GenerateDataKey"- "kms:GenerateDataKeyWithoutPlaintext"Resource:"*"EFSSecurityGroup:Type:"AWS::EC2::SecurityGroup"Properties:GroupDescription:"security group for the prod EFS"GroupName:"test-EFS-SG"VpcId:!Ref VPCSecurityGroupIngress:- SourceSecurityGroupId:sg-IDDescription:"servers to connect to efs"FromPort:2049IpProtocol:"tcp"ToPort:2049Tags:- Key:EnvironmentValue:prod- Key:NameValue:test-VPC-EFS-SG- Key:ProjectValue:ITEngineeringEFSFileSystem01:Type:AWS::EFS::FileSystemProperties:BackupPolicy:Status:ENABLEDEncrypted:falseLifecyclePolicies:- TransitionToIA:AFTER_60_DAYSPerformanceMode:generalPurposeThroughputMode:burstingFileSystemTags:- Key:EnvironmentValue:prod- Key:NameValue:test-VPC-EFS- Key:ProjectValue:ITEngineeringMountTarget1:Type:AWS::EFS::MountTargetProperties:FileSystemId:!Ref EFSFileSystem01IpAddress:"*.*.*.*"SecurityGroups:- !Ref EFSSecurityGroupSubnetId:!Ref SubnetID1MountTarget2:Type:AWS::EFS::MountTargetProperties:FileSystemId:!Ref EFSFileSystem01IpAddress:"*.*.*.*"SecurityGroups:- !Ref EFSSecurityGroupSubnetId:!Ref SubnetID2MountTarget3:Type:AWS::EFS::MountTargetProperties:FileSystemId:!Ref EFSFileSystem01IpAddress:"*.*.*.*"SecurityGroups:- !Ref EFSSecurityGroupSubnetId:!Ref SubnetID3MountTarget4:Type:AWS::EFS::MountTargetProperties:FileSystemId:!Ref EFSFileSystem01IpAddress:"*.*.*.*"SecurityGroups:- !Ref EFSSecurityGroupSubnetId:!Ref SubnetID4Outputs:EFS:Description:The created EFSValue:!Ref EFSFileSystem01EFSMountTarget1:Description:The EFS MountTarget1Value:!Ref MountTarget1EFSMountTarget2:Description:The EFS MountTarget2Value:!Ref MountTarget2EFSMountTarget3:Description:The EFS MountTarget3Value:!Ref MountTarget3EFSMountTarget4:Description:The EFS MountTarget4Value:!Ref MountTarget4
1
2
rulesets:- CloudFormation / AWS # Rules to enforce / AWS.
Demander une démonstration personnalisée
Commencer avec Datadog
Ask AI
AI-generated responses may be inaccurate. Verify important info.