Skip to Content
0
Former Member
Aug 26, 2009 at 06:47 PM

Digitally Signing specific SOAP elements using Java Mapping

326 Views

Hello SDNers,

Iu2019m having trouble creating java mappings to sign and verify digital signatures. Iu2019m new to Java so this is proving difficult. I understand the basic concepts of OO programming and utilizing classes/objects to build the program, but Iu2019m having trouble with the conceptual understanding of how I would like to get this done.

I have outbound and inbound messages. The outbound messages are originating from an ECC backend. The messages are processed through PI with a basic Message Mapping, then it is wrapped in a SOAP envelope with specific information using a XSL mapping and then I would like to use a Java Mapping to Digitally Sign specific portions of the entire message; specifically around an element in the SOAP header and sign the SOAP body. I also need to verify these sections for all inbound messages.

The simple pseudo code I have for the outbound messages is as follows:

<ol>

<li>1. read in xml (file input stream)</li>

<li>2. find the (specific information)</li>

<ol>

<li>a. assign that string to a variable</li>

<li>b. sign this variable with the security profile (keystore, private key)</li>

<li>c. e-write the variable into the main xml file</li>

</ol>

<li>3. find the soap body</li>

<ol>

<li>a. assign that string to a variable</li>

<li>b. sign this variable with the security profile (keystore, private key)</li>

<li>c. re-write the variable into the main xml file</li>

</ol>

<li>4. write the output file with both variables written (file output stream)</li>

</ol>

Currently Iu2019m using PI 7.1 so there is no more Visual Administrator tool.

Iu2019ve seen the examples from the last link, but I canu2019t seem to put it together when mixed with basic java mapping example. I have been searching the SDN forums for a while now, but hereu2019s my specific question: how do you create a java mapping to sign and verify specific elements of a SOAP message?

Thanks in advance,

Jason