I tried to use cacls to give "Everyone" group access to certain folder. And I failed. As I understand the reason is i'm trying to use groupname in english while my windows is localized. Attempt to use localized groupname succeded. I can't predict language of target system. How can I grant permissions on folder regardless of Windows localization?
-
What version of Windows?– Harry JohnstonFeb 3, 2012 at 3:17
-
i want to use cacls in bat-file on wide range of systems. From Win2K to Win7. That's why i can't ise icacls.– Aleksandr KravetsFeb 3, 2012 at 8:59
-
Is it OK to replace the existing permissions on the folder?– Harry JohnstonFeb 4, 2012 at 4:40
-
@HarryJohnston: Yes, I think.– Aleksandr KravetsFeb 4, 2012 at 15:25
-
The /s option to cacls will do what you want, but I'm not sure which version of the OS introduced it. If cacls /s didn't exist in Windows 2000, then I think you're stuck - you'll probably have to ship an executable along with the batch file.– Harry JohnstonFeb 4, 2012 at 21:44
|
Show 2 more comments
1 Answer
Best i could do is use version number checking, if winVersion >= 6 then use icacls else use xcacls.vbs which i ship with my script. Though xcacls is extremly slow, it works for me for now. In future - we'll see.