• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Tim Cooke
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
  • Rob Spoor
  • Junilu Lacar
  • paul wheaton
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
  • Scott Selikoff
  • Piet Souris
  • Jj Roberts
  • fred rosenberger

basic windows authentication

Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I have JSP Page with login link that point to the login.asp that resides on the IIS webserver. I protected this page with basic authentication.When the user clicks the link, windowns login popup will be prompted. If everything is okay then my login.asp will redircet to the following link.

my problem is once the user is logged out, i am sending to. home page. If he click the login link once again i am not getting the popup but it is successfully going to the application. Anybody can help me how can i force this one in my code.

Prabhakar P
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You're probably loggin out by using a "session.invalidate()".

Basic authentication works differently, it adds its own Cookie to the HTTP header, and you need to remove this as well, otherwise your application will always accept them as authenticated.

The name of the cookie you need to clear is 'Authorization'.

Use cookie.setMaxAge(0) to delete a Cookie, but you may need to check the API to find how to get the cookies and then find the correct one to delete.

Consider Paul's rocket mass heater.
    Bookmark Topic Watch Topic
  • New Topic