com.atlassian.crowd.plugin.rest.auth
Class BasicApplicationAuthenticationFilter

java.lang.Object
  extended by com.atlassian.crowd.plugin.rest.auth.BasicApplicationAuthenticationFilter
All Implemented Interfaces:
javax.servlet.Filter

public class BasicApplicationAuthenticationFilter
extends java.lang.Object
implements javax.servlet.Filter

Implementation of HTTP Basic Authentication such that all invocations to the filter must be authenticated with a valid application name and corresponding password. As a performance enhancement the application name is saved in the session after a successful authentication. Password check is waived with consequent requests when the application name in the request matches the application name in the session. Clients wishing to take advantage of this feature must support cookies.


Constructor Summary
BasicApplicationAuthenticationFilter(ApplicationManager applicationManager, ClientValidationManager clientValidationManager)
           
 
Method Summary
 void destroy()
           
 void doFilter(javax.servlet.ServletRequest servletRequest, javax.servlet.ServletResponse servletResponse, javax.servlet.FilterChain chain)
           
 void init(javax.servlet.FilterConfig filterConfig)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicApplicationAuthenticationFilter

public BasicApplicationAuthenticationFilter(ApplicationManager applicationManager,
                                            ClientValidationManager clientValidationManager)
Method Detail

init

public void init(javax.servlet.FilterConfig filterConfig)
          throws javax.servlet.ServletException
Specified by:
init in interface javax.servlet.Filter
Throws:
javax.servlet.ServletException

doFilter

public void doFilter(javax.servlet.ServletRequest servletRequest,
                     javax.servlet.ServletResponse servletResponse,
                     javax.servlet.FilterChain chain)
              throws java.io.IOException,
                     javax.servlet.ServletException
Specified by:
doFilter in interface javax.servlet.Filter
Throws:
java.io.IOException
javax.servlet.ServletException

destroy

public void destroy()
Specified by:
destroy in interface javax.servlet.Filter


Copyright © 2010 Atlassian. All Rights Reserved.