2025 年 .NET Driver 版本说明

本文包含 .NET Driver 的版本说明,包括以下内容(如果适用):

  • 行为变更

  • 新功能

  • 面向客户的错误修复

Snowflake 对 .NET Driver 更新使用语义版本控制。

有关文档,请参阅 .NET 驱动程序

Version 5.0.0 (October 16, 2025)

BCR (Behavior Change Release) changes

  • Implemented a new CRL (Certificate Revocation List) checking mechanism.

    Enabling CRLs improves security by checking for revoked certificates during the TLS handshake process. For more information, see the Replacing OCSP with CRL as the method of certificate revocation checking (https://community.snowflake.com/s/article/Replacing-OCSP-with-CRL-as-the-method-of-certificate-revocation-checking) Knowledge Base article.

    This feature is disabled by default. For information on enabling this feature, see Switching on/off certificate revocation checks (CRL) (https://github.com/snowflakedb/snowflake-connector-net/blob/master/doc/CertficateValidation.md#switching-onoff-certificate-revocation-checks-crl). We recommend you test this feature in advisory mode before enabling it in production.

  • Removed the log4net dependency and enabled delegated logging.

  • Upgraded the AWS SDK library to v4.

  • Removed some internal classes from the public API.

新功能和改进

  • Added support for TLS 1.3. The default negotiated version of TLS is either TLS 1.2 or TLS 1.3, and the server decides which one to establish.

  • Removed noisy log messages.

错误修复

  • 无。

Version 4.8.0 (August 13, 2025)

New features and updates

  • Added support for workload identity federation in the AWS, Azure, Google Cloud, and Kubernetes platforms.

    • Added the WORKLOAD_IDENTITY_PROVIDER connection parameter.

    • Added WORKLOAD_IDENTITY to the values for the authenticator connection parameter.

  • Added support of single use refresh tokens during the OAuth flow.

错误修复

  • Removed trailing slash from the default RedirectUri within the OAuth Authorization process.

  • Fixed a problem with ignoring endpoint override in AWS FIPS deployments.

版本 4.7.0(2025 年 7 月 1 日)

非公开预览版 (PrPr) 功能

Added support for workload identity federation in the AWS, Azure, GCP, and Kubernetes platforms.

免责声明:

  • 只有将 SF_ENABLE_EXPERIMENTAL_AUTHENTICATION 环境变量设置为 true 时,才能使用此功能。

  • 应仅在非生产数据中使用此功能。

  • 此 PrPr 功能不在支持范围内。但在 PrPr 阶段,产品和工程团队可提供服务。

  • 如需了解参与情况和相关文档,请联系您的客户团队。

新功能和改进

  • 无。

错误修复

  • 为异步编程访问令牌身份验证设置 ConfigureAwait(false)

  • 修复了以下问题:在创建使用 MinPoolSize 功能的会话时,缺少外部提供给连接字符串的 OAuthClientSecret 参数。

版本 4.6.0(2025 年 6 月 18 日)

新功能和改进

  • 在 Google Cloud Storage (GCS) 中添加了对虚拟式域的支持。

  • 在 HTTPS 调用中添加了持续时间。

  • 添加了在池化连接之前清理查询上下文缓存。

错误修复

  • 启用返回 DML 操作的结果集。

  • 添加了在获取操作结果时刷新过期会话的功能。

版本 4.5.0(2025 年 5 月 9 日)

新功能和改进

  • 添加了 OAuth 2.0 授权码流身份验证:

    • 添加了 oauth_authorization_code 身份验证器。

    • 添加了 oauthScopeoauthClientIdoauthClientSecretoauthAuthorizationUrloauthTokenRequestUrloauthRedirectUri 连接参数,用于配置身份验证。

    • 添加了通过设置 SnowflakeDbConnection.OAuthClientSecret 属性来提供 :codenowrap:`oauthClientSecret`(而非在连接字符串中提供该属性)的能力。

    • 添加了用于 OAuth 2.0 令牌的缓存。

  • 添加了 OAuth 2.0 客户端凭据流身份验证:

    • 添加了 oauth_client_credentials 身份验证器。

    • 添加了 oauthScopeoauthClientIdoauthClientSecretoauthTokenRequestUrl 连接参数,用于配置身份验证。

    • 添加了通过设置 SnowflakeDbConnection.OAuthClientSecret 属性来提供 :codenowrap:`oauthClientSecret`(而非在连接字符串中提供该属性)的能力。

  • 添加了编程式访问令牌身份验证:

    • 添加了 programmatic_access_token 身份验证器。

    • 增加了在连接字符串中指定 token 参数或通过设置 SnowflakeDbConnection.Token 属性指定此参数的能力。

  • 添加了对 schemeporthost 连接属性的验证。

  • 添加了通过设置 SnowflakeDbConnection.Token 属性提供令牌(而非在连接字符串中提供令牌)的能力。

错误修复

  • 无。

版本 4.4.1(2025 年 4 月 28 日)

新功能和改进

  • 无。

错误修复

  • 修复了检查 Easy Logging 配置文件访问权限时的 Time-of-check Time-of-use (TOCTOU) 争用条件。有关更多信息,请参阅 CVE-2025-46326 (https://github.com/snowflakedb/snowflake-connector-net/security/advisories/GHSA-c82r-c9f7-f5mj)。

  • 修复了取消与 CancellationTokenSourceCancelAsync() 的连接时,池使用量计数器不减少的问题。

版本 4.4.0(2025 年 4 月 10 日)

新功能和改进

  • 添加了用于外部浏览器身份验证的 SSO 令牌缓存和 client_store_temporary_credential 参数,以指示是否使用 SSO 缓存。

  • Implemented and improved the file-based credentials cache for Linux, including enhanced token caching.

错误修复

  • 修复了身份验证器不区分大小写的问题。在修复之前,如果身份验证器使用大写字符,则无法正确应用 username_password_mfaoauth 的逻辑。

  • 修复了向查询参数传递 null 时的问题。

  • 修复了从 Windows 凭据管理器读取令牌时出现的问题,该管理器用于 username_password_mfa 身份验证器。在某些情况下,从凭据管理器读取的值可能太长。

  • 对凭据管理器实现进行了一些细微改动,例如更改了某些日志级别,并就 Unix 上过于宽松的缓存目录权限发出警告,而非自动更改权限。

  • 修复了 AnsiString 参数与 TEXT 类型的绑定。

  • 修复了将结构化或半结构化数据加载到 DataTable 时的问题。

版本 4.3.0(2025 年 1 月 29 日)

新功能和改进

  • 添加了对在 TOML 文件中配置连接参数的支持。

  • 添加了 MFA 令牌缓存。

  • 添加了对 GCP 区域特定端点的支持。

  • 使通过 GET 下载的文件的加密标头不区分大小写。

  • 使用 .net9 框架测试了驱动程序。

  • 扩展了有关为 Windows 用户检查 CRL 端点的文档。

错误修复

  • 改进了放置在 OS 临时目录中的中间文件的安全性,使这些文件不再具有全局可读性。有关更多信息,请参阅 CVE-2025-24788 (https://github.com/snowflakedb/snowflake-connector-net/security/advisories/GHSA-2mqw-rq5m-8hc8)。

  • 修复了在失败响应中处理空数据的问题。

  • 修复了记录诊断信息的问题。

  • 修复了使用 GCS (Google Cloud Storage) 处理 PUT 命令的文件路径中空格的问题。

  • 修复了处理不带 https:// 前缀的 GCS 端点的问题。

  • 修复了通过 GET 操作下载文件时,文件元数据中没有 SFC_DIGEST 属性的问题。

  • 修复了在 Easy Logging 功能中使用 STDOUT 作为日志路径的功能。

语言: 中文