org.aselect.authspserver.authsp.nullauthsp
Class NullAuthSP

java.lang.Object
  extended by javax.servlet.GenericServlet
      extended by javax.servlet.http.HttpServlet
          extended by org.aselect.system.servlet.ASelectHttpServlet
              extended by org.aselect.authspserver.authsp.nullauthsp.NullAuthSP
All Implemented Interfaces:
java.io.Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

public class NullAuthSP
extends ASelectHttpServlet

.
Null AuthSP is an AuthSP used for testing
Description:
The Null AuthSP is a test AuthSP that uses his configuration tosend an access denied or access granted.

Concurrency issues:
-

Author:
Alfa & Ariss
See Also:
Serialized Form

Constructor Summary
NullAuthSP()
           
 
Method Summary
protected  void doGet(javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse servletResponse)
          Processes requests for HTTP GET.
protected  void doPost(javax.servlet.http.HttpServletRequest servletRequest, javax.servlet.http.HttpServletResponse servletResponse)
          Private entry point of the Null AuthSP.
 void init(javax.servlet.ServletConfig oServletConfig)
          Initialization of the Null AuthSP.
protected  boolean isRestartableServlet()
          Determines whether or not the NULL AuthSP is restartable.
 
Methods inherited from class org.aselect.system.servlet.ASelectHttpServlet
getModuleName, getWorkingDir, handleRestartRequest, isReinit, isRestartInProgress, restartServlets, service, setDisableCachingHttpHeaders, showErrorPage
 
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service
 
Methods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NullAuthSP

public NullAuthSP()
Method Detail

init

public void init(javax.servlet.ServletConfig oServletConfig)
          throws javax.servlet.ServletException
Initialization of the Null AuthSP.

Description:
The Null AuthSP uses the following components from the A-Select AuthSP Server
- the config manager
- the crypto engine
- the user friendly name
- the working directory

Initialization includes:
- It loads the AuthSP components from the servlet context.
- It loads the error messages from the errors.conf file.
- It loads the error.html file.
- Sets the configured authentication_mode (default = grant all users)


Preconditions:
- the AuthSPServer must be succesfully started
- an error config file must exist:
workingdir/conf/nullauthsp/errors/errors.conf
- an error template file must exist:
workingdir/conf/nullauthsp/html/error.html
- needs an 'authsp' config section with name='nullauthsp' in the configuration of the AuthSP Server

Specified by:
init in interface javax.servlet.Servlet
Overrides:
init in class ASelectHttpServlet
Throws:
javax.servlet.ServletException
See Also:
Servlet.init(javax.servlet.ServletConfig)

doGet

protected void doGet(javax.servlet.http.HttpServletRequest servletRequest,
                     javax.servlet.http.HttpServletResponse servletResponse)
              throws javax.servlet.ServletException,
                     java.io.IOException
Processes requests for HTTP GET.

name valueencoded
ridA-Select Server request idno
as_urlA-Select Server URLyes
uidA-Select User IDyes
a-select-serverA-Select Server IDno
signaturesignature of all paramaters in the above sequenceyes


Overrides:
doGet in class javax.servlet.http.HttpServlet
Throws:
javax.servlet.ServletException
java.io.IOException
See Also:
HttpServlet.doGet(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)

doPost

protected void doPost(javax.servlet.http.HttpServletRequest servletRequest,
                      javax.servlet.http.HttpServletResponse servletResponse)
               throws javax.servlet.ServletException,
                      java.io.IOException
Private entry point of the Null AuthSP. This will not be used, so always an error page will be shown.

Overrides:
doPost in class javax.servlet.http.HttpServlet
Throws:
javax.servlet.ServletException
java.io.IOException
See Also:
HttpServlet.doPost(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)

isRestartableServlet

protected boolean isRestartableServlet()
Determines whether or not the NULL AuthSP is restartable.

Specified by:
isRestartableServlet in class ASelectHttpServlet
Returns:
true if the Servlet is restartable, otherwise false.
See Also:
ASelectHttpServlet.isRestartableServlet()


Copyright © 2008 SURFnet BV. All Rights Reserved.