Enable secure_delete and foreign_keys on the Sequoia key DB. sync
authorNeal H. Walfield <neal@pep.foundation>
Fri, 28 Dec 2018 12:47:31 +0100
branchsync
changeset 3213e56efa502f08
parent 3212 fb4124923112
child 3214 79dacdb24a4b
Enable secure_delete and foreign_keys on the Sequoia key DB.

- Secure delete is important since we are storing private keys.

- foreign keys is necessary since we are using foreign keys.
src/pgp_sequoia.c
     1.1 --- a/src/pgp_sequoia.c	Fri Dec 28 12:40:23 2018 +0100
     1.2 +++ b/src/pgp_sequoia.c	Fri Dec 28 12:47:31 2018 +0100
     1.3 @@ -107,6 +107,8 @@
     1.4                    sqlite3_errmsg(session->key_db));
     1.5  
     1.6      sqlite_result = sqlite3_exec(session->key_db,
     1.7 +                                 "PRAGMA secure_delete=true;\n"
     1.8 +                                 "PRAGMA foreign_keys=true;\n"
     1.9                                   "PRAGMA locking_mode=NORMAL;\n"
    1.10                                   "PRAGMA journal_mode=WAL;\n",
    1.11                                   NULL, NULL, NULL);