login with domain controller and without domain controll

Viewed 23

I tried to access the username DomainControlle I succeeded with the following code

Request.ServerVariables.Get("logon_user");
System.Security.Principal.WindowsIdentity.GetCurrent().Name;
System.Security.Principal.WindowsPrincipal(System.Security.Principal.WindowsIdentity.GetCurrent()).Identity.Name;

with web.config

     <authorization>
    <deny users="?"/>
    <allow users ="*" />
  </authorization>
</system.web>

If the configuration code is not in the server, the code will not work

My problem is this. Internal users of the domain are working. Users outside the domain give an error. Unauthorized I want to direct the domain's internal users to the next login page. And users outside the domain can see the login page

Thanks for your help

0 Answers
Related