Use different SSL certificates for REST calls
search cancel

Use different SSL certificates for REST calls

book

Article ID: 14878

calendar_today

Updated On:

Products

CA Application Test CA Continuous Application Insight (PathFinder) Service Virtualization

Issue/Introduction

REST step doesn't support SSL configuration in the current releases of DevTest. We configure the SSL certificate details in local.properties file but this option makes certificate information global.

How to configure different SSL certs for REST calls?

This article provides workarounds to achieve REST SSL functionality without the local.properties.

 

Environment

All supported DevTest releases.

Cause

 

N/A

Resolution

For REST GET and POST calls, SSL certificate details are configured in the local.properties file using the below properties. 

ssl.client.cert.path=
ssl.client.cert.pass=
ssl.client.key.pass=
ssl.client.alias=

Once we set the above properties, they become global and all REST, HTTP, Web Service calls are going to use them. This configuration conflicts, if different certs are needed for different calls.

To use multiple SSL certificates for different REST calls you would have to use either HTTP Step for REST GET calls or the Web Services Execution Step for REST POST calls.

The keystore files for the certificates should be stored in DevTest_HOME/projects/Data folder with subfolder as certificates. These keystore files should be .jks or  .pkcs12.



Usage:

1.  For REST GET Calls - Use the HTTP Request-httpGET  Step.  HTTPS is specified as the protocol and the port and path are entered. Select the SSL Tab and configure  SSL keystore file details. 

2.  For POST Calls – Use the Web Service Execution(XML) Step.  Use the ENDPOINT field for the HTTPS POST call. Under the Advanced Setting, select SSL Tab and configure SSL Keystore file details