remote connection to SQL server problems

Discussion in 'ASP .Net Security' started by VR, Sep 22, 2003.

  1. VR

    VR Guest

    While developing an ASP.NET with a SQL server running
    locally, I didn't have any problems using the following
    connection string (where ATP is the local server's name)

    "Server=ATP;uid=AppAdmin;pwd=pass;Database=DB1";

    When I try to connect to a remote SQL server named DTP,
    using connection string:

    "Server=DTP;uid=AppAdmin;pwd=pass;Database=DB1";

    I am getting an exception "SQL Server doesn't exist or
    access denied".

    I wrote a Windows Forms apps in .NET and successfully
    connected to DTP server with exaclty the same connection
    string as used in ASP.NET. So, I figured my problem had
    something to do with accounts under which both apps run.

    I tried the following:

    1. added to connection string "Network Library =dbmssocn"
    per MS article Q315159

    2. tried using impersonation:

    <identity
    impersonate="true"
    userName="user"
    password="pass"
    />

    where user is the user name for an administrator on my
    machine

    Still, no luck.

    Any suggestions are greatly appreciated.

    Thanks,
    VR
     
    VR, Sep 22, 2003
    #1
    1. Advertising

  2. Hi Victor,

    There are a lot of possible reasons for the error:

    "SQL Server does not exist or access denied"

    Based on my reserch and experience, the following Knowledge Base article is
    useful to you. Please refer to it carefully.

    INF: Potential Causes of the "SQL Server Does Not Exist or Access Denied"
    Error Message
    http://support.microsoft.com/default.aspx?scid=kb;en-us;328306

    I hope it helps.

    Best regards,

    Jacob Yang
    Microsoft Online Partner Support
    <MCSD>
    Get Secure! ¨C www.microsoft.com/security
    This posting is provided "as is" with no warranties and confers no rights.
     
    Jacob Yang [MSFT], Sep 23, 2003
    #2
    1. Advertising

  3. VR

    VR Guest

    Thanks Jacob.

    I will sure read the article.

    Also, while on the subject, what is the customary way for
    allowing ASP.NET applications to access a remote SQL
    server? Is adding ASPNET account on the SQL server
    appropriate or should I impersonate an existing user with
    my ASP.NET app?

    Thanks again.
    VR


    >-----Original Message-----
    >Hi Victor,
    >
    >There are a lot of possible reasons for the error:
    >
    >"SQL Server does not exist or access denied"
    >
    >Based on my reserch and experience, the following

    Knowledge Base article is
    >useful to you. Please refer to it carefully.
    >
    >INF: Potential Causes of the "SQL Server Does Not Exist

    or Access Denied"
    >Error Message
    >http://support.microsoft.com/default.aspx?scid=kb;en-

    us;328306
    >
    >I hope it helps.
    >
    >Best regards,
    >
    >Jacob Yang
    >Microsoft Online Partner Support
    ><MCSD>
    >Get Secure! ¨C www.microsoft.com/security
    >This posting is provided "as is" with no warranties and

    confers no rights.
    >
    >.
    >
     
    VR, Sep 23, 2003
    #3
  4. Hi Victor,

    Your new question is a big topic. Based on my research and experience, the
    following URLs are useful for your new question. Please refer to it
    carefully.

    Building Secure ASP.NET Applications: Authentication, Authorization, and
    Secure Communication - Data Access Security
    http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetsec/ht
    ml/SecNetch12.asp
    "...This chapter presents recommendations and guidance that will help you
    develop a secure data access strategy..."

    HOW TO: Configure SQL Server Security for .NET Applications
    http://support.microsoft.com/default.aspx?scid=kb;en-us;815154

    I hope it helps.

    Best regards,

    Jacob Yang
    Microsoft Online Partner Support
    <MCSD>
    Get Secure! ¨C www.microsoft.com/security
    This posting is provided "as is" with no warranties and confers no rights.
     
    Jacob Yang [MSFT], Sep 24, 2003
    #4
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. vighnesh
    Replies:
    1
    Views:
    5,568
    Landley
    Sep 29, 2005
  2. Mitya Mitriev
    Replies:
    5
    Views:
    12,222
    =?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=
    Aug 6, 2006
  3. =?Utf-8?B?ZGF2aWQ=?=
    Replies:
    4
    Views:
    319
    Alexey Smirnov
    Oct 19, 2007
  4. Wesley Chen
    Replies:
    0
    Views:
    236
    Wesley Chen
    Apr 7, 2009
  5. Wesley Chen
    Replies:
    9
    Views:
    253
    Sean O'Halpin
    Apr 14, 2009
Loading...

Share This Page