ALERT: Some images may not load properly within the Knowledge Base Article. If you see a broken image, please right-click and select 'Open image in a new tab'. We apologize for this inconvenience.

Create virtual Service using Lisa-Virtualize-invoke with Https

book

Article ID: 240397

calendar_today

Updated On:

Products

Service Virtualization

Issue/Introduction

Trying to create a Virtual service using Lisa-Virtualize-invoke with HTTPS.
Successfully created service for HTTP but to create HTTPS were to give path of the certificate ?

Environment

Devtest 10.6.x 10.7.x 
API Calls

Service Virtualization

Resolution

Documentation shows the sample JSON
https://techdocs.broadcom.com/us/en/ca-enterprise-software/devops/devtest-solutions/10-6/using/using-the-apis/service-virtualization-api-v3.html#concept.dita_14d09617429fb8fc9c3abbbdc71919ab63171848_CreateaVirtualService


Below are two examples JSON:
Example 1:

{
        "virtualService": {
                "version": "2",
                "name": "swaggertest273a2",
                "description": "Invoke API V3",
                "status": "",
            
                "capacity": "1",
                "thinkScale": "200",
                "autoRestart": "false",
                "startOnDeploy": "true",
                "groupTag": "test"  
    },
      "transportProtocol": {
                "typeId": "HTTP",
              "basePath": "/",
              "useGateway": true,
              "hostHeaderPassThrough": false,
              "recordingEndpoint": {
                      "useSSL": true,
                    "host": "",
                    "port": "28654",
                    "sslConfig": {
                             "keystoreFile": "/Applications/CA/DevTest105/webreckeys.ks",
                            "keystorePassword": "passphrase",
                            "alias": "lisa",
                            "aliasPassword": "passphrase"        
            }
                 
        }
         
    },
      "dataProtocol": {
                "forRequest": true,
              "typeId": "RESTDPH"  
    }
}

Example 2:
{
    "virtualService": {
        "version": "3",
        "name": "accounts1",
        "description": "{{vserviceName}} by Invoke API V3",
        "status": "",
        "groupTag": "Accounts-Risk"
    },
    "transportProtocol": {
        "typeId": "HTTP",
        "basePath": "/",
        "useGateway": true,
        "hostHeaderPassThrough": false,
      "recordingEndpoint":{  
         "useSSL": true,
         "host":"",
          "port":"10654",
         "sslConfig":{  
            "keystoreFile":"C:/PROGRA~1CA/DevTest/webreckeys.ks",
            "keystorePassword":"passphrase",
            "alias":"lisa",
            "aliasPassword":"passphrase"
         }
    }
    },
    "dataProtocol" : {
        "forRequest":true,
        "typeId":"RESTDPH"
    },
}

The SSL Config is the key!
(SSLCOnfig should work but the key is that the path mentioned should be of VSE server not the machine where the call is being made) 

NOTE:  this DOES NOT WORK for v3 API creation using VSM/VSI only for RR Pairs / SWAGGER, WSDL, etc.