Java DTV API 1.3
18-Nov-2009

com.sun.dtv.security
Class AuthProvider

java.lang.Object
  extended by java.util.Dictionary
      extended by java.util.Hashtable
          extended by java.util.Properties
              extended by java.security.Provider
                  extended by com.sun.dtv.security.AuthProvider
All Implemented Interfaces:
Serializable, Cloneable, Map

public abstract class AuthProvider
extends Provider

This class defines login and logout methods for a provider.
While callers may invoke login directly, the provider may also invoke login on behalf of callers if it determines that a login must be performed prior to certain operations.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.Properties
defaults
 
Constructor Summary
protected AuthProvider(String name, double version, String info)
          Constructs a provider with the specified name, version number, and information.
 
Method Summary
abstract  void login(Principal principal, CallbackHandler handler)
          Log in to this provider.
abstract  void logout()
          Log out from this provider.
abstract  void setCallbackHandler(CallbackHandler handler)
          Set a CallbackHandler.
 
Methods inherited from class java.security.Provider
clear, entrySet, getInfo, getName, getVersion, keySet, load, put, putAll, remove, toString, values
 
Methods inherited from class java.util.Properties
getProperty, getProperty, list, list, propertyNames, save, setProperty, store
 
Methods inherited from class java.util.Hashtable
clone, contains, containsKey, containsValue, elements, equals, get, hashCode, isEmpty, keys, rehash, size
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AuthProvider

protected AuthProvider(String name,
                       double version,
                       String info)
Constructs a provider with the specified name, version number, and information.

Parameters:
name - the provider name
version - the provider version number.
info - a description of the provider and its services.
Method Detail

login

public abstract void login(Principal principal,
                           CallbackHandler handler)
                    throws LoginException
Log in to this provider. The provider relies on a CallbackHandler to obtain authentication information from the caller (a PIN, for example). If the caller passes a null handler to this method, the provider uses the handler set in the setCallbackHandler method.

Parameters:
principal - the Principal which may contain names/login ids used for authentication, or may be populated with additional names/login after successful authentication has completed. This parameter may be null.
handler - he CallbackHandler used by this provider to obtain authentication information from the caller, which may be null
Throws:
LoginException - if the login operation fails

logout

public abstract void logout()
                     throws LoginException
Log out from this provider.

Throws:
LoginException - if the logout operation fails

setCallbackHandler

public abstract void setCallbackHandler(CallbackHandler handler)
Set a CallbackHandler. The provider uses this handler if one is not passed to the login method. The provider also uses this handler if it invokes login on behalf of callers. If the CallbackHandler is not set, the provider is assumed to have alternative means for obtaining authentication information.

Parameters:
handler - a CallbackHandler for obtaining authentication information, which may be null

Java DTV API 1.3
18-Nov-2009

Copyright © 2008-2009 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, California 95054, U.S.A. All rights reserved.

U.S. Government Rights - Commercial software. Government users are subject to the Sun Microsystems, Inc. standard license agreement and applicable provisions of the FAR and its supplements. Sun, Sun Microsystems, the Sun logo and Java are trademarks or registered trademarks of Sun Microsystems, Inc. in the U.S. and other countries.Products covered by and information contained in this service manual are controlled by U.S. Export Control laws and may be subject to the export or import laws in other countries. Nuclear, missile, chemical biological weapons or nuclear maritime end uses or end users, whether direct or indirect, are strictly prohibited. Export or reexport to countries subject to U.S. embargo or to entities identified on U.S. export exclusion lists, including, but not limited to, the denied persons and specially designated nationals lists is strictly prohibited.

DOCUMENTATION IS PROVIDED AS IS AND ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES, INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT, ARE DISCLAIMED, EXCEPT TO THE EXTENT THAT SUCH DISCLAIMERS ARE HELD TO BE LEGALLY INVALID.

Use of this document is subject to license terms.