Hi Deepak, Firstly wanna share the problem em facing: working with servlet and jsp for my project. I have 3 main jsp pages which interacts with user for accepting user input and supply them to servlets and then that info get punched to database. All i need is to stop the illigal access to my main jsp pages and m succesful in that. Upto here everything is fine now if i directly run the 3 pages i get an error that is ;The server encountered an internal error () that prevented it from fulfilling this request: and let me tell you its fine coz one can only go to these pages after getting autheticated from database. but server displays error message and i need when some one directly run these he/she get redircted to main login page.Hope you understand the environment and help me. Thanks in advance for ur help.