diff options
author | 2010-02-11 12:22:48 +0100 | |
---|---|---|
committer | 2010-02-11 12:22:48 +0100 | |
commit | b87921bdf25485afd8f5a5f25e86b5acef32a9cf (patch) | |
tree | d839a1568a74c367a3eda529231002abe15aff79 /net/netfilter/nf_conntrack_expect.c | |
parent | netfilter: ctnetlink: dump expectation helper name (diff) | |
download | linux-b87921bdf25485afd8f5a5f25e86b5acef32a9cf.tar.gz linux-b87921bdf25485afd8f5a5f25e86b5acef32a9cf.tar.bz2 linux-b87921bdf25485afd8f5a5f25e86b5acef32a9cf.zip |
netfilter: nf_conntrack: show helper and class in /proc/net/nf_conntrack_expect
Make the output a bit more informative by showing the helper an expectation
belongs to and the expectation class.
Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'net/netfilter/nf_conntrack_expect.c')
-rw-r--r-- | net/netfilter/nf_conntrack_expect.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/net/netfilter/nf_conntrack_expect.c b/net/netfilter/nf_conntrack_expect.c index 2f25ff610982..33b85f834c06 100644 --- a/net/netfilter/nf_conntrack_expect.c +++ b/net/netfilter/nf_conntrack_expect.c @@ -500,6 +500,7 @@ static void exp_seq_stop(struct seq_file *seq, void *v) static int exp_seq_show(struct seq_file *s, void *v) { struct nf_conntrack_expect *expect; + struct nf_conntrack_helper *helper; struct hlist_node *n = v; char *delim = ""; @@ -525,6 +526,14 @@ static int exp_seq_show(struct seq_file *s, void *v) if (expect->flags & NF_CT_EXPECT_INACTIVE) seq_printf(s, "%sINACTIVE", delim); + helper = rcu_dereference(nfct_help(expect->master)->helper); + if (helper) { + seq_printf(s, "%s%s", expect->flags ? " " : "", helper->name); + if (helper->expect_policy[expect->class].name) + seq_printf(s, "/%s", + helper->expect_policy[expect->class].name); + } + return seq_putc(s, '\n'); } |