In localhost, with an auto-generate certificate, I have access to my API in HTTPS. On the other hand, on my VPS, with the certificate provided by my host, I get errors. I guess the problem must come from the conversion of the certificate provided in .cer to the version in .p12, since my code remains unchanged from the localhost version and in the version on the VPS.
Here are the errors generated
Caused by: org.apache.catalina.LifecycleException: Protocol handler start failed at org.apache.catalina.connector.Connector.startInternal(Connector.java:1075) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:183) at org.apache.catalina.core.StandardService.addConnector(StandardService.java:234) ... 18 more Caused by: java.lang.IllegalArgumentException: Alias name [springboot] does not identify a key entry at org.apache.tomcat.util.net.AbstractJsseEndpoint.createSSLContext(AbstractJsseEndpoint.java:107) at org.apache.tomcat.util.net.AbstractJsseEndpoint.initialiseSsl(AbstractJsseEndpoint.java:71) at org.apache.tomcat.util.net.NioEndpoint.bind(NioEndpoint.java:234) at org.apache.tomcat.util.net.AbstractEndpoint.bindWithCleanup(AbstractEndpoint.java:1227) at org.apache.tomcat.util.net.AbstractEndpoint.start(AbstractEndpoint.java:1313) at org.apache.coyote.AbstractProtocol.start(AbstractProtocol.java:614) at org.apache.catalina.connector.Connector.startInternal(Connector.java:1072) ... 20 more Caused by: java.io.IOException: Alias name [springboot] does not identify a key entry at org.apache.tomcat.util.net.SSLUtilBase.getKeyManagers(SSLUtilBase.java:337) at org.apache.tomcat.util.net.SSLUtilBase.createSSLContext(SSLUtilBase.java:247) at org.apache.tomcat.util.net.AbstractJsseEndpoint.createSSLContext(AbstractJsseEndpoint.java:105)
And here is the HTTPS configuration in spring-boot
server.ssl.enabled=true
server.ssl.key-alias=springboot
server.ssl.key-store=classpath:files/cert/springboot-mooddraw-com.p12
#server.ssl.key-store=classpath:files/cert/springboot-localhost.p12
server.ssl.key-store-type=pkcs12
server.ssl.key-store-password=cxcxvd
server.ssl.key-password=cxcxvd
thank you in advance for your help