I noticed something strange with my OPNsense. If I take several MAC addresses as an alias, use this alias as a source and limit the destination ports for WLAN devices accordingly, it can happen with my Android smartphone that some apps cannot load the content.In general, I have selected all Android ports and summarized the other, important ports in an alias and stored them as destination ports.Now comes the strange thing: if I take the WiFi network as the source, everything works fine. So it looks to me that the OPNsense or my Android smartphone (Samsung Galaxy S21 Ultra 5G with static and real MAC-address) has some problem with the MAC address.Maybe someone can help me on this topic.
Are you sure the phone is not using a randomized MAC? Started in Android 9(or 10) the default is using a randomized MAC when connecting to wlan.
I know Apple does this but I wasn't aware of Android implementing it. I took a quick look and I can't find anything in the settings regarding it.
Android being what it is, is Android version and likely manufacturer dependent. There are currently two android phones in my house. One of them implements it. Oneplus 8T running OxygenOS 13.1 based on Android 13. The setting is inside the wifi connection details i.e. can be set per Wifi network.
Just so I understand, you took your Android MAC address and created an alias with it. You have a rule stating that anything coming from this alias can only access port X. The android device is connected to wifi network 192.168.1.0. When you change the firewall rule from the MAC alias to the 192.168.1.0 network the rule works as expected?How are you assigning IPs? If DHCP, what does the MAC show in the leases page? What ports are you referring to as Android ports, etc?
I took several WiFi MAC-Adresses in an alias. I use the onboard DHCP from OPNsense and the Assingments are correct.
The destination ports can be seen in the screenshot: