gpt4 book ai didi

php - AADSTS1002016 : You are using TLS version 1. 0、1.1 和/或 3DES 密码已弃用,以改善 Azure AD 的安全状况

转载 作者:行者123 更新时间:2023-12-03 03:36:09 25 4
gpt4 key购买 nike

我在我的一个 PHP 应用程序上启用了 Azure 登录,并按照以下文档使用 cUrl 启用此功能 https://learn.microsoft.com/en-us/azure/active-directory/develop/v2-oauth2-auth-code-flow

直到几天前,当我请求 token 时收到授权码后,它才工作正常,即 https://login.microsoftonline.com/{tenant_id}/oauth2/v2.0/token

我收到返回错误

{"error":"invalid_request","error_description":"AADSTS1002016: You are using TLS version 1.0, 1.1 and/or 3DES cipher which are deprecated to improve the security posture of Azure AD. Your TenantID is: {tenant_id}. Please refer to https://go.microsoft.com/fwlink/?linkid=2161187 and conduct needed actions to remediate the issue. For further questions, please contact your administrator."}

已在应用服务器上禁用 tls1 和 1.0 以及 3DES 密码。负载均衡器上的配置也相同。

我的/etc/httpd/conf.d/ssl.conf包含以下内容

 SSLCipherSuite HIGH:MEDIUM:!aNULL:!MD5:!DES:!3DES
SSLHonorCipherOrder on
SSLProtocol all -SSLv2 -SSLv3 -TLSv1 -TLSv1.1

最佳答案

需要强制curl才能使用tls1.2

curl --tlsv1.2 {...REST_OF_CURL}

PHP 代码

$chwnd = curl_init();
curl_setopt ($chwnd, CURLOPT_SSLVERSION, 6);
curl_exec($chwnd);

关于php - AADSTS1002016 : You are using TLS version 1. 0、1.1 和/或 3DES 密码已弃用,以改善 Azure AD 的安全状况,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/73283734/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com