Code Monkey home page Code Monkey logo

detectfrida's People

Contributors

darvincisec avatar thonsi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

detectfrida's Issues

Support flag android:extractNativeLibs="false"

Hi,

Starting AGP 3.6.0 the native libraries are packaged uncompressed by default. This is causing crashes on release builds using AAB.

A workaround is to enable native libs extraction by adding ingradle.properties :

android.bundle.enableUncompressedNativeLibs=false 

Do you have any suggestions how to include support this scenario?

Build command failed

Build command failed.
Error while executing process C:\Users\sridhar\AppData\Local\Android\Sdk\cmake\3.10.2.4988404\bin\ninja.exe with arguments {-C C:\Users\sridhar\Downloads\DetectFrida-master\DetectFrida-master\app.cxx\cmake\debug\arm64-v8a native-lib}
ninja: Entering directory `C:\Users\sridhar\Downloads\DetectFrida-master\DetectFrida-master\app.cxx\cmake\debug\arm64-v8a'
[1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
[2/2] Linking C shared library C:\Users\sridhar\Downloads\DetectFrida-master\DetectFrida-master\app\build\intermediates\cmake\debug\obj\arm64-v8a\libnative-lib.so
FAILED: C:/Users/sridhar/Downloads/DetectFrida-master/DetectFrida-master/app/build/intermediates/cmake/debug/obj/arm64-v8a/libnative-lib.so
cmd.exe /C "cd . && C:\Users\sridhar\AppData\Local\Android\Sdk\ndk\25.2.9519653\toolchains\llvm\prebuilt\windows-x86_64\bin\clang.exe --target=aarch64-none-linux-android21 --sysroot=C:/Users/sridhar/AppData/Local/Android/Sdk/ndk/25.2.9519653/toolchains/llvm/prebuilt/windows-x86_64/sysroot -fPIC -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fno-limit-debug-info -static-libstdc++ -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Wl,--no-undefined -Qunused-arguments -shared -Wl,-soname,libnative-lib.so -o C:\Users\sridhar\Downloads\DetectFrida-master\DetectFrida-master\app\build\intermediates\cmake\debug\obj\arm64-v8a\libnative-lib.so CMakeFiles/native-lib.dir/native-lib.c.o -llog -latomic -lm && cmd.exe /C "cd /D C:\Users\sridhar\Downloads\DetectFrida-master\DetectFrida-master\app.cxx\cmake\debug\arm64-v8a && C:\Users\sridhar\AppData\Local\Android\Sdk\ndk\25.2.9519653\toolchains\llvm\prebuilt\windows-x86_64\bin\aarch64-linux-android-strip -R .comment -g -S -d --strip-unneeded C:/Users/sridhar/Downloads/DetectFrida-master/DetectFrida-master/app/src/main/c/../../../build/intermediates/cmake/Debug/obj/arm64-v8a/libnative-lib.so""
'C:\Users\sridhar\AppData\Local\Android\Sdk\ndk\25.2.9519653\toolchains\llvm\prebuilt\windows-x86_64\bin\aarch64-linux-android-strip' is not recognized as an internal or external command,
operable program or batch file.
ninja: build stopped: subcommand failed.

CreateprocessFailed: System cannot find the file specified

Just downloaded the repo and trying to run the code, getting error:

> Task :app:externalNativeBuildDebug FAILED
Build native-lib_arm64-v8a
ninja: Entering directory `C:\Users\ashwani.pandey\Downloads\DetectFrida-master\app\.cxx\cmake\debug\arm64-v8a'
[1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
FAILED: CMakeFiles/native-lib.dir/native-lib.c.o 
C:\Users\ashwani.pandey\Downloads\DetectFrida-master\app\src\main\c\..\..\..\..\..\build\bin\clang --target=aarch64-none-linux-android21 --gcc-toolchain=E:/android_sdk/ndk/21.0.6113669/toolchains/llvm/prebuilt/windows-x86_64 --sysroot=E:/android_sdk/ndk/21.0.6113669/toolchains/llvm/prebuilt/windows-x86_64/sysroot -D_64_BIT -Dnative_lib_EXPORTS -IC:/Users/ashwani.pandey/Downloads/DetectFrida-master/app/src/main/c/arch/arm64-v8a -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security  -mllvm -sub -mllvm -bcf -mllvm -fla -O0 -fno-limit-debug-info  -fPIC -MD -MT CMakeFiles/native-lib.dir/native-lib.c.o -MF CMakeFiles\native-lib.dir\native-lib.c.o.d -o CMakeFiles/native-lib.dir/native-lib.c.o   -c C:/Users/ashwani.pandey/Downloads/DetectFrida-master/app/src/main/c/native-lib.c
CreateProcess failed: The system cannot find the file specified.
ninja: build stopped: subcommand failed.

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:externalNativeBuildDebug'.
> Build command failed.
  Error while executing process E:\android_sdk\cmake\3.10.2.4988404\bin\ninja.exe with arguments {-C C:\Users\ashwani.pandey\Downloads\DetectFrida-master\app\.cxx\cmake\debug\arm64-v8a native-lib}
  ninja: Entering directory `C:\Users\ashwani.pandey\Downloads\DetectFrida-master\app\.cxx\cmake\debug\arm64-v8a'
  [1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
  FAILED: CMakeFiles/native-lib.dir/native-lib.c.o 
  C:\Users\ashwani.pandey\Downloads\DetectFrida-master\app\src\main\c\..\..\..\..\..\build\bin\clang --target=aarch64-none-linux-android21 --gcc-toolchain=E:/android_sdk/ndk/21.0.6113669/toolchains/llvm/prebuilt/windows-x86_64 --sysroot=E:/android_sdk/ndk/21.0.6113669/toolchains/llvm/prebuilt/windows-x86_64/sysroot -D_64_BIT -Dnative_lib_EXPORTS -IC:/Users/ashwani.pandey/Downloads/DetectFrida-master/app/src/main/c/arch/arm64-v8a -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security  -mllvm -sub -mllvm -bcf -mllvm -fla -O0 -fno-limit-debug-info  -fPIC -MD -MT CMakeFiles/native-lib.dir/native-lib.c.o -MF CMakeFiles\native-lib.dir\native-lib.c.o.d -o CMakeFiles/native-lib.dir/native-lib.c.o   -c C:/Users/ashwani.pandey/Downloads/DetectFrida-master/app/src/main/c/native-lib.c
  CreateProcess failed: The system cannot find the file specified.
  ninja: build stopped: subcommand failed.

How to implement the detection on my current project?

Hi,

First of all I would like to thank you for your post about Frida detection.
I would like to implement this on my current project to detect Frida and add some logic if it detects Frida.
Is there any example or README on how I can implement it?

Thanks.

Crash when inject to My Project

hi, I'm a little confused what happens, when I create a new project either using java/kotlin, the script you created successfully compiles and the application can run well..
but when i add it to the project i'm working on, the app can't run at all..

maybe you can help me because I don't know how to debug it.. here's the error log I got..

2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: Libc[38][3e][3f][39][4e][65]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[0][0]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[45][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[190][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[162][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[149][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[209][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[111][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[170][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[89][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[139][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[74][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[259][50]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[97][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[180][2]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[25][6]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: (2) SectionHeader[25][6]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: SectionHeader[79][6]
2021-07-15 11:43:08.292 24903-24903/com.prod.neoapp V/DetectFrida: (2) SectionHeader[79][6]
2021-07-15 11:43:08.296 24903-24903/com.prod.neoapp W/DetectFrida: ExecSection:[0][266240][674528][65191045]
2021-07-15 11:43:08.296 24903-24903/com.prod.neoapp W/DetectFrida: ExecSection:[1][940768][8016][673036]
2021-07-15 11:43:08.298 24903-24903/com.prod.neoapp W/ank.prod.neopa: 0xebadde09 skipped times: 0
--------- beginning of crash
2021-07-15 11:43:08.298 24903-24903/com.prod.neoapp A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x3e8000003e8 in tid 24903 (ank.prod.neoapp), pid 24903 (ank.prod.neoapp)
2021-07-15 11:43:08.340 24988-24988/? E/crash_dump64: unknown process state: t
2021-07-15 11:43:08.358 24988-24988/? I/crash_dump64: obtaining output fd from tombstoned, type: kDebuggerdTombstone
2021-07-15 11:43:08.360 5555-5555/? I//system/bin/tombstoned: received crash request for pid 24903
2021-07-15 11:43:08.362 24988-24988/? I/crash_dump64: performing dump of process 24903 (target tid = 24903)
2021-07-15 11:43:08.378 24988-24988/? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
2021-07-15 11:43:08.378 24988-24988/? A/DEBUG: Build fingerprint: 'samsung/m20ltedx/m20lte:10/QP1A.190711.020/M205GDXU7CUD2:user/release-keys'
2021-07-15 11:43:08.378 24988-24988/? A/DEBUG: Revision: '5'
2021-07-15 11:43:08.378 24988-24988/? A/DEBUG: ABI: 'arm64'
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: Timestamp: 2021-07-15 11:43:08+0700
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: pid: 24903, tid: 24903, name: ank.prod.neoapp >>> com.prod.neoapp <<<
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: uid: 10458
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x3e8000003e8
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: x0 000003e8000003e8 x1 0000000000000002 x2 0000000000000010 x3 000000000000001c
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: x4 0000000000000007 x5 0000007fd51a3250 x6 0000007b237c8028 x7 0000007b237c8028
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: x8 0000000000000000 x9 000003e8000003e8 x10 00000000ffffffff x11 0000007b23c445ec
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: x12 0000000000000008 x13 000000002a71c708 x14 0000000000000e24 x15 0000007ab934a070
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: x16 0000007ba46428f0 x17 0000007ba4634a30 x18 0000007ba9996000 x19 0000007fd51a3250
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: x20 0000000000000002 x21 0000000000000002 x22 0000000000000000 x23 aa7b1ebec12364c5
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: x24 0000000000000000 x25 0000000000000001 x26 0000000000000000 x27 0000000000000002
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: x28 0000000000000070 x29 0000007fd51a3170
2021-07-15 11:43:08.379 24988-24988/? A/DEBUG: sp 0000007fd51a3160 lr 0000007b2336925c pc 0000007b2336927c
2021-07-15 11:43:08.413 24903-24984/com.prod.neoapp V/DetectFrida: Map [7ba4552000-7ba4593000 r--p 00000000 fe:00 291 /apex/com.android.runtime/lib64/bionic/libc.so]
2021-07-15 11:43:08.414 24903-24984/com.prod.neoapp V/DetectFrida: Map [7ba4593000-7ba463a000 --xp 00041000 fe:00 291 /apex/com.android.runtime/lib64/bionic/libc.so]
2021-07-15 11:43:08.414 24903-24984/com.prod.neoapp V/DetectFrida: LIBC Executable Section not readable!
2021-07-15 11:43:08.414 24903-24984/com.prod.neoapp V/DetectFrida: Map [7ba463a000-7ba463d000 rw-p 000e8000 fe:00 291 /apex/com.android.runtime/lib64/bionic/libc.so]
2021-07-15 11:43:08.414 24903-24984/com.prod.neoapp V/DetectFrida: Map [7ba463d000-7ba4644000 r--p 000eb000 fe:00 291 /apex/com.android.runtime/lib64/bionic/libc.so]
2021-07-15 11:43:08.533 5877-7332/? E/TaskPersister: File error accessing recents directory (directory doesn't exist?).
2021-07-15 11:43:08.608 24644-24681/? E/nightwatch-target: lmkd signal waiters
2021-07-15 11:43:08.616 5877-5877/? D/CustomFrequencyManagerService: releaseDVFSLockLocked : Getting Lock type frm List : DVFS_MIN_LIMIT frequency : 1560000 uid : 1000 pid : 5877 tag : AMS_RESUME_TAIL@CPU_MIN@30
2021-07-15 11:43:08.781 24988-24988/? A/DEBUG: backtrace:
2021-07-15 11:43:08.781 24988-24988/? A/DEBUG: #00 pc 000000000015227c /apex/com.android.runtime/lib64/libart.so (std::__1::__hash_table<std::__1::__hash_value_type<art::ArtMethod*, std::__1::vector<std::__1::pair<art::ArtMethod*, art::OatQuickMethodHeader*>, std::__1::allocator<std::__1::pair<art::ArtMethod*, art::OatQuickMethodHeader*>>>>, std::__1::__unordered_map_hasher<art::ArtMethod*, std::__1::__hash_value_type<art::ArtMethod*, std::__1::vector<std::__1::pair<art::ArtMethod*, art::OatQuickMethodHeader*>, std::__1::allocator<std::__1::pair<art::ArtMethod*, art::OatQuickMethodHeader*>>>>, std::__1::hashart::ArtMethod*, true>, std::__1::__unordered_map_equal<art::ArtMethod*, std::__1::__hash_value_type<art::ArtMethod*, std::__1::vector<std::__1::pair<art::ArtMethod*, art::OatQuickMethodHeader*>, std::__1::allocator<std::__1::pair<art::ArtMethod*, art::OatQuickMethodHeader*>>>>, std::__1::equal_toart::ArtMethod*, true>, std::__1::allocator<std::__1::__hash_value_type<art::ArtMethod*, std::__1::vector<std::__1::pair<art::ArtMethod*, art::OatQuickMethodHeader*>, std::__1::allocator<std::__1::pair<art::ArtMethod*, art::OatQuickMethodHeader*>>>>>>::__rehash(unsigned long)+72) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.781 24988-24988/? A/DEBUG: #1 pc 000000000018ad94 /apex/com.android.runtime/lib64/libart.so (ZNSt3__112__hash_tableIN3art6ObjPtrINS1_6mirror5ClassEEENS1_10HashObjPtrENS_8equal_toIS5_EENS_9allocatorIS5_EEE25__emplace_unique_key_argsIS5_JRKS5_EEENS_4pairINS_15__hash_iteratorIPNS_11__hash_nodeIS5_PvEEEEbEERKT_DpOT0+440) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.781 24988-24988/? A/DEBUG: #2 pc 000000000017586c /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::SetupInterfaceLookupTable(art::Thread*, art::Handleart::mirror::Class, art::Handle<art::mirror::ObjectArrayart::mirror::Class>)+2016) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.781 24988-24988/? A/DEBUG: #3 pc 00000000001749f4 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::LinkMethods(art::Thread*, art::Handleart::mirror::Class, art::Handle<art::mirror::ObjectArrayart::mirror::Class>, bool*, art::ArtMethod**)+116) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #4 pc 000000000016a478 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::LinkClass(art::Thread*, char const*, art::Handleart::mirror::Class, art::Handle<art::mirror::ObjectArrayart::mirror::Class>, art::MutableHandleart::mirror::Class)+252) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #5 pc 0000000000165d00 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::DefineClass(art::Thread
, char const*, unsigned long, art::Handleart::mirror::ClassLoader, art::DexFile const&, art::dex::ClassDef const&)+1148) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #6 pc 000000000018f370 /apex/com.android.runtime/lib64/libart.so (_ZN3art27VisitClassLoaderDexElementsIZNS_24VisitClassLoaderDexFilesIZNS_24VisitClassLoaderDexFilesIZNS_11ClassLinker38FindClassInBaseDexClassLoaderClassPathERNS_33ScopedObjectAccessAlreadyRunnableEPKcmNS_6HandleINS_6mirror11ClassLoaderEEEE4$31EEvS5_SB_T_EUlPKNS_7DexFileEPPvE_SH_EET0_S5_SB_SD_SK_EUlNS_6ObjPtrINS9_6ObjectEEESI_E_SH_EESK_S5_SB_SD_SK+628) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #7 pc 0000000000164e90 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::FindClassInBaseDexClassLoader(art::ScopedObjectAccessAlreadyRunnable&, art::Thread*, char const*, unsigned long, art::Handleart::mirror::ClassLoader, art::ObjPtrart::mirror::Class)+684) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #8 pc 00000000001666d8 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::FindClass(art::Thread
, char const*, art::Handleart::mirror::ClassLoader)+1044) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #9 pc 00000000001534c0 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::DoResolveType(art::dex::TypeIndex, art::Handleart::mirror::DexCache, art::Handleart::mirror::ClassLoader)+184) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #10 pc 0000000000153a54 /apex/com.android.runtime/lib64/libart.so (art::ObjPtrart::mirror::Class art::ClassLinker::DoResolveType<art::ObjPtrart::mirror::Class>(art::dex::TypeIndex, art::ObjPtrart::mirror::Class)+220) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #11 pc 000000000016a088 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::LoadSuperAndInterfaces(art::Handleart::mirror::Class, art::DexFile const&)+480) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #12 pc 0000000000165c78 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::DefineClass(art::Thread*, char const*, unsigned long, art::Handleart::mirror::ClassLoader, art::DexFile const&, art::dex::ClassDef const&)+1012) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #13 pc 000000000018f370 /apex/com.android.runtime/lib64/libart.so (_ZN3art27VisitClassLoaderDexElementsIZNS_24VisitClassLoaderDexFilesIZNS_24VisitClassLoaderDexFilesIZNS_11ClassLinker38FindClassInBaseDexClassLoaderClassPathERNS_33ScopedObjectAccessAlreadyRunnableEPKcmNS_6HandleINS_6mirror11ClassLoaderEEEE4$31EEvS5_SB_T_EUlPKNS_7DexFileEPPvE_SH_EET0_S5_SB_SD_SK_EUlNS_6ObjPtrINS9_6ObjectEEESI_E_SH_EESK_S5_SB_SD_SK+628) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #14 pc 0000000000164e90 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::FindClassInBaseDexClassLoader(art::ScopedObjectAccessAlreadyRunnable&, art::Thread*, char const*, unsigned long, art::Handleart::mirror::ClassLoader, art::ObjPtrart::mirror::Class)+684) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #15 pc 00000000001666d8 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::FindClass(art::Thread
, char const*, art::Handleart::mirror::ClassLoader)+1044) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #16 pc 00000000001534c0 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::DoResolveType(art::dex::TypeIndex, art::Handleart::mirror::DexCache, art::Handleart::mirror::ClassLoader)+184) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #17 pc 0000000000528cc0 /apex/com.android.runtime/lib64/libart.so (_ZN3art8verifier4impl12_GLOBAL__N_114MethodVerifierILb0EE12ResolveClassILNS2_11CheckAccessE0EEERKNS0_7RegTypeENS_3dex9TypeIndexE+172) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #18 pc 000000000053e568 /apex/com.android.runtime/lib64/libart.so (art::verifier::impl::(anonymous namespace)::MethodVerifier::CodeFlowVerifyInstruction(unsigned int*)+8268) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #19 pc 0000000000522f84 /apex/com.android.runtime/lib64/libart.so (_ZN3art8verifier4impl12_GLOBAL__N_114MethodVerifierILb0EE6VerifyEv$09bf97eb2c0d684adb6d215f7005036e+14252) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #20 pc 000000000051eb78 /apex/com.android.runtime/lib64/libart.so (art::verifier::MethodVerifier::FailureData art::verifier::MethodVerifier::VerifyMethod(art::Thread*, unsigned int, art::DexFile const*, art::Handleart::mirror::DexCache, art::DexFile const*art::Handle::ClassLoader, art::dex::ClassDef const&, art::DexFile const*art::Handle::ClassLoader::CodeItem const*, art::ArtMethod*, unsigned int, art::CompilerCallbacks*, bool, art::verifier::HardFailLogMode, bool, unsigned int, std::__1::basic_string<char, art::verifier::HardFailLogMode::char_traits, art::verifier::HardFailLogMode::allocator>)+256) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #21 pc 000000000051d08c /apex/com.android.runtime/lib64/libart.so (art::verifier::ClassVerifier::VerifyClass(art::Thread
, art::DexFile const*, art::Handleart::mirror::DexCache, art::Handleart::mirror::ClassLoader, art::dex::ClassDef const&, art::CompilerCallbacks*, bool, art::verifier::HardFailLogMode, unsigned int, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator>)+1328) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #22 pc 000000000051c91c /apex/com.android.runtime/lib64/libart.so (art::verifier::ClassVerifier::VerifyClass(art::Thread
, art::ObjPtrart::mirror::Class, art::CompilerCallbacks*, bool, art::verifier::HardFailLogMode, unsigned int, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator>)+488) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #23 pc 000000000016e3e8 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::VerifyClass(art::Thread
, art::Handleart::mirror::Class, art::verifier::HardFailLogMode)+1460) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #24 pc 00000000001713a8 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::InitializeClass(art::Thread*, art::Handleart::mirror::Class, bool, bool)+356) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.782 24988-24988/? A/DEBUG: #25 pc 000000000015c944 /apex/com.android.runtime/lib64/libart.so (art::ClassLinker::EnsureInitialized(art::Thread*, art::Handleart::mirror::Class, bool, bool)+92) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #26 pc 00000000002b716c /apex/com.android.runtime/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+372) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #27 pc 00000000002db950 /apex/com.android.runtime/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+884) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #28 pc 000000000059ce64 /apex/com.android.runtime/lib64/libart.so (MterpInvokeStatic+368) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #29 pc 0000000000131994 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_static+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #30 pc 00000000001d79b6 [anon:dalvik-classes.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk] (androidx.activity.ComponentActivity.+22)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #31 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #32 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #33 pc 00000000001d7a70 [anon:dalvik-classes.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk] (androidx.activity.ComponentActivity.)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #34 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #35 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #36 pc 0000000000305268 [anon:dalvik-classes.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk] (androidx.fragment.app.FragmentActivity.)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #37 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #38 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #39 pc 00000000001dc680 [anon:dalvik-classes.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk] (androidx.appcompat.app.AppCompatActivity.)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #40 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #41 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #42 pc 000000000013042c [anon:dalvik-classes4.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk!classes4.dex] (dagger.android.support.DaggerAppCompatActivity.)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #43 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #44 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #45 pc 00000000003a8fb8 [anon:dalvik-classes2.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk!classes2.dex] (com.prod.neoapp.core.base.BaseActivity.+4)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #46 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #47 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #48 pc 000000000039600a [anon:dalvik-classes2.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk!classes2.dex] (com.prod.neoapp.app.ui.view.SplashActivity.+2)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #49 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #50 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #51 pc 0000000000396082 [anon:dalvik-classes2.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk!classes2.dex] (com.prod.neoapp.app.ui.view.SplashActivity.+26)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #52 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #53 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #54 pc 0000000000395fee [anon:dalvik-classes2.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk!classes2.dex] (com.prod.neoapp.app.ui.view.SplashActivity.+6)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #55 pc 00000000002b12d8 /apex/com.android.runtime/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEbb.llvm.7789675287834264783+240) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #56 pc 000000000058b8c0 /apex/com.android.runtime/lib64/libart.so (artQuickToInterpreterBridge+1012) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #57 pc 0000000000140468 /apex/com.android.runtime/lib64/libart.so (art_quick_to_interpreter_bridge+88) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #58 pc 0000000000137334 /apex/com.android.runtime/lib64/libart.so (art_quick_invoke_stub+548) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #59 pc 000000000014606c /apex/com.android.runtime/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+244) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #60 pc 0000000000424ac4 /apex/com.android.runtime/lib64/libart.so (art::Class_newInstance(_JNIEnv*, _jobject*)+712) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #61 pc 00000000000b91ec /system/framework/arm64/boot.oat (art_jni_trampoline+124) (BuildId: 756926e017f1467bd891b7cc9ef65b68fe0f9525)
2021-07-15 11:43:08.783 24988-24988/? A/DEBUG: #62 pc 0000000000137334 /apex/com.android.runtime/lib64/libart.so (art_quick_invoke_stub+548) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #63 pc 000000000014606c /apex/com.android.runtime/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+244) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #64 pc 00000000002e068c /apex/com.android.runtime/lib64/libart.so (art::interpreter::ArtInterpreterToCompiledCodeBridge(art::Thread*, art::ArtMethod*, art::ShadowFrame*, unsigned short, art::JValue*)+384) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #65 pc 00000000002db96c /apex/com.android.runtime/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+912) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #66 pc 000000000059a2b8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+648) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #67 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #68 pc 00000000001b39fc /system/framework/framework.jar (android.app.AppComponentFactory.instantiateActivity+8)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #69 pc 000000000059b26c /apex/com.android.runtime/lib64/libart.so (MterpInvokeSuper+2312) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #70 pc 0000000000131894 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_super+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #71 pc 00000000002b3738 [anon:dalvik-classes.dex extracted in memory from /data/app/com.prod.neoapp-SS2wYDpssnr6cwqN9kJTJQ==/base.apk] (androidx.core.app.CoreComponentFactory.instantiateActivity)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #72 pc 000000000059a5c8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+1432) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #73 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #74 pc 000000000021cd24 /system/framework/framework.jar (android.app.Instrumentation.newActivity+44)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #75 pc 000000000059a5c8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+1432) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #76 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #77 pc 000000000019e0b0 /system/framework/framework.jar (android.app.ActivityThread.performLaunchActivity+180)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #78 pc 000000000059c958 /apex/com.android.runtime/lib64/libart.so (MterpInvokeDirect+1168) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #79 pc 0000000000131914 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_direct+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #80 pc 000000000019df6a /system/framework/framework.jar (android.app.ActivityThread.handleLaunchActivity+94)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #81 pc 000000000059a5c8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+1432) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #82 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #83 pc 00000000002a753e /system/framework/framework.jar (android.app.servertransaction.LaunchActivityItem.execute+126)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #84 pc 000000000059a5c8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+1432) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #85 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #86 pc 00000000002a9a8a /system/framework/framework.jar (android.app.servertransaction.TransactionExecutor.executeCallbacks+154)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #87 pc 000000000059a5c8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+1432) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #88 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #89 pc 00000000002a99c6 /system/framework/framework.jar (android.app.servertransaction.TransactionExecutor.execute+146)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #90 pc 000000000059a5c8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+1432) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #91 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #92 pc 000000000019d276 /system/framework/framework.jar (android.app.ActivityThread$H.handleMessage+78)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #93 pc 000000000059a5c8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+1432) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #94 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.784 24988-24988/? A/DEBUG: #95 pc 000000000035af3a /system/framework/framework.jar (android.os.Handler.dispatchMessage+38)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #96 pc 000000000059a5c8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+1432) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #97 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #98 pc 000000000039b0c6 /system/framework/framework.jar (android.os.Looper.loop+466)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #99 pc 000000000059d164 /apex/com.android.runtime/lib64/libart.so (MterpInvokeStatic+1136) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #100 pc 0000000000131994 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_static+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #101 pc 00000000001a7632 /system/framework/framework.jar (android.app.ActivityThread.main+214)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #102 pc 00000000002b12d8 /apex/com.android.runtime/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEbb.llvm.7789675287834264783+240) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #103 pc 000000000058b8c0 /apex/com.android.runtime/lib64/libart.so (artQuickToInterpreterBridge+1012) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #104 pc 0000000000140468 /apex/com.android.runtime/lib64/libart.so (art_quick_to_interpreter_bridge+88) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #105 pc 00000000001375b8 /apex/com.android.runtime/lib64/libart.so (art_quick_invoke_static_stub+568) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #106 pc 000000000014608c /apex/com.android.runtime/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+276) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #107 pc 00000000004ab8e0 /apex/com.android.runtime/lib64/libart.so (art::(anonymous namespace)::InvokeWithArgArray(art::ScopedObjectAccessAlreadyRunnable const&, art::ArtMethod*, art::(anonymous namespace)::ArgArray*, art::JValue*, char const*)+104) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #108 pc 00000000004ad308 /apex/com.android.runtime/lib64/libart.so (art::InvokeMethod(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, _jobject*, _jobject*, unsigned long)+1476) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #109 pc 0000000000439760 /apex/com.android.runtime/lib64/libart.so (art::Method_invoke(_JNIEnv*, _jobject*, _jobject*, _jobjectArray*)+52) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #110 pc 00000000000c2d34 /system/framework/arm64/boot.oat (art_jni_trampoline+180) (BuildId: 756926e017f1467bd891b7cc9ef65b68fe0f9525)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #111 pc 0000000000137334 /apex/com.android.runtime/lib64/libart.so (art_quick_invoke_stub+548) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #112 pc 000000000014606c /apex/com.android.runtime/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+244) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #113 pc 00000000002e068c /apex/com.android.runtime/lib64/libart.so (art::interpreter::ArtInterpreterToCompiledCodeBridge(art::Thread*, art::ArtMethod*, art::ShadowFrame*, unsigned short, art::JValue*)+384) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #114 pc 00000000002db96c /apex/com.android.runtime/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+912) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #115 pc 000000000059a2b8 /apex/com.android.runtime/lib64/libart.so (MterpInvokeVirtual+648) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #116 pc 0000000000131814 /apex/com.android.runtime/lib64/libart.so (mterp_op_invoke_virtual+20) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #117 pc 000000000047fd42 /system/framework/framework.jar (com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run+22)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #118 pc 00000000002b12d8 /apex/com.android.runtime/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEbb.llvm.7789675287834264783+240) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #119 pc 000000000058b8c0 /apex/com.android.runtime/lib64/libart.so (artQuickToInterpreterBridge+1012) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #120 pc 0000000000140468 /apex/com.android.runtime/lib64/libart.so (art_quick_to_interpreter_bridge+88) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #121 pc 00000000009ce418 /system/framework/arm64/boot-framework.oat (com.android.internal.os.ZygoteInit.main+3016) (BuildId: 8b5b2db1869062be40ca1ced059459dac94f89b4)
2021-07-15 11:43:08.785 24988-24988/? A/DEBUG: #122 pc 00000000001375b8 /apex/com.android.runtime/lib64/libart.so (art_quick_invoke_static_stub+568) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.786 24988-24988/? A/DEBUG: #123 pc 000000000014608c /apex/com.android.runtime/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+276) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.786 24988-24988/? A/DEBUG: #124 pc 00000000004ab8e0 /apex/com.android.runtime/lib64/libart.so (art::(anonymous namespace)::InvokeWithArgArray(art::ScopedObjectAccessAlreadyRunnable const&, art::ArtMethod*, art::(anonymous namespace)::ArgArray*, art::JValue*, char const*)+104) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.786 24988-24988/? A/DEBUG: #125 pc 00000000004ab54c /apex/com.android.runtime/lib64/libart.so (art::InvokeWithVarArgs(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, _jmethodID*, std::__va_list)+408) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.786 24988-24988/? A/DEBUG: #126 pc 00000000003b77ac /apex/com.android.runtime/lib64/libart.so (art::JNI::CallStaticVoidMethodV(_JNIEnv*, _jclass*, _jmethodID*, std::__va_list)+628) (BuildId: 30bd09447631b1b7b9d553a2bf914b3b)
2021-07-15 11:43:08.786 24988-24988/? A/DEBUG: #127 pc 00000000000ec560 /system/lib64/libandroid_runtime.so (_JNIEnv::CallStaticVoidMethod(_jclass*, _jmethodID*, ...)+116) (BuildId: 080ffd35d37892df15566e533d6e519f)
2021-07-15 11:43:08.786 24988-24988/? A/DEBUG: #128 pc 00000000000ef5a0 /system/lib64/libandroid_runtime.so (android::AndroidRuntime::start(char const*, android::Vectorandroid::String8 const&, bool)+796) (BuildId: 080ffd35d37892df15566e533d6e519f)
2021-07-15 11:43:08.786 24988-24988/? A/DEBUG: #129 pc 00000000000034e0 /system/bin/app_process64 (main+1168) (BuildId: 5d0cadc6c1be2721921ead0447a78c51)
2021-07-15 11:43:08.786 24988-24988/? A/DEBUG: #130 pc 000000000007e798 /apex/com.android.runtime/lib64/bionic/libc.so (__libc_init+108) (BuildId: f0e764f03a5004a006cd457ee8a428dc)

Build .so file

how can i build all the library into single .so file ?

Error while trying to build project

Hi, I encountered this problem while trying to build the externalNativeBuildDebug:

Build command failed.
Error while executing process C:\Users\Usr\AppData\Local\Android\Sdk\cmake\3.10.2.4988404\bin\ninja.exe with arguments {-C D:\Android Projects\DetectFrida-master\app.cxx\cmake\debug\armeabi-v7a native-lib}
ninja: Entering directory `D:\Android Projects\DetectFrida-master\app.cxx\cmake\debug\armeabi-v7a'
[1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
FAILED: CMakeFiles/native-lib.dir/native-lib.c.o
"D:\Android Projects\DetectFrida-master\app\src\main\c..........\build\bin\clang" --target=armv7-none-linux-androideabi21 --gcc-toolchain=C:/Users/Usr/AppData/Local/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/windows-x86_64 --sysroot=C:/Users/Usr/AppData/Local/Android/Sdk/ndk-bundle/toolchains/llvm/prebuilt/windows-x86_64/sysroot -D_32_BIT -Dnative_lib_EXPORTS -I"D:/Android Projects/DetectFrida-master/app/src/main/c/arch/armeabi-v7a" -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -march=armv7-a -mthumb -Wformat -Werror=format-security -mllvm -sub -mllvm -bcf -mllvm -fla -O0 -fno-limit-debug-info -fPIC -MD -MT CMakeFiles/native-lib.dir/native-lib.c.o -MF CMakeFiles\native-lib.dir\native-lib.c.o.d -o CMakeFiles/native-lib.dir/native-lib.c.o -c "D:/Android Projects/DetectFrida-master/app/src/main/c/native-lib.c"
CreateProcess failed: The system cannot find the file specified.
ninja: build stopped: subcommand failed.

Any idea how I can resolve this? Thanks.

This project was not build.

Hi, @darvincisec

I cloned this project on Mac M1 device. I got an error while I was building.

Build command failed.
Error while executing process /Users/halilozel/Library/Android/sdk/cmake/3.10.2.4988404/bin/ninja with arguments {-C /Users/halilozel/Desktop/DetectFrida/app/.cxx/cmake/debug/arm64-v8a native-lib}
ninja: Entering directory `/Users/halilozel/Desktop/DetectFrida/app/.cxx/cmake/debug/arm64-v8a'
[1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
FAILED: CMakeFiles/native-lib.dir/native-lib.c.o 
/Users/halilozel/Desktop/DetectFrida/app/src/main/c/../../../../../o-llvm-binary/ollvm-tll/build/bin_Darwin/clang --target=aarch64-none-linux-android21 --gcc-toolchain=/Users/halilozel/Library/Android/sdk/ndk/23.0.7599858/toolchains/llvm/prebuilt/darwin-x86_64 --sysroot=/Users/halilozel/Library/Android/sdk/ndk/23.0.7599858/toolchains/llvm/prebuilt/darwin-x86_64/sysroot -D_64_BIT -Dnative_lib_EXPORTS -I/Users/halilozel/Desktop/DetectFrida/app/src/main/c/arch/arm64-v8a -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security  -mllvm -sub -mllvm -bcf -mllvm -fla -O0 -fno-limit-debug-info  -fPIC -MD -MT CMakeFiles/native-lib.dir/native-lib.c.o -MF CMakeFiles/native-lib.dir/native-lib.c.o.d -o CMakeFiles/native-lib.dir/native-lib.c.o   -c /Users/halilozel/Desktop/DetectFrida/app/src/main/c/native-lib.c
/bin/sh: /Users/halilozel/Desktop/DetectFrida/app/src/main/c/../../../../../o-llvm-binary/ollvm-tll/build/bin_Darwin/clang: No such file or directory
ninja: build stopped: subcommand failed.

I don't know what to do. I tried the solutions but it didn't work. Can you help me?

Cannot build

Hi, I cloned the repo and tried building it. But I'm facing this issue. Is there anything that I'm missing?

Executing tasks: [:app:assembleDebug] in project /Users/daryl/AndroidStudioProjects/DetectFrida

> Task :app:preBuild UP-TO-DATE
> Task :app:preDebugBuild UP-TO-DATE
> Task :app:compileDebugAidl NO-SOURCE
> Task :app:compileDebugRenderscript NO-SOURCE
> Task :app:checkDebugManifest UP-TO-DATE
> Task :app:generateDebugBuildConfig UP-TO-DATE
> Task :app:javaPreCompileDebug UP-TO-DATE
> Task :app:mainApkListPersistenceDebug UP-TO-DATE
> Task :app:generateDebugResValues UP-TO-DATE
> Task :app:generateDebugResources UP-TO-DATE
> Task :app:mergeDebugResources UP-TO-DATE
> Task :app:createDebugCompatibleScreenManifests UP-TO-DATE
> Task :app:processDebugManifest
> Task :app:processDebugResources
> Task :app:compileDebugJavaWithJavac UP-TO-DATE
> Task :app:generateJsonModelDebug UP-TO-DATE

> Task :app:externalNativeBuildDebug FAILED
Build native-lib_armeabi-v7a
ninja: Entering directory `/Users/daryl/AndroidStudioProjects/DetectFrida/app/.cxx/cmake/debug/armeabi-v7a'
[1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
FAILED: CMakeFiles/native-lib.dir/native-lib.c.o 
/Users/daryl/AndroidStudioProjects/DetectFrida/app/src/main/c/../../../../../o-llvm-binary/ollvm-tll/build/bin_Darwin/clang --target=armv7-none-linux-androideabi19 --gcc-toolchain=/Users/daryl/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64 --sysroot=/Users/daryl/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64/sysroot -D_32_BIT -Dnative_lib_EXPORTS -I/Users/daryl/AndroidStudioProjects/DetectFrida/app/src/main/c/arch/armeabi-v7a -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -march=armv7-a -mthumb -Wformat -Werror=format-security  -mllvm -sub -mllvm -bcf -mllvm -fla -O0 -fno-limit-debug-info  -fPIC -MD -MT CMakeFiles/native-lib.dir/native-lib.c.o -MF CMakeFiles/native-lib.dir/native-lib.c.o.d -o CMakeFiles/native-lib.dir/native-lib.c.o   -c /Users/daryl/AndroidStudioProjects/DetectFrida/app/src/main/c/native-lib.c
/bin/sh: /Users/daryl/AndroidStudioProjects/DetectFrida/app/src/main/c/../../../../../o-llvm-binary/ollvm-tll/build/bin_Darwin/clang: No such file or directory
ninja: build stopped: subcommand failed.

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:externalNativeBuildDebug'.
> Build command failed.
  Error while executing process /Users/daryl/Library/Android/sdk/cmake/3.10.2.4988404/bin/ninja with arguments {-C /Users/daryl/AndroidStudioProjects/DetectFrida/app/.cxx/cmake/debug/armeabi-v7a native-lib}
  ninja: Entering directory `/Users/daryl/AndroidStudioProjects/DetectFrida/app/.cxx/cmake/debug/armeabi-v7a'
  [1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
  FAILED: CMakeFiles/native-lib.dir/native-lib.c.o 
  /Users/daryl/AndroidStudioProjects/DetectFrida/app/src/main/c/../../../../../o-llvm-binary/ollvm-tll/build/bin_Darwin/clang --target=armv7-none-linux-androideabi19 --gcc-toolchain=/Users/daryl/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64 --sysroot=/Users/daryl/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64/sysroot -D_32_BIT -Dnative_lib_EXPORTS -I/Users/daryl/AndroidStudioProjects/DetectFrida/app/src/main/c/arch/armeabi-v7a -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -march=armv7-a -mthumb -Wformat -Werror=format-security  -mllvm -sub -mllvm -bcf -mllvm -fla -O0 -fno-limit-debug-info  -fPIC -MD -MT CMakeFiles/native-lib.dir/native-lib.c.o -MF CMakeFiles/native-lib.dir/native-lib.c.o.d -o CMakeFiles/native-lib.dir/native-lib.c.o   -c /Users/daryl/AndroidStudioProjects/DetectFrida/app/src/main/c/native-lib.c
  /bin/sh: /Users/daryl/AndroidStudioProjects/DetectFrida/app/src/main/c/../../../../../o-llvm-binary/ollvm-tll/build/bin_Darwin/clang: No such file or directory
  ninja: build stopped: subcommand failed.
  


* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 0s
12 actionable tasks: 3 executed, 9 up-to-date

Screenshot 2021-06-11 at 7 27 52 PM

False positive when run on x86 architecture

Firstly, thanks for the repo. I wanted to try and get this sample project to run on 32-bit architecture since it would just crash on older devices, so I added x86 to the list of valid ABIs in build.gradle.

...
ndk {
     abiFilters 'arm64-v8a', 'armeabi-v7a', 'x86_64', 'x86'
}
...

Because of that, all system calls using the my_ prefix are broken once we try to run in x86. After removing all the my_ prefixes from the system calls, the sample app seems to be working as expected except for the check in the detect_frida_memdiskcompare function. The logs indicate that the libc library has a mismatching checksum despite the device being clean. I encountered this issue when running the app on a Pixel 4 emulator on x86 ABI with API version 30. This checksum mismatch did not occur on different x86 emulator running on API 29. Any idea what could be causing this?

Logcat

2022-12-27 18:10:33.630 7534-7561/com.darvin.security V/DetectFrida: Map [b9c26000-b9c29000 r-xp 00000000 fd:05 49183                              /data/app/~~CdhyIBdGvW9M9-2j_yxpNg==/com.darvin.security-HX80p3_DA5ykyXtiMkYaKQ==/lib/x86/libnative-lib.so]
2022-12-27 18:10:33.630 7534-7561/com.darvin.security V/DetectFrida: Checksum:[44199][44199]
2022-12-27 18:10:33.630 7534-7561/com.darvin.security V/DetectFrida: Checksum:[494221][494221]
2022-12-27 18:10:33.630 7534-7561/com.darvin.security V/DetectFrida: Map [b9c29000-b9c2a000 r--p 00002000 fd:05 49183                              /data/app/~~CdhyIBdGvW9M9-2j_yxpNg==/com.darvin.security-HX80p3_DA5ykyXtiMkYaKQ==/lib/x86/libnative-lib.so]
2022-12-27 18:10:33.630 7534-7561/com.darvin.security V/DetectFrida: Map [b9c2a000-b9c2b000 rw-p 00003000 fd:05 49183                              /data/app/~~CdhyIBdGvW9M9-2j_yxpNg==/com.darvin.security-HX80p3_DA5ykyXtiMkYaKQ==/lib/x86/libnative-lib.so]
2022-12-27 18:10:33.806 7534-7561/com.darvin.security V/DetectFrida: Map [e5e61000-e5ea3000 r--p 00000000 07:60 17                                 /apex/com.android.runtime/lib/bionic/libc.so]
2022-12-27 18:10:33.806 7534-7561/com.darvin.security V/DetectFrida: Map [e5ea3000-e5f4f000 r-xp 00041000 07:60 17                                 /apex/com.android.runtime/lib/bionic/libc.so]
2022-12-27 18:10:33.808 7534-7561/com.darvin.security V/DetectFrida: Checksum:[67333658][67435579]
2022-12-27 18:10:33.808 7534-7561/com.darvin.security V/DetectFrida: Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2022-12-27 18:10:33.808 7534-7561/com.darvin.security V/DetectFrida: Checksum:[1008449][1051236]
2022-12-27 18:10:33.809 7534-7561/com.darvin.security V/DetectFrida: Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2022-12-27 18:10:33.809 7534-7561/com.darvin.security V/DetectFrida: Map [e5f4f000-e5f52000 r--p 000ec000 07:60 17                                 /apex/com.android.runtime/lib/bionic/libc.so]
2022-12-27 18:10:33.809 7534-7561/com.darvin.security V/DetectFrida: Map [e5f52000-e5f54000 rw-p 000ee000 07:60 17                                 /apex/com.android.runtime/lib/bionic/libc.so]

Build failed while generating obfuscated build.

Build failed while generating obfuscated build.

#Start - Comment this block for generating non-obfuscated builds
set(OLLVM_PATH "${CMAKE_HOME_DIRECTORY}/../../../../../Users/a1vszht2/Downloads/o-llvm-binary")
set(OLLVM_C_COMPILER ${OLLVM_PATH}/clang)
set(OLLVM_CXX_COMPILER ${OLLVM_PATH}/clang++)

set(OLLVM_C_FLAGS "-mllvm -sub -mllvm -bcf -mllvm -fla")

set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OLLVM_C_FLAGS}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OLLVM_C_FLAGS}")
set(CMAKE_C_COMPILER ${OLLVM_C_COMPILER})
set(CMAKE_CXX_COMPILER ${OLLVM_CXX_COMPILER})
#End - Comment this block for generating non-obfuscated builds

Build command failed.
Error while executing process /Users/a1vszht2/Library/Android/sdk/cmake/3.10.2.4988404/bin/ninja with arguments {-C /Users/a1vszht2/Downloads/DetectFrida-master/app/.cxx/cmake/debug/armeabi-v7a native-lib}
ninja: Entering directory `/Users/a1vszht2/Downloads/DetectFrida-master/app/.cxx/cmake/debug/armeabi-v7a'
[1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
FAILED: CMakeFiles/native-lib.dir/native-lib.c.o
/Users/a1vszht2/Downloads/DetectFrida-master/app/src/main/c/../../../../../Users/a1vszht2/Downloads/o-llvm-binary/clang --target=armv7-none-linux-androideabi19 --gcc-toolchain=/Users/a1vszht2/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64 --sysroot=/Users/a1vszht2/Library/Android/sdk/ndk/21.4.7075529/toolchains/llvm/prebuilt/darwin-x86_64/sysroot -D_32_BIT -Dnative_lib_EXPORTS -I/Users/a1vszht2/Downloads/DetectFrida-master/app/src/main/c/arch/armeabi-v7a -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -march=armv7-a -mthumb -Wformat -Werror=format-security -mllvm -sub -mllvm -bcf -mllvm -fla -O0 -fno-limit-debug-info -fPIC -MD -MT CMakeFiles/native-lib.dir/native-lib.c.o -MF CMakeFiles/native-lib.dir/native-lib.c.o.d -o CMakeFiles/native-lib.dir/native-lib.c.o -c /Users/a1vszht2/Downloads/DetectFrida-master/app/src/main/c/native-lib.c
/bin/sh: /Users/a1vszht2/Downloads/DetectFrida-master/app/src/main/c/../../../../../Users/a1vszht2/Downloads/o-llvm-binary/clang: No such file or directory
ninja: build stopped: subcommand failed.

new object

I use this project build a .AAR package.

After I import .aar in my project

import com.darvin.security

I don't have function to new.

How can I use this package?

Fatal signal 11 (SIGSEGV), code 2, fault addr 0xc107000 in tid 2494 (darvin.security)

image
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: Build fingerprint: 'OPPO/OPPO/PCRT00:7.1.2/20171130.376229:user/release-keys'
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: Revision: '0'
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: ABI: 'x86'
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: pid: 2476, tid: 2494, name: flush-8:0 >>> com.darvin.security <<<
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: signal 11 (SIGSEGV), code 2 (SEGV_ACCERR), fault addr 0xc107000
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: eax 99254ef8 ebx 0c107000 ecx 00000013 edx 0c107001
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: esi 80000013 edi 80000013
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: xcs 00000073 xds 0000007b xes 0000007b xfs 0000003b xss 0000007b
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: eip 0e1104ef ebp 10128000 esp 99254450 flags 00010287
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: backtrace:
2021-04-05 14:21:22.890 2498-2498/? A/DEBUG: #00 pc 000814ef anonymous:0e08f000

How to implement this project in React Native?

Thanks for this wonderful package. I have a react native project and I couldn't find any readme for integrating with React Native. Could you point me to tutorial to implement this in React native.

False positive on few specific devices like samsung A13 Android 12

hi ,

For samsung A13 model android 12.0, script is giving false positive for frida detection.
It is happening in scan_executable_segments method where checksum is not matching.

Following is the log dump of the same:

2023-01-25 18:18:08.878 20767-20796 DetectMalware pid-20767 E !@ Checksum:[64076][64076], count: 0
2023-01-25 18:18:08.878 20767-20796 DetectMalware pid-20767 E !@ Checksum:[956873][956873], count: 1
2023-01-25 18:18:08.990 20767-20796 DetectMalware pid-20767 E !@ Checksum:[59601097][59680139], count: 0
2023-01-25 18:18:08.990 20767-20796 DetectMalware pid-20767 E !@ Checksum:[1421520][1670286], count: 1

Here we can see that 59601097 and 59680139 is mismatch and 1421520 and 1670286.

Please help.
Also if there is documentation which explains clearly on what we are trying to do with scan_executable_segments, will be more helpful.

Build is Successful but while trying to install the APK in device. Build is failing with error

Build command failed.
Error while executing process C:\Users\Priyesh\AppData\Local\Android\Sdk\cmake\3.22.1\bin\ninja.exe with arguments {-C C:\Users\Priyesh\Downloads\DetectFrida-master\app.cxx\Debug\4y238423\armeabi-v7a native-lib}
ninja: Entering directory `C:\Users\Priyesh\Downloads\DetectFrida-master\app.cxx\Debug\4y238423\armeabi-v7a'
[1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
[2/2] Linking C shared library C:\Users\Priyesh\Downloads\DetectFrida-master\app\build\intermediates\cxx\Debug\4y238423\obj\armeabi-v7a\libnative-lib.so
FAILED: C:/Users/Priyesh/Downloads/DetectFrida-master/app/build/intermediates/cxx/Debug/4y238423/obj/armeabi-v7a/libnative-lib.so
cmd.exe /C "cd . && C:\Users\Priyesh\AppData\Local\Android\Sdk\ndk\25.1.8937393\toolchains\llvm\prebuilt\windows-x86_64\bin\clang.exe --target=armv7-none-linux-androideabi19 --sysroot=C:/Users/Priyesh/AppData/Local/Android/Sdk/ndk/25.1.8937393/toolchains/llvm/prebuilt/windows-x86_64/sysroot -fPIC -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -march=armv7-a -mthumb -Wformat -Werror=format-security -fno-limit-debug-info -static-libstdc++ -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Wl,--gc-sections -Wl,--no-undefined -Qunused-arguments -shared -Wl,-soname,libnative-lib.so -o C:\Users\Priyesh\Downloads\DetectFrida-master\app\build\intermediates\cxx\Debug\4y238423\obj\armeabi-v7a\libnative-lib.so CMakeFiles/native-lib.dir/native-lib.c.o C:/Users/Priyesh/AppData/Local/Android/Sdk/ndk/25.1.8937393/toolchains/llvm/prebuilt/windows-x86_64/sysroot/usr/lib/arm-linux-androideabi/19/liblog.so -latomic -lm && cmd.exe /C "cd /D C:\Users\Priyesh\Downloads\DetectFrida-master\app.cxx\Debug\4y238423\armeabi-v7a && C:\Users\Priyesh\AppData\Local\Android\Sdk\ndk\25.1.8937393\toolchains\llvm\prebuilt\windows-x86_64\bin\arm-linux-androideabi-strip -R .comment -g -S -d --strip-unneeded C:/Users/Priyesh/Downloads/DetectFrida-master/app/src/main/c/../../../build/intermediates/cmake/Debug/obj/armeabi-v7a/libnative-lib.so""
'C:\Users\Priyesh\AppData\Local\Android\Sdk\ndk\25.1.8937393\toolchains\llvm\prebuilt\windows-x86_64\bin\arm-linux-androideabi-strip' is not recognized as an internal or external command,
operable program or batch file.
ninja: build stopped: subcommand failed.

Disk To Memory Checks fail on Android 11, even if there isn't hooking framework

Although there isn't any hooking framework invoked, when trying the library code on Android 11, this is being executed:
__android_log_print(ANDROID_LOG_WARN, APPNAME, "Executable Section Manipulated, "
"maybe due to Frida or other hooking framework."
"Act Now!!!");
(native-lib.c file, line 195)

This false alert is only happening on Android 11.

Crash occurred while running the project on a mobile phone with FRIDA-SERVER enabled

2021-04-11 07:43:33.194 28237-28305/com.darvin.security V/DetectFrida: Map [7925484000-7925486000 rwxp 00027000 fd:00 784 /system/lib64/libc.so]
2021-04-11 07:43:33.194 28237-28305/com.darvin.security V/DetectFrida: Checksum:[708127][649658]
2021-04-11 07:43:33.194 28237-28305/com.darvin.security V/DetectFrida: Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2021-04-11 07:43:33.199 28237-28305/com.darvin.security A/libc: Fatal signal 11 (SIGSEGV), code 2, fault addr 0x7925525000 in tid 28305 (darvin.security), pid 28237 (darvin.security)

While integrating code to other project getting this Path issue.

    Build command failed.

Error while executing process C:\Users\Priyesh\AppData\Local\Android\Sdk\cmake\3.10.2.4988404\bin\ninja.exe with arguments {-C D:\Novopay\novopay-platform-digi-distribution-app\app.cxx\Debug\6g1o2x5t\armeabi-v7a native-lib}
ninja: Entering directory `D:\Novopay\novopay-platform-digi-distribution-app\app.cxx\Debug\6g1o2x5t\armeabi-v7a'
[1/2] Building C object CMakeFiles/native-lib.dir/native-lib.c.o
[2/2] Linking C shared library D:\Novopay\novopay-platform-digi-distribution-app\app\build\intermediates\cxx\Debug\6g1o2x5t\obj\armeabi-v7a\libnative-lib.so
FAILED: D:/Novopay/novopay-platform-digi-distribution-app/app/build/intermediates/cxx/Debug/6g1o2x5t/obj/armeabi-v7a/libnative-lib.so
cmd.exe /C "cd . && C:\Users\Priyesh\AppData\Local\Android\Sdk\ndk\20.1.5948944\toolchains\llvm\prebuilt\windows-x86_64\bin\clang.exe --target=armv7-none-linux-androideabi21 --gcc-toolchain=C:/Users/Priyesh/AppData/Local/Android/Sdk/ndk/20.1.5948944/toolchains/llvm/prebuilt/windows-x86_64 --sysroot=C:/Users/Priyesh/AppData/Local/Android/Sdk/ndk/20.1.5948944/toolchains/llvm/prebuilt/windows-x86_64/sysroot -fPIC -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -fno-addrsig -march=armv7-a -mthumb -Wa,--noexecstack -Wformat -Werror=format-security -O0 -fno-limit-debug-info -Wl,--exclude-libs,libgcc.a -Wl,--exclude-libs,libatomic.a -static-libstdc++ -Wl,--build-id -Wl,--warn-shared-textrel -Wl,--fatal-warnings -Wl,--exclude-libs,libunwind.a -Wl,--no-undefined -Qunused-arguments -Wl,-z,noexecstack -shared -Wl,-soname,libnative-lib.so -o D:\Novopay\novopay-platform-digi-distribution-app\app\build\intermediates\cxx\Debug\6g1o2x5t\obj\armeabi-v7a\libnative-lib.so CMakeFiles/native-lib.dir/native-lib.c.o -llog -latomic -lm && cmd.exe /C "cd /D D:\Novopay\novopay-platform-digi-distribution-app\app.cxx\Debug\6g1o2x5t\armeabi-v7a && C:\Users\Priyesh\AppData\Local\Android\Sdk\ndk\20.1.5948944\toolchains\llvm\prebuilt\windows-x86_64\bin\arm-linux-androideabi-strip -R .comment -g -S -d --strip-unneeded D:/Novopay/novopay-platform-digi-distribution-app/app/src/main/c/../../../build/intermediates/cmake/Debug/obj/armeabi-v7a/libnative-lib.so""
C:\Users\Priyesh\AppData\Local\Android\Sdk\ndk\20.1.5948944\toolchains\llvm\prebuilt\windows-x86_64\bin\arm-linux-androideabi-strip: 'D:/Novopay/novopay-platform-digi-distribution-app/app/src/main/c/../../../build/intermediates/cmake/Debug/obj/armeabi-v7a/libnative-lib.so': No such file
ninja: build stopped: subcommand failed.

@patuoynageek @darvincisec can you give suggestions how to resolve this issue. I am trying to add this C module in another project. TIA

Originally posted by @erpriyeshpanchal in #20 (comment)

minSdkVersion 23 or above will crash app

The project's current gradle-5.4.1-all.zip and com.android.tools.build:gradle:3.5.0 works with minSdkVersion 23+

However upon updating to latest gradle i.e.

  • Update root build.gradle to classpath 'com.android.tools.build:gradle:7.0.0'
  • Update gradle-wrapper.properties to distributionUrl=https\://services.gradle.org/distributions/gradle-7.0.2-all.zip

minSdkVersion 19 to 22 works
but 23 and above would crash on native-lib.c file at free(filePaths[i])
https://github.com/darvincisec/DetectFrida/blob/master/app/src/main/c/native-lib.c#L92
the log below:

com.darvin.security A/libc: Fatal signal 11 (SIGSEGV), code 1, fault addr 0x10 in tid 2547 (darvin.security), pid 2547 (darvin.security)
? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
? A/DEBUG: Build fingerprint: 'google/bullhead/bullhead:8.1.0/OPM7.181205.001/5080180:user/release-keys'
? A/DEBUG: Revision: 'rev_1.0'
? A/DEBUG: ABI: 'arm64'
? A/DEBUG: pid: 2547, tid: 2547, name: darvin.security  >>> com.darvin.security <<<
? A/DEBUG: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x10
? A/DEBUG: Cause: null pointer dereference
? A/DEBUG:     x0   000000773a627208  x1   000000000000003f  x2   000000773a60d000  x3   0000000000000000
? A/DEBUG:     x4   0000000040100401  x5   a880000040404000  x6   0000000000000000  x7   7f7f7f7f7f7f7f7f
? A/DEBUG:     x8   ffffffffffffff98  x9   fffffffffffffff3  x10  0000000000000000  x11  0000000000080000
? A/DEBUG:     x12  0000000000000000  x13  0000000000000038  x14  ff00000000000000  x15  ffffffffffffffff
? A/DEBUG:     x16  00000077bc9d7ca8  x17  00000077bc9744b8  x18  f3b5ed4d78e7ce10  x19  000000000000003f
? A/DEBUG:     x20  000000773a627208  x21  000000773a60d000  x22  0000000000000000  x23  00000077bc9e28b8
? A/DEBUG:     x24  00000077bc9e2934  x25  00000077bf295000  x26  00000077bf262662  x27  0000000000000001
? A/DEBUG:     x28  000000772208bd1c  x29  0000007fdb3db690  x30  00000077bc9a08b8
? A/DEBUG:     sp   0000007fdb3db660  pc   00000077bc9a0364  pstate 0000000080000000
? A/DEBUG: backtrace:
? A/DEBUG:     #00 pc 0000000000094364  /system/lib64/libc.so (ifree+88)
? A/DEBUG:     #01 pc 00000000000948b4  /system/lib64/libc.so (je_free+120)
? A/DEBUG:     #02 pc 0000000000001c70  /data/app/com.darvin.security-vIupc0UTGDhYeuWaj9_R8A==/base.apk (offset 0x4000) (detectfrida+3924)
? A/DEBUG:     #03 pc 000000000002087c  /system/bin/linker64 (__dl__ZL10call_arrayIPFviPPcS1_EEvPKcPT_mbS5_+280)
? A/DEBUG:     #04 pc 0000000000020aa8  /system/bin/linker64 (__dl__ZN6soinfo17call_constructorsEv+396)
? A/DEBUG:     #05 pc 000000000000c19c  /system/bin/linker64 (__dl__Z9do_dlopenPKciPK17android_dlextinfoPKv+1788)
? A/DEBUG:     #06 pc 0000000000008dfc  /system/bin/linker64 (__dl__Z20__android_dlopen_extPKciPK17android_dlextinfoPKv+72)
? A/DEBUG:     #07 pc 000000000000120c  /system/lib64/libdl.so (android_dlopen_ext+12)
? A/DEBUG:     #08 pc 0000000000002ca0  /system/lib64/libnativeloader.so (android::OpenNativeLibrary(_JNIEnv*, int, char const*, _jobject*, _jstring*, bool*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>*)+376)
? A/DEBUG:     #09 pc 0000000000300d60  /system/lib64/libart.so (art::JavaVMExt::LoadNativeLibrary(_JNIEnv*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, _jobject*, _jstring*, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>*)+2132)
? A/DEBUG:     #10 pc 00000000000041d0  /system/lib64/libopenjdkjvm.so (JVM_NativeLoad+268)
? A/DEBUG:     #11 pc 00000000002821c4  /system/framework/arm64/boot.oat (offset 0x1da000) (java.lang.Runtime.nativeLoad+228)
? A/DEBUG:     #12 pc 000000000054ae4c  /system/lib64/libart.so (art_quick_invoke_static_stub+604)
? A/DEBUG:     #13 pc 00000000000dc5d0  /system/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+264)
? A/DEBUG:     #14 pc 000000000029b49c  /system/lib64/libart.so (art::interpreter::ArtInterpreterToCompiledCodeBridge(art::Thread*, art::ArtMethod*, art::ShadowFrame*, unsigned short, art::JValue*)+344)
? A/DEBUG:     #15 pc 0000000000295a90  /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+700)
? A/DEBUG:     #16 pc 0000000000533f50  /system/lib64/libart.so (MterpInvokeStatic+264)
? A/DEBUG:     #17 pc 000000000053ca94  /system/lib64/libart.so (ExecuteMterpImpl+14612)
? A/DEBUG:     #18 pc 0000000000275c00  /system/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame&, art::JValue, bool)+444)
? A/DEBUG:     #19 pc 000000000027b7cc  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame*, art::JValue*)+216)
? A/DEBUG:     #20 pc 0000000000295a70  /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+668)
? A/DEBUG:     #21 pc 0000000000533d68  /system/lib64/libart.so (MterpInvokeDirect+356)
? A/DEBUG:     #22 pc 000000000053ca14  /system/lib64/libart.so (ExecuteMterpImpl+14484)
? A/DEBUG:     #23 pc 0000000000275c00  /system/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame&, art::JValue, bool)+444)
? A/DEBUG:     #24 pc 000000000027b7cc  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame*, art::JValue*)+216)
? A/DEBUG:     #25 pc 0000000000295a70  /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+668)
? A/DEBUG:     #26 pc 0000000000532ad8  /system/lib64/libart.so (MterpInvokeVirtual+652)
? A/DEBUG:     #27 pc 000000000053c914  /system/lib64/libart.so (ExecuteMterpImpl+14228)
? A/DEBUG:     #28 pc 0000000000275c00  /system/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame&, art::JValue, bool)+444)
? A/DEBUG:     #29 pc 000000000027b7cc  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame*, art::JValue*)+216)
? A/DEBUG:     #30 pc 0000000000295a70  /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+668)
? A/DEBUG:     #31 pc 0000000000533f50  /system/lib64/libart.so (MterpInvokeStatic+264)
? A/DEBUG:     #32 pc 000000000053ca94  /system/lib64/libart.so (ExecuteMterpImpl+14612)
? A/DEBUG:     #33 pc 0000000000275c00  /system/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame&, art::JValue, bool)+444)
? A/DEBUG:     #34 pc 0000000000525450  /system/lib64/libart.so (artQuickToInterpreterBridge+1052)
? A/DEBUG:     #35 pc 0000000000553d0c  /system/lib64/libart.so (art_quick_to_interpreter_bridge+92)
? A/DEBUG:     #36 pc 000000000054ae4c  /system/lib64/libart.so (art_quick_invoke_static_stub+604)
? A/DEBUG:     #37 pc 00000000000dc5d0  /system/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+264)
? A/DEBUG:     #38 pc 00000000001394d0  /system/lib64/libart.so (art::ClassLinker::InitializeClass(art::Thread*, art::Handle<art::mirror::Class>, bool, bool)+2740)
? A/DEBUG:     #39 pc 0000000000122bf4  /system/lib64/libart.so (art::ClassLinker::EnsureInitialized(art::Thread*, art::Handle<art::mirror::Class>, bool, bool)+184)
? A/DEBUG:     #40 pc 00000000003dee64  /system/lib64/libart.so (art::Class_newInstance(_JNIEnv*, _jobject*)+1152)
? A/DEBUG:     #41 pc 00000000001da2ac  /system/framework/arm64/boot.oat (offset 0x1da000) (java.lang.Object.internalClone [DEDUPED]+124)
? A/DEBUG:     #42 pc 000000000054ab88  /system/lib64/libart.so (art_quick_invoke_stub+584)
? A/DEBUG:     #43 pc 00000000000dc594  /system/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+204)
? A/DEBUG:     #44 pc 000000000029b49c  /system/lib64/libart.so (art::interpreter::ArtInterpreterToCompiledCodeBridge(art::Thread*, art::ArtMethod*, art::ShadowFrame*, unsigned short, art::JValue*)+344)
? A/DEBUG:     #45 pc 0000000000295a90  /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+700)
? A/DEBUG:     #46 pc 0000000000532ad8  /system/lib64/libart.so (MterpInvokeVirtual+652)
? A/DEBUG:     #47 pc 000000000053c914  /system/lib64/libart.so (ExecuteMterpImpl+14228)
? A/DEBUG:     #48 pc 0000000000275c00  /system/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame&, art::JValue, bool)+444)
? A/DEBUG:     #49 pc 000000000027b7cc  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame*, art::JValue*)+216)
? A/DEBUG:     #50 pc 0000000000295a70  /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+668)
? A/DEBUG:     #51 pc 0000000000532ad8  /system/lib64/libart.so (MterpInvokeVirtual+652)
? A/DEBUG:     #52 pc 000000000053c914  /system/lib64/libart.so (ExecuteMterpImpl+14228)
? A/DEBUG:     #53 pc 0000000000275c00  /system/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame&, art::JValue, bool)+444)
? A/DEBUG:     #54 pc 000000000027b7cc  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame*, art::JValue*)+216)
? A/DEBUG:     #55 pc 0000000000295a70  /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+668)
? A/DEBUG:     #56 pc 0000000000533d68  /system/lib64/libart.so (MterpInvokeDirect+356)
? A/DEBUG:     #57 pc 000000000053ca14  /system/lib64/libart.so (ExecuteMterpImpl+14484)
? A/DEBUG:     #58 pc 0000000000275c00  /system/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame&, art::JValue, bool)+444)
? A/DEBUG:     #59 pc 000000000027b7cc  /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame*, art::JValue*)+216)
? A/DEBUG:     #60 pc 0000000000295a70  /system/lib64/libart.so (_ZN3art11interpreter6DoCallILb0ELb0EEEbPNS_9ArtMethodEPNS_6ThreadERNS_11ShadowFrameEPKNS_11InstructionEtPNS_6JValueE+668)
? A/DEBUG:     #61 pc 0000000000533d68  /system/lib64/libart.so (MterpInvokeDirect+356)
? A/DEBUG:     #62 pc 000000000053ca14  /system/lib64/libart.so (ExecuteMterpImpl+14484)
? A/DEBUG:     #63 pc 0000000000275c00  /system/lib64/libart.so (art::interpreter::Execute(art::Thread*, art::DexFile::CodeItem const*, art::ShadowFrame&, art::JValue, bool)+444)

I also tried com.android.tools.build:gradle:4.1.3' and gradle-6.7-all.zip resulting in same crash issue

cmake_build_type does not include flavors

In cmake you have the following command:
add_custom_command( TARGET native-lib
POST_BUILD
COMMAND "${ANDROID_TOOLCHAIN_PREFIX}strip" -R .comment -g -S -d --strip-unneeded ${CMAKE_HOME_DIRECTORY}/../../../build/intermediates/cmake/${CMAKE_BUILD_TYPE}/obj/${ANDROID_ABI}/libnative-lib.so
COMMENT "Stripped native library")

And it uses ${CMAKE_BUILD_TYPE} to locate .so, but if project has flavors this will not be valid path
Is there any modification to include flavors?

can not find libnative-lib.so in /proc/self/maps , then crash

the source code ``` if ((fd = my_openat(AT_FDCWD, PROC_MAPS, O_RDONLY | O_CLOEXEC, 0)) != 0) {

    while ((read_one_line(fd, map, MAX_LINE)) > 0) {
        for (int i = 0; i < NUM_LIBS; i++) {
            if (my_strstr(map, libstocheck[i]) != NULL) {
                char tmp[MAX_LENGTH] = "";
                char path[MAX_LENGTH] = "";
                char buf[5] = "";
                sscanf(map, "%s %s %s %s %s %s", tmp, buf, tmp, tmp, tmp, path);
                if (buf[2] == 'x') {
                    size_t size = my_strlen(path) + 1;
                    filepaths[i] = malloc(size);
                    my_strlcpy(filepaths[i], path, size);
                    counter++;
                }
            }
        }
        if (counter == NUM_LIBS)
            break;
    }
    my_close(fd);
} ``` will show the different result on the same device.  

Crash on freeing a non null pointer on non-rooted devices when installed as AAB

Steps to reproduce:
  1. Set android app config to Deploy: APK from app bundle
  2. Run the app on non rooted device.
Issue:

char* filePaths[NUM_LIBS] is not set to null by default and on non-rooted devices, it s not getting filled with file path pointer. If the app is deployed from bundle, this variable gets filled with some random garbage address. Since we have only null check before freeing the memory, the code tries to free some random garbage address and crashes.

This works fine with rooted devices and if the app is deployed as apk on non-rooted devices

Solution:

Set a default null char to the array values like, char* filePaths[NUM_LIBS] = {'\0'};

build/intermediates/cmake/Debug/obj/armeabi-v7a/libnative-lib.so': No such file

Hi, would you be able to advise if these steps are correct for importing this library to another project?

I am doing the followings:

  1. Copy whole of c folder into main folder
  2. Comment out OLLVM library in CMake
  3. Update app/build.gradle
externalNativeBuild {
        cmake {
            path "src/main/c/CMakeLists.txt"
            version "3.10.2"
        }
    }
  1. Update root build.gradleto classpath 'com.android.tools.build:gradle:4.1.3'
  2. Update gradle-wrapper.properties to distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip
  3. Add System.loadLibrary("native-lib")

I did the above steps to different projects and below is my result

  • Clone of this repo project
  • Blank Kotlin project (All blank projects created from Android Studio Arctic Fox (2020.3.1))
  • Blank Java project
  • Existing Kotlin project
  • Blank Flutter project via native Kotlin code
  • Blank Flutter plugin project via dart:ffi

Not sure if you are able to help with this but I am having issues adding this library to Flutter projects

Gradle Error that I get:

Launching lib/main.dart on SM G920F in debug mode...
Running Gradle task 'assembleDebug'...

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':native_add:externalNativeBuildDebug'.
> Build command failed.
  Error while executing process /Users/nageek/Library/Android/sdk/cmake/3.10.2.4988404/bin/ninja with arguments {-C /Users/nageek/Documents/Workplace/native_add/android/.cxx/cmake/debug/armeabi-v7a native-lib}
  ninja: Entering directory `/Users/nageek/Documents/Workplace/native_add/android/.cxx/cmake/debug/armeabi-v7a'
  [1/1] Linking C shared library /Users/nageek/Documents/Workplace/native_add/example/build/native_add/intermediates/cmake/debug/obj/armeabi-v7a/libnative-lib.so
  FAILED: /Users/nageek/Documents/Workplace/native_add/example/build/native_add/intermediates/cmake/debug/obj/armeabi-v7a/libnative-lib.so 
  : && /Users/nageek/Library/Android/sdk/ndk/22.1.7171670/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang --target=armv7-none-linux-androideabi16 --gcc-toolchain=/Users/nageek/Library/Android/sdk/ndk/22.1.7171670/toolchains/llvm/prebuilt/darwin-x86_64 --sysroot=/Users/nageek/Library/Android/sdk/ndk/22.1.7171670/toolchains/llvm/prebuilt/darwin-x86_64/sysroot -fPIC -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -march=armv7-a -mthumb -Wformat -Werror=format-security  -O0 -fno-limit-debug-info  -Wl,--exclude-libs,libgcc.a -Wl,--exclude-libs,libgcc_real.a -Wl,--exclude-libs,libatomic.a -static-libstdc++ -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Wl,--exclude-libs,libunwind.a -Wl,--no-undefined -Qunused-arguments -shared -Wl,-soname,libnative-lib.so -o /Users/nageek/Documents/Workplace/native_add/example/build/native_add/intermediates/cmake/debug/obj/armeabi-v7a/libnative-lib.so CMakeFiles/native-lib.dir/native-lib.c.o  -llog -latomic -lm && cd /Users/nageek/Documents/Workplace/native_add/android/.cxx/cmake/debug/armeabi-v7a && /Users/nageek/Library/Android/sdk/ndk/22.1.7171670/toolchains/llvm/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-strip -R .comment -g -S -d --strip-unneeded /Users/nageek/Documents/Workplace/native_add/android/src/main/c/../../../build/intermediates/cmake/Debug/obj/armeabi-v7a/libnative-lib.so
  /Users/nageek/Library/Android/sdk/ndk/22.1.7171670/toolchains/llvm/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-strip: '/Users/nageek/Documents/Workplace/native_add/android/src/main/c/../../../build/intermediates/cmake/Debug/obj/armeabi-v7a/libnative-lib.so': No such file
  ninja: build stopped: subcommand failed.



* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 17s
Exception: Gradle task assembleDebug failed with exit code 1

Frida-Server is not running, but the memory manipulate log is recorded.

  • Target Devices
    • Android Emulator x86_x64 (Pixel 6 Pro API 33)
    • Samsung Galaxy S20+

The FRIDA server is not executed on the device, the memory manipulate log is recorded.

As shown in the attached source, the detect_frida_threads, detect_frida_namedpipe, and detect_frida_memdiskcompare functions have been modified to force the app to shut down when they return true.

What is the problem?

---------------------------- PROCESS STARTED (19228) for package com.example.detectfrida ----------------------------
2023-03-01 23:52:42.394 19228-19228 DetectFrida             com.example.detectfrida       V  Libc[101][8][0][3][10b][23]
2023-03-01 23:52:42.402 19228-19272 DetectFrida             com.example.detectfrida       V  Map [7727e12ac000-7727e12b1000 r-xp 00000000 fe:21 65604                      /data/app/~~3F80LSYqQUTByzlCxdzskA==/com.example.detectfrida-2XZELj6s20OVLUKaFcJzkQ==/lib/x86_64/libdetectfrida.so]
2023-03-01 23:52:42.402 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[33588][33588]
2023-03-01 23:52:42.402 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[1660554][1660554]
2023-03-01 23:52:42.402 19228-19272 DetectFrida             com.example.detectfrida       V  Map [7727e12b1000-7727e12b2000 r--p 00004000 fe:21 65604                      /data/app/~~3F80LSYqQUTByzlCxdzskA==/com.example.detectfrida-2XZELj6s20OVLUKaFcJzkQ==/lib/x86_64/libdetectfrida.so]
2023-03-01 23:52:42.403 19228-19272 DetectFrida             com.example.detectfrida       V  Map [7727e12b2000-7727e12b3000 rw-p 00005000 fe:21 65604                      /data/app/~~3F80LSYqQUTByzlCxdzskA==/com.example.detectfrida-2XZELj6s20OVLUKaFcJzkQ==/lib/x86_64/libdetectfrida.so]
2023-03-01 23:52:42.466 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a48d000-772b0a4d1000 r--p 00000000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.467 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4d1000-772b0a4e8000 r-xp 00043000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.468 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[58445356][58689518]
2023-03-01 23:52:42.468 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.468 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[944815][934687]
2023-03-01 23:52:42.468 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.468 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4e8000-772b0a4e9000 rwxp 0005a000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.470 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[24476903][58689518]
2023-03-01 23:52:42.470 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.470 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.470 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.470 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4e9000-772b0a4ec000 r-xp 0005b000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.471 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[24105621][58689518]
2023-03-01 23:52:42.471 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.471 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.471 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.471 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4ec000-772b0a4ed000 rwxp 0005e000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.472 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[22942464][58689518]
2023-03-01 23:52:42.472 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.473 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.473 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.473 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4ed000-772b0a4ee000 r-xp 0005f000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.474 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[22495429][58689518]
2023-03-01 23:52:42.474 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.474 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.474 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.478 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4ee000-772b0a4ef000 rwxp 00060000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.479 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[22070342][58689518]
2023-03-01 23:52:42.480 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.480 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.480 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.480 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4ef000-772b0a4f0000 r-xp 00061000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.482 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[21700838][58689518]
2023-03-01 23:52:42.482 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.483 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.483 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.483 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4f0000-772b0a4f1000 rwxp 00062000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.484 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[21337756][58689518]
2023-03-01 23:52:42.484 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.484 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.485 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.486 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4f1000-772b0a4fa000 r-xp 00063000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.487 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[21000140][58689518]
2023-03-01 23:52:42.488 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.488 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.489 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.490 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4fa000-772b0a4fb000 rwxp 0006c000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.491 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[17488954][58689518]
2023-03-01 23:52:42.491 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.492 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.492 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.492 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4fb000-772b0a544000 r-xp 0006d000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.493 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[17078986][58689518]
2023-03-01 23:52:42.493 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.494 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.494 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.494 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a544000-772b0a546000 rwxp 000b6000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.495 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][58689518]
2023-03-01 23:52:42.495 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.495 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.495 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.495 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a546000-772b0a54f000 r-xp 000b8000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.496 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][58689518]
2023-03-01 23:52:42.496 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.496 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.496 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.496 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a54f000-772b0a550000 rwxp 000c1000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.497 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][58689518]
2023-03-01 23:52:42.497 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.497 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.497 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.497 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a550000-772b0a55d000 r-xp 000c2000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.499 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][58689518]
2023-03-01 23:52:42.499 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.499 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.500 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.500 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a55d000-772b0a55e000 rwxp 000cf000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.502 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][58689518]
2023-03-01 23:52:42.503 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.503 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.503 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.503 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a55e000-772b0a564000 r-xp 000d0000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.504 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][58689518]
2023-03-01 23:52:42.504 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.504 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:42.504 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:42.504 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a564000-772b0a569000 r--p 000d5000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:42.504 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a569000-772b0a56a000 rw-p 000d9000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
---------------------------- PROCESS STARTED (19280) for package com.example.detectfrida ----------------------------
2023-03-01 23:52:42.849 19228-19228 PluginManager           com.example.detectfrida       D  startupPlugins: put - DetectFridaPlugin
2023-03-01 23:52:47.546 19228-19272 DetectFrida             com.example.detectfrida       V  Map [7727e12ac000-7727e12b1000 r-xp 00000000 fe:21 65604                      /data/app/~~3F80LSYqQUTByzlCxdzskA==/com.example.detectfrida-2XZELj6s20OVLUKaFcJzkQ==/lib/x86_64/libdetectfrida.so]
2023-03-01 23:52:47.546 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[33588][33588]
2023-03-01 23:52:47.546 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[1660554][1660554]
2023-03-01 23:52:47.546 19228-19272 DetectFrida             com.example.detectfrida       V  Map [7727e12b1000-7727e12b2000 r--p 00004000 fe:21 65604                      /data/app/~~3F80LSYqQUTByzlCxdzskA==/com.example.detectfrida-2XZELj6s20OVLUKaFcJzkQ==/lib/x86_64/libdetectfrida.so]
2023-03-01 23:52:47.547 19228-19272 DetectFrida             com.example.detectfrida       V  Map [7727e12b2000-7727e12b3000 rw-p 00005000 fe:21 65604                      /data/app/~~3F80LSYqQUTByzlCxdzskA==/com.example.detectfrida-2XZELj6s20OVLUKaFcJzkQ==/lib/x86_64/libdetectfrida.so]
2023-03-01 23:52:47.585 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a48d000-772b0a4d1000 r--p 00000000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.585 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4d1000-772b0a4e8000 r-xp 00043000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.585 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[58445356][58689518]
2023-03-01 23:52:47.586 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.586 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[944815][934687]
2023-03-01 23:52:47.586 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.586 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4e8000-772b0a4e9000 rwxp 0005a000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.587 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[24516589][58689518]
2023-03-01 23:52:47.587 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.587 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:47.587 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.587 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4e9000-772b0a4ec000 r-xp 0005b000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.588 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[24145250][58689518]
2023-03-01 23:52:47.588 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.588 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:47.588 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.589 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4ec000-772b0a4ed000 rwxp 0005e000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.589 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[22982093][58689518]
2023-03-01 23:52:47.590 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.590 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:47.590 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.590 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4ed000-772b0a4ee000 r-xp 0005f000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.590 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[22535058][58689518]
2023-03-01 23:52:47.591 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.591 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:47.591 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.591 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4ee000-772b0a4ef000 rwxp 00060000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.591 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[22109971][58689518]
2023-03-01 23:52:47.591 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.591 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:47.591 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.592 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4ef000-772b0a4f0000 r-xp 00061000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.592 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[21740467][58689518]
2023-03-01 23:52:47.592 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.592 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:47.593 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.593 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4f0000-772b0a4f1000 rwxp 00062000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.594 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[21377385][58689518]
2023-03-01 23:52:47.594 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.594 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:47.594 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.594 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4f1000-772b0a4fa000 r-xp 00063000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.595 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[21041255][58689518]
2023-03-01 23:52:47.595 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.595 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]
2023-03-01 23:52:47.595 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.596 19228-19272 DetectFrida             com.example.detectfrida       V  Map [772b0a4fa000-772b0a4fb000 rwxp 0006c000 07:48 21                         /apex/com.android.runtime/lib64/bionic/libc.so]
2023-03-01 23:52:47.597 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[17529477][58689518]
2023-03-01 23:52:47.597 19228-19272 DetectFrida             com.example.detectfrida       V  Executable Section Manipulated, maybe due to Frida or other hooking framework.Act Now!!!
2023-03-01 23:52:47.597 19228-19272 DetectFrida             com.example.detectfrida       V  Checksum:[0][934687]

How to add code app crash when frida is detected??

i just implement your code from github, just see this Log if app is running

V/DetectFrida: Libc[38][3e][3f][39][4e][65]

but i confuse how to implement if frida is detected then app crash / something else

Build Issue

FAILED: /Users/hariprasanth.ramesh/StudioProjects/DetectFrida/app/build/intermediates/cmake/debug/obj/arm64-v8a/libnative-lib.so
: && /Users/hariprasanth.ramesh/Library/Android/sdk/ndk/23.1.7779620/toolchains/llvm/prebuilt/darwin-x86_64/bin/clang --target=aarch64-none-linux-android21 --gcc-toolchain=/Users/hariprasanth.ramesh/Library/Android/sdk/ndk/23.1.7779620/toolchains/llvm/prebuilt/darwin-x86_64 --sysroot=/Users/hariprasanth.ramesh/Library/Android/sdk/ndk/23.1.7779620/toolchains/llvm/prebuilt/darwin-x86_64/sysroot -fPIC -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fno-limit-debug-info -static-libstdc++ -Wl,--build-id=sha1 -Wl,--no-rosegment -Wl,--fatal-warnings -Wl,--no-undefined -Qunused-arguments -shared -Wl,-soname,libnative-lib.so -o /Users/hariprasanth.ramesh/StudioProjects/DetectFrida/app/build/intermediates/cmake/debug/obj/arm64-v8a/libnative-lib.so CMakeFiles/native-lib.dir/native-lib.c.o -llog -latomic -lm && cd /Users/hariprasanth.ramesh/StudioProjects/DetectFrida/app/.cxx/cmake/debug/arm64-v8a && /Users/hariprasanth.ramesh/Library/Android/sdk/ndk/23.1.7779620/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android-strip -R .comment -g -S -d --strip-unneeded /Users/hariprasanth.ramesh/StudioProjects/DetectFrida/app/src/main/c/../../../build/intermediates/cmake/Debug/obj/arm64-v8a/libnative-lib.so
/bin/sh: /Users/hariprasanth.ramesh/Library/Android/sdk/ndk/23.1.7779620/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android-strip: No such file or directory
ninja: build stopped: subcommand failed.

How to check in Activity

How to check is app detected frida or not in mainactivity.
It will helpfull if you create native method and assign values if it is detect frida and use that in actvity,

Is the d-bus auth dance still relevant?

Hi

Lately I have been investigating and studying about reverse engineering on Android as well as possible mitigation tactics. I was wondering if the d-bus auth dance is still relevant with the latest versions of Frida.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.