This task describes how to add set the security for your Web Service calls. For details about Web Services security, see Setting Security Overview.
Place the cursor at the point at which you want to add the security settings. In most cases, it is best to place it in vuser_init so that the security scope will be applied to the whole script. To apply the security for specific calls, place it at the desired location.
Select Insert > New Step from the right-click menu and choose web_service_set_security from the Web Services functions in the Steps Toolbox. The Set Security Properties box opens.
Click Add to add a new token. The Add Token dialog box opens.
Select a token type. For details, see Security Tokens and Encryption.
In the Token Name box, assign a name for the token to be used by VuGen in identifying the token.
Add any relevant information, such as User Name and Password for the User Name and Password type token.
To send the token explicitly in the SOAP envelope header, select True. To exclude the token from the SOAP envelope header, select False.
Click Add > Message Signature or Add > Encrypted Data.
Select a token to use with the message signature or encryption. Both signatures and encryptions require you to specify a token previously defined as the signing/encrypting token.
Specify a target token, or leave the field blank to apply the signature or encryption to the whole message body. For details, see Security Tokens and Encryption.
To specify a time for which the message packet is considered valid, select Time To Live and specify a time in seconds.Back to top
To cancel the security settings at a specific point within the script, add a Web Service Cancel Security step at the desired point.