0

I am trying to authenticate my IAM user with my GCP Cloud SQL instance via ./cloud-sql-proxy. After the ./cloud-sql-proxy is ran and awaiting connections, I used VSC's SQLTools extension by Matheus Teixeira to add a connection to my DB instance.

While I have no issues with in-buit users that I have created on my Cloud SQL instance, I seem to be running to a connection error like this below for my IAM user:

CloudSQL Instance's IAM access denied for user <IAM USER>: Error Message : IAM Connections using insecure transport are prohibited. Please use secure transport.

This is the code I'm using to start my ./cloud-sql-proxy as found here:

./cloud-sql-proxy --auto-iam-authn <INSTANCE NAME>

It will then output the following:

2023/08/01 11:51:30 Authorizing with Application Default Credentials
2023/08/01 11:51:31 [INSTANCE ID] Listening on 127.0.0.1:3306
2023/08/01 11:51:31 The proxy has started successfully and is ready for new connections!

Any help is much appreciated.

OnionCoder
  • 87
  • 7
  • Do you have the latest version of Cloud SQL proxy? – guillaume blaquiere Jul 31 '23 at 13:30
  • In addition to @guillaumeblaquiere's question, please show us how you're starting the proxy, and how you're connecting to the database. – enocom Jul 31 '23 at 15:36
  • Remove the image and replace it with text. Read this [guide](https://meta.stackoverflow.com/questions/285551/why-should-i-not-upload-images-of-code-data-errors/285557#285557) The error message says you are using an insecure transport. Add more details to your question to show what you are configuring. – John Hanley Jul 31 '23 at 16:58
  • @guillaumeblaquiere yes! – OnionCoder Aug 01 '23 at 03:40
  • @JohnHanley Done! Thanks for informing. – OnionCoder Aug 01 '23 at 03:40
  • Please provide all information on how you are getting this error. Review your question and ask yourself, can I reproduce the problem with the details in my post? For example, how are you using the proxy? You mention `VSC MySQL client` but I do not know what that means. Is this client code you wrote using Visual Studio in C/C++ or a client you downloaded from the Internet? Add more details including the code you are using. If not code, then show how you are configuring the MySQL client. Your problem is `insecure transport`, but I do not see anything regarding connections in your post. – John Hanley Aug 01 '23 at 03:47

0 Answers0