Re: Windows Authentication and Anonymous login URGENT
From: Michal A. Valasek (news_at_altaircom.net)
Date: Fri, 25 Jul 2003 17:56:40 +0200
| users. However I need to be able to tell a difference if
| they have login through the intranet, which window
| authentication just lets them in, or through the internet
| where the login pop up box asks for their username and
I'm affraid that you won't be able to tell this - they're just
authenticated, and if browser asked for authentication or provided it on
itself is his thing and you can't discover that.
However, based on your network structure, you may try to filter
Internet/intranet users based on IP address. If users inside your network
are using some IP range, you may check if user is from this range or not.
| My second issue is that I need to let anonymous users into
| my default.aspx page but if my intranet users hit this
| page it needs to redirect them to a different
| default.aspx. But I cant tell the difference if the user
| logs in through the intranet or the internet. How can I
| achive this?
You can check if user is authenticated or not (via the
Request.IsAuthenticated) property. So, you can setup your Default.aspx to be
accessible for both authenticated and anonymous users and chech if they are
authenticated and then modify the page or redirect them away.
Honestly, I don't know *WHY* you need to know how the user is logged? I
think that matters only if is authenticated or not. If enters password by
hand or is remembered and sent automatically by browser, is user's thing,
not mine, as application author.
-- Michal A. Valasek, Altair Communications, http://www.altaircom.net Please do not reply to this e-mail, for contact see http://www.rider.cz