Re: Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection from ASP.Net pages
From: Miha Markic [MVP C#] (miha)
Date: 08/31/04
- Previous message: HG: "Re: Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection from ASP.Net pages"
- In reply to: Brian Fulford: "Re: Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection from ASP.Net pages"
- Next in thread: HG: "Re: Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection from ASP.Net pages"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 31 Aug 2004 09:25:11 +0200
"Brian Fulford" <brian.fulford@ssigroup.com> wrote in message
news:%23Pa7satjEHA.3632@TK2MSFTNGP09.phx.gbl...
> Originally the app was set up to use sql security and not windows
> authentication; however, it was mandated that we convert to windows
> integrated security.
>
> When I check the Windows Identity... IUSR is the current user.. so
> shouldnt
> the IUSR account be able to access the SQL server if that user was created
> on the SQL server?
No, aspnet application is run under aspnet account by default (if not
otherwise specified) or under network service under windows 2003.
--
Miha Markic [MVP C#] - RightHand .NET consulting & development
miha at rthand com
www.rthand.com
> ? System.Security.Principal.WindowsIdentity.GetCurrent
>
> {System.Security.Principal.WindowsIdentity}
>
> AuthenticationType: "NTLM"
>
> IsAnonymous: False
>
> IsAuthenticated: True
>
> IsGuest: False
>
> IsSystem: False
>
> Name: "CBF1\IUSR_FULFOB"
>
> Token: 868
>
>
>
>
>
>
>
> "Miha Markic [MVP C#]" <miha at rthand com> wrote in message
> news:OU3ZoWtjEHA.1040@TK2MSFTNGP09.phx.gbl...
>> Brian,
>>
>> aspnet Application runs under local aspnet account thus it can't connect
> to
>> sql server using integrated security.
>> Why don't you use sql server security instead?
>> Or you might run your app under some other domain account (see <identity>
>> node of web.config)
>>
>> --
>> Miha Markic [MVP C#] - RightHand .NET consulting & development
>> miha at rthand com
>> www.rthand.com
>>
>> "Brian Fulford" <brian.fulford@ssigroup.com> wrote in message
>> news:%234QX4%23sjEHA.728@TK2MSFTNGP09.phx.gbl...
>> >I am losing lots of hair over this issue. We are trying to implement
>> >windows
>> > authentication from a web server to a database server.
>> > The web server is on a domain; the db server is not... does this
>> > matter?
>> > the IUSR_machinename user from the web server has been added as an
> account
>> > on the db server and also been to added to db logins and given access
>> > to
>> > the
>> > databases that it will need access to.
>> >
>> > My web.config has the following:
>> > <authentication mode="Windows"/>
>> >
>> > <sessionState mode="SQLServer" sqlConnectionString="Network
>> > Library=DBMSSOCN; data source=192.168.30.95; Integrated Security=SSPI;"
>> > cookieless="false" timeout="20"/>
>> >
>> >
>> > Anyone run into this?
>> >
>> >
>> > Login failed for user '(null)'. Reason: Not associated with a trusted
> SQL
>> > Server connection.
>> > at System.Data.SqlClient.ConnectionPool.GetConnection(Boolean&
>> > isInTransaction)
>> > at
>> >
> System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(SqlConnec
>> > tionString options, Boolean& isInTransaction)
>> > at System.Data.SqlClient.SqlConnection.Open()
>> > at System.Web.SessionState.SqlStateConnection..ctor(String
>> > sqlconnectionstring)
>> >
>> >
>> >
>>
>>
>
>
- Previous message: HG: "Re: Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection from ASP.Net pages"
- In reply to: Brian Fulford: "Re: Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection from ASP.Net pages"
- Next in thread: HG: "Re: Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection from ASP.Net pages"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|