From 58e2c069653c4adc40160b672faaf2939ec93b9f Mon Sep 17 00:00:00 2001 From: tamanoha Date: Tue, 9 Apr 2024 21:08:16 -0700 Subject: [PATCH] fix: Added -n option in iptables list cmd to prevent reverse dns lookup cherry pick from commit id b8f6db627ae7c80b933226bd8cf3bc3dd199eb86 --- iptables/iptables.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/iptables/iptables.go b/iptables/iptables.go index bc8feb9aca..88b6e6603d 100644 --- a/iptables/iptables.go +++ b/iptables/iptables.go @@ -109,7 +109,7 @@ func RunCmd(version, params string) error { // check if iptable chain alreay exists func ChainExists(version, tableName, chainName string) bool { - params := fmt.Sprintf("-t %s -L %s", tableName, chainName) + params := fmt.Sprintf("-t %s -nL %s", tableName, chainName) if err := RunCmd(version, params); err != nil { return false }