Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Probe of dynamically discovered method does not work #78

Open
cryptax opened this issue Jan 24, 2023 · 0 comments
Open

Probe of dynamically discovered method does not work #78

cryptax opened this issue Jan 24, 2023 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@cryptax
Copy link
Contributor

cryptax commented Jan 24, 2023

I wish to hook a method which is from a dynamically loaded DEX (packing). Dexcalibur does manage to see the class & methods, and I am able to click on "Probe ON", but then when the sample is spawned the hook never gets called although the method does get called. I suspect the hook is not quite written correctly and does not hook correctly.

To reproduce / to understand

  • Use a packed sample. For example SHA256 8a7309366917e05c348caf79d4f29f60878958baff794f07c12f08dadcb186fa. Beware, this is a malicious sample of Android/Xenonorph.
  • In static analysis, seach for class("name:org.securitypolicies.setup.utilities"), search for UtilGlobal class, and select Probe ON for method Log
  • In hook, make sure this Log method is mentioned as a custom hook and spawn the malware

In the log lines, there will be no call from that UtilGlobal.Log, though the method does get called. For example, with another tool House I am able to hook that very method and get plenty of hits.

Screenshots
UtilGlobal.Log is Probe ON
UtilGlobal.Log is Probe ON

There is no hit for UtilGlobal.Log when the malware is spawned with Dexcalibur
There is no hit for UtilGlobal.Log when the malware is spawned with Dexcalibur

With House, we see plenty of hits for the same malware & hook
With House, we see plenty of hits for the same malware & hook

Desktop (please complete the following information):

  • OS: Docker container here cryptax/dexcalibur:2023.01
  • Node JS version: 19.4.0
  • Dexcalibur version (see 'package.json' or output) : 0.7.10
  • Frida 16.0.8
  • Android version: emulator Android 10 x86_64
  • Rooted
@cryptax cryptax added the bug Something isn't working label Jan 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants