org.jasig.cas.authentication.handler.support
Class JaasAuthenticationHandler.UsernamePasswordCallbackHandler

java.lang.Object
  extended by org.jasig.cas.authentication.handler.support.JaasAuthenticationHandler.UsernamePasswordCallbackHandler
All Implemented Interfaces:
CallbackHandler
Enclosing class:
JaasAuthenticationHandler

protected static final class JaasAuthenticationHandler.UsernamePasswordCallbackHandler
extends Object
implements CallbackHandler

A simple JAAS CallbackHandler which accepts a Name String and Password String in the constructor. Only NameCallbacks and PasswordCallbacks are accepted in the callback array. This code based loosely on example given in Sun's javadoc for CallbackHandler interface.


Constructor Summary
protected JaasAuthenticationHandler.UsernamePasswordCallbackHandler(String userName, String password)
          Constuctor accepts name and password to be used for authentication.
 
Method Summary
 void handle(Callback[] callbacks)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JaasAuthenticationHandler.UsernamePasswordCallbackHandler

protected JaasAuthenticationHandler.UsernamePasswordCallbackHandler(String userName,
                                                                    String password)
Constuctor accepts name and password to be used for authentication.

Parameters:
userName - name to be used for authentication
password - Password to be used for authentication
Method Detail

handle

public void handle(Callback[] callbacks)
            throws UnsupportedCallbackException
Specified by:
handle in interface CallbackHandler
Throws:
UnsupportedCallbackException


Copyright © 2004-2013 Jasig. All Rights Reserved.