asp.net - Avoiding authentication required popup while using integrated windows authentication and accessing application from internet -
i need implement single sign on application being used on both intranet , internet. , application uses own table storing user information , has more users present in ad company. example contract workers/3rd party vendors etc , hence many users don't belong active directory of domain listed in user table.
the application bit old , uses form authenticate users. strangely authentication mode in web.config file has following entry authentication. <authentication mode="none" />
i changed authentication mode windows in web.config , in iis 6 selected integrated windows authentication , unchecked anonymous access.
now have following 2 scenarios.
#1 intranet
user logs in system using system credential stored in ad if user hits link web application should logged in. have implemented part using page.user.identity.name in page load of login.aspx check if user exists in db.
#2 internet
if check external network browser prompts me credential.
the requirement user should not prompted credential instead should shown current login page
i googled , ended on stackoverflow every time. sadly solutions did not work out me.
i stumbled upon post scott enabling windows authentication within intranet asp.net web application , if check comments scott refers use of solution commenter ripster in case application accessed internet intranet. though didn't work out me or may didn't properly.
any regarding appreciated.
it seems require mix of windows , forms authentication : the requirement user should not prompted credential instead should shown current login page
thought share . may can have seen people second below mentioned solution lot. ( atleast when read it.)
if you're in classic mode - can have both windows , forms authentication. alert pop
challenge-based , login redirect-based authentication cannot used simultaneously you can ignore warning. carlosag says that:
we decided leave there because still behavior many user scenarios consider incorrect, since of time forms authentication uses anonymous authentication , not windows. read here.
now when want use integrated mode, stack question : iis7 challenge-based , login redirect-based authentication cannot used simultaneously leads famous link: http://mvolo.com/iis-70-twolevel-authentication-with-forms-authentication-and-windows-authentication/, allows change authentication way page. way can manage when using windows authentication manage usernames using code:
string user = request.servervariables["logon_user"]; refer link: http://beensoft.blogspot.in/2008/06/mixing-forms-and-windows-authentication.html , gives different way of mixing forms , windows authentication.
Comments
Post a Comment