This discussion is archived
0 Replies Latest reply: Jan 29, 2013 6:01 PM by NexusChris RSS

Connection failure through Weblogic HTTP Authentication

NexusChris Newbie
Currently Being Moderated
Hi all

We are recently migrating webservice from 10g to 11g, but keep 10g client use for connecting the new 11g interface. Due to previous technical limitation, the 10g client is found failed to connect 11g and thus we built a middleware between them.

The webservice server side (11g) is protected with HTTP authentication on weblogic and we found that both 11g client and the middleware can connect the server side successfully authenticated. Only when we use the 10g to connect the middleware, server side blocks the transaction with error code 401 unauthorized.

Can everybody know any tricks behind, thanks in advance.

[ OK ] 11g ws client -----[HTTP AUTH] --------> 11g server

[ OK ] Middleware ----[library calls] ------> 11g ws client --------[HTTP AUTH] -------> 11g server

[ FAILED ] 10g client --------> Middleware ----[library calls] ----> 11g ws client ------[HTTP AUTH] -------> 11g server


The middleware is just a servlet to listen 10g client calls, and repeat it using 11g library toward 11g webservice.

*10g client*
    URL endpointURL = new URL(endpoint);
    org.apache.soap.rpc.Call call = new org.apache.soap.rpc.Call();
    call.setSOAPTransport(m_httpConnection);
    call.setTargetObjectURI("ServiceWS");
    call.setMethodName("service");
    call.setEncodingStyleURI(Constants.NS_URI_LITERAL_XML);

    Vector params = new Vector();
    params.addElement(new Parameter("element", Element.class, xmlData, Constants.NS_URI_LITERAL_XML));
    call.setParams(params);

    call.setSOAPMappingRegistry(m_smr);
    Response response = call.invoke(endpointURL, "");
Cheers
Chris

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points