I have create client keyStore and certificate in my EJBCA publick Web,and in my java code I use it like this:
Provider tlsProvider = new TLSProvider();
Security.addProvider(tlsProvider);
Security.setProperty("ssl.TrustManagerFactory.algorithm", "AcceptAll");
Security.setProperty("ssl.KeyManagerFactory.algorithm", "NewSunX509");
but it always has Caused by: java.io.IOException: HTTPS hostname wrong: should be <222.161.197.250>
or Caused by: java.security.cert.CertificateException: No subject alternative names present
can someBody tell me why,I didn't get rid of for a few days, is to add the client's certificate to the server trustStore?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Now, I want to use EJBCA WebService interface in java code, but after I installed ejbca at this stage,I don't know what to do? Should i use the WEB GUI to create a CA certificate 、keyStore and trustStore then set them in my java code? Can you tell me what should i do?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have create client keyStore and certificate in my EJBCA publick Web,and in my java code I use it like this:
Provider tlsProvider = new TLSProvider();
Security.addProvider(tlsProvider);
Security.setProperty("ssl.TrustManagerFactory.algorithm", "AcceptAll");
Security.setProperty("ssl.KeyManagerFactory.algorithm", "NewSunX509");
but it always has Caused by: java.io.IOException: HTTPS hostname wrong: should be <222.161.197.250>
or Caused by: java.security.cert.CertificateException: No subject alternative names present
can someBody tell me why,I didn't get rid of for a few days, is to add the client's certificate to the server trustStore?
The TLS server certificate is invalid. A better solution is creating a real TLS certificate than trying to get around the problem.
give the host a proper name and put the IP in "hosts" file to begin with.
Cheers
Anders
Now, I want to use EJBCA WebService interface in java code, but after I installed ejbca at this stage,I don't know what to do? Should i use the WEB GUI to create a CA certificate 、keyStore and trustStore then set them in my java code? Can you tell me what should i do?