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. helpful :)
View Tutorial          By: ravinder at 2012-03-22 11:52:19

2. super article for freshers and good
View Tutorial          By: santhosh at 2011-11-03 14:32:44

3. Hi

Anybody plz send me the sms send

View Tutorial          By: Venky at 2008-11-19 08:33:22

4. thank for this script
because i will work

View Tutorial          By: r at 2009-06-27 05:07:31

5. Hi ,learn a new thing about These Transient and Vo
View Tutorial          By: LakshmiNarayana Golla at 2010-07-28 02:49:48

6. hi how ru
anybody tell me that how to print

View Tutorial          By: imran at 2010-12-10 00:34:51

7. How to download more than one files. If I use for
View Tutorial          By: Riyas at 2012-01-08 07:55:03

8. can you guys please help me in inserting values on
View Tutorial          By: Fariha at 2015-06-15 20:44:04

9. a very rare but useful tutorial. Thanks a bunch!
View Tutorial          By: Dalitso at 2014-02-19 12:07:34

10. Very concise, but it would be more helpful without
View Tutorial          By: Randy at 2010-11-17 14:16:01