mirror of
https://github.com/team-infusion-developers/android_kernel_samsung_msm8976.git
synced 2024-11-07 04:09:21 +00:00
[NETFILTER]: nfnetlink_log: fix crash on bridged packet
physoutdev is only set on purely bridged packet, when nfnetlink_log is used in the OUTPUT/FORWARD/POSTROUTING hooks on packets forwarded from or to a bridge it crashes when trying to dereference skb->nf_bridge->physoutdev. Reported by Holger Eitzenberger <heitzenberger@astaro.com> Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
881dbfe8ac
commit
ba5dcee128
1 changed files with 1 additions and 1 deletions
|
@ -486,7 +486,7 @@ __build_packet_message(struct nfulnl_instance *inst,
|
|||
* for physical device (when called from ipv4) */
|
||||
NFA_PUT(inst->skb, NFULA_IFINDEX_OUTDEV,
|
||||
sizeof(tmp_uint), &tmp_uint);
|
||||
if (skb->nf_bridge) {
|
||||
if (skb->nf_bridge && skb->nf_bridge->physoutdev) {
|
||||
tmp_uint =
|
||||
htonl(skb->nf_bridge->physoutdev->ifindex);
|
||||
NFA_PUT(inst->skb, NFULA_IFINDEX_PHYSOUTDEV,
|
||||
|
|
Loading…
Reference in a new issue