Pre Marshmallow my app would obtain it\'s device MAC address via BluetoothAdapter.getDefaultAdapter().getAddress().
Now with Marshmallow Android is retu
First the following permissions have to be added to Manifest;
Then,
public static final String SECURE_SETTINGS_BLUETOOTH_ADDRESS = "bluetooth_address";
String macAddress = Settings.Secure.getString(getContentResolver(), SECURE_SETTINGS_BLUETOOTH_ADDRESS);
After that the application has to be signed with OEM / System key. Tested and verified on Android 8.1.0.