Mark Pazon
Mark Pazon

Reputation: 6205

Dexguard: Encrypting .so files without the Android application

Currently I have a simple android library. I am able to perform obfuscation with DexGuard. But now I want to use DexGuard's native library encryption feature without actually having an Android application. Is it possible to do this?

Upvotes: 1

Views: 1817

Answers (1)

Mark Pazon
Mark Pazon

Reputation: 6205

Found out the solution

-injars ./libhello-jni.zip
-injars ./myjar.jar
-encryptnativelibraries lib/**/*.so

Important points:

  • libhello-jni.zip should contain a lib folder containing the *.so files
  • Somewhere in the code in myjar.jar it should be using the class which calls the System.loadLibrary("hello-jni") so DexGuard can successfully encrypt the *.so files

Upvotes: 3

Related Questions