org.apache.commons.httpclient.HttpException: Session contains no certificates - Untrusted

Ravi Kumar S
Kilo Explorer

Hello Team,

I am using developer edition (Quebec) to test vRealize Automation (vRA) 8.2 integration with Service Now. While trying to add vRA endpoint in service now, it fails with below error in logs:

(added xxxxxxxxxxxxxxxxx intentionaly for hostname)

REST call error found inside vRARegistervRA.generateApiToken: The request failed: Request not sent to uri= https://xxxxxxxxxxxxxxxxxx/csp/gateway/am/api/login?access_token&apiVersion=2019-01-15 : org.apache.commons.httpclient.HttpException: Session contains no certificates - Untrusted 

Attached screenshot for reference. Is there a way we can bypass the certificate check and add the endpoint?

I already tried to added the vRA certs as base 64 and DER format in service now certificate option and in the MID server (Windows) I have installed these certificates in trusted root folder. 

Any suggestions? Thank you in advance! - Very New to ServiceNow!

Thanks & Regards,
Ravi Kumar S

1 ACCEPTED SOLUTION

Ravi Kumar S1
Giga Contributor

Fixed the issue! Had to import the vRA certs to MID Server keystore:

 

Open a command prompt and navigate to the folder containing the JRE keytool .

An example path might be: C:\Program Files(x86)­\Service­Now\­\agent\­jre\­bin

Enter the following keytool command to import a certificate into the MIDServer's cacerts keystore: keytool -import -alias -file "" -keystore "\agent\­jre\­lib\­security\­cacerts"

For example, youmight enter: keytool -import -alias MyCA -file "C:\myca.cer" -keystore "C:\Program Files (x86)­\Service­Now\­MIDserver\agent\­jre\­lib\­security\­cacerts"

Note: Keytool prompts for a certificate password. If the certificate is for a CA, keytool also asks whether to trust the certificate authority. To add a certificate to an instance, see Upload a certificate to an instance . (changeit - default password)

View solution in original post

5 REPLIES 5

Gilberto Silva
Tera Contributor

My integration not use MID SERVER, what I can do to solve it? I had the same problem.