• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
0

How to get Mac Address on Android?

Explorer ,
Jun 18, 2019 Jun 18, 2019

Copy link to clipboard

Copied

Hi!

In Android 6 >, is it possible?

I'm getting this result: 02:00:00:00:00:00

Thanks a lot.

TOPICS
Development

Views

1.7K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 18, 2019 Jun 18, 2019

Copy link to clipboard

Copied

I believe that the only way, will be thru an ANE.

Should be a simple ANE with a single method, however you still need to build one.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Jun 18, 2019 Jun 18, 2019

Copy link to clipboard

Copied

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jun 27, 2019 Jun 27, 2019

Copy link to clipboard

Copied

Hi!

Thanks, but even with the ANE, the mac return 02:00:00:00:00:00.

'-'

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jun 28, 2019 Jun 28, 2019

Copy link to clipboard

Copied

Android stopped allowing access to the mac address in Android 6

To provide users with greater data protection, starting in this release, Android removes programmatic access to the device’s local hardware identifier for apps using the Wi-Fi and Bluetooth APIs. The WifiInfo.getMacAddress() and the BluetoothAdapter.getAddress() methods now return a constant value of 02:00:00:00:00:00.

https://developer.android.com/about/versions/marshmallow/android-6.0-changes#behavior-hardware-id

You should use one of the OS provided identifiers instead of the mac address.

air native extensions // https://airnativeextensions.com

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Jun 28, 2019 Jun 28, 2019

Copy link to clipboard

Copied

LATEST

if it is only for identification purpose like generating a unique serie of numbers
you can also generate UUID

see
as3-universal-analytics/generateUUID.as at master · zwetan/as3-universal-analytics · GitHub

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines