Problem in updating a java client to invoke data-secured web service

hello
i'm following the document 'programming weblogic web services' to use ws-security
functionality to encrypt & digitally sign SOAP Request & Response
and I first made a client that calls a secure weblogic web service.
( using a keystore having RSA key pair. )
the code is like below -----------------------------------------------------------------
final KeyStore keystore = loadKeystore(CLIENT_KEYSTORE, KEYSTORE_PASS);
TestEJB_Impl service = new TestEJB_Impl("file:///C:/bea/user_projects/domains/FirstDomain/working/TestEJB_with_Security_surpport.wsdl");
WebServiceContext context = service.context();
System.out.println("passing context info to the client");
X509Certificate clientcert;
clientcert = getCertificate(CLIENT_KEYNAME, keystore);
PrivateKey clientprivate;
clientprivate = getPrivateKey(CLIENT_KEYNAME, CLIENT_KEYPASS, keystore);
WebServiceSession session = context.getSession();
session.setAttribute(WSSEClientHandler.CERT_ATTRIBUTE, clientcert);
session.setAttribute(WSSEClientHandler.KEY_ATTRIBUTE, clientprivate);
UserInfo ui = new UserInfo(AUTHENTICATION_USER, AUTHENTICATION_USER_PASS);
session.setAttribute(WSSEClientHandler.REQUEST_USERINFO, ui);
TestEJBPort port = service.getTestEJBPort();
String result = null;
result = port.firstMethodTest("A123");
System.out.println(result);
and there comes error stacktrace like below ------------------------------
<Info> <WebService> <BEA-220024> <Handler
weblogic.webservice.core.handler.WSSEClientHandler threw an exception from its
h
andleRequest method. The exception was:
weblogic.xml.security.SecurityConfigurationException: Failed adding encryption
t
o request - with nested exception:
[weblogic.xml.security.SecurityProcessingException: No keywrapping algorithm ava
ilable for DSA keys].>
Exception in thread "main" java.rmi.RemoteException: SOAP Fault:javax.xml.rpc.so
ap.SOAPFaultException: Exception during processing: weblogic.xml.security.Securi
tyConfigurationException: Failed adding encryption to request - with nested exce
ption:
[weblogic.xml.security.SecurityProcessingException: No keywrapping algorithm ava
ilable for DSA keys] (see Fault Detail for stacktrace)
Detail:
<detail>
<bea_fault:stacktrace xmlns:bea_fault="http://www.bea.com/servers/wls70/webse
rvice/fault/1.0.0">
</bea_fault:stacktrace>weblogic.xml.security.SecurityProcessingException: No
ke
ywrapping algorithm available for DSA keys
at weblogic.xml.security.wsse.v200207.SecurityImpl.getWrappingAlgorithm(
SecurityImpl.java:200)
at weblogic.xml.security.wsse.v200207.SecurityImpl.addEncryption(Securit
yImpl.java:175)
at weblogic.xml.security.wsse.v200207.SecurityImpl.addEncryption(Securit
yImpl.java:153)
i am using RSA key pair but, when i use DSA key pair , the error message is same
as above.
what is problem? and what am i missing?

Hello,
The current implementation only supports RSA key types as legal
wrapping. It is on the TODO list to expand this to other algorithms.
Regards,
Bruce
dolso wrote:
>
hello
i'm following the document 'programming weblogic web services' to use ws-security
functionality to encrypt & digitally sign SOAP Request & Response
and I first made a client that calls a secure weblogic web service.
( using a keystore having RSA key pair. )
the code is like below -----------------------------------------------------------------
final KeyStore keystore = loadKeystore(CLIENT_KEYSTORE, KEYSTORE_PASS);
TestEJB_Impl service = new TestEJB_Impl("file:///C:/bea/user_projects/domains/FirstDomain/working/TestEJB_with_Security_surpport.wsdl");
WebServiceContext context = service.context();
System.out.println("passing context info to the client");
X509Certificate clientcert;
clientcert = getCertificate(CLIENT_KEYNAME, keystore);
PrivateKey clientprivate;
clientprivate = getPrivateKey(CLIENT_KEYNAME, CLIENT_KEYPASS, keystore);
WebServiceSession session = context.getSession();
session.setAttribute(WSSEClientHandler.CERT_ATTRIBUTE, clientcert);
session.setAttribute(WSSEClientHandler.KEY_ATTRIBUTE, clientprivate);
UserInfo ui = new UserInfo(AUTHENTICATION_USER, AUTHENTICATION_USER_PASS);
session.setAttribute(WSSEClientHandler.REQUEST_USERINFO, ui);
TestEJBPort port = service.getTestEJBPort();
String result = null;
result = port.firstMethodTest("A123");
System.out.println(result);
and there comes error stacktrace like below ------------------------------
<Info> <WebService> <BEA-220024> <Handler
weblogic.webservice.core.handler.WSSEClientHandler threw an exception from its
h
andleRequest method. The exception was:
weblogic.xml.security.SecurityConfigurationException: Failed adding encryption
t
o request - with nested exception:
[weblogic.xml.security.SecurityProcessingException: No keywrapping algorithm ava
ilable for DSA keys].>
Exception in thread "main" java.rmi.RemoteException: SOAP Fault:javax.xml.rpc.so
ap.SOAPFaultException: Exception during processing: weblogic.xml.security.Securi
tyConfigurationException: Failed adding encryption to request - with nested exce
ption:
[weblogic.xml.security.SecurityProcessingException: No keywrapping algorithm ava
ilable for DSA keys] (see Fault Detail for stacktrace)
Detail:
<detail>
<bea_fault:stacktrace xmlns:bea_fault="http://www.bea.com/servers/wls70/webse
rvice/fault/1.0.0">
</bea_fault:stacktrace>weblogic.xml.security.SecurityProcessingException: No
ke
ywrapping algorithm available for DSA keys
at weblogic.xml.security.wsse.v200207.SecurityImpl.getWrappingAlgorithm(
SecurityImpl.java:200)
at weblogic.xml.security.wsse.v200207.SecurityImpl.addEncryption(Securit
yImpl.java:175)
at weblogic.xml.security.wsse.v200207.SecurityImpl.addEncryption(Securit
yImpl.java:153)
i am using RSA key pair but, when i use DSA key pair , the error message is same
as above.
what is problem? and what am i missing?

Similar Messages

  • Unable to invoke a secured web service

    Hi all
    I have been trying to call a secured web service which enforces wss11_saml_token_with_message_protection_client_policy policy. To create a web proxy in JDev, I am using the following wiki - http://aseng-wiki.us.oracle.com/asengwiki/display/ASDevOWSM/How+can+I+create+a+JSE+client+to+invoke+ADF+BC+Web+Service+with+OWSM+wss11_saml_token_with_message_protection_service_policy (scroll down to find "Creating JSE client for above Web service")
    I have got the default-keystore.jks, cwallet.sso and jps-config.xml from the webservice env. I am getting this error now -
    SEVERE: WSM-00055 The keystore located at xyzabc\default-keystore.jks cannot be loaded due to java.io.IOException: Keystore was tampered with, or password was incorrect. Ensure that valid keystore type and password are configured.
    Any pointers would be appreciated.
    Thanks,
    Pushkal

    One more update i tried printing l_http_response.status_code and got 302.
    Thanks,
    PKV

  • Invoking a secure web service from a standalone java client

    I am using stand alone java client to invoke a web service. This web service in turn invokes a jcs which is protected ( role based access ).
    I am using a proxy at the client side for web service invocation
    FileSubmission_Impl filesubmission_impl = new FileSubmission_Impl();
    FileSubmissionSoap filesubmissionsoap = filesubmission_impl.getFileSubmissionSoap();
    filesubmissionsoap.processFiles(...)
    This works if there are no security constraints on any of the resources (@common:security).
    I need to pass the username and password from the java client that will be authenticated and allowed to access the protected resources.
    Please let me know as to how this can be achieved ( passing username and password from client )

    Paula,
    I suppose you're using CFINVOKE (http://www.activsoftware.com/code_samples/code.cfm/CodeID/44/ColdFusion/Invoking_SOAP_Web_Services_with_ColdFusion_MX_CFINVOKE_Tag) or are you using a third party tool like CFX_SOAP (http://www.activsoftware.com/products/productdetail.cfm/id/1015)?
    Are you working with WebAS 6.4 or 6.2?
    It works with web services created with WebAS 6.4, but you should generate proxy classes. Check Thomas' weblog (second part of it)->https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/1012. [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken]
    The WSDL generated by this method is more standard than the one generated when you just Remote enable an FM and look at the webservice browser.
    Th core of CF MX is Java and that engine is rather strict in standards.
    Eddy

  • Build soap client to invoke jax-rpc web services

    Hi,
    I would like realize a simple soap java client to invoke a web services starting from wdsl file configuration of my web services.
    Thanks,
    Enrico.

    Hi,
    You can use jax-rpc to invoke the web services by creating stubs classes in your client side using wsdl. If you have ant ,then use wscompile command (in ant) or through dos command passing this wsdl file as parameter to create stubs classes automatically.And then set your classpaths accordingly when calling the web services from your client.
    thanks
    javaonlyjava

  • How to create stub for C++ client to invoke a  j2ee web service

    Hi All,
    I have developed a j2ee web service which is deployed in Tomcat. I have to call this service from C++ client. I have followed "Axis C++ Client User's Guide" to create stub for my service. I am running WSDL2Ws tool with command
    D:\axisserver\axis-c-win\wsdls>java -cp %AXISCLASSPATH_C%; org.apache.axis.wsdl.wsdl2ws.WSDL2Ws Calculator.wsdl -lc++ -sclient. While running this WSDL2Ws tool , it is giving error.
    Exception Stack is as follows.
    Exception in thread "main" java.lang.NoSuchMethodError
    at org.apache.axis.wsdl.wsdl2ws.info.Type.<init>(Unknown Source)
    at org.apache.axis.wsdl.wsdl2ws.info.TypeMap.getType(Unknown Source)
    at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.createParameterInfo(Unknown Source)
    at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.addRPCStyleInputMessageToMethodInfo(Unknown Source)
    at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.setMethodInfo(Unknown Source)
    at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.getServiceInfo(Unknown Source)
    at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.generateWrappers(Unknown Source)
    at org.apache.axis.wsdl.wsdl2ws.WSDL2Ws.main(Unknown Source)
    Anybody can suggest me what i missed...
    Thanks in advance...

    Hi all,
    I have solved this issue. I had JDK1.3 by default. So it was giving error. When i use java from jdk1.4, it created stubs for web service. Java version was the problem. Now it is working fine.
    Thanks....

  • Java client failing to connect to web service - help!!

    Hi
    I have created a Web service using ASP Web Matrix, which currently resides on my C drive in c:\Service6\HelloWorld.asmx.
    The service can be tested from a browser on my local machine by calling: http://localhost/Service6/HelloWorld.asmx. This works fine, i.e. it takes a string as a parameter and returns an amended string.
    When I try to access this from a Java client I created in Netbeans, however, I get the following error message:
    Server did not recognize the value of HTTP Header SOAPAction: sayHiya.
    at System.Web.Services.Protocols.Soap11ServerProtocolHelper.RouteRequest()
    at System.Web.Services.Protocols.SoapServerProtocol.Initialize()
    at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, HttpRequest request, HttpResponse response, Boolean& abortProcessing)
    Can anyone advise what I am doing wrong?
    [nb. I have spent over a week trying to sort this, so I have tried!!)
    The code for the client follows:-
    // The Axis package is used to generate and handle the SOAP call
    import org.apache.axis.client.Call;
    import org.apache.axis.client.Service;
    import org.apache.axis.encoding.XMLType;
    // The rpc package is used to create the RPC call
    import javax.xml.namespace.QName;
    import javax.xml.rpc.NamespaceConstants;
    // The java.net package gives a URL class
    import java.net.URL;
    public class HelloWorldClient {
        /** Creates a new instance of HiyaClient */
        public static void main(String[] args)
    try
    String endpoint = "http://localhost/Service6/HelloWorld.asmx";
    Service service = new Service();
    Call call = (Call) service.createCall();
    // Configure the call
    call.setTargetEndpointAddress(new URL(endpoint));
    call.setSOAPActionURI("sayHello");
    call.setEncodingStyle(NamespaceConstants.NSURI_SOAP_ENCODING);
    call.setOperationName(new QName("urn:HelloWorld", "sayHello"));
    //call.setReturnType(XMLType.XSD_STRING);
    System.out.println("**Works to here**");
    //Invoke the call
    String result = (String) call.invoke(new Object[] { "Diane" });
    System.out.println("Sent 'Diane', got '" + result + "'");
    catch(Exception e)
    System.err.println(e.toString());

    Hiya, did try that - tried
    "http://localhost:8080/HelloWorld.asmx" and
    "http://localhost:8080/Service6/HelloWorld.asmx" and it still didn't work.
    Thanks anyway.
    Anyone else got any bright ideas?

  • Handshaking problem while invoking a secured web service

    Hi,
    I have developed a web service. I made my WLS 7.0 secured, using SSL. Also
    I made the
    my web service accessible only by https protocol. Also I configured the WLS SSL
    to have one
    way SSL. The problem is I am not able to access this web service using a swing
    client, It throws
    an exception saying some Handshaking exception. This problem occured only when
    I made
    the web service secured (https).
    Has anybody faced this problem ever?.
    For one way SSL do I need to supply any certificate file or PEM file from the
    client to the
    server?.
    Thanks,
    Anish

    Hi Anish,
    No, in this case the client is checking the cert provided by the
    server. Have you tried the flag
    -Dweblogic.webservice.client.ssl.strictcertchecking=false on the client
    side?
    Also take a look at the entry by Michael Jouravlev, on SSL "how to"
    http://newsgroups.bea.com/cgi-bin/dnewsweb?cmd=article&group=weblogic.developer.interest.webservices&item=1910&utag=
    Have you gone through the simpleSSL example:
    http://webservice.bea.com/simpleSSL.zip
    HTHs,
    Bruce
    Anish wrote:
    >
    Hi,
    I have developed a web service. I made my WLS 7.0 secured, using SSL. Also
    I made the
    my web service accessible only by https protocol. Also I configured the WLS SSL
    to have one
    way SSL. The problem is I am not able to access this web service using a swing
    client, It throws
    an exception saying some Handshaking exception. This problem occured only when
    I made
    the web service secured (https).
    Has anybody faced this problem ever?.
    For one way SSL do I need to supply any certificate file or PEM file from the
    client to the
    server?.
    Thanks,
    Anish

  • OWSM 11g: Invoking a secured web service through a java proxy service

    Hi All,
    I am trying to call a secured bpel service which is expecting a username token password. I have created a java proxy service for the same. I now need to add the username token to the same. Can anyone please guide me in this regard.
    Thanks in advance.

    Just to add some pointers,
    I added the following code to the proxy still the soap headers is not getting propagated.
    OrderBookingAndShipment orderBookingAndShipment = orderbookingandshipment_client_ep.getOrderBookingAndShipment_pt();
    String username = "OWSM_11g";
    String password = "password";
    List credProviders = new ArrayList();
    //client side UsernameToken credential provider
    CredentialProvider cp = new ClientUNTCredentialProvider(username.getBytes(),password.getBytes());
    credProviders.add(cp);
    Map<String,Object> context = ((BindingProvider) orderBookingAndShipment).getRequestContext();
    context.put(WSSecurityContext.CREDENTIAL_PROVIDER_LIST,credProviders);

  • Java client for calling a XI web service

    Hello,
    does anyone have created a Java client
    with Apache Axis? I tried it and it works
    for web service which aren't provided by
    SAP XI, but if I use to call a XI web service
    something went wrong.
    The XI web service works. I tested it with
    XML Spy.
    I think there must be something special with
    XI web service.
    So anyone got a tutorial/guide for this???
    thanks
    chris

    Hola mi  nombre es Luis,
    Creyendo que eres español te escribo en tal idioma.
    He visto que a ti también te devolvía un error de autentificación 401, y que lo subsanaste, pero a mi con la solución que te dieron no me vale, ya que implemento el código que te ofrecieron para arreglarlo y ahora me da un fallo de "Server Error" poniendo en usuario y password, los correspondientes a XI.
    +Request_MI_outTurnoverDetailsDisplay_MI_outTurnoverDetailsDisplay req=new Request_MI_outTurnoverDetailsDisplay_MI_outTurnoverDetailsDisplay();
    wdContext.nodeRequest_MI_outTurnoverDetailsDisplay_MI_outTurnoverDetailsDisplay().bind(req);
    req._setUser("username");
    req._setPassword("password");+
    No sé si es que ese usuario y contraseña son otros distintos.
    Si pudieras ayudarme, te lo agradecería.
    Un saludo, Luis

  • Problems to invoke a secure Web service from Oracle BPM Studio 10.3

    Hi all
    I'm trying to consume a web service through HTTPS protoloco Oracle BPM Studio v10.3, but I get the following error: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target.
    Some help!!
    Thanks

    Without going into any technical discussion about the code, my first question is what JDK version was used to create this which was imported into the form? Understand that Forms 10 runs on JDK 1.4.2, so if you used any newer JDK version, likely there will be problems.

  • Invoking a secured web service

    Hello,
    I'm using a clustered osb with a loadbalancer, i have two nodes osb1 and osb2.
    i'm trying to test a secured business service which points to a web service deployed on another server.
    i installed its certificate in both nodes.
    if i stop osb1, the test is always successful.
    if i stop osb2, the test always fails.
    if they are both running, the test fails sometimes and succeeds sometimes.
    the log in osb1 contains the following errors :
    java.security.InvalidKeyException: Illegal key size
    at javax.crypto.Cipher.a(DashoA13*..)
    at javax.crypto.Cipher.init(DashoA13*..)
    at javax.crypto.Cipher.init(DashoA13*..)
    <Error> <WliSbTransports> <BEA-381304> <Exception in HttpTransportServlet.service: java.net.SocketException: Broken pipe
    java.net.SocketException: Broken pipe
    at java.net.SocketOutputStream.socketWrite0(Native Method)
    at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92)
    at java.net.SocketOutputStream.write(SocketOutputStream.java:136)
    at weblogic.utils.io.ChunkedOutputStream.writeTo(ChunkedOutputStream.java:193)
    at weblogic.servlet.internal.ResponseHeaders.writeHeaders(ResponseHeaders.java:434)
    Truncated. see log file for complete stacktrace
    <Error> <Socket> <soaapp1> <osbms1> <ExecuteThread: '4' for queue: 'weblogic.socket.Muxer'> <<WLS Kernel>> <> <> <1263614497772> <BEA-000403> <IOException occurred on socket: Socket[addr=/10.100.10.112,port=59913,localport=7001]
    java.net.SocketException: Connection refused.
    java.net.SocketException: Connection refused
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:129)
    at weblogic.socket.SocketMuxer.readReadySocketOnce(SocketMuxer.java:887)
    at weblogic.socket.SocketMuxer.readReadySocket(SocketMuxer.java:859)
    at weblogic.socket.DevPollSocketMuxer.processSockets(DevPollSocketMuxer.java:120)
    at weblogic.socket.SocketReaderRequest.run(SocketReaderRequest.java:29)
    at weblogic.socket.SocketReaderRequest.execute(SocketReaderRequest.java:42)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:145)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:117)
    the log in osb2 contains the following error :
    <Error> <WliSbTransports> <BEA-381304> <Exception in HttpTransportServlet.service: java.net.SocketException: Broken pipe
    java.net.SocketException: Broken pipe
    at java.net.SocketOutputStream.socketWrite0(Native Method)
    at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92)
    at java.net.SocketOutputStream.write(SocketOutputStream.java:136)
    at weblogic.utils.io.ChunkedOutputStream.writeTo(ChunkedOutputStream.java:193)
    at weblogic.servlet.internal.ResponseHeaders.writeHeaders(ResponseHeaders.java:434)
    Truncated. see log file for complete stacktrace
    <Error> <Socket> <soaapp2> <osbms2> <ExecuteThread: '2' for queue: 'weblogic.socket.Muxer'> <<WLS Kernel>> <> <> <1261190759758> <BEA-000403> <IOException occurred on socket: Socket[addr=/10.100.10.112,port=41815,localport=7001]
    java.net.SocketException: Connection refused.
    java.net.SocketException: Connection refused
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:129)
    at weblogic.socket.SocketMuxer.readReadySocketOnce(SocketMuxer.java:887)
    at weblogic.socket.SocketMuxer.readReadySocket(SocketMuxer.java:859)
    at weblogic.socket.DevPollSocketMuxer.processSockets(DevPollSocketMuxer.java:120)
    at weblogic.socket.SocketReaderRequest.run(SocketReaderRequest.java:29)
    at weblogic.socket.SocketReaderRequest.execute(SocketReaderRequest.java:42)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:145)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:117)
    >
    could someone help?

    Hi - I know it has been a long time since you posted into this forum. I am seeing a similar error though I have "Hostname verification" set to none. Can you please tell me if your problem has been fixed and if so, how? Thanks

  • Can config wallet on cloud DB for security web service invoke ?

    Currently, I can invoke the security web service by APEX at my local DB env.
    based the apex_web_service API
    http://docs.oracle.com/cd/E37546_01/doc/doc.41/e28475/apex_web_service.htm#AEAPI537
    we need wallet to store the cert files.
    want to confirm that
    --> Can we config wallet to import cert files on cloud DB?
    Thanks
    Edited by: 985754 on Feb 6, 2013 2:17 AM

    Hello 985754,
    Unfortunately, you cannot import your own certificates into the wallet used by Application Express in the Database Cloud Service. However, this wallet already contains many common CA certificates. Unless the web service you are consuming uses a self-signed certificate, chances are you will be able to use this functionality in the Cloud.
    -- Vlad

  • Invoking a AXIS Web Service with a Java object as input argument

    Hi
    I've been trying to execute a bpel process that invokes a web service deployed through axis.
    This web service takes a java object as input argument as opposed to data types that are directly mapped to java types through the SOAP engine.
    I deployed and tested the service outside of BPEL using a test client class. Everything works well.
    When I try to configure the "Assign" and "Invoke" activities so that service can be invoked, I cannot see the data structure through the variable picker and I see the following message:
    "The element {urn:ComplexTypeWebService}TimeSheetBean is not know to the schema container. Perhaps a schema file that uses it needs to include or import its definition.There mat also be an XML schema issue (non resolvable schema) which prevents {urn:ComplexTypeWebService}TimeSheetBean from being seen by the schema processor."
    Is there any example that demonstrates how to invoke an axis web service in such scenario? What am I doing wrong?
    Please, let me know.

    The passing of Java objects in and out of a web service is NOT supported. variables must be xml documents defined by a XML schema. In my opinion, missing Java object and WSDL is not a good idea. -Edwin

  • Security exception while running the java client for a secured web service.

    hi,
    I created a proxy for a secured web service.
    When I run the client java program I am getting the following exception :
    java.io.IOException: could not load the default-keystore.jks file because The keystore file is tampered or password is incorrect.
    Its saying that password is invalid.
    Can you please help me on this thanks in advance.
    Regards,
    Chandra

    hi,
    I created a proxy for a secured web service.
    When I run the client java program I am getting the following exception :
    java.io.IOException: could not load the default-keystore.jks file because The keystore file is tampered or password is incorrect.
    Its saying that password is invalid.
    Can you please help me on this thanks in advance.
    Regards,
    Chandra

  • JWSDP 1.5 client and WSE 2.0 Web Service

    Hello all
    This post is mostly about .Net and WSE 2.0 but here goes:
    I�m securing a web service using WSE 2.0. One of the potential client�s of the web service is a Java client using Sun JWSDP 1.5. The problem is that the java client gets the error �Server did not recognize the value of HTTP Header SOAPAction:�, and when I look at the trace the error is:
    WSE841: An error occured processing an outgoing fault response. ---> System.Web.Services.Protocols.SoapHeaderException: Header http://schemas.xmlsoap.org/ws/2004/08/addressing:Action for ultimate recipient is required but not present in the message.
    The soap the java client is sending has no Action header and I�m told it can not be changed. Therefore I have been trying to tell my service that actionheader is not required but without success.
    This is a actionheader the webservice accepts:
    <wsa:Action wsu:Id="Id-29db7046-313a-4675-9bf8-6446b9463aeb">http://tempuri.org/send</wsa:Action>
    What I have tried is to change the policy file
    This is the default:
    <!--MessagePredicate is used to require headers. This assertion should be used along with the Integrity assertion when the presence of the signed element is required. NOTE: this assertion does not do anything for enforcement (send-side) policy.-->
    <wsp:MessagePredicate wsp:Usage="wsp:Required" Dialect="http://schemas.xmlsoap.org/2002/12/wsse#part">wsp:Body() wsp:Header(wsa:To) wsp:Header(wsa:Action) wsp:Header(wsa:MessageID) wse:Timestamp()</wsp:MessagePredicate>
    Here I tried to tell the service that only body and timestamp was required
    <wsp:MessagePredicate wsp:Usage="wsp:Required" Dialect="http://schemas.xmlsoap.org/2002/12/wsse#part">wsp:Body() wse:Timestamp()</wsp:MessagePredicate>
    I have also tried to tell the web service everything was optional:
    <wsp:MessagePredicate wsp:Usage="wsp:Optional" Dialect="http://schemas.xmlsoap.org/2002/12/wsse#part">wsp:Body() wsp:Header(wsa:To) wsp:Header(wsa:Action) wsp:Header(wsa:MessageID) wse:Timestamp()</wsp:MessagePredicate>
    I have also tried to skip the policy file and check on the the bodyparts in code but the error occurs before the webmethod is even invoked.
    It is my understanding that WS-specifications are optional and that the way to define which ones I want to use is via a policy file. Is that the correct understanding? I find it difficult to find good documentation on how to use different WS-specifications with WSE 2.0 enabled web service. Does anyone know of good documentation on WS-security using X509 certificates for signing?
    Does anyone have solution to this problem or ideas that might lead to solution?
    P.s. I have looked at http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnbda/html/wssinteropjwsdp15.asp but I need an example where a java client is talking to a .Net WS. It would be very helpful
    Regards,
    - Bjarki B.

    Hi,
    firstly JWSDP 1.5 is pretty old, the latest release of JWSDP is JWSDP 2.0 that happened late last year.
    The problem is most likely happening due to a bug in JWSDP 1.5. If you dump the Message that is going over the wire you will probably see
    SOAPAction : ""
    SOAPAction : "<the correct action value>"
    And this is the reason for the failure. I believe you are using SOAP 1.1 messages right ?
    What you will need to do is upgrade to
    JWSDP 2.0 and more important also upgrade your SAAJ jars in the JWSDP installation to SAAJ 1.3
    https://saaj.dev.java.net/files/documents/52/32730/saaj1.3.zip
    Alternatively, you can use Sun's Project Tango (Sun's Next Generation WebServices Interoperability Technology Offering) which has been tested to interoperate with Microsoft WCF.
    http://java.sun.com/developer/technicalArticles/glassfish/ProjectTango/
    You can download Project Tango by visiting the following page :
    https://wsit.dev.java.net/
    Look at the Try It section for instructions on how to use it.
    Using the Netbeans Plugin you can develop a java client which can securely communicate with the .Net WebService. All you need to do for that is use Netbeans to create a Java WebService Client by pointing it to the WSDL of the .Net Service.
    Let us know if this helped.
    Thanks...
    Message was edited by:
    kumar_at_sun

Maybe you are looking for

  • Movies taken with digital camera on sd cards

    As a matter of organization should I keep these files with iphoto or move them to another location like where I keep my uploaded home movies that I take with a handicam? Anytime I plug in my headcam which records on sd the mac thinks they are photo f

  • Ipad to aplle tv to vga projector

    For teaching and presentation purposes I need to connect my ipad to an apple tv and then to a projector that only has vga inputs. Is this possible?

  • Purchase Requisition Processing Time

    I am currently facing an issue with the purchase requisitoin processing time functionality. It does not appear to work for items without a material master. So if I create a purchase requisition with material master line items and non-material master

  • Does apple provide professional Installation for new hardware?

    I want to know if i can bring my Imac 21.5 mid 2014 for new hard drive installation to an apple store. Is there a service for that? I know they have a repair service, does it provide for that as well? I do have applecare coverage, I'm not sure if tha

  • HT1749 G5 problem on standby mode only

    When power on,only lights showed up.standby mode only