fr.paris.lutece.portal.service.security
Class SecurityTokenService

java.lang.Object
  extended by fr.paris.lutece.portal.service.security.SecurityTokenService
All Implemented Interfaces:
ISecurityTokenService

public class SecurityTokenService
extends Object
implements ISecurityTokenService

This class provides a security service for getting and verify tokens


Field Summary
static String MARK_TOKEN
           
static String PARAMETER_TOKEN
           
 
Method Summary
static ISecurityTokenService getInstance()
          Returns the instance of the singleton
 String getToken(javax.servlet.http.HttpServletRequest request, String strAction)
          return a security token
 boolean validate(javax.servlet.http.HttpServletRequest request, String StrAction)
          verify if the request contains the securiy token
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MARK_TOKEN

public static final String MARK_TOKEN
See Also:
Constant Field Values

PARAMETER_TOKEN

public static final String PARAMETER_TOKEN
See Also:
Constant Field Values
Method Detail

getInstance

public static ISecurityTokenService getInstance()
Returns the instance of the singleton

Returns:
The instance of the singleton

getToken

public String getToken(javax.servlet.http.HttpServletRequest request,
                       String strAction)
return a security token

Specified by:
getToken in interface ISecurityTokenService
Parameters:
request - The Http request
strAction - the action type
Returns:
a security token

validate

public boolean validate(javax.servlet.http.HttpServletRequest request,
                        String StrAction)
verify if the request contains the securiy token

Specified by:
validate in interface ISecurityTokenService
Parameters:
request - The Http request
StrAction - the action type
Returns:
true if the request contains the security token associated to the action type


Copyright © 2014 Mairie de Paris. All rights reserved.