Page 1 of 1
Accessrights on destination folders on Windows Vista
Posted: Tue Feb 19, 2008 1:15 pm
by semike
Hello,
I use the Codegear Express Edition of InstallAware 6 and try to set the permissions of a subdirectory $ALLAPPDATA$\\productname\\data to "grant everyone full control". But regardless of my settings (full control or read+write), the destination PC (Windows Vista with enabled UAC) will not set any permissions.
How can I use these permissions with my Express Edition correctly?
Thank you in advance
Michael
Posted: Fri Mar 20, 2009 7:23 pm
by glenharvy
Same problem here - did you ever figure it out?
Posted: Fri Mar 20, 2009 9:43 pm
by MichaelNesmith
Try it with new folders you create empty and it will work.
Posted: Tue Sep 22, 2009 3:04 pm
by Frankk
I am using a trial version of InstallAware9 and am having the same problem (in Vista w/UAC) getting the built-in group "Users" to have RW rights to a folder below $ALLAPPDATA$\\productname\\data. I create new empty folders and I have tried every combination of granting full rights.
After the install when I check settings for "Users" in that folder they are RO.
This is a showstopper for us - can you elaborate on the correct set of steps?
I have tried changing the location in MSICode of the create and Grant Access rights statements but it has no effect.
Posted: Tue Sep 29, 2009 4:58 am
by rspag
I used this after checking the SUCCESS variable:
Code: Select all
Run Program cmd.exe /C icacls $TARGETDIR$ /grant:r *S-1-1-0:(OI)(CI)F /t (WAIT)
cmd /C tells to cmd to execute the command in the string that follows and then to close the cmd window itself
icacls is a cmd command to modify premission to files and folders...
S-1-1-0 is the SID for Everyone (you can use even a User Name but you have to remove *)
(OI)(CI) is to set the access property to subfolders and files (inherit)
F is full access
for some doc just type icacls on a cmd window and you will find all the command line parameters you can use or follow this technet link
http://technet.microsoft.com/en-us/libr ... 10%29.aspx
However I think this only works if you're running the setup as an admin...
PS: If your TARGETDIR contains spaces you have to use "$TARGETDIR$" or convert TARGETDIR in 8.3 format... I used:
Code: Select all
Set Variable TARGETSHORT to $TARGETDIR$
Convert to Short Path: TARGETSHORT
Run Program cmd.exe /C icacls $TARGETSHORT$ /grant:r *S-1-1-0:(OI)(CI)F /t (WAIT)
to avoid any problems with spaces and quotes
EDIT: I used this method cause the set access control of IA 9 wasn't working on Program Files or Program Files (x86) subfolders for me...
EDIT 2: I found icacls is only available on vista, seven and server 2003/2008, on Xp and earlier you have to use cacls instead, with some differences on command line parameters to use...