aspose file tools*
The moose likes Servlets and the fly likes Verify that user has accepted consent message before allowing user to enter page Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Verify that user has accepted consent message before allowing user to enter page" Watch "Verify that user has accepted consent message before allowing user to enter page" New topic
Author

Verify that user has accepted consent message before allowing user to enter page

Bob Talbert
Greenhorn

Joined: Mar 26, 2013
Posts: 4
This is what I am trying to implement:

When the user logs into the page, they are redirected to a consent page with a message. The user must accept the consent message (not authentication) before getting access to the page in the domain. The user will have to consent whenever their session expires.

What would be a good way to implement this? This is a java web application running on Tomcat 7.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61657
    
  67

Sounds simple enough. Add a filter that checks for a "consent" token in the session. If it's not there, redirect to the "consent" page. Once they "consent" place the token in the session.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Bob Talbert
Greenhorn

Joined: Mar 26, 2013
Posts: 4
Bear Bibeault wrote:Sounds simple enough. Add a filter that checks for a "consent" token in the session. If it's not there, redirect to the "consent" page. Once they "consent" place the token in the session.


Thanks, a filter was just what I needed.
 
 
subject: Verify that user has accepted consent message before allowing user to enter page