From 7db62c96d4b4d587de75e14036fe8fc50da4381f Mon Sep 17 00:00:00 2001 From: Krzysztof Nozderko Date: Wed, 13 Dec 2023 12:47:58 +0100 Subject: [PATCH] Fix usage of insecure mode in connection parameters --- .../UnitTests/Session/SFHttpClientPropertiesTest.cs | 2 +- Snowflake.Data/Core/Session/SFSessionHttpClientProperties.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Snowflake.Data.Tests/UnitTests/Session/SFHttpClientPropertiesTest.cs b/Snowflake.Data.Tests/UnitTests/Session/SFHttpClientPropertiesTest.cs index ea6deb5ca..2eba8fd49 100644 --- a/Snowflake.Data.Tests/UnitTests/Session/SFHttpClientPropertiesTest.cs +++ b/Snowflake.Data.Tests/UnitTests/Session/SFHttpClientPropertiesTest.cs @@ -79,7 +79,7 @@ public void ShouldBuildHttpClientConfig() var config = properties.BuildHttpClientConfig(); // then - Assert.AreEqual(properties.insecureMode, config.CrlCheckEnabled); + Assert.AreEqual(!properties.insecureMode, config.CrlCheckEnabled); Assert.AreEqual(properties.proxyProperties.proxyHost, config.ProxyHost); Assert.AreEqual(properties.proxyProperties.proxyPort, config.ProxyPort); Assert.AreEqual(properties.proxyProperties.proxyUser, config.ProxyUser); diff --git a/Snowflake.Data/Core/Session/SFSessionHttpClientProperties.cs b/Snowflake.Data/Core/Session/SFSessionHttpClientProperties.cs index b7466a362..f129de25a 100644 --- a/Snowflake.Data/Core/Session/SFSessionHttpClientProperties.cs +++ b/Snowflake.Data/Core/Session/SFSessionHttpClientProperties.cs @@ -75,7 +75,7 @@ internal TimeSpan TimeoutDuration() internal HttpClientConfig BuildHttpClientConfig() { return new HttpClientConfig( - insecureMode, + !insecureMode, proxyProperties.proxyHost, proxyProperties.proxyPort, proxyProperties.proxyUser,