Connect to MS Access DB on different server

Discussion in 'ASP .Net Security' started by Roby2222, Nov 1, 2004.

  1. Roby2222

    Roby2222 Guest

    I am trying to connect to a Microsoft Access database, located on a different
    server. I am using ASP.NET and the code I am using works when run from my
    local IIS, but it does not work when I deploy the project to the web server.
    The database is not on the web server or my local machine. I am currently
    using a DSN, which is setup on both machines through a mapped drive.

    I disabled Anonymous Authentication on the IIS directory and enabled
    "Integrated Windows Authentication". In my web.config settings, I set the
    following:

    <authentication mode="Windows"/>
    <identity impersonate="true"/>

    <authorization>
    <allow users="IS-Users"/>
    <deny users="?"/>
    </authorization>

    Here is the first part of the error I receive:

    Data Retrieval Error. System.Data.Odbc.OdbcException: ERROR [HY024]
    [Microsoft][ODBC Microsoft Access Driver] '(unknown)' is not a valid path.
    Make sure that the path name is spelled correctly and that you are connected
    to the server on which the file resides.

    The security of the web page works correctly, but I don't think it's
    delegating the credentials properly. I thought it would by setting the
    Impersonate property to true.

    I have the option of using OleDB if that is a possible solution. Any ideas
    would be appreciated.

    Thanks,
    Roby2222
    Roby2222, Nov 1, 2004
    #1
    1. Advertising

  2. Roby2222

    [MSFT] Guest

    Hello Roby,

    Is the account "IS-Users" a local user or a domain user? If you logon as
    this user and access the web app, it will use this account to permission to
    open the access database file. If it is local account, we need to create a
    same account with on the remote server; if it is a domain account, it
    should be enough pemission on the remote server. For more info about
    ASP.NET impersonate, you may refer to this article:

    INFO: Implementing Impersonation in an ASP.NET Application
    http://support.microsoft.com/default.aspx?scid=KB;EN-US;Q306158

    Luke
    [MSFT], Nov 2, 2004
    #2
    1. Advertising

  3. Roby2222

    Roby2222 Guest

    Thanks for the reply. The "IS-Users" account is a domain group, and it has
    permissions to the folder where the Access database resides. Could it be
    this user does not have visibility to the mapped drive on the web server?

    Thanks,
    Roby2222

    "[MSFT]" wrote:

    > Hello Roby,
    >
    > Is the account "IS-Users" a local user or a domain user? If you logon as
    > this user and access the web app, it will use this account to permission to
    > open the access database file. If it is local account, we need to create a
    > same account with on the remote server; if it is a domain account, it
    > should be enough pemission on the remote server. For more info about
    > ASP.NET impersonate, you may refer to this article:
    >
    > INFO: Implementing Impersonation in an ASP.NET Application
    > http://support.microsoft.com/default.aspx?scid=KB;EN-US;Q306158
    >
    > Luke
    >
    >
    Roby2222, Nov 2, 2004
    #3
  4. Roby2222

    Paul Clement Guest

    On Tue, 2 Nov 2004 06:26:01 -0800, "Roby2222" <> wrote:

    ¤ Thanks for the reply. The "IS-Users" account is a domain group, and it has
    ¤ permissions to the folder where the Access database resides. Could it be
    ¤ this user does not have visibility to the mapped drive on the web server?
    ¤

    That would be my guess. Can you use an UNC path instead?


    Paul ~~~
    Microsoft MVP (Visual Basic)
    Paul Clement, Nov 2, 2004
    #4
  5. Roby2222

    Roby2222 Guest

    I don't think you can use UNC with DSNs, but I'll give it a try with OleDB.

    Thanks,
    Roby2222

    "Paul Clement" wrote:

    > On Tue, 2 Nov 2004 06:26:01 -0800, "Roby2222" <> wrote:
    >
    > ¤ Thanks for the reply. The "IS-Users" account is a domain group, and it has
    > ¤ permissions to the folder where the Access database resides. Could it be
    > ¤ this user does not have visibility to the mapped drive on the web server?
    > ¤
    >
    > That would be my guess. Can you use an UNC path instead?
    >
    >
    > Paul ~~~
    > Microsoft MVP (Visual Basic)
    >
    Roby2222, Nov 2, 2004
    #5
  6. Roby2222

    Paul Clement Guest

    Paul Clement, Nov 2, 2004
    #6
  7. Roby2222

    [MSFT] Guest

    Hello,

    Since it is a user group, I think you may use Roles instead of Users. For
    example:

    <authorization>
    <deny users="*"/>
    <allow roles="IS-Users" />
    </authorization>


    Luke
    [MSFT], Nov 3, 2004
    #7
    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. Otis Mukinfus
    Replies:
    3
    Views:
    911
    Juan T. Llibre
    Jul 8, 2005
  2. Replies:
    3
    Views:
    40,219
    Roedy Green
    Nov 16, 2005
  3. BenM
    Replies:
    4
    Views:
    135
  4. Replies:
    2
    Views:
    278
  5. Mohsen Pahlevanzadeh

    Qt connect and first connect or unicode

    Mohsen Pahlevanzadeh, Sep 17, 2013, in forum: Python
    Replies:
    3
    Views:
    152
    Mohsen Pahlevanzadeh
    Sep 18, 2013
Loading...

Share This Page