views:

183

answers:

1

I'm considering using IsolatedStorage for my temporary files. However, the documenation seems to imply that the storage space is determiend by the windows user account, which for an ASP.NET application is NETWORK SERVICES. If there are multiple websites/applications using NETWORK SERVICES as their account, won't that mean they all will share the same IsolatedStorage and be able to read each others files?

+1  A: 

I think you have more flexibility if you construct your IsolatedStorageFileStream using an IsolatedStorageFile instance, because they can be created on for example an app-specific basis:

using (IsolatedStorageFile isf = IsolatedStorageFile.GetMachineStoreForApplication())
using (IsolatedStorageFileStream isfs = new IsolatedStorageFileStream("filename", FileMode.Create, isf))
{
    // Code using the file stream here...
}
jerryjvl