Questions tagged [sqlcipher]

SQLCipher is an open source extension to SQLite that provides transparent 256-bit AES encryption of database files.

SQLCipher is an open source extension to SQLite that provides transparent 256-bit AES encryption of database files. SQLCipher has a small footprint and great performance so it’s ideal for protecting embedded application databases and is well suited for mobile development.

  • Blazing fast performance with as little as 5-15% overhead for encryption
  • 100% of data in the database file is encrypted
  • Uses good security practices (CBC mode, key derivation)
  • Zero-configuration and application level cryptography
  • Broad platform support: works with C/C++, Obj-C, QT, Win32/.NET, Java, Python, Ruby, Linux, iPhone/iOS and Android
  • Algorithms provided by the peer reviewed OpenSSL crypto library.

Useful Links

591 questions
4
votes
0 answers

Android SQCipher do I need to close the database?

I've read a lot about using a standard SQLiteDatabase in android and it seems that the best way is to keep one instance of SQLiteOpenHelper and never close the returned SQLiteDatabase object, nor SQLiteOpenHelper. The question is whether those…
kmalmur
  • 2,809
  • 3
  • 29
  • 37
4
votes
2 answers

sqlcipher crashing with "not an error" stacktrace

I am trying to use the sqlcipher (2.0.8) in my project for API 16 (Motorola Xoom 4.1.2) and getting the following stacktrace. I have the 3 so libraries in armeabi folder in libs and icudt46l.zip in the assets folder. I have…
Win Myo Htet
  • 5,377
  • 3
  • 38
  • 56
4
votes
2 answers

sqlcipher ./configuration linux

I want to cross-compile SQL-Cipher with OpenSSL for my Raspberry Pi. I'm using the crosstool-ng as compiler toolchain. ./configure --enable-tempstore=yes CFLAGS="-DSQLITE_HAS_CODEC" LDFLAGS="/home/USER1/openssl-1.0.1c/libcrypto.a" gives me…
3
votes
1 answer

How to read an encrypted database created previously on pc with sqlcipher on android?

I'm trying to read an encrypted database created with sqlcipher on my PC but I can't read it on my app. For example: Cursor c = database.rawQuery("SELECT name FROM sqlite_master WHERE type='table'", null); c.moveToFirst(); do { …
aanm
  • 41
  • 4
3
votes
1 answer

Compressing Encrypted SQLite FTS3 Database for iOS

My app uses a SQLite database with FTS3 to do product search. I am trying to encrypt the database using SQLCipher but it causes the database size to balloon (7mb --> ~20mb). It doesn't look like there is a great way to compress an encrypted FTS…
Rangers4me
  • 177
  • 2
  • 9
3
votes
1 answer

NoSuchFieldError while using SqlCipher with ProGuard in Android app

Due to security reasons one of the requirement is to encrypt the SQLite database. Hence, i had to use SQLCupher. The application work as expected as long as i do not enable Obfuscation using minifyEnabled true. As soon as i set minifyEnabled true, i…
Zax
  • 2,870
  • 7
  • 52
  • 76
3
votes
2 answers

Xcode build error - "Implicit declaration of function ‘sqlite3_key’ is invalid in C99"

I am modularising a large iOS app lets say, MyAppWithDatabase into two modules (i.e. projects). So I will have one main project MyApp as a host and a linked MyDataPlatform as a framework under same workspace MyApp.xcworkspace. When SQLCipher pod was…
Sazzad Hissain Khan
  • 37,929
  • 33
  • 189
  • 256
3
votes
1 answer

Android custom migration Sqlcipher from 3 to 4

I upgraded Sqlcipher for Android from 3.5.7 to 4.1.3 in my app. For the existing database, which has been created with Sqlcipher 3, I need a custom migration as it is based on custom parameters, as also the option 3 of this article explains. I'm…
Gigi
  • 359
  • 2
  • 16
3
votes
1 answer

Deadlock when closing sqlite database

I'm investigating occassinal ANR in my project. It happens when there are a lot of requests to database in the background, user clicks button and database is being closed as a part of logout. I'm using saferoom and rx-java2. Here is some code from…
mol
  • 2,607
  • 4
  • 21
  • 40
3
votes
1 answer

SQLCipher with Room Persistence Library exception in SQLCipherUtils.getDatabaseState

I have a Room database in my Android app, and in my AppClass, I have some logic that checks the database encryption state in order to handle some potential encryption operations that might need to be performed on the database. However, whenever I…
oaky_afterbirth
  • 125
  • 3
  • 15
3
votes
1 answer

How to use SQLCipher in .Net

I want to use C# (winform) to read an SQLCipher database and find an open source project SQLitePCL, but I have not found examples of this use, and the documentation is not a lot. Have any friends used this thing, can you provide some examples to…
桑榆肖物
  • 73
  • 2
  • 8
3
votes
0 answers

Custom Migration - Encrypted Core Data - iOS

Does EncryptedCoreData support changing the Entity Attribute Type and thus can it successfully do custom migrations in iOS? I have installed pod EncryptedCoreData for a swift iOS project and I am able to encrypt the sqldatabase file. I can also do…
Ganesh Nayak
  • 802
  • 11
  • 38
3
votes
2 answers

Android 7.0 Native crashes due to sqlcipher library and NDK restrictions

I'm receiving following crash on Android 7.0 Samsung S8 and many other such native crashes: backtrace: #00 pc 000000000005da7c /system/lib64/libbinder.so (_ZN7android6Parcel14freeDataNoInitEv+16) #01 pc 00000000000f8538 …
3
votes
0 answers

How to properly add custom database support to Laravel 5?

Suppose you want to add custom database support in Laravel 5. Whether it is MongoDB, Oracle or sqlite mod (SQLCipher). How would you go about it? What I'm looking for is proper, elegant solution. Without core-hacking, which is easy to do, but would…
Svyatoslav
  • 121
  • 1
  • 5
3
votes
2 answers

sqlcipher stopped working in iOS 10

I have use Sqlite (sqlcipher) in my iOS project for database. In iOS 9 all things are working perfectly. Now i have update new Xcode. But DB encryption is not working now. sqlite3 *db1; if (sqlite3_open([[self.databaseURL path] UTF8String],…
Nirav Patel
  • 113
  • 1
  • 5