stealthcopter / AndroidNetworkTools

Set of useful android network tools
Apache License 2.0
1.39k stars 282 forks source link

ip neigh command does not work after upgrading targetSDK to 30 #91

Closed 5hahryar closed 9 months ago

5hahryar commented 2 years ago

Reading the ARP table and accessing the MAC address of devices on network is working just fine. But when you upgrade the targetSDK to 30, suddenly the "ip neigh" command won't return a value anymore. I'm guessing this has something to do with the restrictions on android. Is there any way to fix this issue? Note: tested on samsung galaxy s10 running android 11.

fulvius31 commented 2 years ago

Hello, I did a library to fix that! https://github.com/fulvius31/ip-neigh-sdk30

Agmcz commented 1 year ago

Hello, I did a library to fix that! https://github.com/fulvius31/ip-neigh-sdk30

Hello I used the library and it works fine on Android 12, but when using infinite loop there is a crash!!! while (true) { Toast.makeText(MainActivity.this, ArpNDK.getARP(), Toast.LENGTH_SHORT).show(); } Please fix it.

stealthcopter commented 9 months ago

@fulvius31 great work on the workaround. It's a shame that on newer devices we will not longer have access to any ARP information without root :smiling_face_with_tear: Closing this as nothing we can really do....