Comment on Tutorial - java.io.IOException: HTTPS hostname wrong: should be By Ramlak



Comment Added by : java

Comment Added at : 2012-08-22 09:39:57

Comment on Tutorial : java.io.IOException: HTTPS hostname wrong: should be By Ramlak
had the sample problem.. java.io.IOException: HTTPS hostname wrong: should be <server_ip>
Used following code as specified in the post .. & it worked

HostnameVerifier hv = new HostnameVerifier() {
public boolean verify(String urlHostName, SSLSession session) {
System.out.println("Warning: URL Host: " + urlHostName
+ " vs. " + session.getPeerHost());
return true;
}
};
HttpsURLConnection.setDefaultHostnameVerifier(hv);

Thanks.


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. realy good explanation
View Tutorial          By: pandit at 2009-07-19 11:24:55

2. Thanks a ton. Was struggling to get the ListView u
View Tutorial          By: Avinash at 2012-09-25 12:25:12

3. Please resolve this problems :

ja

View Tutorial          By: madhusudhakar at 2014-10-24 06:11:10

4. We migrated to office365 this morning and i was ab
View Tutorial          By: Muthukumaran at 2012-09-01 08:37:27

5. Sometimes java do support operator overloading as
View Tutorial          By: Gunjan Srivastava at 2011-07-06 09:14:00

6. we can write an abstract class without any abstrac
View Tutorial          By: keerthi at 2013-08-20 16:31:38

7. i need the code
View Tutorial          By: C.Ajith Franklin at 2010-05-05 06:04:40

8. Programs are so good..!
i wish to say one t

View Tutorial          By: Shashikumar Misal at 2012-09-01 20:35:47

9. excellent information is provided to you sir try t
View Tutorial          By: Raghav at 2007-12-16 05:03:53

10. pls help how to fetch vowels as a first letter of
View Tutorial          By: anjali at 2014-09-18 20:45:49