0

I am working on an asp.net mvc web application, and i have updated the web.config file to use windows authentication as follow:-

  <authentication mode="Windows" />
    <authorization>
      <deny users="?" />
    </authorization>

Currently the users will be prompted with a username & password dialog to enter their credentials, so is there a way to automatically sign users without the need to re-enter their credentials? Best Regards

1 Answer 1

1

If users are already authenticated by the domain that the application sits in (eg. your intranet) they will automatically be logged in. if your users are coming from another network (eg. the internet) they will be prompted with the basic authentication dialog that you are seeing.

Make sure IIS has it's authentication setup so that you don't have anonymous enabled and windows authentication enabled.

Sign up to request clarification or add additional context in comments.

3 Comments

this is my case anonymouse is disabled and windows authentication is enalbed. but users are promted to enter their credentials
if i try to access the site using IE it will automatically signin users, but if i access the site using firefox then the user will be prompted to enter his username and password
Yes different browsers will behave differently. There isn't much you can do about this without writing your own HttpModule that writes an authentication cookie for you.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.