This commit is contained in:
Looly
2024-05-13 16:50:05 +08:00
parent 73764db818
commit cf44ae005a
3 changed files with 20 additions and 2 deletions

View File

@@ -229,7 +229,7 @@ public class HttpGlobalConfig implements Serializable {
* @param customTrustAnyHost 如果设置为{@code false}则按照JDK默认验证机制验证目标服务器的证书host和请求host是否一致{@code true}表示不验证。
* @since 5.8.27
*/
public static void setTrustAnyHost(boolean customTrustAnyHost) {
public static void setTrustAnyHost(final boolean customTrustAnyHost) {
trustAnyHost = customTrustAnyHost;
}
}

View File

@@ -40,7 +40,9 @@ public class SSLInfo {
/**
* 默认{@code SSLInfo},全部为{@code null},使用客户端引擎默认配置
*/
public static final SSLInfo DEFAULT = SSLInfo.of();
public static final SSLInfo DEFAULT = SSLInfo.of()
// issue#3582
.setSslContext(SSLContextUtil.getDefault());
/**
* 信任所有的{@code SSLInfo}