locked
Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON' RRS feed

  • Question

  • User1383829521 posted

    hi team

    i have this issues, i have 2 machines Machine A has SQL server 2008 express Machine B has IIS 7 with windows 7 32 bit

    i have a web page that search the log information from tables from Machine A,if a run the website from Machine B where the iis is installed the webpage will open

    but if i run it from another machine the samewebsite im getting this error

    Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'

    any advice

    i have this option to true

    connectionString<add name="ConnectionString" connectionString="Data Source=DBA\SQLEXPRESSP3;Initial Catalog=MYDB;Integrated Security=True" providerName="System.Data.SqlClient"/>

    <identity impersonate="true"/>

    <authentication mode="Windows"/>

     

    Monday, April 28, 2014 11:54 PM

Answers

  • User1815411410 posted

    hi there,

    you should create a separate db user to access the database. Next, your connection stirng should look something like.:

    <add name="connString" connectionString="Data Source=our_SQL_SERVER_ID;uid=your_DB_username;pwd=your_DB_password;Initial Catalog=your_DB_name"></add>

    Therefore, you cannot use the "Windows Authentication mode", but "SQL Server Authentication mode"

    Please mark this response as an answer if it helps. Thanks heaps!

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, April 29, 2014 1:21 AM

All replies

  • User1815411410 posted

    hi there,

    you should create a separate db user to access the database. Next, your connection stirng should look something like.:

    <add name="connString" connectionString="Data Source=our_SQL_SERVER_ID;uid=your_DB_username;pwd=your_DB_password;Initial Catalog=your_DB_name"></add>

    Therefore, you cannot use the "Windows Authentication mode", but "SQL Server Authentication mode"

    Please mark this response as an answer if it helps. Thanks heaps!

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, April 29, 2014 1:21 AM
  • User1383829521 posted

    thanks dyyo but if i do that

    the user and password will be see and we can have a securty breach

    thanks for your advice

    Tuesday, April 29, 2014 10:26 AM
  • User219464869 posted

    I had a similar issue with my site not so long ago.  I added the following to the web.config file and it cured it:

        <authorization>
          <deny users="?" />
        </authorization>

    Not sure if that will fix the problem as I'm fairly new to ASP coming from a Windows forms based background but it's worth a try.

    Thursday, May 1, 2014 8:22 AM
  • User1324782620 posted

    Possible areas to check

    1-Check which application pool the web site is running.if its taking application pool identity and that account does not have acces to db then it will fail.

    2-Chek what authentication is set up at IIS level for this site.if both windows and anonymous authentication is enabled then disable anonymous authentication as you are

    using windowsauthentication only.

    Thursday, May 1, 2014 11:15 AM
  • User1140095199 posted

    Hi,

    Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'

    First, your users need to have delegation enabled and if the only thing that's changed, it'l likely they do. Otherwise you can uncheck the "Account is sensitive and cannot be delegated" checkbox is the user properties in AD.

    Second, your service account(s) must be trusted for delegation. Since you recetly changed your service account I suspect this is the culprit. (http://technet.microsoft.com/en-us/library/cc739474(v=ws.10).aspx)

    Refer to the following article:

    http://stackoverflow.com/questions/12462674/sql-server-returns-error-login-failed-for-user-nt-authority-anonymous-logon

    Best Regards!

    Thursday, May 8, 2014 6:24 AM