0
0
GCPcloud~20 mins

Cloud SQL Proxy for secure connections in GCP - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Cloud SQL Proxy Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
service_behavior
intermediate
2:00remaining
How does Cloud SQL Proxy authenticate connections?

Cloud SQL Proxy helps secure connections to Cloud SQL instances. How does it authenticate the client connecting to the database?

AIt authenticates clients by checking their SSL certificates only.
BIt requires the client to provide the database username and password directly to authenticate.
CIt uses a static IP whitelist configured on the Cloud SQL instance to allow connections.
DIt uses the client's Google Cloud IAM credentials to authenticate and authorize the connection.
Attempts:
2 left
💡 Hint

Think about how Google Cloud services verify identity without exposing database passwords.

Configuration
intermediate
2:00remaining
Which command correctly starts Cloud SQL Proxy for a specific instance?

You want to start Cloud SQL Proxy to connect to a Cloud SQL instance named my-instance in project my-project. Which command is correct?

Acloud_sql_proxy -instances=my-project:my-instance=tcp:5432
Bcloud_sql_proxy -instance=my-project:us-central1:my-instance=tcp:5432
Ccloud_sql_proxy -instances=my-project:us-central1:my-instance=tcp:5432
Dcloud_sql_proxy -instances=my-instance=tcp:5432
Attempts:
2 left
💡 Hint

Remember the full instance connection name format includes project, region, and instance.

Architecture
advanced
2:00remaining
What is the main benefit of using Cloud SQL Proxy over direct IP connections?

Consider the architecture of connecting to Cloud SQL. What is the primary advantage of using Cloud SQL Proxy instead of connecting directly via IP address?

AIt allows connections only from within the same VPC network without extra configuration.
BIt automatically encrypts traffic and manages authentication using IAM, removing the need for IP whitelisting and SSL setup.
CIt increases the database performance by caching queries locally.
DIt replaces the need for database user accounts by using proxy user accounts.
Attempts:
2 left
💡 Hint

Think about security and ease of managing access.

security
advanced
2:00remaining
What happens if Cloud SQL Proxy is started without proper IAM permissions?

You start Cloud SQL Proxy but your Google Cloud IAM user lacks the required permissions. What will happen?

AThe proxy will fail to connect and show an authentication error.
BThe proxy will connect but deny all SQL queries.
CThe proxy will connect but log warnings about permissions.
DThe proxy will connect successfully but with limited access.
Attempts:
2 left
💡 Hint

Consider how authentication failures affect connection attempts.

Best Practice
expert
2:00remaining
Which practice ensures the most secure use of Cloud SQL Proxy in production?

To securely use Cloud SQL Proxy in a production environment, which practice is best?

ARun Cloud SQL Proxy on a dedicated VM with minimal permissions and use service accounts with least privilege.
BDisable IAM authentication and rely on IP whitelisting only.
CEmbed database user passwords in the proxy startup script for quick access.
DRun Cloud SQL Proxy on any VM with broad admin permissions for easier management.
Attempts:
2 left
💡 Hint

Think about the principle of least privilege and secure credential management.