From 45afd71ac16ea55aeba91b8bacb4859344ae1b34 Mon Sep 17 00:00:00 2001 From: Piotr Bulawa Date: Wed, 30 Oct 2024 14:51:57 +0100 Subject: [PATCH] SNOW-1553930: Fix incorrect key size condition check for GCP and Azure (#1946) --- .../client/jdbc/cloud/storage/SnowflakeAzureClient.java | 2 +- .../snowflake/client/jdbc/cloud/storage/SnowflakeGCSClient.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/net/snowflake/client/jdbc/cloud/storage/SnowflakeAzureClient.java b/src/main/java/net/snowflake/client/jdbc/cloud/storage/SnowflakeAzureClient.java index 4bec46ca7..0f8014ef6 100644 --- a/src/main/java/net/snowflake/client/jdbc/cloud/storage/SnowflakeAzureClient.java +++ b/src/main/java/net/snowflake/client/jdbc/cloud/storage/SnowflakeAzureClient.java @@ -695,7 +695,7 @@ private SFPair createUploadStream( final InputStream stream; FileInputStream srcFileStream = null; try { - if (isEncrypting() && getEncryptionKeySize() < 256) { + if (isEncrypting() && getEncryptionKeySize() <= 256) { try { final InputStream uploadStream = uploadFromStream diff --git a/src/main/java/net/snowflake/client/jdbc/cloud/storage/SnowflakeGCSClient.java b/src/main/java/net/snowflake/client/jdbc/cloud/storage/SnowflakeGCSClient.java index 003d894ae..31341c5a3 100644 --- a/src/main/java/net/snowflake/client/jdbc/cloud/storage/SnowflakeGCSClient.java +++ b/src/main/java/net/snowflake/client/jdbc/cloud/storage/SnowflakeGCSClient.java @@ -1036,7 +1036,7 @@ private SFPair createUploadStream( final InputStream stream; FileInputStream srcFileStream = null; try { - if (isEncrypting() && getEncryptionKeySize() < 256) { + if (isEncrypting() && getEncryptionKeySize() <= 256) { try { final InputStream uploadStream = uploadFromStream