首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >有没有人尝试过在Windows1121h2中使用TLS1.3使用SChannel?

有没有人尝试过在Windows1121h2中使用TLS1.3使用SChannel?
EN

Stack Overflow用户
提问于 2022-01-19 08:34:47
回答 3查看 1.7K关注 0票数 1

我正在开发一个需要升级以在Windows11上使用TLS 1.3的TLS客户端。是否有人使用SChannel API成功地实现了TLS1.3?

如下面所示,win-11 & server-2022支持链接TLS 1.3。

https://learn.microsoft.com/en-us/windows/win32/secauthn/protocols-in-tls-ssl--schannel-ssp-

下面是为TLS1.3添加的代码片段:

代码语言:javascript
运行
复制
#define SECURITY_PROTOCOL_TLSV13 0x00
securityInfo->bySecurityProtocol = SECURITY_PROTOCOL_TLSV13;
sChannelCred->grbitEnabledProtocols =SP_PROT_TLS1_3_CLIENT;

status = pMyFunTab->**AcquireCredentialsHandleA**(NULL, UNISP_NAME_A, SECPKG_CRED_OUTBOUND, NULL, &sChannelCred, NULL, NULL, phCred, &ts);

返回状态= SEC_E_ALGORITHM_MISMATCH(0x80090331)

**error details: Secure connection failed. An error occurred while trying to connect to the host, error code 0x80090331. The client and server cannot communicate, because they do not possess a common algorithm.**

api链接:

https://learn.microsoft.com/en-us/windows/win32/api/sspi/nf-sspi-acquirecredentialshandlea https://github.com/MicrosoftDocs/win32/blob/docs/desktop-src/SecAuthN/acquirecredentialshandle--schannel.md

尝试了下面的更改来修复相同的问题:

Windows版本测试: windows 11 21h2 os build 22000.434

注册表更改:如下所示:链接:how to enable TLS 1.3 in windows 10

任何建议或一小部分C++代码片段都很受欢迎,以及任何可能帮助我理解客户端问题的建议。

FYI:我没有用卷发假发.

谢谢

问候: Ajay Jaiswal

EN

Stack Overflow用户

发布于 2022-01-25 06:08:38

你在Win10或Win11上尝试过最新的curl7.81.0吗?以下是我所看到的。

代码语言:javascript
运行
复制
curl -vI --tls-max 1.3 https://www.google.com
*   Trying 142.251.35.164:443...
* Connected to www.google.com (142.251.35.164) port 443 (#0)
* schannel: disabled automatic use of client certificate
* schannel: TLS 1.3 is not yet supported
* Closing connection 0
curl: (35) schannel: TLS 1.3 is not yet supported
票数 1
EN
查看全部 3 条回答
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/70767482

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档