Java Doc for RememberMeServices.java in  » Security » acegi-security » org » acegisecurity » ui » rememberme » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Security » acegi security » org.acegisecurity.ui.rememberme 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.acegisecurity.ui.rememberme.RememberMeServices

All known Subclasses:   org.acegisecurity.ui.rememberme.TokenBasedRememberMeServices,  org.acegisecurity.ui.rememberme.NullRememberMeServices,
RememberMeServices
public interface RememberMeServices (Code)
Implement by a class that is capable of providing a remember-me service.

Acegi Security filters (namely org.acegisecurity.ui.AbstractProcessingFilter and org.acegisecurity.ui.rememberme.RememberMeProcessingFilter will call the methods provided by an implementation of this interface.

Implementations may implement any type of remember-me capability they wish. Rolling cookies (as per http://fishbowl.pastiche.org/2004/01/19/persistent_login_cookie_best_practice) can be used, as can simple implementations that don't require a persistent store. Implementations also determine the validity period of a remember-me cookie. This interface has been designed to accommodate any of these remember-me models.

This interface does not define how remember-me services should offer a "cancel all remember-me tokens" type capability, as this will be implementation specific and requires no hooks into Acegi Security.


author:
   Ben Alex
version:
   $Id: RememberMeServices.java 1784 2007-02-24 21:00:24Z luke_t $




Method Summary
 AuthenticationautoLogin(HttpServletRequest request, HttpServletResponse response)
     This method will be called whenever the SecurityContextHolder does not contain an Authentication and the Acegi Security system wishes to provide an implementation with an opportunity to authenticate the request using remember-me capabilities.
 voidloginFail(HttpServletRequest request, HttpServletResponse response)
     Called whenever an interactive authentication attempt was made, but the credentials supplied by the user were missing or otherwise invalid.
 voidloginSuccess(HttpServletRequest request, HttpServletResponse response, Authentication successfulAuthentication)
     Called whenever an interactive authentication attempt is successful.



Method Detail
autoLogin
Authentication autoLogin(HttpServletRequest request, HttpServletResponse response)(Code)
This method will be called whenever the SecurityContextHolder does not contain an Authentication and the Acegi Security system wishes to provide an implementation with an opportunity to authenticate the request using remember-me capabilities. Acegi Security makes no attempt whatsoever to determine whether the browser has requested remember-me services or presented a valid cookie. Such determinations are left to the implementation. If a browser has presented an unauthorised cookie for whatever reason, it should be silently ignored and invalidated using the HttpServletResponse object.

The returned Authentication must be acceptable to org.acegisecurity.AuthenticationManager or org.acegisecurity.providers.AuthenticationProvider defined by the web application. It is recommended org.acegisecurity.providers.rememberme.RememberMeAuthenticationToken be used in most cases, as it has a corresponding authentication provider.


Parameters:
  request - to look for a remember-me token within
Parameters:
  response - to change, cancel or modify the remember-me token a valid authentication object, or null if the request should not be authenticated



loginFail
void loginFail(HttpServletRequest request, HttpServletResponse response)(Code)
Called whenever an interactive authentication attempt was made, but the credentials supplied by the user were missing or otherwise invalid. Implementations should invalidate any and all remember-me tokens indicated in the HttpServletRequest.
Parameters:
  request - that contained an invalid authentication request
Parameters:
  response - to change, cancel or modify the remember-me token



loginSuccess
void loginSuccess(HttpServletRequest request, HttpServletResponse response, Authentication successfulAuthentication)(Code)
Called whenever an interactive authentication attempt is successful. An implementation may automatically set a remember-me token in the HttpServletResponse, although this is not recommended. Instead, implementations should typically look for a request parameter that indicates the browser has presented an explicit request for authentication to be remembered, such as the presence of a HTTP POST parameter.
Parameters:
  request - that contained the valid authentication request
Parameters:
  response - to change, cancel or modify the remember-me token
Parameters:
  successfulAuthentication - representing the successfully authenticated principal



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.