can't access file on a remote file server

Discussion in 'ASP .Net' started by =?Utf-8?B?cmV5Y29u?=, Jun 3, 2005.

  1. I have a problem that has been doggin me for 2 days now.

    I have a web app that needs to access files on another server in the same
    domain. but nothing that I have tried has allowed the web app access to the
    files.

    the system is set up as follows:

    Server 2: Windows 2000 server contains report files needed by the webapp

    Server 1: Window 2003 server
    iis server with website
    asp.net dll used to access files on server 2

    web.config settings are
    <authentication
    mode="Windows" />
    <identity impersonate="true" />

    the dll code used to test file access is
    Dim strTest As String
    strTest = "User Name: " &
    System.Security.Principal.WindowsIdentity.GetCurrent.Name() & vbCrLf
    strTest = strTest & "File Name: " & strZipFileName & vbCrLf
    Dim ofile As File
    strTest = strTest & "Exists: " &
    ofile.Exists(strZipFileName).ToString() & vbCrLf


    the output from the system is
    User Name: <domain\user name>
    File Name: \\uncpath\file.zip
    Exists: False

    but the file does exist and when I audit the logons on server 2 I am not
    seeing attempts by <domain\user name>. instead NT AUTHORITY\ANONYMOUS LOGON
    is login on to Sever 2 what happened to impersonation? What am I doing wrong?
    =?Utf-8?B?cmV5Y29u?=, Jun 3, 2005
    #1
    1. Advertising

  2. =?Utf-8?B?cmV5Y29u?=

    Bruce Barker Guest

    your configuration will not allow network access due to the 1 hop rule. you
    will need to change to kerberos and enable creditial forwarding.

    -- bruce (sqlwork.com)


    "reycon" <> wrote in message
    news:...
    >I have a problem that has been doggin me for 2 days now.
    >
    > I have a web app that needs to access files on another server in the same
    > domain. but nothing that I have tried has allowed the web app access to
    > the
    > files.
    >
    > the system is set up as follows:
    >
    > Server 2: Windows 2000 server contains report files needed by the webapp
    >
    > Server 1: Window 2003 server
    > iis server with website
    > asp.net dll used to access files on server 2
    >
    > web.config settings are
    > <authentication
    > mode="Windows" />
    > <identity impersonate="true" />
    >
    > the dll code used to test file access is
    > Dim strTest As String
    > strTest = "User Name: " &
    > System.Security.Principal.WindowsIdentity.GetCurrent.Name() & vbCrLf
    > strTest = strTest & "File Name: " & strZipFileName & vbCrLf
    > Dim ofile As File
    > strTest = strTest & "Exists: " &
    > ofile.Exists(strZipFileName).ToString() & vbCrLf
    >
    >
    > the output from the system is
    > User Name: <domain\user name>
    > File Name: \\uncpath\file.zip
    > Exists: False
    >
    > but the file does exist and when I audit the logons on server 2 I am not
    > seeing attempts by <domain\user name>. instead NT AUTHORITY\ANONYMOUS
    > LOGON
    > is login on to Sever 2 what happened to impersonation? What am I doing
    > wrong?
    >
    Bruce Barker, Jun 3, 2005
    #2
    1. Advertising

  3. thanks Bruce,

    I don't have control over the domain controler and can't switch to kerberos.
    I've also tried this configuration with no success.
    > > web.config settings are
    > > <authentication
    > > mode="Windows" />
    > > <identity impersonate="true" />
    > >

    and then I granted read access to domain\server1$.
    I can see that the server is being logged on and recognized through the
    security audits. but it still can not read the files. Can you think of any
    other way to get at remote files? FTP maybe?




    "Bruce Barker" wrote:

    > your configuration will not allow network access due to the 1 hop rule. you
    > will need to change to kerberos and enable creditial forwarding.
    >
    > -- bruce (sqlwork.com)
    >
    >
    > "reycon" <> wrote in message
    > news:...
    > >I have a problem that has been doggin me for 2 days now.
    > >
    > > I have a web app that needs to access files on another server in the same
    > > domain. but nothing that I have tried has allowed the web app access to
    > > the
    > > files.
    > >
    > > the system is set up as follows:
    > >
    > > Server 2: Windows 2000 server contains report files needed by the webapp
    > >
    > > Server 1: Window 2003 server
    > > iis server with website
    > > asp.net dll used to access files on server 2
    > >
    > > web.config settings are
    > > <authentication
    > > mode="Windows" />
    > > <identity impersonate="true" />
    > >
    > > the dll code used to test file access is
    > > Dim strTest As String
    > > strTest = "User Name: " &
    > > System.Security.Principal.WindowsIdentity.GetCurrent.Name() & vbCrLf
    > > strTest = strTest & "File Name: " & strZipFileName & vbCrLf
    > > Dim ofile As File
    > > strTest = strTest & "Exists: " &
    > > ofile.Exists(strZipFileName).ToString() & vbCrLf
    > >
    > >
    > > the output from the system is
    > > User Name: <domain\user name>
    > > File Name: \\uncpath\file.zip
    > > Exists: False
    > >
    > > but the file does exist and when I audit the logons on server 2 I am not
    > > seeing attempts by <domain\user name>. instead NT AUTHORITY\ANONYMOUS
    > > LOGON
    > > is login on to Sever 2 what happened to impersonation? What am I doing
    > > wrong?
    > >

    >
    >
    >
    =?Utf-8?B?cmV5Y29u?=, Jun 3, 2005
    #3
  4. =?Utf-8?B?cmV5Y29u?=

    agrnidhi

    Joined:
    May 24, 2007
    Messages:
    1
    How to connect to the file server?

    Hi,

    I am also facing the same problem as yours. I am trying to open PDF files which resides in a secure file share, I have a user ID and Pwd to access the share which my application can use but I don't know where to put it. If I give it in the identity tag, my whole application stops working!!! ~!@!@#

    I have the file name show up in a data grid as a hyperlink and I want to open the respective PDF file from the file share on click of the name of file. Can anybody tell me how I can do it?
    agrnidhi, May 24, 2007
    #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. =?Utf-8?B?VmljdG9y?=

    Access to create file on remote server denied

    =?Utf-8?B?VmljdG9y?=, Aug 15, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    498
    =?Utf-8?B?RnJhbsOnb2lzIExlbWFpcmU=?=
    Aug 16, 2005
  2. Siddharth Jain
    Replies:
    1
    Views:
    2,879
    Thomas Fritsch
    Dec 2, 2004
  3. Sid
    Replies:
    0
    Views:
    416
  4. =?Utf-8?B?RGF2aWQgVGhpZWxlbg==?=

    Can't access remote Sql Server from my web app

    =?Utf-8?B?RGF2aWQgVGhpZWxlbg==?=, May 31, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    445
    =?Utf-8?B?RGF2aWQgVGhpZWxlbg==?=
    May 31, 2006
  5. Replies:
    2
    Views:
    278
Loading...

Share This Page