通过将https.protocol设置为TLSv1.2来执行wsimport

时间:2016-03-10 12:12:42

标签: java web-services wsimport tls1.2

我想使用wsdl导入Web服务。服务器正在使用TLSv1.2。

使用java代码我通过设置System.setProperty("https.protocols", "TLSv1.2");

连接到服务器

使用wsimport时如何执行相同操作?我正在使用Java 1.7.0_65。

当我尝试wsimport <wsdl-url>时,我正在

parsing WSDL...


[ERROR] Received fatal alert: protocol_version

Failed to read the WSDL document: https://<server-name>/Test/Test/Transform?wsdl, because 1) could not find the document; /2) the document cou
ld not be read; 3) the root element of the document is not <wsdl:definitions>.


[ERROR] failed.noservice=Could not find wsdl:service in the provided WSDL(s):

 At least one WSDL with at least one service definition needs to be provided.


    Failed to parse the WSDL.

1 个答案:

答案 0 :(得分:0)

q_search