wsdl2java - WARNING: Default key managers cannot b

2019-07-19 04:39发布

While generating java WSDL client I am receiving these errors. Can you please help me to understand these?

C:\Users\Administrator\workspace\apache-cxf-3.0.2\bin> wsdl2java https://example.com/V1/HelpService?wsdl

*Nov 03, 2014 1:11:20 PM org.apache.cxf.configuration.jsse.SSLUtils getDefaultKeyStoreManagers WARNING: Default key managers cannot be initialized: C:\Users\Administrator.keystore (The system cannot find the file specified)

Nov 03, 2014 1:11:20 PM org.apache.cxf.configuration.jsse.SSLUtils getDefaultKeyStoreManagers WARNING: Default key managers cannot be initialized: C:\Users\Administrator.keystore (The system cannot find the file specified)

Nov 03, 2014 1:11:21 PM org.apache.cxf.configuration.jsse.SSLUtils getDefaultKeyStoreManagers WARNING: Default key managers cannot be initialized: C:\Users\Administrator.keystore (The system cannot find the file specified)*

C:\Users\Administrator\workspace\apache-cxf-3.0.2\bin>

标签: cxf wsdl2java
1条回答
三岁会撩人
2楼-- · 2019-07-19 05:17

Your problem is that the property javax.net.ssl.keyStore is not specified and if it is not specified .keystore is used in your home directory. If .keystore does not exist you will get this error.

Snip from org.apache.cxf.configuration.jsse.SSLUtils.java :

public static String getKeystore(String keyStoreLocation, Logger log) 

...//some other code

keyStoreLocation = SystemPropertyAction.getProperty("javax.net.ssl.keyStore");
if (keyStoreLocation != null) {
    logMsg = "KEY_STORE_SYSTEM_PROPERTY_SET";
} else {
keyStoreLocation =
    SystemPropertyAction.getProperty("user.home") + "/.keystore";
    logMsg = "KEY_STORE_NOT_SET";
}
查看更多
登录 后发表回答