Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

exclude filter from specific pages

843840Jan 23 2003 — edited Jan 23 2003
What is the best way to exclude a filter from a specific resource? I have two JSPs that should not have my Authentication filter run on them, but the rest should.

Two ideas came to my mind:

1. Make a filter to disable the Authentication filter and map it to the two URLs that should not be authenticated. This seems like an inelegant workaround at best, and I'm hoping it's not the best way to do it.

2. Write a URL-mapping for Authentication filter for every resource in my webapp except those two. This also seems kind of shortsighted, and a pain to update whenever I add a new JSP or servlet.

Any advice?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 20 2003
Added on Jan 23 2003
2 comments
292 views