cancel
Showing results for 
Search instead for 
Did you mean: 

API SSL connection Issue - Could not create secure SSL/TLS channel

Nandhakumar626
Level 4

Hi,

I'm currently working with an API which is 3rd party and we have credentials and setup done from the bot to make request. I have tried a test request to api and get the response back via SOAPUI.

But when i tried the same via blueprism, getting the below error. Can anyone help if you have faced the same?

I have created an API under System>Objects>Web API Services. This api needs certificates to be loaded with key to create a 2way SSL connection with API.

Now the api source has given a C# code to create a 2 way SSL connection via code stage as below, tried the same in code stage, by passing the parameters required.

using System.Net;
using System.Security.Cryptography.X509Certificates;
HttpWebRequest request = WebRequest.Create (requestURL) as HttpWebRequest;
// Add headers
string authString = userId + ":" + password;
var authStringBytes = System.Text.Encoding.UTF8.GetBytes (authString);
string authHeaderString = Convert.ToBase64String (authStringBytes);
request.Headers ["Authorization"] = "Basic " + authHeaderString;
// Add certificate
var certificate = new X509Certificate2(p12certificatePath, p12certificatePassword);
request.ClientCertificates.Add(certificate);
**Highlighted in bold are input parameters being passed to this stage.
 
Once this stage is executed, i'm trying to call a method that i have setup in blueprism but getting the below error.
 
Nandhakumar626_0-1713751640095.png

I have loaded the same certificate file and key into SSL settings under preferences in SOAPUI and it worked. but via blue prism facing this issue.

Please guide me.

 
0 REPLIES 0