By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,302 Members | 1,816 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,302 IT Pros & Developers. It's quick & easy.

C#-WEB: access denied using GetFiles() on AD network share

P: 1
I am attempting to access the files on a share on a server in my network so I can list the files there on an intranet web page.

At this point, the share permissions and the NTFS permissions are set so open that it scares me but my GetFiles() call still generates an "access denied" exception. I have even given "Everyone" read access to the share and read, read&execute, and list folder contents permision on NTFS.

The Directory Security settings for IIS 6 are:
- "Enable anonymous access" is NOT set
- "Integrated Windows Authentication" is set
- Everything else is not set

Web.Config has the following settings:
- <identity impersonate="True" />
- <authentication mode="Windows" />

In Active Directory,
- I have set the "Account is trusted for delegation" option for the account I am using
- I have set the "Trust computer for delegation" option on the computer I am accessing.

I have my website showing the
- ame is "mynetwork/myuserid"
- is "mynetwork/myuserid"
(this is as expected; the case is correct in the code.)

If I change the website to allow anonymous access and set the access account to my userid, it works except that is blank; this is undesirable.

I'm also puzzled that I am prompted for credentials even though I am logged on as an authenticated user when I access the web site; it would be preferable if the site was accessed using my current creditials.

I am stumpped! I have searched for additional settings I might set; everything is set as I understand it should be.

Thank You.
Sep 12 '07 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.