How to change directory security attributes using InstallShield?

对着背影说爱祢 提交于 2019-12-06 04:45:20

you can also just easily call Windows commands "CACLS.EXE" or "ICACLS.EXE" -both are easy command line tool, e.g.

icacls file /grant Administrator:(D,WDAC) - Will grant the user Administrator Delete and Write DAC permissions to file

Under InstallShield 2008 it's

Installation Designer > Components > [somecomponent] > Destination Permissions

Note that the directory properties are attached to the component, while individual File permissions are set under the 'Files' node

This assumes you are letting InstallShield / Windows Installer handle directory creation. If you're creating the directory in a script then things start getting tricky if you need to ensure a clean uninstall.

I think I found the answer for this - on this page: http://www.installsite.org/pages/en/isp_os.htm there's an ntperm.zip archive which contains a script that seems to do what I need.

I don't know whether a Installshield builtin function exists for that. The simple solution is to create a DLL that does the real work of manipulating the security attributes and call it once the directory is created.

Typically, one might want to change the access so that everyone is able to read/write to the whole directory or file(s) within it.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!