Re: Login failed for user (null). Not associated with a trusted SQLSe

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Sherri,

If your developers have IIS and SQL installed on the same box the user token for SSPI will be passed to SQL for the login. If your demo environment has the IIS and SQL on different boxes this would explain your issue. IIS can not pass the Windows user token to another machine on the network. The simplest solution will be to add and SQL server username and password to the connection string. If you want to use windows authentication and SSPI you will have to configure Active Directory to pass the Kerberos ticket along to the next machine for authentication.

Hope this helps.

Kris

"Sherri" <Sherri@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message news:869C31CE-EFCF-4BC7-B406-F217FEB815D0@xxxxxxxxxxxxxxxx
I know this question has been posted in many places, but I have not been able
to solve our current problem. The developers in my office are all new to
C#.net. We have been developing an application using Visual Studio .NET 2003
and IIS 6 with SQL Server 2000. Up until this point each developer has used
a local copy of IIS and connected to sql server on a remote server without
any problems. Next week we have a demo, and I have tried to deploy our
solution to the IIS(6) on the remote server which also hosts the SQL server
we have been using. Now we all get the 'Login failed for user (null)......'
error message.
The web.config has the following:
<authentication mode="Windows"/>
<identity impersonate="true" />

Integrated Security = SSPI is a part of the connection string.

On the remote server, Sql server is set to use both windows and sql server
authentication
IIS is set for Integrated Windows authentication.
We cannot use active directory and therefore do not have Kerberos enabled.
Any help would be greatly appreciated.

Thanks
Sherri


.



Relevant Pages

  • Re: PROBLEM: ASP on IIS 5 secured via "Windows Integrated Authentication" accessing "
    ... uses NT group based permissons on the SQL Server, ... > transfered to the IIS box and IIS does a local logon. ... > delegation for all accounts. ...
    (microsoft.public.inetserver.iis.security)
  • Re: crash on virtual dimensions
    ... SQL authentication doesn't work for SQL Server to anywhere. ... It is basically a way for access developers to start writing all of their ...
    (microsoft.public.sqlserver.olap)
  • Re: Standalone IIS server access to sql in Domain
    ... There is no way to "trust" a domain from a non-domain machine - the only workaround is to replicate the account used on both ends. ... That means you need an account on IIS and the same account on the sql server machine. ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Re: Alternate to RDA
    ... Saves me a lot of time on researching. ... strict group and local policies rights, why was IIS chosen ... > I'm not aware of any other way to connect to SQL Server. ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: Active sync and SQL CE
    ... IIS is a requirement for either merge replication or RDA. ... ActiveSync to play with take a look at the Data Port line of products ... These work over ActiveSync to port SQL CE databases to ... and from SQL Server 2000 and Access. ...
    (microsoft.public.pocketpc.developer)