Jump to content

Question upon generating valid tokens


Recommended Posts

I am currently trying to create a script which sends a number of XML requests to a server, and each of the requests must have a certain <soapenv:Header> section containing valid information:
<soapenv:Header>
      <wsse:Security soapenv:mustUnderstand="1" xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
         <wsse:UsernameToken wsu:Id="UsernameToken-********************************">
            <wsse:Username>*******</wsse:Username>
            <wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#Password">******</wsse:Password>
            <wsse:Nonce EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary">************************==</wsse:Nonce>
            <wsu:Created>2014-07-10T12:27:06.131Z</wsu:Created>
         </wsse:UsernameToken>
      </wsse:Security>
   </soapenv:Header>

I encountered a problem, when sending the same xml request multiple times, I get an error. I assume this is due to the fact that I am using the same UsernameToken and Nonce.

Do you have any suggestions about how can I generate valid UsernameToken also Nonce for each request that I am sending?

Can anyone give me a hint?

Edited by RamonaC
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...