Hi

You can use CXF HttpConduit to set up the client certs, please check the archives there are many examples of it, or try JAXRS 2.0 Client API, it allows setting the client certs using the standard API

HTH, Sergey
On 12/09/14 13:04, Adrián Roselló Rey wrote:
Hi!

Some months ago I used JAXRSClientFactoryBean to programatically create a
REST client for a remote application. Please find the code to create the
client:












*       ProxyClassLoader classLoader = new ProxyClassLoader();
classLoader.addLoader(apiClass.getClassLoader());
classLoader.addLoader(JAXRSClientFactoryBean.class.getClassLoader());
     JAXRSClientFactoryBean bean = new JAXRSClientFactoryBean();
bean.setAddress(address);        bean.setResourceClass(MyClass.class);
     bean.setClassLoader(classLoader);        return
bean.create(MyClass.class);*


I can't use my client any more, since security module has been implemented
in the server side. It's based in x509 certificates.

The curl command looks like this:

*curl --cert my_cer.pem --key user_cer.pkey .....*

How do I configure the client to use such authentication type? How do I
integrate the user certificate in the request?

Thanks a lot!

All the best,

Adrián Roselló Rey



--
Sergey Beryozkin

Talend Community Coders
http://coders.talend.com/

Blog: http://sberyozkin.blogspot.com

Reply via email to