Allow devices for src_ip, src_dip and dest_ip options
authorJo-Philipp Wich <jow@openwrt.org>
Sat, 25 May 2013 16:00:04 +0000 (18:00 +0200)
committerJo-Philipp Wich <jow@openwrt.org>
Sat, 25 May 2013 16:14:57 +0000 (18:14 +0200)
redirects.c
rules.c

index aec47fdf46db19ae4feeeb5ade2858655bddb346..d1aa0f049f9bfa1773ff1634ef6c1953764e7d31 100644 (file)
@@ -32,14 +32,14 @@ const struct fw3_option fw3_redirect_opts[] = {
 
        FW3_LIST("proto",              protocol,  redirect,     proto),
 
-       FW3_OPT("src_ip",              address,   redirect,     ip_src),
+       FW3_OPT("src_ip",              network,   redirect,     ip_src),
        FW3_LIST("src_mac",            mac,       redirect,     mac_src),
        FW3_OPT("src_port",            port,      redirect,     port_src),
 
-       FW3_OPT("src_dip",             address,   redirect,     ip_dest),
+       FW3_OPT("src_dip",             network,   redirect,     ip_dest),
        FW3_OPT("src_dport",           port,      redirect,     port_dest),
 
-       FW3_OPT("dest_ip",             address,   redirect,     ip_redir),
+       FW3_OPT("dest_ip",             network,   redirect,     ip_redir),
        FW3_OPT("dest_port",           port,      redirect,     port_redir),
 
        FW3_OPT("extra",               string,    redirect,     extra),
diff --git a/rules.c b/rules.c
index 145b71f4df3991a792191de4cd7ed62a0d730fde..0f4e925765931bf3a4c09f147a87e80208aa7594 100644 (file)
--- a/rules.c
+++ b/rules.c
@@ -32,11 +32,11 @@ const struct fw3_option fw3_rule_opts[] = {
 
        FW3_LIST("proto",              protocol,  rule,     proto),
 
-       FW3_LIST("src_ip",             address,   rule,     ip_src),
+       FW3_LIST("src_ip",             network,   rule,     ip_src),
        FW3_LIST("src_mac",            mac,       rule,     mac_src),
        FW3_LIST("src_port",           port,      rule,     port_src),
 
-       FW3_LIST("dest_ip",            address,   rule,     ip_dest),
+       FW3_LIST("dest_ip",            network,   rule,     ip_dest),
        FW3_LIST("dest_port",          port,      rule,     port_dest),
 
        FW3_LIST("icmp_type",          icmptype,  rule,     icmp_type),