org.openi.security
Class AuthorizationFilter
java.lang.Object
org.openi.security.AuthorizationFilter
- All Implemented Interfaces:
- javax.servlet.Filter
public class AuthorizationFilter
- extends java.lang.Object
- implements javax.servlet.Filter
Checks session to make sure it has all required attributes (does not populate session).
The project_list_page is responsible for populating the session values.
Why not set the session vars here? B/c choice of projectId is up to the user. Didn't want
to set the session var based on user input here (filter doesn't seem like it should responsd to user input).
Since didn't want to set the projectId var here, wanted to set all session vars in one place.
Doubt this will make much sense - unless you try to refactor.
|
Method Summary |
void |
destroy()
|
void |
doFilter(javax.servlet.ServletRequest req,
javax.servlet.ServletResponse res,
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 |
PROJECT_ID
public static final java.lang.String PROJECT_ID
- See Also:
- Constant Field Values
AuthorizationFilter
public AuthorizationFilter()
doFilter
public void doFilter(javax.servlet.ServletRequest req,
javax.servlet.ServletResponse res,
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
init
public void init(javax.servlet.FilterConfig filterConfig)
- Specified by:
init in interface javax.servlet.Filter
destroy
public void destroy()
- Specified by:
destroy in interface javax.servlet.Filter