Expand my Community achievements bar.

SOLVED

How to make CXF support HTTPS webservice invoking?

Avatar

Former Community Member

Hi there,

when i use CXF to invoke remote webservice that support HTTPS protocol:

07.04.2015 13:56:48.033 *INFO* [fe80:0:0:0:e041:4e24:9c99:e38%11 [1428386208033] GET /content/xxx/jcr_content.persist.json HTTP/1.1] com.adobe.cq.CustomerServiceImpl xxx configure url: https://w113.xxxx.com:8443/xxx/aemServices/WebService4AEM?wsdl

but it happens error:

com.XXX.www.webservices.WebServiceException_Exception: Web services is not installed.

 

And i also invoke setTrustStore before to invoke webservice:

private void setTrustStore() { StringBuffer certsPath = new StringBuffer(); String javaHome = System.getProperty("java.home"); if (javaHome == null || "".equals(javaHome)) { log.error("JAVA_HOME is null, please set it."); return; } certsPath.append(javaHome == null ? "" : javaHome) .append(File.separator).append("lib").append(File.separator) .append("security"); File file = new File(certsPath.toString(), "cacerts"); if (!file.exists() || !file.isFile()) { file = new File(certsPath.toString(), "jssecacerts"); log.info("cacerts file created."); } if (file.exists()) { String path = file.getAbsolutePath(); System.setProperty("javax.net.ssl.trustStore", path); log.info("cacerts path: " + path); // password is not required // System.setProperty("javax.net.ssl.trustStorePassword","changeit"); } }

 

Anyone know how to deal with it? Please comment here.

 

Thanks a lot.

Best regards,

Brian 

1 Accepted Solution

Avatar

Correct answer by
Level 10

We do have a community article on CFX WS and AEM. 

https://helpx.adobe.com/experience-manager/using/creating-cxf-bundles-consume-web.html

however - it does not use HTTPs. Information about using HTTPs and CFX can be found in Apahce docs at:

http://cxf.apache.org/docs/ws-security.html

Not sure if AEM supports this. If you read all the Apache docs and build the bundle and its still not working - you may want to open a ticket. 

View solution in original post

1 Reply

Avatar

Correct answer by
Level 10

We do have a community article on CFX WS and AEM. 

https://helpx.adobe.com/experience-manager/using/creating-cxf-bundles-consume-web.html

however - it does not use HTTPs. Information about using HTTPs and CFX can be found in Apahce docs at:

http://cxf.apache.org/docs/ws-security.html

Not sure if AEM supports this. If you read all the Apache docs and build the bundle and its still not working - you may want to open a ticket.