MAC address randomization | F40 | Network Manager

I understand that the configuration to randomize WiFi and NIC MAC addresses has changed in Fedora 40. I copied the text shown below to the file /etc/NetworkManager/conf.d/22-wifi-mac-addr.conf It doesn’t seem to work properly to randomize WiFi and NIC MAC addresses each time I connect wired and wireless. Help please.

[connection.22-wifi-mac-addr]
match-device=type:wifi
wifi.cloned-mac-address=random
ethernet.cloned-mac-address=random

[.config]
enable=nm-version-min:1.45

Welcome to :fedora:

howto

From Gnome Settings:

For Wired Networks:

2 Likes

Removed workstation

Added f40, networkmanager

As I understand it after research, when using wifi it generates a random MAC each time it attaches to a different access point (SSID). From that time on it should use the same MAC for that same SSID every time it connects.

On my settings for wifi I see the same as posted above by @hamrheadcorvette but I have one additional option for the cloned address bar. Mine has a 5th line that reads “Stable per SSID”
I believe if you select the “Stable per SSID” option it will do as noted above. A random MAC the first time it connects to a different SSID then always use that MAC when connecting to that SSID.

I believe if you select the Random option it should generate a random MAC every time it connects anywhere. Even disconnecting from a SSID then immediately reconnecting should give a different MAC for that reconnect.

1 Like

I’m in the Public Library, and after I shutdown or log out I have a different MAC. I can’t test connect/reconnect at the moment, but will do later.

I hope I’m not leaving any one out. I’m always grateful for all replies. I think I found a solution that was posted on redit. Go through Settings and under the Identity tab for WiFi and NIC, select Cloned Address, and from the drop down menu, choose Random. I didn’t think to look there. It wasn’t my solution. I looked through so many web sites including Fedora. I posted as a last resort. Funny the solution should be so simple yet I couldn’t find any mention of it in Fedora Docs. Thanks to all.

That’s all those screenshots I just posted !

I don’t think there are any Docs for it.