Last post Mar 24, 2014 07:17 AM by ArneATK
Mar 19, 2014 05:06 PM|ArneATK|LINK
I would like to connect to SQL Server with integrated Security in an intranet Asp.net page.
<identity impersonate="true" />
My web page connects properly from localhost directly on the web server to SQL server.
If I run the web page from my browser on my workstation I get the error message
Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'.
I use .net 2.0 and a classic App pool. Windows Authenicattion is enabled
What am I doing wrong?
Mar 19, 2014 05:36 PM|PatriceSc|LINK
Is SQL Server on another machine ? If yes this is not as simple as it sounds and requires additional configuration. Try for example
The idea is that this is not because the user logs on server A that your app should be free to use those credentials and connect to wherever you want. Instead you have to explicitely allow those credentials to be reused on other servers.
Start pehaps by making sure you really do need this (ie you want to use db level security for user accounts ?)
Mar 20, 2014 08:25 AM|ArneATK|LINK
Yes SQL server is on another computer. I will study the link you sent.
Mar 21, 2014 05:13 AM|Michelle Ge - MSFT|LINK
Please refer to use the connectionstring below:
Server=YourServer; Database=YourDatabase; Integrated Security=true;
The same time for windows authentication, we need add Security=SSPI to the connectionstring.
For more information, please refer to the links below:
Hope it's useful for you.
Mar 24, 2014 07:17 AM|ArneATK|LINK
In my experience
has the same effect.