Åke Ekmark
Åke Ekmark

Reputation: 21

WSE 2.0 How do i generate digestvalue for the body

I am trying to generate a soap-message manually with python, without using anything like suds. I have examples from the partner i'm sending the message to and i can run for example the timestamp part through my c14n and sha1 function and get the same digestvalue as in the example. The problem is with the reference to the body. Here i just can't seem to get the right digestvalue, is there anything special about generating the digestvalue for the body element? I have the same problem with messages generated in SoapUI, i can't understand how they generate the digestvalue for the body. An example from SoapUI:

<soapenv:Body wsu:Id="id-994341CF8E95A7426314404882851955" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"></soapenv:Body>

<ds:Reference URI="#id-994341CF8E95A7426314404882851955">
 <ds:Transforms>
  <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
  <ec:InclusiveNamespaces PrefixList="app app1 app2 exp phon tran work" xmlns:ec="http://www.w3.org/2001/10/xml-exc-c14n#"/>
  </ds:Transform>
 </ds:Transforms>
  <ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/>
  <ds:DigestValue>Np4j6gDbIqwyqahEgs5nocZlsKc=</ds:DigestValue>
</ds:Reference>

Upvotes: 2

Views: 149

Answers (0)

Related Questions