views:

146

answers:

2

Hi, I was just wondering if there is a way to prevent people from copying a file which is stored by using System.IO.IsolatedStorage? To me, I can't think of anyway. Any person can go and grab those files manually. Is there other ways that I am missing?

+2  A: 

Isolated storage is linked to the logged in user and stored under their profile only. So with out-of-the-box NTFS ACL's in place, no other user can access these files.

From MSDN:

Data is stored in compartments that are isolated by the current user and by the assembly in which the code exists. Additionally, data can be isolated by domain. Roaming profiles can be used in conjunction with isolated storage so isolated stores will travel with the user's profile.

So, not just any person can copy them, only the person under which' context they were created can.

Is that not secure enough?

Wim Hollebrandse
Thanks for your prompt response. So what you are referring is that unless a user is logged in with the same account you were logged in while creating those files, you cannot find those folders and manually copy/paste the file into another folder, right? if it's the case, which is my expected case, I would say it's very secure.
paradisonoir
That is correct. Isolated storage files are stored in the user's "Application Data" folder and therefore cannot be accessed by different users.
Wim Hollebrandse
A: 

Isolated storage is designed to keep your program data fenced in rather than keeping other applications out, Data is ring fenced from other .net programs running under reduced permission sets. Data is stored in local or roaming user compartments and cannot be accessed via ordinary file streams only via IsolatedStorageFileStream.

In short though if another program really wanted access it could, but you would have to deliberately set out to do so.

Andrew