diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2012-01-22 22:00:54 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2012-01-22 22:02:56 +0100 |
commit | 451dafe6f5e1add75793597ba9bd0e3fddf2d7f9 (patch) | |
tree | c7b98e060b716c54df8ac733232c7b7909da58d5 /src/main.c | |
parent | b5ca4272d185171971872a9a2ee677cd66c8386b (diff) | |
download | conntrack-tools-451dafe6f5e1add75793597ba9bd0e3fddf2d7f9.tar.gz conntrack-tools-451dafe6f5e1add75793597ba9bd0e3fddf2d7f9.zip |
conntrackd: support `-i exp -x' and `-e exp -x' options
This patch allows you to dump the internal and external expectation
cache in XML.
% conntrackd -i exp -x
<flow><layer3 protonum="2" protoname="ipv4"><expected><src>192.168.1.135</src><dst>130.89.148.12</dst></expected><mask><src>255.255.255.255</src><dst>255.255.255.255</dst></mask><master><src>192.168.1.135</src><dst>130.89.148.12</dst></master></layer3><layer4 protonum="6" protoname="tcp"><expected><sport>0</sport><dport>9082</dport></expected><mask><sport>0</sport><dport>65535</dport></mask><master><sport>50518</sport><dport>21</dport></master></layer4><meta><helper-name>ftp</helper-name></meta></flow>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -290,6 +290,10 @@ int main(int argc, char *argv[]) action = CT_DUMP_INT_XML; else if (action == CT_DUMP_EXTERNAL) action = CT_DUMP_EXT_XML; + else if (action == EXP_DUMP_INTERNAL) + action = EXP_DUMP_INT_XML; + else if (action == EXP_DUMP_EXTERNAL) + action = EXP_DUMP_EXT_XML; else { show_usage(argv[0]); fprintf(stderr, "Error: Invalid parameters\n"); |