Receipt validation: no MAC address, en0 port missing in registry

For some reason, a small percentage of Mac users don't have "en0" Ethernet port in their IORegistry. Therefore the Apple's recommended code for getting the computer GUID for receipt validation does not work:


IOBSDNameMatching(master_port, 0, "en0");


For obvious reasons, such users experience problems with many other apps from the Mac App Store and I believe with macOS itself too.


However they do have "en1" (AirPort) and "en2", "en3" (Thunderbolt), but no "en0" (Ethernet) in the registry.


In theory, I could use "en1" (AirPort)'s MAC address instead, but I can't make the Mac App Store do the same, to match the GUID hash in the receipt.


So, what does Apple recommend for such cases for us developers? And what are the steps for the users to restore their system registry?


Thanks!

Replies

Apple recommends checking built-in en0, built-in en1, and non built-in en0 in that order.

This is the details: https://developer.apple.com/documentation/appstorereceipts/validating_receipts_on_the_device