91-9990449935 0120-4256464 |
Authentication FilterWe can perform authentication in filter. Here, we are going to check to password given by the user in filter class, if given password is admin, it will forward the request to the WelcomeAdmin servlet otherwise it will display error message. Example of authenticating user using filterLet's see the simple example of authenticating user using filter. Here, we have created 4 files:
MyFilter.java AdminServlet.java web.xml
download this example (developed using Myeclipse IDE)
download this example (developed using Eclipse IDE) download this example (developed using Netbeans IDE)
Next TopicFilter Config
|