4

I have integrated dexguard in my android application. Everything is working fine.

I have also encrypted the native libraries using dexguard. The problem here is when I apply dexguard it takes few seconds to load the native library whereas without dexguard it loads immediately. If I remove -encryptnativelibraries from the dexguard properties file, then it loads immediately.

I guess decrytping the .so file in run-time is taking few seconds? Or should it not take this long?

JoshDM
  • 4,939
  • 7
  • 43
  • 72
Pavani Reddy
  • 81
  • 1
  • 6
  • 1
    if you are doing something `extra` than obviously it will take more time than usual. bdw *what is your issue now?* be clear on stackoverflow. please read [how to ask](http://stackoverflow.com/questions/how-to-ask) – Maveňツ May 14 '15 at 11:06
  • System.loadLibrary("sample") loads so file. This doesnot usually take time. But When I encrypt so file with dexguard and load the library it is taking around 10seconds. So I had to take extra care of putting progress bar. My question here is that this time delay is an expected one??? Or Am I doing something wrong? – Pavani Reddy May 14 '15 at 11:57
  • Are you testing on `Device` or `Emulator` ? – Maveňツ May 14 '15 at 12:02
  • 10 seconds is too long then – Maveňツ May 14 '15 at 12:28
  • What should I do about it? – Pavani Reddy May 14 '15 at 12:51
  • make a async task and load the lib in background. – Maveňツ May 14 '15 at 13:12
  • @PavaniReddy Hi, Now I am also facing that issue. How can we solve the issue ? Did you get solution for that ? – Finder Jul 15 '15 at 10:38
  • @KarthickRamu No I dont have solution for this problem. Dexguard needs to decrypt the encrypted libraries when they are loaded. So it will indeed take some time. – Pavani Reddy Jul 16 '15 at 08:54
  • A lot is going to depend on the hardware and how much support for encryption it has. Hardware decryption can be 1000 times slower in software than in top-of-the-line hardware encryption on a phone. Keep in mind users that have older/cheaper phones. – zaph Jun 03 '16 at 21:49

1 Answers1

2

Old versions of DexGuard did the loading of encrypted native libraries in a quite inefficient way. More recent versions 7.1.20+ improved the performance of the decryption and loading and you should not notice much difference anymore compared to an unencrypted library.

T. Neidhart
  • 6,060
  • 2
  • 15
  • 38