Need some help plz. I am able to connect to https://localhost:8443 on my JBoss. My problem now is certifcates etc.
Here is the contents of my keystore. It has also got a self issued certificate contained in it.
E:\SSL\keys>keytool -list -v -keystore localhost.keystore
Enter keystore password: localhost
Keystore type: jks
Keystore provider: SUN
Your keystore contains 1 entry
Alias name: localhost
Creation date: 26-Jan-2004
Entry type: keyEntry
Certificate chain length: 1
Owner: CN=Joyce Stack, OU=digisoft, O=digisoft, L=Cork, ST=Cork, C=IE
Issuer: CN=Joyce Stack, OU=digisoft, O=digisoft, L=Cork, ST=Cork, C=IE
Serial number: 40155d7c
Valid from: Mon Jan 26 18:33:32 GMT 2004 until: Sun Apr 25 19:33:32 BST 2004
I only need to make a ssl connection based on some boolean.
So I dont need no client side authetication. The servlet will
just parse some XML for details and store it in the DB.
Meanwhile I have a little Java client that just makes a URL connection to https://localhost:8443 and i keep getting
the following error java.io.IOException: HTTPS hostname wrong: should be ( see attached logs ). Is their
something I should be checking for. ??
Here is my code:-
Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider()); System.setProperty("java.protocol.handler.pkgs",
"com.sun.net.ssl.internal.www.protocol"); System.setProperty("javax.net.debug", "ssl");
URL url = new URL("https", "localhost", 8443, "");
BufferedReader in =
new BufferedReader(new InputStreamReader(url.openStream()));
while ((inputLine = in.readLine()) != null)