sonarjs/aws-rds-unencrypted-databases
eslint-plugin-sonarjs
No autofixRecommended
eslint.config.js
export default [
{
rules: {
"sonarjs/aws-rds-unencrypted-databases": "error",
},
},
];Amazon RDS resources should be encrypted at rest
The documentation shows no incorrect example for this rule.
import { aws_rds as rds } from 'aws-cdk-lib';
new rds.CfnDBCluster(this, 'example', {
storageEncrypted: true,
});import { aws_rds as rds } from 'aws-cdk-lib';
new rds.CfnDBInstance(this, 'example', {
storageEncrypted: true,
});import { aws_rds as rds } from 'aws-cdk-lib';
declare const vpc: ec2.Vpc;
const cluster = new rds.DatabaseCluster(this, 'example', {
engine: rds.DatabaseClusterEngine.auroraMysql({ version: rds.AuroraMysqlEngineVersion.VER_2_08_1 }),
instanceProps: {
vpcSubnets: {
subnetType: ec2.SubnetType.PRIVATE_WITH_EGRESS,
},
vpc,
},
storageEncrypted: false, // Sensitive
});Examples from the ESLint documentation.
sonarjs/aws-rds-unencrypted-databases
eslint-plugin-sonarjs
export default [
{
rules: {
"sonarjs/aws-rds-unencrypted-databases": "error",
},
},
];Oxlint does not have this rule.
Biome does not have this rule.
OpenSearch domains should have encryption at rest enabled
Administration services access should be restricted to specific IP addresses
AWS resource-based policies should not grant public access
S3 buckets should not grant access to all users or authenticated users
AWS IAM policies should limit the scope of permissions given
S3 buckets should enforce HTTPS-only access