org.smartcc.login
Class HTTPLoginModule

java.lang.Object
  |
  +--java.net.Authenticator
        |
        +--org.smartcc.login.HTTPLoginModule
All Implemented Interfaces:
javax.security.auth.spi.LoginModule

public class HTTPLoginModule
extends java.net.Authenticator
implements javax.security.auth.spi.LoginModule


Constructor Summary
HTTPLoginModule()
           
 
Method Summary
 boolean abort()
           
 boolean commit()
           
protected  java.net.PasswordAuthentication getPasswordAuthentication()
          The method is called by the HttpURLConnection to authenticate a user for a 401 or 407 http response.
 void initialize(javax.security.auth.Subject subject, javax.security.auth.callback.CallbackHandler callbackHandler, java.util.Map sharedState, java.util.Map options)
           
 boolean login()
           
 boolean logout()
           
 
Methods inherited from class java.net.Authenticator
getRequestingHost, getRequestingPort, getRequestingPrompt, getRequestingProtocol, getRequestingScheme, getRequestingSite, requestPasswordAuthentication, requestPasswordAuthentication, setDefault
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HTTPLoginModule

public HTTPLoginModule()
Method Detail

initialize

public void initialize(javax.security.auth.Subject subject,
                       javax.security.auth.callback.CallbackHandler callbackHandler,
                       java.util.Map sharedState,
                       java.util.Map options)
Specified by:
initialize in interface javax.security.auth.spi.LoginModule

login

public boolean login()
              throws javax.security.auth.login.LoginException
Specified by:
login in interface javax.security.auth.spi.LoginModule
javax.security.auth.login.LoginException

commit

public boolean commit()
               throws javax.security.auth.login.LoginException
Specified by:
commit in interface javax.security.auth.spi.LoginModule
javax.security.auth.login.LoginException

abort

public boolean abort()
              throws javax.security.auth.login.LoginException
Specified by:
abort in interface javax.security.auth.spi.LoginModule
javax.security.auth.login.LoginException

logout

public boolean logout()
               throws javax.security.auth.login.LoginException
Specified by:
logout in interface javax.security.auth.spi.LoginModule
javax.security.auth.login.LoginException

getPasswordAuthentication

protected java.net.PasswordAuthentication getPasswordAuthentication()
The method is called by the HttpURLConnection to authenticate a user for a 401 or 407 http response.

Overrides:
getPasswordAuthentication in class java.net.Authenticator
Returns:
a password authentication with userid and password.


Copyright © 2002 DC-TSS. All Rights Reserved.