gpt4 book ai didi

sockets - 使用 demo.docusign.net 提供的 docusign Rest API 时获取 ssl socket factory null

转载 作者:太空宇宙 更新时间:2023-11-03 13:38:28 24 4
gpt4 key购买 nike

我在使用由“https://demo.docusign.net”提供的 Docusign Rest API 时遇到 ssl 认证错误' 在 IBM websphere 中。我下载'演示 ssl 证书并从 https://trust.docusign.com/certificates 添加

I am using api like this....
Proxy proxy = new Proxy(Proxy.Type.HTTP, new InetSocketAddress("......", 81));
AuthenticateRequest authReq = null;
if(appConfiguration == null)
authReq = new AuthenticateRequest(configuration);
else
authReq = new AuthenticateRequest(configuration,appConfiguration);

System.out.println(url);
logger.debug("url : "+url);
logger.debug("Request : "+authReq.toJSONString());


HttpURLConnection connection = (HttpURLConnection) new URL(url).openConnection(proxy);
connection.setRequestMethod("GET");
connection.setRequestProperty(DOCU_SIGN_AUTH, authReq.toJSONString());
connection.setRequestProperty(ACCEPT, CONTENT_TYPE_VALUE);
connection.setRequestProperty(CONTENT_TYPE, CONTENT_TYPE_VALUE);


if(connection.getResponseCode()==HttpStatus.SC_OK || connection.getResponseCode() == HttpStatus.SC_CREATED) {

String response = getResponse(connection);
connection.disconnect();
return response;
}

****Error found....****
SSLSocketFactory is null. This can occur if javax.net.ssl.SSLSocketFactory.getDefault() is called to create a socket and javax.net.ssl.* properties are not set.

最佳答案

friend 们好,

我找到了解决方案,只需将 javax.net.ssl.trustStoreType=JKS"设置为 WebSphere Application servers > server1 > Process definition > Java Virtual Machine > Custom properties

阅读更多信息
http://www.coderanch.com/t/573425/Web-Services/java/javax-net-ssl-SSLException-SSLSocketFactory

http://www-01.ibm.com/support/docview.wss?uid=swg1PM14425

关于sockets - 使用 demo.docusign.net 提供的 docusign Rest API 时获取 ssl socket factory null,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32435202/

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