android_kernel_motorola_sm6375/net/bridge
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Ido Schimmel de9d1010b9 bridge: Avoid infinite loop when suppressing NS messages with invalid options
[ Upstream commit 53fc685243bd6fb90d90305cea54598b78d3cbfc ]

When neighbor suppression is enabled the bridge device might reply to
Neighbor Solicitation (NS) messages on behalf of remote hosts.

In case the NS message includes the "Source link-layer address" option
[1], the bridge device will use the specified address as the link-layer
destination address in its reply.

To avoid an infinite loop, break out of the options parsing loop when
encountering an option with length zero and disregard the NS message.

This is consistent with the IPv6 ndisc code and RFC 4886 which states
that "Nodes MUST silently discard an ND packet that contains an option
with length zero" [2].

[1] https://tools.ietf.org/html/rfc4861#section-4.3
[2] https://tools.ietf.org/html/rfc4861#section-4.6

Fixes: ed842faeb2 ("bridge: suppress nd pkts on BR_NEIGH_SUPPRESS ports")
Signed-off-by: Ido Schimmel <[email protected]>
Reported-by: Alla Segal <[email protected]>
Tested-by: Alla Segal <[email protected]>
Acked-by: Nikolay Aleksandrov <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
2020-06-17 16:40:20 +02:00
..
netfilter netfilter: nft_reject_bridge: enable reject with bridge vlan 2020-06-03 08:21:34 +02:00
br.c net: bridge: move default pvid init/deinit to NETDEV_REGISTER/UNREGISTER 2019-08-05 13:32:53 -07:00
br_arp_nd_proxy.c bridge: Avoid infinite loop when suppressing NS messages with invalid options 2020-06-17 16:40:20 +02:00
br_device.c net: bridge: deny dev_set_mac_address() when unregistering 2019-12-18 16:08:19 +01:00
br_fdb.c
br_forward.c
br_if.c
br_input.c
br_ioctl.c
br_mdb.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2019-09-15 14:17:27 +02:00
br_multicast.c net: bridge: mdb: allow add/delete for host-joined groups 2019-08-17 12:36:57 -07:00
br_netfilter_hooks.c netfilter: bridge: make sure to pull arp header in br_nf_forward_arp() 2020-01-04 19:18:38 +01:00
br_netfilter_ipv6.c
br_netlink.c
br_netlink_tunnel.c
br_nf_core.c net: add bool confirm_neigh parameter for dst_ops.update_pmtu 2020-01-04 19:18:58 +01:00
br_private.h net: bridge: mdb: allow add/delete for host-joined groups 2019-08-17 12:36:57 -07:00
br_private_stp.h
br_private_tunnel.h
br_stp.c
br_stp_bpdu.c
br_stp_if.c
br_stp_timer.c
br_switchdev.c
br_sysfs_br.c
br_sysfs_if.c
br_vlan.c net: bridge: Populate the pvid flag in br_vlan_get_info 2019-08-31 13:21:19 -07:00
br_vlan_tunnel.c
Kconfig
Makefile