I am doing firewall related work. I can turn ON/OFF windows firewall programatically using COM interface but I want to disable turn ON/OFF options. Is there any COM interface, Windows API present for that?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
This behavior is triggered by the presence of Group Policy for the firewall, specifically the Windows Firewall: Protect all Network connections setting.
As per How to disable Windows Firewall using python, you need to enable this setting in any of the available ways outlined there.