psd option parsing
PATCH 1/1 psd option parsing
psd match is too greedy with options, and doesn't play well with other matches. For example:
# iptables -A INPUT -m psd -m recent --set -j DROP iptables v1.2.11: missing optarg Try `iptables -h' or 'iptables --help' for more information.
Below patch makes it less greedy.
This fixes bugzilla #18
Phil
extensions/libipt_psd.c +0 -5
@@ -84,11 +84,6 @@struct ipt_psd_info *psdinfo = (struct ipt_psd_info *)(*match)->data;unsigned int num; -if (!optarg) -exit_error (PARAMETER_PROBLEM ,"missing optarg" ); - -/* string_to_number needs a leading space */ -switch (c) {/* PSD-weight-threshold */ case '1' :
Patrick McHardy
AppliedQuoted 12 lines · Phil Oester
psd match is too greedy with options, and doesn't play well with other matches. For example:
# iptables -A INPUT -m psd -m recent --set -j DROP iptables v1.2.11: missing optarg Try `iptables -h' or 'iptables --help' for more information.Below patch makes it less greedy.
This fixes bugzilla #18
Applied, thanks.
Quoted 2 lines
Phil