Re: [PATCH 3/7] extensions: add IPv6 SNAT extension

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 9 Aug 2012, Jan Engelhardt wrote:


On Thursday 2012-08-09 22:11, kaber@xxxxxxxxx wrote:
+
+static const struct xt_option_entry SNAT_opts[] = {
+	{.name = "to-source", .id = O_TO_SRC, .type = XTTYPE_STRING,
+	 .flags = XTOPT_MAND | XTOPT_MULTI},

According to the IPv4 SNAT/DNAT manpage, support for multiple ranges
was removed after 2.6.10. Has this changed?
If not, XTOPT_MULTI seems misplaced.

+	case O_TO_SRC:
+		if (cb->xflags & F_X_TO_SRC) {
+			if (!kernel_version)
+				get_kernel_version();
+			if (kernel_version > LINUX_VERSION(2, 6, 10))
+				xtables_error(PARAMETER_PROBLEM,
+					   "SNAT: Multiple --to-source not supported");

It certainly is misplaced. IPv6 S/DNAT did not exist in any form in 2.6.10,
so we do not need to do the version check here.

Right, I'm going to delete all this.
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux