Forum Discussion

maxtester's avatar
maxtester
Contributor
8 years ago

Again WebServices - how to convert to SHA256 to base64

Hi all,

 

I still work on WebServices and I still have some problems.

 

I have a method which expects a "base64Binary" for the pin input.

 

(SOAP UI- Call)

<stor:ModifyUserPIN>
  <userSID>1475127864</userSID>
  <oldPinHash>iI3yWuNXckJKVgxxUqHeeURA4Opc/uYoKDM6RWpQbgU=</oldPinHash>
  <newPinHash>ewg4wq9+ax8/5aScMt1FnZl6kxzuNJymhp88F8yDg5Q=</newPinHash>
</stor:ModifyUserPIN>

 

Now I try to implement the call in Testcomplete. 

When I pass the hash as a string my complete request is false because TC adds a namespace into the hash- filed:

 

<ns1:ModifyUserPIN xsi:type="ns1:ModifyUserPIN">
  <userSID>1475127864</userSID>
  <oldPinHash xsi:type="xsd:string">iI3yWuNXckJKVgxxUqHeeURA4Opc/uYoKDM6RWpQbgU= </oldPinHash>
  <newPinHash xsi:type="xsd:string">ewg4wq9+ax8/5aScMt1FnZl6kxzuNJymhp88F8yDg5Q=</newPinHash>
</ns1:ModifyUserPIN>

 

The string must be SHA-256 encoding and the method expects a base64string- Object. 

 

Can anybody help me out?

 

No RepliesBe the first to reply