P
Peter Lykkegaard
Hi
I have a problem connecting to MSSQL using windows authentication on
an intranet website
I need to enable integrated windows authentication in IIS6 (Windows
2003 server) and connect to mssql as individual windows users due to
some auditing
Number of people allowed access to the site is limited (4-6)
I have created a new website running on a specified port
ASP.NET 2 is enabled
Integrated windows authentication is enabled
The site is using its own app pool (running with the network service
account)
C# classes/files etc is copied to a directory on the server
Webconfig is edited with this content
<system.web>
<identity impersonate="true"/>
<authentication mode="Windows"/>
<authorization>
<deny users="?"/> <!-- Deny anonymous access -->
</authorization>
</system.web>
My mssql connection is using SSPI
<add name="*************"
connectionString="Data Source=*********;
Initial Catalog=************;
Integrated Security=SSPI;"
providerName="System.Data.SqlClient"/>
The database is located on an server different from the webserver
-----------------
When I start IE on the webserver everything is running ok
When I start IE on my own local computer I get this error:
Event code: 3005
Event message: An unhandled exception has occurred.
Event time: 17-04-2009 15:10:33
Event time (UTC): 17-04-2009 13:10:33
Event ID: c079d364ccb34dcd96ad4b840931f0ad
Event sequence: 4
Event occurrence: 1
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/1643659441/
Root-5-128844474292801572
Trust level: Full
Application Virtual Path: /
Application Path: D:\WebSites\<webfolder>
Machine name: <webserver>
Process information:
Process ID: 3380
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE
Exception information:
Exception type: SqlException
Exception message: Login failed for user 'NT AUTHORITY\ANONYMOUS
LOGON'.
Request information:
Request URL: <url>
Request path: <aspx-file>
User host address: <host-ip>
User: <domain>\myuseraccount>
Is authenticated: True
Authentication Type: Negotiate
Thread account name: NT AUTHORITY\NETWORK SERVICE
Maybe it's an IIS issue?
Just wondering if I missed anything obvious?
I have tried to google through various sites/blogs etc about the topic
but unfortunately I haven't find the key to solve my problem
Thanks in advance
- Peter
I have a problem connecting to MSSQL using windows authentication on
an intranet website
I need to enable integrated windows authentication in IIS6 (Windows
2003 server) and connect to mssql as individual windows users due to
some auditing
Number of people allowed access to the site is limited (4-6)
I have created a new website running on a specified port
ASP.NET 2 is enabled
Integrated windows authentication is enabled
The site is using its own app pool (running with the network service
account)
C# classes/files etc is copied to a directory on the server
Webconfig is edited with this content
<system.web>
<identity impersonate="true"/>
<authentication mode="Windows"/>
<authorization>
<deny users="?"/> <!-- Deny anonymous access -->
</authorization>
</system.web>
My mssql connection is using SSPI
<add name="*************"
connectionString="Data Source=*********;
Initial Catalog=************;
Integrated Security=SSPI;"
providerName="System.Data.SqlClient"/>
The database is located on an server different from the webserver
-----------------
When I start IE on the webserver everything is running ok
When I start IE on my own local computer I get this error:
Event code: 3005
Event message: An unhandled exception has occurred.
Event time: 17-04-2009 15:10:33
Event time (UTC): 17-04-2009 13:10:33
Event ID: c079d364ccb34dcd96ad4b840931f0ad
Event sequence: 4
Event occurrence: 1
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/1643659441/
Root-5-128844474292801572
Trust level: Full
Application Virtual Path: /
Application Path: D:\WebSites\<webfolder>
Machine name: <webserver>
Process information:
Process ID: 3380
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE
Exception information:
Exception type: SqlException
Exception message: Login failed for user 'NT AUTHORITY\ANONYMOUS
LOGON'.
Request information:
Request URL: <url>
Request path: <aspx-file>
User host address: <host-ip>
User: <domain>\myuseraccount>
Is authenticated: True
Authentication Type: Negotiate
Thread account name: NT AUTHORITY\NETWORK SERVICE
Maybe it's an IIS issue?
Just wondering if I missed anything obvious?
I have tried to google through various sites/blogs etc about the topic
but unfortunately I haven't find the key to solve my problem
Thanks in advance
- Peter