projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6e1ce3c
)
netfilter: nf_tables_trace: fix endiness when dump chain policy
author
Liping Zhang
<liping.zhang@spreadtrum.com>
Fri, 2 Sep 2016 12:49:12 +0000
(20:49 +0800)
committer
Pablo Neira Ayuso
<pablo@netfilter.org>
Mon, 5 Sep 2016 17:28:23 +0000
(19:28 +0200)
NFTA_TRACE_POLICY attribute is big endian, but we forget to call
htonl to convert it. Fortunately, this attribute is parsed as big
endian in libnftnl.
Signed-off-by: Liping Zhang <liping.zhang@spreadtrum.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/nf_tables_trace.c
patch
|
blob
|
history
diff --git
a/net/netfilter/nf_tables_trace.c
b/net/netfilter/nf_tables_trace.c
index 39eb1cc62e91fdda9608f96eb678f061f7b91a0c..fa24a5b398b1f889817b8873be1aa197bbf179d3 100644
(file)
--- a/
net/netfilter/nf_tables_trace.c
+++ b/
net/netfilter/nf_tables_trace.c
@@
-237,7
+237,7
@@
void nft_trace_notify(struct nft_traceinfo *info)
break;
case NFT_TRACETYPE_POLICY:
if (nla_put_be32(skb, NFTA_TRACE_POLICY,
-
info->basechain->policy
))
+
htonl(info->basechain->policy)
))
goto nla_put_failure;
break;
}