01 package examples.security.sslclient;
02
03 /**
04 * HostnameVerifier provides a callback mechanism so that implementers
05 * of this interface can supply a policy for handling the case where
06 * the host that's being connected to and the server name from the
07 * certificate SubjectDN must match.
08 *
09 * <p>
10 * This is a null version of that class to show the WebLogic SSL client
11 * classes without major problems. For example, in this case, the client
12 * code connects to a server at 'localhost' but the democertificate's
13 * SubjectDN CommonName is 'bea.com' and the default WebLogic
14 * HostnameVerifier does a String.equals() on those two hostnames.
15 *
16 * @see javax.net.ssl.HostnameVerifier#verify
17 * @author Copyright (c) 1999,2009, Oracle and/or its affiliates. All Rights Reserved.
18 */
19 public class NulledHostnameVerifier implements weblogic.security.SSL.HostnameVerifier {
20
21 public boolean verify(String urlHostname, javax.net.ssl.SSLSession session) {
22 return true;
23 }
24
25 }
|