[PATCH conntrack 2/2] conntrack: fix expectation entry creation

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

 



Store tuple-src and tuple-dst in exptuple,
as used by the EXP_CREATE case.

Verified with doc/cli/test.sh

Also reorder the cases, so the netmask case is last.

Reported-by: Szilárd Pfeiffer <pfeiffer.szilard@xxxxxxxxxx>
Signed-off-by: Asbjørn Sloth Tønnesen <ast@xxxxxxxxxx>
---
 src/conntrack.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/conntrack.c b/src/conntrack.c
index 324daf4..45b8822 100644
--- a/src/conntrack.c
+++ b/src/conntrack.c
@@ -2072,10 +2072,12 @@ int main(int argc, char *argv[])
 		case 'q':
 			nfct_set_addr_from_opt(c, tmpl.ct, &ad, &family);
 			break;
-		case '{':
-		case '}':
 		case '[':
 		case ']':
+			nfct_set_addr_from_opt(c, tmpl.exptuple, &ad, &family);
+			break;
+		case '{':
+		case '}':
 			nfct_set_addr_from_opt(c, tmpl.mask, &ad, &family);
 			break;
 		case 'p':
-- 
2.6.4

--
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