fr.paris.lutece.plugins.mylutece.authentication
Class PortalAuthentication

java.lang.Object
  extended by fr.paris.lutece.plugins.mylutece.authentication.PortalAuthentication
All Implemented Interfaces:
fr.paris.lutece.portal.service.security.LuteceAuthentication

public abstract class PortalAuthentication
extends Object
implements fr.paris.lutece.portal.service.security.LuteceAuthentication

PortalAuthentication : default authentication


Constructor Summary
PortalAuthentication()
           
 
Method Summary
 boolean findResetPassword(javax.servlet.http.HttpServletRequest request, String strLogin)
          
 String getAccessControledTemplate()
          Returns the access controled template
 String getAccessDeniedTemplate()
          Returns the access denied template
 String getDoLoginUrl()
          
 String getDoLogoutUrl()
          Returns the disconnect URL of the Authentication Service
 fr.paris.lutece.portal.service.security.LuteceUser getHttpAuthenticatedUser(javax.servlet.http.HttpServletRequest request)
          Returns a Lutece user object if the user is already authenticated in the Http request.
 String getIconUrl()
          
 String getLoginPageUrl()
          
 String getLostLoginPageUrl()
          
 String getLostPasswordPageUrl()
          
 String getNewAccountPageUrl()
          Returns the new account page URL of the Authentication Service
 String getResetPasswordPageUrl(javax.servlet.http.HttpServletRequest request)
          
 String[] getRolesByUser(fr.paris.lutece.portal.service.security.LuteceUser user)
          get all roles for this user : - user's roles - user's groups roles
 fr.paris.lutece.portal.service.security.LuteceUser getUser(String strUserLogin)
          Returns the user managed by the authentication service if this feature is available.
 Collection<fr.paris.lutece.portal.service.security.LuteceUser> getUsers()
          Returns all users managed by the authentication service if this feature is available.
 String getViewAccountPageUrl()
          Returns the View account page URL of the Authentication Service
 boolean isDelegatedAuthentication()
          
 boolean isExternalAuthentication()
          Indicates that the user should be already authenticated by an external authentication service (ex : Web Server authentication).
 boolean isMultiAuthenticationSupported()
          Return false
 boolean isUsersListAvailable()
          Tells whether or not the authentication service can provide a list of all its users
 String toString()
          
 void updateDateLastLogin(fr.paris.lutece.portal.service.security.LuteceUser user, javax.servlet.http.HttpServletRequest request)
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface fr.paris.lutece.portal.service.security.LuteceAuthentication
getAnonymousUser, getAuthServiceName, getAuthType, getName, getPluginName, isUserInRole, login, logout
 

Constructor Detail

PortalAuthentication

public PortalAuthentication()
Method Detail

isExternalAuthentication

public boolean isExternalAuthentication()
Indicates that the user should be already authenticated by an external authentication service (ex : Web Server authentication).

Specified by:
isExternalAuthentication in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
true if the authentication is external, false if the authentication is provided by the Lutece portal.

isDelegatedAuthentication

public boolean isDelegatedAuthentication()

Specified by:
isDelegatedAuthentication in interface fr.paris.lutece.portal.service.security.LuteceAuthentication

getLoginPageUrl

public String getLoginPageUrl()

Specified by:
getLoginPageUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication

getDoLoginUrl

public String getDoLoginUrl()

Specified by:
getDoLoginUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication

findResetPassword

public boolean findResetPassword(javax.servlet.http.HttpServletRequest request,
                                 String strLogin)

Specified by:
findResetPassword in interface fr.paris.lutece.portal.service.security.LuteceAuthentication

getResetPasswordPageUrl

public String getResetPasswordPageUrl(javax.servlet.http.HttpServletRequest request)

Specified by:
getResetPasswordPageUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication

getNewAccountPageUrl

public String getNewAccountPageUrl()
Returns the new account page URL of the Authentication Service

Specified by:
getNewAccountPageUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
The URL

getViewAccountPageUrl

public String getViewAccountPageUrl()
Returns the View account page URL of the Authentication Service

Specified by:
getViewAccountPageUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
The URL

getLostPasswordPageUrl

public String getLostPasswordPageUrl()

Specified by:
getLostPasswordPageUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication

getLostLoginPageUrl

public String getLostLoginPageUrl()

Specified by:
getLostLoginPageUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication

getDoLogoutUrl

public String getDoLogoutUrl()
Returns the disconnect URL of the Authentication Service

Specified by:
getDoLogoutUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
The URL

getHttpAuthenticatedUser

public fr.paris.lutece.portal.service.security.LuteceUser getHttpAuthenticatedUser(javax.servlet.http.HttpServletRequest request)
Returns a Lutece user object if the user is already authenticated in the Http request. This method should return null if the user is not authenticated or if the authentication service is not based on Http authentication.

Specified by:
getHttpAuthenticatedUser in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Parameters:
request - The HTTP request
Returns:
Returns A Lutece User

getAccessDeniedTemplate

public String getAccessDeniedTemplate()
Returns the access denied template

Specified by:
getAccessDeniedTemplate in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
The template

getAccessControledTemplate

public String getAccessControledTemplate()
Returns the access controled template

Specified by:
getAccessControledTemplate in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
The template

isUsersListAvailable

public boolean isUsersListAvailable()
Tells whether or not the authentication service can provide a list of all its users

Specified by:
isUsersListAvailable in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
true if the service can return a users list

getUsers

public Collection<fr.paris.lutece.portal.service.security.LuteceUser> getUsers()
Returns all users managed by the authentication service if this feature is available.

Specified by:
getUsers in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
A collection of Lutece users or null if the service doesn't provide a users list

getUser

public fr.paris.lutece.portal.service.security.LuteceUser getUser(String strUserLogin)
Returns the user managed by the authentication service if this feature is available.

Specified by:
getUser in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Parameters:
strUserLogin - user login
Returns:
A Lutece users or null if the service doesn't provide a user

getRolesByUser

public String[] getRolesByUser(fr.paris.lutece.portal.service.security.LuteceUser user)
get all roles for this user : - user's roles - user's groups roles

Specified by:
getRolesByUser in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Parameters:
user - The user
Returns:
Array of roles

isMultiAuthenticationSupported

public boolean isMultiAuthenticationSupported()
Return false

Specified by:
isMultiAuthenticationSupported in interface fr.paris.lutece.portal.service.security.LuteceAuthentication
Returns:
false
See Also:
LuteceAuthentication.isMultiAuthenticationSupported()

getIconUrl

public String getIconUrl()

Specified by:
getIconUrl in interface fr.paris.lutece.portal.service.security.LuteceAuthentication

toString

public String toString()

Overrides:
toString in class Object

updateDateLastLogin

public void updateDateLastLogin(fr.paris.lutece.portal.service.security.LuteceUser user,
                                javax.servlet.http.HttpServletRequest request)

Specified by:
updateDateLastLogin in interface fr.paris.lutece.portal.service.security.LuteceAuthentication


Copyright © 2014 Mairie de Paris. All Rights Reserved.