3
votes

How do i implement Window Active Directory authentication for Intranet user and Forms authentication for Internet users, i found many examples online explaining each of them individually but can't get to find one that explain both implemented together.

I have my ASP MVC 4 project working with Forms Authentication but was requested to add Windows Active Directory authenticate for intranet users. How do i do it?

My existing Forms Authentication

    <authentication mode="Forms">
        <forms loginUrl="~/Account/Login" timeout="2880" name=".ASPXFORMSAUTH"/>
    </authentication>
1
Did you ever get this figured out? It's 2016 and I still can't find a definitive answer to this! (And I've been searching for two days!)Scott Fraley
@ScottK.Fraley I could not recall exactly how i resolve the above but I remember that upgraded my MVC project to MVC 5 and use AuthenticationManager to manage the logins (be in intra net or token). AuthenticationManager.SignOut(DefaultAuthenticationTypes.ApplicationCookie, DefaultAuthenticationTypes.ExternalCookie);JeeShen Lee

1 Answers

2
votes

I am only just beginning to explore this type of situation myself so I am not going to try and give a definitive answer, but I think that you will want to start looking at Claims Based Authentication and Secure Token Services (STS) Have a look at:

  • Least Privilege by Dominick Baier; as well as some of his
  • pluralsight courses to get a better understanding of what you're trying to achieve.