0

I am developing SAP Extension Application using java 1.8, Spring Boot and SAP SDK. I am deploying this application in SAP BTP (SAP Cloud platform). My S4HANA instance is trial version and it is running in CAL.

My Spring Boot application could talk to S4HANA instance from my local after doing below steps.

  1. provided entries in /etc/hosts
  2. exported certificate by using open-ssl command
  3. Added the exported certificate to Java CACerts
  4. Used Domain Name in application as destination

I have deployed same application to SAP BTP and configured the destination from Sub Domain -> Space -> Instances -> Destinations

Here I could give only IP address only as the domain name is not recognised and provided the certificate which I was using in my local. But it is not working, the application is failing with below error.

2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT Caused by: java.security.KeyStoreException: CERTIFICATE not found
   2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT     at java.security.KeyStore.getInstance(KeyStore.java:851) ~[na:1.8.0_281]
   2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT     at com.sap.cloud.sdk.cloudplatform.connectivity.ScpCfDestination.getKeyStore(ScpCfDestination.java:257) ~[connectivity-scp-cf-2.1.2.jar:na]
   2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT     ... 63 common frames omitted
   2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT Caused by: java.security.NoSuchAlgorithmException: CERTIFICATE KeyStore not available
   2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT     at sun.security.jca.GetInstance.getInstance(GetInstance.java:159) ~[na:1.8.0_281]
   2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT     at java.security.Security.getImpl(Security.java:697) ~[na:1.8.0_281]
   2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT     at java.security.KeyStore.getInstance(KeyStore.java:848) ~[na:1.8.0_281]
   2021-04-05T22:04:24.42+0530 [APP/PROC/WEB/0] OUT     ... 64 common frames omitted

Looks like the issue withe providing certificate. Please help me by providing inputs to solve this issue.

Mario Varchmin
  • 3,704
  • 4
  • 18
  • 33
  • Can you please update the question with the SAP Cloud SDK version you use too? And please give us more details into the configuration of your destination. – Ksivakumar Apr 06 '21 at 12:00

1 Answers1

0

The stacktrace appears to reveal that you use an outdated SAP Cloud SDK version. It contains the jar file name connectivity-scp-cf-2.1.2.jar indicating that you use version 2.1.2.

We recommend using the SAP Cloud SDK version 3 which is a major advancement compared to the version 2. Check out the release notes for further reference.

Emdee
  • 1,689
  • 5
  • 22
  • 35