SQLCipher主要API
PRAGMA key
Example 1: Passphrase with Key Derivation
sqlite> PRAGMAkey = 'passphrase';
Example 2: Raw Key Data (Without KeyDerivation)
sqlite> PRAGMA key = "x'2DD29CA851E7B56E4697B0E1F08507293D761A05CE4D1B628663F411A8086D99'";
PRAGMA cipher
sqlite> PRAGMA key = 'blue valentines';
sqlite> PRAGMA cipher = 'aes-256-cfb';
PRAGMA kdf_iter
sqlite> PRAGMA key = 'blue valentines';
sqlite> PRAGMA kdf_iter = '10000';
PRAGMA cipher_default_kdf_iter
./sqlcipher sqlcipher2.0.db
sqlite> PRAGMA cipher_default_kdf_iter = 4000;
sqlite> PRAGMA key = 's3cr37';
PRAGMA cipher_page_size
sqlite> PRAGMA KEY = 'testkey';
sqlite> PRAGMA cipher_page_size = 4096;
PRAGMA cipher_default_page_size
$ ./sqlcipher foo.db
sqlite> PRAGMA key = 'foo';
sqlite> PRAGMA cipher_page_size = 4096;
sqlite> CREATE TABLE t1(a,b);
sqlite> INSERT INTO t1(a,b) values('one for the money', 'two for the show');
sqlite> .q
$ ./sqlcipher bar.db
sqlite> PRAGMA ciphe