So I found this which is what I'm looking for - basically press a key to toggle on/off a firewall rule. Unfortunately I get a call to nonexistent function error which I have no idea how to fix.
F3::NetConnect(1) F2::NetConnect(0) NetConnect(Enable = 0) { If Enable = 1 { run, netsh advfirewall firewall set rule name="Rust" new enable=no } Else { run, netsh advfirewall firewall set rule name="Rust" new enable=yes } }