evilsocket / arminject

An application to dynamically inject a shared object into a running process on ARM architectures.
Other
444 stars 159 forks source link

Problem running make test #2

Open Garbolino opened 8 years ago

Garbolino commented 8 years ago

Hello, I've been trying to run it but the script stops at this point: python test.py @ Pushing files to /data/local/tmp ... @ Starting com.instagram.android/.activity.MainTabActivity ... @ Injection into PID 3472 starting ... --------- beginning of main --------- beginning of system

Do you have any idea why? I have installed busybox to accept grep command. Thank you in advance!

evilsocket commented 8 years ago

what does "adb logcat | grep LIBHOOK" says while the app is running?

Garbolino commented 8 years ago

Ah sorry! when I run make test. it says: W/ADB_SERVICES( 134): create_local_service_socket() name=shell:export ANDROID_LOG_TAGS="''"; exec logcat '-s' 'LIBHOOK'

evilsocket commented 8 years ago

is your device rooted?

Garbolino commented 8 years ago

Yes, it's rooted. Instagram version, 7.9.2, Android 4.0.4

evilsocket commented 8 years ago

what if you try with chrome ( as by default ) instead of instagram?

Garbolino commented 8 years ago

I got the same problem... W/ADB_SERVICES( 134): create_local_service_socket() name=shell:export ANDROID_LOG_TAGS="''"; exec logcat '-s' 'LIBHOOK'

Running Chrome 42.0.2311.109 in Android 4.0.4

evilsocket commented 8 years ago

very weird, I'll dig into this and let you know.

Garbolino commented 8 years ago

Thank you very much.

Jarlene commented 8 years ago

hi, i just want hook a method in libdvm.so, the method name is "dvmResolveClass", first issue is " si = (struct soinfo )dlopen( soname, 4 / RTLD_NOLOAD */ );" there is no flag RTLD_NOLOAD. than I change it to RTLD_GLOBAL. in the way, I can find the symbole, and get "sym_offset=14", but last I get a message "Unable to find symbol in the reloc tables". what wrong?

maqsoodahmadjan commented 8 years ago

Garbolino, Did you manage to solve the problem?

roperi commented 7 years ago

Hello, folks! @evilsocket @Garbolino

I encountered the same problem. I'm stuck here:

@ Starting com.instagram.android/.activity.MainTabActivity ...
@ Injection into PID 14582 starting ...
--------- beginning of /dev/log/main
--------- beginning of /dev/log/system

I can see in my phone while running the above my current logged in Instagram account is logged out and closed down, but then a new Instagram session starts but it stops at the sign/up login screen.

By the way, I do NOT get any results when doing... adb logcat | grep LIBHOOK

I connected my mobile in debbuging mode to my laptop....

...installed NDK...

wget "http://dl.google.com/android/ndk/android-ndk-r10c-linux-x86.bin"
chmod +x android-ndk-r10c-linux-x86.bin
./android-ndk-r10c-linux-x86.bin

...and installed ADB:

apt-get -t wheezy-backports install android-tools-adb

Questions

  1. How do I know if my mobile is rooted?
  2. How do I run this program with Chrome? Does it has to run Chrome from my laptop or from my mobile? I ask this because my linux Debian Wheezy 32 bit system has an unsolved (and rare) bug that fails to run Chrome and/or Chromium. If Chome is needed to be run from a laptop, is there a way to use Firefox instead?
  3. Did I miss to do something during the NDK and ADB installation process?

Any ideas/pointers would be greatly appreciated. Thanks!

roperi commented 7 years ago

Ops! Forgot to mention I have Instagram 10.2.1, Android 4.4.2 (and I think API level 19).

roperi commented 7 years ago

I read in another thread to install BusyBox on my phone. Now I can see the following results when doing adb logcat | grep LIBHOOK:

W/ADB_SERVICES( 1496): create_local_service_socket() name=shell:export ANDROID_LOG_TAGS="" ; exec logcat -s LIBHOOK
W/ADB_SERVICES( 1496): service_to_fd() name=shell:export ANDROID_LOG_TAGS="" ; exec logcat -s LIBHOOK
W/ADB_SERVICES( 1496): LS(84): bound to 'shell:export ANDROID_LOG_TAGS="" ; exec logcat -s LIBHOOK' via 15

@maqsoodahmadjan Have you got the same problem?