Windows Authentication problems

T

Thomas Scheiderich

I am having a problem connecting to an Sql Server using Windows
Authentication.

I am using the following command:

server=Raptor;uid=tfs;password=tol1ee;database=ABC;Network Library =dbmssocn

This works fine if Sql Server is set up as Sql and Windows Authentication.
If I change the Sql Server to Windows Authentication, I get the following
page:

*******************************************************************
Server Error in '/' Application.
----------------------------------------------------------------------------
----

Login failed for user 'tfs'. Reason: Not associated with a trusted SQL
Server connection.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException: Login failed for user
'tfs'. Reason: Not associated with a trusted SQL Server connection.

Source Error:


Line 69:
Line 70: Dim objConnect as SqlConnection = new
SqlConnection("server=Raptor;uid=tfs;password=tfstom;database=VDW;Network
Library =dbmssocn")
Line 71: objConnect.Open()
Line 72: sqlString = "exec ExecPackage " &
request.QueryString("name")
Line 73:


Source File: c:\inetpub\wwwroot\contour\VDW\TMPbbduhzgxxi.aspx Line: 71

Stack Trace:


[SqlException: Login failed for user 'tfs'. Reason: Not associated with a
trusted SQL Server connection.]
System.Data.SqlClient.ConnectionPool.GetConnection(Boolean&
isInTransaction) +484

System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(SqlConnec
tionString options, Boolean& isInTransaction) +372
System.Data.SqlClient.SqlConnection.Open() +384
ASP.TMPbbduhzgxxi_aspx.Page_Load(Object Sender, EventArgs E) in
c:\inetpub\wwwroot\contour\VDW\TMPbbduhzgxxi.aspx:71
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +35
System.Web.UI.Page.ProcessRequestMain() +731




----------------------------------------------------------------------------
----
Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET
Version:1.1.4322.573
****************************************************************************
****

I have no problem connecting using the Query program.

I can also connect using ASP pages using a DNS that is set to Windows
Authentication.

What do I have to change to connect to a computer using Windows
Authentication?

Thanks,

Tom.
 
T

Trevor Benedict R

Either associate tfs with a valid NT Login account or remove the user
name and password and allow Impersonation from the web.config file and
also remove the anonymous login & use basic authentication (W/ SSL) if
required or change the anonymous account used by IIS to an NT Domain
account.

Trevor Benedict R
MCSD

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,596
Members
45,128
Latest member
ElwoodPhil
Top