A developer wants to connect to a Cloud SQL instance from a Compute Engine VM without whitelisting IP addresses and with automatic encryption. What should they use?
Use the Cloud SQL Auth Proxy. It provides secure, encrypted connections without IP allowlisting using IAM authentication. It runs as a sidecar or on the client.
Why this answer
Cloud SQL Auth Proxy provides secure, encrypted connections without IP allowlisting. It uses IAM for authentication and runs as a sidecar or on the client. Direct IP with SSL still requires IP allowlisting.
Cloud SQL Connector libraries also provide secure connections but the proxy is the standard tool for VMs.