FileDocCategorySizeDatePackage
SunOneBasicHostNameVerifier.javaAPI DocGlassfish v2 API3505Fri May 04 22:36:24 BST 2007com.sun.enterprise.admin.jmx.remote.https

SunOneBasicHostNameVerifier

public class SunOneBasicHostNameVerifier extends Object implements HostnameVerifier
Provides for the basic defense against spoofing attack in that it checks whether the host name with which instance of this object was created is the same as the one received from the server that claims to be the real server.
author
Kedar Mhaswade
since
S1AS8.0
version
$Revision: 1.4 $

Fields Summary
private final String
host
Constructors Summary
public SunOneBasicHostNameVerifier(String host)

		if (host == null)
			throw new IllegalArgumentException ("Null Arg");
		this.host = host;
	
Methods Summary
public booleanverify(java.lang.String hostName, javax.net.ssl.SSLSession s)

		//defend against spoofing attack if any.
		if (host.equals(hostName))
			return ( true );
		return ( false );