GoogleCloudPlatform / GoogleCloudPlatform/cloud-sql-go-connector
PSC-based connections should use the DNS name in TLS config
Open
priority: p2
type: feature request
- Dominant language
- Go
- Stars
- 145
- Forks
- 35
- Avg merge
- 3d 22h
- Merged PRs (30d)
- 5
Description
### Feature Description
When connecting to a PSC endpoint, we should use the PSC DNS name as the server name in the TLS configuration here: https://github.com/GoogleCloudPlatform/cloud-sql-go-connector/blob/aeb4de166cdf9aae24ada5d6c2320467788d5015/internal/cloudsql/refresh.go#L234.
That should also allow us to remove `InsecureSkipVerify` for PSC-based connections.
### Sample code
_No response_
### Alternatives Considered
_No response_
### Additional Details
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.