stealthcopter / AndroidNetworkTools

Set of useful android network tools
Apache License 2.0
1.36k stars 283 forks source link

Android 10 and access to /proc/net/* #64

Closed Zaporozhec7 closed 4 years ago

Zaporozhec7 commented 4 years ago

On devices that run Android 10 or higher, apps cannot access /proc/net https://developer.android.com/about/versions/10/privacy/changes#proc-net-filesystem

So seems this library will not work on Android 10, in part of that use "/proc/net/arp" read.

As workaround, possibly command "ip neigh show" can be used, that should be still available in Android 10. Althought I have not checked that.

stealthcopter commented 4 years ago

@Zaporozhec7 Thanks for the info! You're right, on Android 10 the features in ARPInfo class will return empty results. I will look at adding in the data from ip neigh show into the next release

stealthcopter commented 4 years ago

Merged in PR https://github.com/stealthcopter/AndroidNetworkTools/pull/66