com.atlassian.sal.core.auth
Class SeraphAuthenticationController

java.lang.Object
  extended by com.atlassian.sal.core.auth.SeraphAuthenticationController
All Implemented Interfaces:
AuthenticationController

public class SeraphAuthenticationController
extends Object
implements AuthenticationController

Implementation of the AuthenticationController to integrate with Atlassian Seraph.


Constructor Summary
SeraphAuthenticationController()
           
 
Method Summary
 boolean canLogin(Principal principal, javax.servlet.http.HttpServletRequest request)
          Checks the RoleMapper on whether or not the principal can login.
 boolean shouldAttemptAuthentication(javax.servlet.http.HttpServletRequest request)
          Checks the request attibutes for the BaseLoginFilter.OS_AUTHSTATUS_KEY.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SeraphAuthenticationController

public SeraphAuthenticationController()
Throws:
IllegalArgumentException - if the roleMapper is null.
Method Detail

canLogin

public boolean canLogin(Principal principal,
                        javax.servlet.http.HttpServletRequest request)
Checks the RoleMapper on whether or not the principal can login.

Specified by:
canLogin in interface AuthenticationController
Parameters:
principal - the identified principal
request - the current HttpServletRequest
Returns:
true if the principal is allowed to login for the given request, false otherwise.
See Also:
AuthenticationController.canLogin(Principal, HttpServletRequest)

shouldAttemptAuthentication

public boolean shouldAttemptAuthentication(javax.servlet.http.HttpServletRequest request)
Checks the request attibutes for the BaseLoginFilter.OS_AUTHSTATUS_KEY. Will return true if the key is not present.

Specified by:
shouldAttemptAuthentication in interface AuthenticationController
Parameters:
request - the current HttpServletRequest
Returns:
true if authentication should be tried, false otherwise.


Copyright © 2011 Atlassian. All Rights Reserved.