All Users Application Data Permissions

D

Dennis C. Drumm

I use the Documents and Settings\All Users\Application Data\AppName folder
to store xml settings that are applicable to all user who log onto a
machine. (The uers personal settings associated with my application are
stored in the system registry's HKEY_CURRENT_USER section)

When the xml file and news folder are created by my application running
under Windows XP, the new folder and the xml file have permissions set for
Everyone to read and write to the file and folder by default.

When the xml file and new folder are created by my application running under
Windows 2000, the new folder and xml file cannot be written to by Everyone,
only read.

Is there a way to change the permissions programmatically for file and
folders created by the application when running under Windows 2000 to behave
like Windows XP?

Thanks,

Dennis
 
D

Dennis C. Drumm

Correction:

The XP machine I was looking at apparently has a corrupted All Users
profile. Other XP machines I test on have the same schema as the W2K
machines, i.e. the user must have at least a member of the Power User group
to write to a file and folder in the All Users Application Data folder.

Is it the default behavior of the All Users Application Data folder to
restrict write access for all members of the User group and Everyone group?
I would have thought that the All Users profile was for all users.

Dennis
 
K

Kevin Yu [MSFT]

Hi Dennis,

In Windows 2000 and XP, it is by default that only Administrator and Power
user can write to the Documents and Settings\All Users\Application
Data\AppName folder. To change the permission, I suggest you check the
following KB article.

http://support.microsoft.com/default.aspx?scid=kb;en-us;818362

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."
 
D

Dennis C. Drumm

Kevin

Thanks for the reference.

That would work great for me, but neither of the two com dll's are strong
named.

Since my application is strong named (and all the dll's it refences), when I
include these refernces in my application, add the method in the example and
try to compile, I get an Assembly generation failed message, the refernced
assembly 'Interop.ActiveDs' and 'Interop.ADSSECURITYLib' does not have a
strong name.

Is there some way to work around or correct this problem?

Thanks,

Dennis
 
D

Dennis C. Drumm

Keven:

I just found MS Article 313666 which describes how to correct this issue.

Thanks so much for the help,

Dennis
 
D

Dennis C. Drumm

Keven:

Another thought, what if the user is using FAT file system instead of NTFS
for a WIN2X or WINXP machine?

Thanks,

Dennis
 
K

Kevin Yu [MSFT]

D

Dennis C. Drumm

Thanks Kevin,

I got that question answered on another post yesterday. It turns out there
are several ways to get the type of file system. Willy Denoyette suggested a
method that is pretty straight forward and easy to implement, even though I
would have never hit on that method on my own.

Thanks,

Dennis
 
K

Kevin Yu [MSFT]

You're welcome, Dennis.

Thanks for sharing your experience with all the people here. If you have
any questions, please feel free to post them in the community.

Kevin Yu
=======
"This posting is provided "AS IS" with no warranties, and confers no
rights."
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top