RE: How can I logoff
I'm using form authentication and used session.invalidate(). This works great but the browser may be cacheing your logoff page, in which case you may get some unexpected results if you logoff and back in more than once. You need to disable the page cacheing. I used the following in the head section of my page. Hopefully this little tidbit will help someone else avoid a few hours of debugging that I went through. :o) Dave
RE: How can I logoff
Title: Re: How can I logoff There are a lot of examples - just look up "connection pool" on yahoo one example is: http://coldjava.hypermart.net/classes/dbpool.htm If you want a concrete walk through example check out Java Servlets by Karl Moss. (Second Edition - third if it's available) It does not cover CallableStatements though only inline SQL - to migrate to callable statements takes a little tweaking. Also, what we did was abstract a class which was responsible for executing a query - it first tries to use the existing connection pool but if it does not exist it connects directly to the database. Good luck. Marc -Original Message-From: Christopher Raber [mailto:[EMAIL PROTECTED]]Sent: Wednesday, July 18, 2001 8:24 PMTo: '[EMAIL PROTECTED]'Subject: Re: How can I logoff Using jdbc connections per user is not advisable. You shoukd think in terms of connection pooling. -- Chris Raber, Systems Engineer, AvantGo Inc. v: 248-554-9330, cell: 810-839-3684 http://www.avantgo.com/ Sent wirelessly using AvantGo Enterprise & RIM! -Original Message- From: Blue, Neil <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] <[EMAIL PROTECTED]> Sent: Wed Jul 18 07:57:09 2001 Subject: How can I logoff Hello, I am using the JDBC sercurity on tomcat 3.3. I am able to logon (via basic authentication) to view a secured .jsp page. however I can not see how a user can logoff again so that a new user can logon. Please could someone point me in the right direction. Cheers Neil
Re: How can I logoff
Title: Re: How can I logoff Using jdbc connections per user is not advisable. You shoukd think in terms of connection pooling. -- Chris Raber, Systems Engineer, AvantGo Inc. v: 248-554-9330, cell: 810-839-3684 http://www.avantgo.com/ Sent wirelessly using AvantGo Enterprise & RIM! -Original Message- From: Blue, Neil <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] <[EMAIL PROTECTED]> Sent: Wed Jul 18 07:57:09 2001 Subject: How can I logoff Hello, I am using the JDBC sercurity on tomcat 3.3. I am able to logon (via basic authentication) to view a secured .jsp page. however I can not see how a user can logoff again so that a new user can logon. Please could someone point me in the right direction. Cheers Neil
RE: How can I logoff
Thank you Chris that works. Now I need to sort out page navigation... Neil -Original Message- From: chris brown [mailto:[EMAIL PROTECTED]] Sent: 19 July 2001 10:35 To: [EMAIL PROTECTED] Subject: Re: How can I logoff Try session.invalidate() then send the HTTP status code "401 Unauthorized" session.invalidate(); response.sendError(response.SC_UNAUTHORIZED, "Logged out"); Might get you going in the right direction. -Chris - Original Message - From: "Blue, Neil" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, July 19, 2001 11:15 AM Subject: RE: How can I logoff > Thank you Kaneda, > > It doesn't seem to work. > > Cheers > Neil > > -Original Message- > From: Kaneda K [mailto:[EMAIL PROTECTED]] > Sent: 19 July 2001 09:42 > To: [EMAIL PROTECTED] > Subject: Re: How can I logoff > > > At 15:57 18/07/2001 +0100, you wrote: > >Hello, > > > >I am using the JDBC sercurity on tomcat 3.3. I am able to logon (via basic > >authentication) to view a secured .jsp page. however I can not see how a > >user can logoff again so that a new user can logon. Please could someone > >point me in the right direction. > > > >Cheers > >Neil > > > The fonction to log of is "<%session.invalidate();%>" but I am not sure > that It works with "basic" authentification. > In fact, I think is does not works. but check any way
RE: How can I logoff
Looking at the headers, the browser keeps sending the authorization info anyway so removing the session does not remove the logon in formation. Neil -Original Message- From: Kaneda K [mailto:[EMAIL PROTECTED]] Sent: 19 July 2001 09:42 To: [EMAIL PROTECTED] Subject: Re: How can I logoff At 15:57 18/07/2001 +0100, you wrote: >Hello, > >I am using the JDBC sercurity on tomcat 3.3. I am able to logon (via basic >authentication) to view a secured .jsp page. however I can not see how a >user can logoff again so that a new user can logon. Please could someone >point me in the right direction. > >Cheers >Neil The fonction to log of is "<%session.invalidate();%>" but I am not sure that It works with "basic" authentification. In fact, I think is does not works. but check any way
Re: How can I logoff
Try session.invalidate() then send the HTTP status code "401 Unauthorized" session.invalidate(); response.sendError(response.SC_UNAUTHORIZED, "Logged out"); Might get you going in the right direction. -Chris - Original Message - From: "Blue, Neil" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, July 19, 2001 11:15 AM Subject: RE: How can I logoff > Thank you Kaneda, > > It doesn't seem to work. > > Cheers > Neil > > -Original Message- > From: Kaneda K [mailto:[EMAIL PROTECTED]] > Sent: 19 July 2001 09:42 > To: [EMAIL PROTECTED] > Subject: Re: How can I logoff > > > At 15:57 18/07/2001 +0100, you wrote: > >Hello, > > > >I am using the JDBC sercurity on tomcat 3.3. I am able to logon (via basic > >authentication) to view a secured .jsp page. however I can not see how a > >user can logoff again so that a new user can logon. Please could someone > >point me in the right direction. > > > >Cheers > >Neil > > > The fonction to log of is "<%session.invalidate();%>" but I am not sure > that It works with "basic" authentification. > In fact, I think is does not works. but check any way
RE: How can I logoff
Thank you Kaneda, It doesn't seem to work. Cheers Neil -Original Message- From: Kaneda K [mailto:[EMAIL PROTECTED]] Sent: 19 July 2001 09:42 To: [EMAIL PROTECTED] Subject: Re: How can I logoff At 15:57 18/07/2001 +0100, you wrote: >Hello, > >I am using the JDBC sercurity on tomcat 3.3. I am able to logon (via basic >authentication) to view a secured .jsp page. however I can not see how a >user can logoff again so that a new user can logon. Please could someone >point me in the right direction. > >Cheers >Neil The fonction to log of is "<%session.invalidate();%>" but I am not sure that It works with "basic" authentification. In fact, I think is does not works. but check any way
Re: How can I logoff
At 15:57 18/07/2001 +0100, you wrote: >Hello, > >I am using the JDBC sercurity on tomcat 3.3. I am able to logon (via basic >authentication) to view a secured .jsp page. however I can not see how a >user can logoff again so that a new user can logon. Please could someone >point me in the right direction. > >Cheers >Neil The fonction to log of is "<%session.invalidate();%>" but I am not sure that It works with "basic" authentification. In fact, I think is does not works. but check any way
How can I logoff
Hello, I am using the JDBC sercurity on tomcat 3.3. I am able to logon (via basic authentication) to view a secured .jsp page. however I can not see how a user can logoff again so that a new user can logon. Please could someone point me in the right direction. Cheers Neil