How to configure Windows Group Policy using c++?

我们两清 提交于 2019-12-12 03:12:37

问题


I am working on IE BHO toolbar. When I install it for IE 8, it works fine. In case of IE 9, It pops up an info bar asking if to enable it. I know what settings to change in group policy manually. I just do not know how to do it in programming.

Changes to make are in Group Policy:
Location : User Config > Administrative Template > Windows Components > IE > Security Features > Add-on Management
Modifications:

  • Set Add-on list to enabled
  • Add an entry in Add-on list

Are there any straight forward APIs to do this job?

I am primarily looking for C++ APIs but I am fine with C# / WMI based approach too.


回答1:


Exists a couple of ways to handle the Windows Group Policies

1) You can use the Group Policy API which has a set of interfaces to access from C++.

2) Using the RSoP WMI Classes

3) Locating the windows registry key where the Group Policy are stored using the Group Policy Settings Reference for Windows and Windows Server



来源:https://stackoverflow.com/questions/9985902/how-to-configure-windows-group-policy-using-c

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