mirror of
https://github.com/bettercap/bettercap
synced 2025-08-14 10:46:57 -07:00
balls
This commit is contained in:
parent
b5371bfccc
commit
bdb4d63c80
1 changed files with 2 additions and 2 deletions
|
@ -77,9 +77,9 @@ func (f *WindowsFirewall) AllowPort(port int, address string, proto string, allo
|
|||
cmd := []string{}
|
||||
|
||||
if allow {
|
||||
cmd = []string{"advfirewall", "add", "rule", nameField, protoField, "dir=in", ipField, portField, "action=allow"}
|
||||
cmd = []string{"advfirewall", "firewall", "add", "rule", nameField, protoField, "dir=in", ipField, portField, "action=allow"}
|
||||
} else {
|
||||
cmd = []string{"advfirewall", "del", "rule", nameField}
|
||||
cmd = []string{"advfirewall", "firewall", "del", "rule", nameField}
|
||||
}
|
||||
|
||||
out, err := core.Exec("netsh", cmd)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue