udev/systemd persistent mac addresses interfere with P2P operation

Roy Marples roy at marples.name
Wed Sep 25 03:45:39 PDT 2019

On 24/09/2019 19:00, Benjamin Berg wrote:
> I was looking into some test failures we were seeing recently for the
> NetworkManager P2P tests. As it turns out, these tests fail because
> there is a mismatch in the BSSID that the P2P client expects from the
> P2P GO.
> The reason for this mismatch is that udev changes the MAC address of
> the p2p device that wpa_supplicant creates when it becomes group owner.
> wpa_supplicant reports the MAC as assigned by the kernel, then udev
> modifies it. At that point we have a mismatch between the MAC that the
> GO is operating on and the one that was reported to the client earlier
> and the client ends up ignoring all probe responses.
> I have opened an upstream systemd issue about this
>    https://github.com/systemd/systemd/issues/13642
> and it seems like they are saying that wpa_supplicant should make sure
> it waits for udev to be done. I guess this would require that
> wpa_supplicant uses libudev to wait for the ADD event from udev before
> trying to do anything with the newly created interface.
> Any thoughts? Should wpa_supplicant be fixed to wait for udev?


dhcpcd waits for it, but mainly for interface name changes.
Code is here for reference:


More information about the Hostap mailing list