gpt4 book ai didi

batch-file - 使用命令提示符修改 Windows 防火墙

转载 作者:行者123 更新时间:2023-12-04 13:48:55 27 4
gpt4 key购买 nike

使用命令提示符修改 Windows 防火墙

我可以允许域/公共(public)/私有(private)复选标记全部出现在同一行中吗(就像我可以手动单击一样)?

到目前为止,我有 3 个条目,每种类型有一个复选标记:

netsh advfirewall firewall add rule name="MyApp" dir=in action=allow program="C:\MyApp.exe" enable=yes profile=domain

netsh advfirewall firewall add rule name="MyApp" dir=in action=allow program="C:\MyApp.exe" enable=yes profile=public

netsh advfirewall firewall add rule name="MyApp" dir=in action=allow program="C:\MyApp.exe" enable=yes profile=private

最佳答案

以下是您可以解决的问题:

profile=Private and/or public and/or domain
(To add rule in more than one profile use “,” E.g.: profile=private, domain )

关于batch-file - 使用命令提示符修改 Windows 防火墙,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28613816/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com