Is there a way to access the file-system outside of the current ASP.NET application, without going around giving IIS_IUSRS
permissions? For example, if I wanted this line to work:
logStream = File.Open("C:logsapp.log", FileMode.Append, FileAccess.Write, FileShare.ReadWrite);
... I'd have to normally grant read/write permission to C:logsapp.log
to the IIS_IUSRS
group. This gets annoying for setting the app up on new systems, where the directories which need to be accessed can be in different locations. Is there any way to tell ASP.NET what directories it should have access to?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…