How to send a signed SOAP message with additional HTTP Header fields

Our Partner's integration requirements are that we send them asynchronous SOAP messages, that are digitally signed, and whose HTTP headers contains 5 or 6 additional header fields, of which 3 or 4 will need to be dynamically set during the message mapping.  I believe we can use the HTTP adapter for adding new fields to the HTTP header, but don't believe it supports signing.  I believe that the SOAP adapter supports signing, but I'm not clear on how to use it to add fields to the HTTP header.  What is the most straight-forward way to achieve both the signing of the message and the addition of the HTTP header values?
Thanks,
Kurt

>>>What is the most straight-forward way to achieve both the signing of the message and the addition of the HTTP header values?
Use Java mapping for both.
1) Signing the message
You can digitally sign the soap message using many standard api like WSS4j? or  refer Java XML signature API which comes in Jdk1.6.
Refer these links
WSS4J  -  http://ws.apache.org/wss4j/axis.html
Java XML signature : http://java.sun.com/developer/technicalArticles/xml/dig_signature_api/
2) >>whose HTTP headers contains 5 or 6 additional header fields, of which 3 or 4 will need to be dynamically set during the message mapping
Use Dynamic configuration API to set the additional header fields during message mapping.

Similar Messages

  • Soap receiver - owerwrite default http header fields

    Hi,
    I'm using the soap receiver adapter in nosoap mode.
    How can I owerwrite the default settings for the header fields in the http request?
    The soap adapter will automatically set content-type = application/xml.
    I would like for example set "text/xml".
    Thanks,
    Bela

    Dear Mohan,
    I tryed with the keep headers option but it didn't change anything to the HTTP header fields.
    In the documentation we have the following : Keep Headers
    If you want to include the header of the XI message in the Web service message, set the indicator.
    Does it mean that I have to create a HTTP header section in the XI message??? Do you have an example?
    Best regards,
    Bela

  • How to send a SOAP message with attachments

    How to send a SOAP message with attachments thru webservice using axis-1_3 can any one sujjest.............................

    Please refer
    http://www.javaworld.com/javaworld/jw-09-2003/jw-0912-webservices.html
    http://xml.sys-con.com/read/40315.htm

  • How to send SOAP message with attachment?

    Hi Experts,
    How do I simulate to send a SOAP message with an attachment? Can I use XMLSpy?
    Please help.
    Thanks,
    Shobhit

    Ravi,
    With the generic SOAP client, it asks for the http based wsdl file location. But my wsdl has been generated by XI and I have the file stored on my desktop.
    Something to do with the path http://zpidd01:8030/XISOAPAdapter/MessageServlet?channel=NetworkPartners:NP_Order_BS:NP_SOAP_Sender_CC ??
    Stefan,
    my scenario is to send a SOAP request with attachment and post the attachment in ECC through the ABAP server proxy.
    WebService Client -
    SOAP----> XI -
    ABAP PROXY CALL ---> ECC
    Need further assistance from both of you how to achieve this scenario.
    Thanks,
    Shobhit
    Edited by: Shobhit Swarup Mathur on Jul 24, 2008 4:34 AM

  • How to send SOAP Message with Oracle B2B

    Hi everyone,
    I need your help to send out from Oracle B2B a SOAP message with attachment of any type of file (image, pdf, etc.). Possibly using a SOA composite application or another way, it doesn't matter. I already create an ebMS partnership with a custom document protocol and I already create a working SOA composite application to send only text message to my trading partner. I have tried this solution: http://anuj-dwivedi.blogspot.it/2011/04/ebms-attachment-handling-in-oracle-b2b.html but it doesn't work for my case... It is to be noticed that I don't give any schema to my component in the SOA application explained firstly, and I select opaque as schema.
    Thanks to all, regards
    Nello

    Hi Anuj and thanks for your help,
    I need to send an ebXML message, with SOAP, and I try to send it with a .war application written in jsp connecting to http://10.85.28.24:8001/b2b/transportServlet to send the SOAP message. The errors reported is:
    javax.xml.soap.SOAPException: Unable to receive message. Received a response from url: http://10.85.28.24:8001/b2b/transportServlet with HTTP status 200 and SOAP content-type: null.
    the code I write is the following (to evaluate the two "null" in the super constructor)
    <%!
    public class EBMSSender extends SOAPRunner
    private String cpaId;
    private String service;
    private String action;
    private String mess;
    private ArrayList<String> allegati=null;
    public EBMSSender(String cpaId, String service, String action, String mess, ArrayList<String> file)
    super("http://10.85.28.24:8001/b2b/transportServlet","null", "null");
    this.cpaId = cpaId;
    this.service = service;
    this.action = action;
    this.mess=mess;
    this.allegati=file;
    @Override
    protected void prepareRequest(SOAPMessage soapMessage, SOAPBody soapBody) throws SOAPException
    soapBody.addChildElement(SOAPUtility.createElement("CPAId", getNsPrefix(), getNsURI(),"agr3"));
    soapBody.addChildElement(SOAPUtility.createElement("service", getNsPrefix(), getNsURI(),"OracleService"));
    soapBody.addChildElement(SOAPUtility.createElement("action", getNsPrefix(), getNsURI(),"Oracletohermesb"));
    soapBody.addChildElement(SOAPUtility.createElement("serviceType", getNsPrefix(), getNsURI(),"OracleServiceType"));
    soapBody.addChildElement(SOAPUtility.createElement("convId", getNsPrefix(), getNsURI(), "convId"));
    soapBody.addChildElement(SOAPUtility.createElement("fromPartyId", getNsPrefix(), getNsURI(), "Oracle"));
    soapBody.addChildElement(SOAPUtility.createElement("fromPartyType", getNsPrefix(), getNsURI(), "Name"));
    soapBody.addChildElement(SOAPUtility.createElement("toPartyId", getNsPrefix(), getNsURI(), "Hermes-b"));
    soapBody.addChildElement(SOAPUtility.createElement("toPartyType", getNsPrefix(), getNsURI(), "Name"));
    attach(soapMessage);
    protected void attach(SOAPMessage soapMessage)
    String h=mess;
    DataHandler dh;
    AttachmentPart ap = soapMessage.createAttachmentPart(h,"text/plain");
    soapMessage.addAttachmentPart(ap);
    if(allegati!=null)
    for(int i=0; i<allegati.size();i++)
    dh=new DataHandler(new FileDataSource(new File(allegati.get(i))));
    ap=soapMessage.createAttachmentPart(dh);
    ap.setContentType(new MimetypesFileTypeMap().getContentType(allegati.get(i)));
    ap.setContentLocation(allegati.get(i));
    soapMessage.addAttachmentPart(ap);
    @Override
    protected void processFault(SOAPFault soapFault) throws SOAPException{}
    @Override
    protected Object processResponse(SOAPMessage responseMessage,SOAPBody responseBody) throws SOAPException
    SOAPElement messageId = SOAPUtility.getChild(responseBody, "message_id", getNsURI());
    return null;
    %>
    The code works fine on the other trading partner side to send ebXML message to Oracle B2B. Apart from this solution (however,it would be my favorite), I find your blog and I try to implement your solution. It works: it sends files with only text payload to the other trading partner without any problem, but if I try to send for example an image in byte array written in a file .txt, the ebxml file received has the byte array with wrong characters. it may be that I have not provided the xsd schema? in case if I wanted to send an ebXML message with text and attachments, what xsd schema do I need to provide?
    or is there another way to implement a SOA composite application to send SOAP messages with attachments?
    Thank for your help!, regards
    Nello

  • Outbound SOAP Message with Attachment

    The requirement is to invoke a web service by sending attachments in the outbound SOAP message. The attachment body needs to be assigned in the message flow, using an element E1 extracted from the message incoming into the flow.
    I am trying to use attachments variable to set content-type (text/xml) and body using E1. However, these are not getting assigned to attachments variable, as seen by logging the variable.
    I was told that $attachments cannot be changed inside the flow (it is marked black in the console unlike the header and body that are marked green). If that is the case, how do we invoke services using attachments from a message flow?
    Any pointers would be appreciated.

    Hi,
    A SOAP message may need to be transmitted together with attachments of various sorts, ranging from facsimile images of legal documents to engineering drawings. Such data are often in some binary format. For example, most images on the Internet are transmitted using either GIF or JPEG data formats. In this document we describe a standard way to associate a SOAP message with one or more attachments in their native format in a multipart MIME structure for transport.
    yes it is possible to send attachment with the SOAP.
    SOAP Message Packages
    A "SOAP message package" contains a primary SOAP 1.1 message. It may also contain additional entities that are not lexically within the SOAP message but are related in some manner. These entities may contain data in formats other than XML. The primary SOAP 1.1 message in a message package may reference the additional entities. Such additional entities are often informally referred to as "attachments." This section describes how to construct SOAP message packages and how SOAP processors will process them.
    A SOAP message package is constructed using the Multipart/Related media type, which is defined in RFC 2387. The rules for the construction of SOAP message packages are as follows:
    The primary SOAP 1.1 message must be carried in the root body part of the Multipart/Related structure. Consequently the type parameter of the Multipart/Related media header will always equal the Content-Type header for the primary SOAP 1.1 message, i.e., text/xml.
    The MIME Multipart/Related encapsulation of a SOAP message is semantically equivalent to a SOAP protocol binding in that the SOAP message itself is not aware that it is being encapsulated. That is, there is nothing in the primary SOAP message proper that indicates that the SOAP message is encapsulated .
    For more details you can refer these links
    http://www.w3.org/TR/SOAP-attachments
    http://www.w3.org/TR/soap12-af/
    regards
    Aashish Sinha
    PS : reward points if helpful

  • Soap message with Attachment

    Hi All,
    I have a requirement wherin I have to send an attachment(image) along with the soap payload.i.e. the soap message contains the payload and an attachment.For eg. the soap message is as shown below:
    <?xml version="1.0" encoding="UTF-8" ?>
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
      <SOAP-ENV:Body>
        <ns1:MT_Soap xmlns:ns1="http://www.adc.com/sample">
             <Record>
                <FieldXML>abc</FieldXML>
                <FieldAthmt />
             </Record>
          </ns1:MT_Soap>
      </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
    How can I include the attachment(which is on a local machine) in the above soap message?
    Is it posssible to send the attachment in the field "FieldAtthmt"?
    If it is possible to send an attachment with the soap message then how can that attachment be handled in XI?
    Thanks in advance,
    Vikram

    Hi,
    A SOAP message may need to be transmitted together with attachments of various sorts, ranging from facsimile images of legal documents to engineering drawings. Such data are often in some binary format. For example, most images on the Internet are transmitted using either GIF or JPEG data formats. In this document we describe a standard way to associate a SOAP message with one or more attachments in their native format in a multipart MIME structure for transport.
    yes it is possible to send attachment with the SOAP.
    SOAP Message Packages
    A "SOAP message package" contains a primary SOAP 1.1 message. It may also contain additional entities that are not lexically within the SOAP message but are related in some manner. These entities may contain data in formats other than XML. The primary SOAP 1.1 message in a message package may reference the additional entities. Such additional entities are often informally referred to as "attachments." This section describes how to construct SOAP message packages and how SOAP processors will process them.
    A SOAP message package is constructed using the Multipart/Related media type, which is defined in RFC 2387. The rules for the construction of SOAP message packages are as follows:
    The primary SOAP 1.1 message must be carried in the root body part of the Multipart/Related structure. Consequently the type parameter of the Multipart/Related media header will always equal the Content-Type header for the primary SOAP 1.1 message, i.e., text/xml.
    The MIME Multipart/Related encapsulation of a SOAP message is semantically equivalent to a SOAP protocol binding in that the SOAP message itself is not aware that it is being encapsulated. That is, there is nothing in the primary SOAP message proper that indicates that the SOAP message is encapsulated .
    For more details you can refer these links
    http://www.w3.org/TR/SOAP-attachments
    http://www.w3.org/TR/soap12-af/
    regards
    Aashish Sinha
    PS : reward points if helpful

  • Business Service sign a message with always same certificate

    Hello,
    We  need to call an external web service that require the request be signed by a certificate.
    Our organization has an Oracle Service Bus and our intention is use the bus to facilitate our clients the calls.
    I did the next steps:
    1.- I Have configured the keystore of OSB with the certificated.
    2.- I have made the business service, with the end-point the external ws.
    3.- I Have configured the sign-body ws-policy in business service.
    4.- When i prove it with debug console of OSB, i select the keystore provider and it works.
    The problem is:
    When I make the Proxy Service seems that the Business Service give the requirement to the Proxy for sign the message,  and what I want is publish the Proxy Service without this requirement and sign the message with always the same certificate.
    I would like the message was signed by Proxy Service or Business Service, and not by clients who call the OSB.
    I don't know how configure it on OSB.
    It is possible to configure OSB in that way?
    Thanks
    Miguel

    Hello,
    Can you please confirm the following
    1. You are setting up an expired certificate as the host certificate for your host (or) are you trying to sign an ASPX file with an expired certificate?
    2. The webserver where you are hosting this ASPX (IIS I presume), has only certificate based authentication enabled - is that right?
    3. You are seeing that when the user opens the website they are prompted that the certificate has expired, and even if they chose to move forward, they are not able to - is that the issue?
    4. If (3) is not the issue and you want to be able to get access to the certificate-expiration error as part of the ASPX code, then that wouldn't be possible because the certificate validation would happen as part of the TLS connection negotiation
    If you can please provide some more details, it will help.
    Thank you

  • Creating, Sending, Receive + Parsing SOAP messages

    Hi all
    I have a requirement to set up a system to send and receive SOAP messages. I googled for some tutorials and found one that used an Apache library. But I also see that Java 6 has got quite a bit of SOAP built-in. Are the built-in SOAP classes ready for prime time or should I use apache?
    If anyone has a code snippet they could post that would also be appreciated.

    JAX-WS (which is part of Java 6) is definitely ready for prime time.
    It's also a whole lot easier to use.
    I'd definitely go with the JAX-WS route.

  • Does Workshop deal with SOAP Messages with Attachments

    I try to send back an image from my web service. Is there a way to make a SOAP Messages
    with Attachments using BEA Workshop?
    Thanks,
    Jerome.

    Hi Jerome,
    I'm pretty sure that Workshop doesn't support SwA (SOAP with Attachments) yet. The
    product manager says that it is being considered for a future version, though :-)
    In the meantime, I don't see any reason why you can't just use a Java class that
    uses the JavaMail API to construct a Multipart MIME message. The MimeMultipart class
    (the one that acts as a container for a multipart/related document) has a writeTo()
    method that you can use to populate a ByteArrayOutputStream. Afterwards, you should
    be able to use the toByteArray() method on this ByteArrayOutputStream, to create
    the byte[] that maps to a xsd:base64Binary data type. The nice thing about this,
    is that the target web service has complete access to the SOAP message (in the first
    Body part), and all the attachments :-)
    Just a thought...
    Mike Wooten
    "Jerome Sonnet" <[email protected]> wrote:
    >
    I try to send back an image from my web service. Is there a way to make
    a SOAP Messages
    with Attachments using BEA Workshop?
    Thanks,
    Jerome.

  • How do you forward a text message with pictures to another mobile user

    How do you forward a text message with pictures to another mobile device?

    Howdy Greg,
    It sounds like you have some texts with images attached you would like to forward to another device. If the it can receive text messages, use these steps:
    Send messages with your iPhone, iPad, or iPod touch
    How do I forward a message?
    To forward a message, tap and hold the message bubble, then tap More.
    Tap to select the message you want to forward, then tap  and select the person to send it to.
    If the receiving device does not have the ability to receive text messages, you can also email them to an account setup on it by first saving the message to your phone:
    How do I save a photo from a message?
    Tap the photo, then tap .
    Then emailing it to an account setup on the device from the Photos app:
    Other ways to share photos and videos - iPhone
    Save or share a photo or video you receive.
    Email:  Tap to download it if necessary, then touch and hold the item to see sharing and other options.
    Thank you for using Apple Support Communities.
    Regards,
    Sterling

  • How do I forward a text message with the iPhone?

    How do I forward a text message with the iPhone?

    You could take a screen shot (hold and release both buttons simultaneously) and then email the resulting image to someone.
    // crude workaround for now...

  • How to send smartforms as pdf attachments with e mail

    hi experts,
    how to send smartforms as pdf attachments with e mail???
    nitin

    Hi
    In the FORM Interface put proper parameter. Hope this helps.

  • Why I can't send any e-mail messages with 6230i?

    Hi mates,
    I have a Nokia 6230i with a Vodafone Italian sim card in it.
    I know for sure that I CAN retrieve messages form my incoming POP3 e-mail server but I can't send any e-mail messages with it.
    Any time I try to do that it prompts me an information balloon saying: message failed. Why??
    I mean, I properly set up my phone with all Vodafone details but it still does not seem to work.
    Any help will be appreciate
    Stefano.
    P.S.
    I can even send and receive MMS and of course SMS too
    Solved!
    Go to Solution.

    thanks mate for your reply
    When you say: "Make sure your SP allows sending e-mail"
    Do you mean the provider who give me the mail service?
    Because I know for sure that with MS Outlook express I can send and recive e-mail with it
    Bye,
    Stefano.

  • How to send notifications to multiple person with same role and with result

    How to send notifications to multiple people with resultout as approve/reject?
    We are looping the notification by attaching a cursor query to find the different emp nos to send for approval.
    I cannot associate a role because these emp nos are sub-set of a role which I have created and i am getting thru the cursor query.
    For FYI notification there is no problem, but for approval notification, I am not unable to send approval notifications to all the people.It stops at the first person in the loop.Pls suggest alternate way. Thanks in advance.

    Manju,
    I would use the cursor to populate the API for creating an ad-hoc role within the workflow process as a function. Then set your notification performer as the ad-hoc role.
    Here is an example function:
    create or replace procedure sample_emp_fill(itemtype in varchar2,
    itemkey in varchar2,
    actid in number,
    funcmode in varchar2,
    resultout in out varchar2) as
    cursor get_name is
    select ename from scott.emp where mgr = 7839 and empno != 7566;
    role_name varchar2(50);
    names varchar2(500);
    begin
    if (funcmode = 'RUN') then
    role_name := 'ad_hoc_role_'|| itemkey;
    for row in get_name loop
    names := names || row.ename || ' ';
    end loop;
    WF_DIRECTORY.CreateAdHocRole( role_name=>role_name,
    role_display_name=>role_name,
    language=>'AMERICAN',
    territory=>'AMERICA',
    role_description=>role_name,
    notification_preference=>'QUERY',
    role_users=>names,
    email_address=>' ',
    fax=>'',
    status=>'ACTIVE',
    expiration_date=>'');
    resultout := wf_engine.eng_completed||':'||wf_engine.eng_null;
    return;
    end if;
    end;

Maybe you are looking for