We have an .NET application that needs to read/write data to/from a network share that's pointed to with a symbolic link. I believe this would be called a L2R link. It does not work. We get access denied no matter what we set our permissions to be. Let me explain the details....
Within our web folder, we point to that network share using a symlink:
For example: D:\iisapp\helloapp\ > mklink /D dataarea \\REMOTESERVER\dataarea
We have a very simple hello world page to test reading a file from the symlink. Basically, the .NET code does a file.open on one of the files in this area. No matter how we set the permissions on the share or the symlink, it throwsa System.UnauthorizedAccessException (Access denied):
<script runat="server">
sub page_load
Dim mystream As Streamreader
mystream=file.open("D:\iisapp\helloapp\dataarea\testfile.txt")
mystream.close()
end sub
</script>
We've gone so far as to set permissions on the remote share to "Everyone:Everyone" full control for both share and regular Windows permissions (NTFS) to inherit the whole "dataarea" folder. It still doesn't work and that's as loose as it can get it just to see if it works.
Just as a sanity check, if we move the data area from the remote server over to the local server, then create a L2L link there "with the exact same permissions on the folder", the code works fine. I.E mklink /D mylink E:\mylink
Everything is enabled in fsutil: L2L, R2R, R2L, L2R
The .NET code is running anonymously as the IUSR account in IIS. IUSR is a local account to our web server, but the fact that are share is set to Everyone:Everyone with full control should allow anyone to read/write data in that share. This is a Windows 2008 R2 web server running IIS 7.5.