Hello,
We are getting some link failures on loading the sqcipher library on certain Android devices.
Fatal Exception: java.lang.UnsatisfiedLinkError
dlopen failed: empty/missing DT_HASH/DT_GNU_HASH in “/data/app/com.hp.pregnancy.lite-T4vhugp-5yTTpV9SuAiY5g==/lib/arm/libsqlcipher.so” (new hash type from the future?)
The Android versions are 8.10 and 9 and the devices are Moto G (5h Gen), Moto G(5S) and Samsung Galaxy J3(2017)
We are using the community edition with the following in build.gradle
implementation ‘net.zetetic:android-database-sqlcipher:4.4.0@aar’
implementation “androidx.sqlite:sqlite:2.0.1”
Imports are:
import net.sqlcipher.database.SQLiteDatabase;
import net.sqlcipher.database.SQLiteStatement
And I am loading the library with SQLiteDatabase.loadLibs(context)
Is there something Im missing?
Thank you.
Hello @Martin13,
Thanks for reaching out, I’m sorry to hear you are experiencing an issue with the latest release of the library. We are currently tracking this issue. Do you have possession any of the devices that are reporting the crashing behavior to test? It sounds as if your organization relies of SQLCipher for Android as a security component. We make prerelease builds available to customers who license the software directly, if this is something you are interested please feel free to reach out at support@zetetic.net. Thanks!
Thank you for getting back to me
We have two different problems at the moment, one is the error above and one is a crash deep inside the libsqlcipher.so library. Both of these are reported via Firebase Crashlytics from some of our users. We have a device that reproduces the second native crash but not the error above. This crash mostly affects Android 5 LG devices but also has some crashes on Android 9 and 10. Unfortunately I don’t have symbols for the native library so cannot tell where the crash is. Is there a way to get the unstripped version of the library, Firebase can then match up the symbols. I was intending to try to build the library from source and run it on the crashing device before reporting the second error.
Hi @Martin13
We have instructions for building SQLCipher for Android here. We look forward to hearing any additional information you are able to identify. Thanks!
@Martin13 @developernotes How frequent is the issue being reported ? It would help to link known-issues to the Release notes, it would help teams decide which version to upgrade to.
Hello @rsarma, @Martin13,
I apologize for the delayed response, I wanted to circle back to your request regarding a mechanism to review known issues within the library. We have been discussing this idea internally and feel that publicizing a repository of known issues would be a good addition. Unfortunately, our libraries often receive issue reports from users who report incorrect defects due to various incorrect utilization behaviors on their part. To move forward, we are reviewing the acceptance criteria for an issue to be quantified as a known issue. Additionally, we are putting together the details for communicating known issues to all users. We will provide an update once we have additional information to share regarding this.
1 Like
I’m having the similar error when running the 4.4.0 version of the SQLCipher SDK. Below is the crash log.
java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file “/data/app/-pUf57HFS_FYnkew1bJHXpg==/base.apk”],nativeLibraryDirectories=[/data/app/-pUf57HFS_FYnkew1bJHXpg==/lib/x86, /data/app/-pUf57HFS_FYnkew1bJHXpg==/base.apk!/lib/x86, /system/lib, /system/product/lib]]] couldn’t find “libsqlcipher.so”
at java.lang.Runtime.loadLibrary0(Runtime.java:1067)
at java.lang.Runtime.loadLibrary0(Runtime.java:1007)
at java.lang.System.loadLibrary(System.java:1667)
at net.sqlcipher.database.SQLiteDatabase$1.loadLibraries(SQLiteDatabase.java:227)
at net.sqlcipher.database.SQLiteDatabase.loadLibs(SQLiteDatabase.java:244)
at net.sqlcipher.database.SQLiteDatabase.loadLibs(SQLiteDatabase.java:223)
at net.sqlcipher.database.SQLiteDatabase.loadLibs(SQLiteDatabase.java:216)
If I downgrade to 4.3.0, there is no crash.
1 Like
Hi @Deepak_Unnikrishnan
Is it possibly you are excluding the x86 ABI from your build by chance? The 4.4.0 AAR does include the x86 variant of libsqlcipher.so:
No. We are not excluding the x86 ABI.
Hi @Deepak_Unnikrishnan
Can you try running the SQLCipher for Android test suite on the same device to see if the tests will run without issue?