Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ASP Connection Failure using SQL Authentication
Message
De
01/02/2006 02:37:32
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
31/01/2006 16:08:29
Information générale
Forum:
ASP.NET
Catégorie:
Bases de données
Divers
Thread ID:
01091297
Message ID:
01092221
Vues:
16
>>Probably from windows app you're actually using windows authentication
>>(recommended) and not SQL authentication. Does that windows app connect if >you do that from a nontrusted computer?
>>Cetin
>
>I'm running them on the same computer. In fact they are using the same class for establishing the connection to the database and the same file for storing the connection string, so I can't imagine any way the windows app would be using a different connection. I checked the string just before issuing the open connection and it is identical in each application.
>
>It seems to me as if the web app can't even see the server. Unfortunately I'm rather a novice when it comes to IIS.

It sounds strange I know. However it's how SQL server works. When configured for windows authentication or mixed mode and the user is a trusted one, it simply even doesn't care 'username/pwd' combination and instead does a windows authentication. With SQL server directly on your dev. machine this is the case. You can trace it in profiler. Though you have uid/pwd the connecting account is trusted windows account (unless you do it via TCP/IP:port).
For web apps. the account is ASPNET if the machine is not a domain controller. If you grant local ASPNET account to access your MSSQL database then it would work.
PS: If you impersonate="true" in web.config w/o username/pwd then it's IUSR_machinename.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform