๐ก๏ธ Google Cloud SQL Instance SSL Connections are not enforced๐ข
- Contextual name: ๐ก๏ธ Instance SSL Connections are not enforced๐ข
- ID:
/ce/ca/google/sql/instance-ssl - Tags:
- ๐ข Policy with categories
- ๐ข Policy with type
- ๐ข Production policy
- Policy Type:
COMPLIANCE_POLICY - Policy Categories:
SECURITY
Logicโ
- ๐ง prod.logic.yaml๐ข
Similar Policiesโ
- Cloud Conformity: Enable SSL/TLS for Cloud SQL Incoming Connections
Descriptionโ
Descriptionโ
It is recommended to enforce SSL for all incoming connections to SQL database instances.
Rationaleโ
SQL database connections that are successfully intercepted (MITM) can reveal sensitive data such as credentials, database queries, and query outputs. For security, it is recommended to always use SSL encryption when connecting to your instance. This recommendation is applicable to PostgreSQL, MySQL generation 1, MySQL generation 2, and SQL Server 2017 instances.
Impactโ
After enforcing the SSL requirement, existing clients will not be able to communicate with a Cloud SQL database instance unless they use SSL-encrypted connections.
Auditโ
This policy flags a Google SQL Instance as
INCOMPLIANTif itsSSL Modeis not set to ENCRYPTED_ONLY or TRUSTED_CLIENT_CERTIFICATE_REQUIRED.Default Valueโ
By default, the parameter
settings: ipConfiguration: sslModeis not set, which is equivalent tosslMode:ALLOW_UNENCRYPTED_AND_ENCRYPTED.Referencesโ
... see more
Remediationโ
Remediationโ
From Google Cloud Consoleโ
- Go to https://console.cloud.google.com/sql/instances.
- Click on an instance name to see its configuration overview.
- In the left-side panel, select
Connections.- In the
Securitysection, select SSL mode asAllow only SSL connections.- Under
Configure SSL server certificates, clickCreate new certificateand save the setting.From Google Cloud CLIโ
To enforce SSL encryption for an instance, run the command:
gcloud sql instances patch {{instance-name}} \
--ssl-mode={{ssl-mode}}Note:
RESTARTis required for type MySQL Generation 1 Instances (backendType: FIRST_GEN) to get this configuration in effect.