From 9b4bc872ef4fe230c7f038bb94adad435471d758 Mon Sep 17 00:00:00 2001 From: gyurix Date: Sun, 27 Feb 2022 16:01:43 +0000 Subject: [PATCH] Setting SOURCE_IP and TARGET_IP variables if they have not values. --- firewall/firewall-add | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/firewall/firewall-add b/firewall/firewall-add index 42d706f..99ba352 100755 --- a/firewall/firewall-add +++ b/firewall/firewall-add @@ -28,6 +28,13 @@ EXTRA_OPTIONS="$2 $3 $4" fi; +if [[ $SOURCE_IP = "" ]]; then + $SOURCE_IP="0.0.0.0/0" +fi; +if [[ $TARGET_IP = "" ]]; then + $TARGET_IP="0.0.0.0/0" +fi; + ############################## echo 1 > /proc/sys/net/ipv4/ip_forward