I want to create a jsp login filter. 

The filter should:

* intercept requests to any page; verify whether the request is part of a logged-session
* if the session is not logged, redirect the client to a login page
* if the requested page is the login page, don't redirect, otherwise it will loop

thanks in advance