Skip to content

Some fixes for DAT/TT/Speedy join corner cases

Simon Wunderlich batman 1 version Applied

Status from this message: Applied in revision 2decb5f.

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 5 repliesApplied

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/3batman-adv: fix speedy join for DAT cache repliesnet/batman-adv/routing.c+15 -41 reply
2/3batman-adv: avoid keeping false temporary entrynet/batman-adv/translation-table.c+8 -22 replies
3/3batman-adv: detect local excess vlans in TT requestnet/batman-adv/translation-table.c+13 -12 replies

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchAntonio Quartulli
1/3A-b
2/3A-b
3/3A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [B.A.T.M.A.N.] [PATCH-maintv3 0/3] Some fixes for DAT/TT/Speedy join corner cases

This is the third iteration of the patches, with the following changes (thanks Antonio for review):
* add Antonios ack to first patch
* extend commit message for second patch

Original (slightly updated) description here:

Upon debugging a network with dangling, bogus TT entries, I found a couple of bugs for which I would like to propose fixes. The network showed the following symptoms:

* DAT was enabled
* VLANs were used, but not every originator used the same VLANs
* I've found global entries assigned to originators which actually never had the client in question connected to them. These false target originators didn't even had the VLANs in use or bridged for which the entry was done. This caused packets sent to be sent to these wrong originators.
* The wrong entries also didn't get purged automatically, since they didn't announce the VLAN in question through their TT TLVLs, and the TT code didn't check for excess VLANs.
* Furthermore, the temp flag was removed too early from the TT entries so that the purge function was not removing the entry after a timeout as well.
* I've found that with DAT, the cached ARP replies may cause these TT entries to be created on behalf of the answering host. This is wrong, since the answering host (usually) doesn't actually has the client connected.

We have not yet tested these patches in the network, and the bug also appears only once in a couple of days. Therefore I'd like to ask to review these patches thoroughly, and if you agree to the fixes we will apply them in this production network.

Thanks,
Simon

Simon Wunderlich (3):
batman-adv: fix speedy join for DAT cache replies
batman-adv: avoid keeping false temporary entry
batman-adv: detect local excess vlans in TT request

 net/batman-adv/routing.c           | 19 +++++++++++++++----
 net/batman-adv/translation-table.c | 24 +++++++++++++++++++++---
 2 files changed, 36 insertions(+), 7 deletions(-)
Signature · 1 line
2.5.0