marius

Distinguished
Apr 4, 2002
40
0
18,530
Archived from groups: microsoft.public.windowsxp.security_admin (More info?)

Hi,

I have problems connecting to SQL server using SSPI. I have a connection
string like
SqlConnection("server=[servername];database=pubs;Integrated Security=SSPI")

I get this error msg: Login failed for [servername\ASPNET].
Is ASPNET a user?, and where do I define it ? I have tried Config .Net
framwork but i do not really understand the logical connection between ASPNET
user, the framework and the general security policy at the server.. Could
anybody give me an example or something..
 
G

Guest

Guest
Archived from groups: microsoft.public.windowsxp.security_admin (More info?)

Marius;

What are you using to connect with SQL Server? Sound like you are using a
..NET application or web page. computername\ASPNET is an account that is set
up when you install the framework to allow the aspnet_wp worker process to
access your computer. When you run a .NET app, the app (by default) accesses
the computer as computername\ASPNET. By design, this acocunt is a member of
"Users" and has hardly any privileges.

So, you need to narrow things down:

1) Try to connect with the SQL SERVER instance using query manager and the
exact same connection parameters. If you fail, you have a much more limited
set of things to look into.

2) Try "server=(local)...", if indeed it is on the local machine.

No sense in looking further until you can do one of the above.

If you have a .NET app, then you may want to turn impersonation on, which
will tell the framework to use the current user's credentials instead of the
aspnet_wp's default credentials: "computername\ASPNET."

David


"marius" wrote:

> Hi,
>
> I have problems connecting to SQL server using SSPI. I have a connection
> string like
> SqlConnection("server=[servername];database=pubs;Integrated Security=SSPI")
>
> I get this error msg: Login failed for [servername\ASPNET].
> Is ASPNET a user?, and where do I define it ? I have tried Config .Net
> framwork but i do not really understand the logical connection between ASPNET
> user, the framework and the general security policy at the server.. Could
> anybody give me an example or something..
>
>