snowflake-jdbc
snowflake-jdbc copied to clipboard
SNOW-506871: PUT command fails due to invalid DNS name being returned and used.
PUT command fails due to an invalid DNS name being returned in a pre-signed URL which is then used to stage data.
When attempting to run a PUT command with the driver, the following message appears in the logs when -Djavax.net.debug=all is set as a JVM option on the command line.
javax.net.ssl|FINE|0C|sf-file-upload-worker-1|2021-11-19 20:11:59.222 GMT|Utilities.java:114|gcpuscentral1_xxxxxxx_stage.storage.googleapis.com" is not a legal HostName for server name indication
I have replaced part of the DNS name with xxxxxxx.
Underscores in DNS names are invalid and are rejected by Java, causing the SNI header to be omitted.
The server, however, requires the SNI entry and returns an invalid certificate in response, making the request fail.
Either the driver should change underscores to dashes before using URLs or the services should return valid DNS names to the driver for it to use.
Furthermore, when the exception is detected by the driver it doesn't recognise it as something which is not recoverable and attempts to indefinitely retry the request. Instead it should throw and exception.
This occurs in version 3.13.11 and previous when tried on Java 8 and 11.
Hi @bagguley , we are looking into this.
This has been fix. Please try latest driver.
To clean up and re-prioritize more pressing bugs and feature requests we are closing all issues older than 6 months as of March 1, 2023. If there are any issues or feature requests that you would like us to address, please create them according to the new templates we have created. For urgent issues, opening a support case with this link Snowflake Community is the fastest way to get a response.