From f08aaaff4e1a62b9b1dbfb0f699ee2e1e8edc1a8 Mon Sep 17 00:00:00 2001 From: Jan-Philipp Litza Date: Sun, 7 Sep 2014 12:17:36 +0200 Subject: [PATCH] Fix fuzzy MAC matching --- ffmap/inputs/batadv.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ffmap/inputs/batadv.py b/ffmap/inputs/batadv.py index 576b09a..3a5abc9 100644 --- a/ffmap/inputs/batadv.py +++ b/ffmap/inputs/batadv.py @@ -28,8 +28,8 @@ class Input: if mac_a[1] != mac_b[1] or mac_a[2] != mac_b[2]: return False - # First byte must only differ in bit 2 - if mac_a[0] | 2 != mac_b[0] | 2: + # First byte must only differ in bits 2 and 3 + if mac_a[0] | 6 != mac_b[0] | 6: return False # Count differing bytes after the third