在写fetion Api 的过程中遇到的问提及解决办法

1.HTTPS hostname wrong:  should be <nav.fetion.com.cn>

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);

你可能感兴趣的:(java)