From c654d5e777c0d1db75b5f3586bd20ce2ec4edadc Mon Sep 17 00:00:00 2001 From: Kali Kaneko Date: Mon, 5 Jan 2015 10:46:31 -0400 Subject: add raw sqlcipher query method --- client/src/leap/soledad/client/adbapi.py | 1 + client/src/leap/soledad/client/api.py | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/client/src/leap/soledad/client/adbapi.py b/client/src/leap/soledad/client/adbapi.py index 9ae2889e..f0b7f182 100644 --- a/client/src/leap/soledad/client/adbapi.py +++ b/client/src/leap/soledad/client/adbapi.py @@ -106,6 +106,7 @@ class U1DBConnection(adbapi.Connection): else: return getattr(self._connection, name) + class U1DBTransaction(adbapi.Transaction): """ A wrapper for a U1DB 'cursor' object. diff --git a/client/src/leap/soledad/client/api.py b/client/src/leap/soledad/client/api.py index 81bf1fd9..88bb4969 100644 --- a/client/src/leap/soledad/client/api.py +++ b/client/src/leap/soledad/client/api.py @@ -778,6 +778,16 @@ class Soledad(object): """ self._secrets.change_passphrase(new_passphrase) + # + # Raw SQLCIPHER Queries + # + + def raw_sqlcipher_query(self, *args, **kw): + """ + Run a raw sqlcipher query in the local database. + """ + return self._dbpool.runQuery(*args, **kw) + def _convert_to_unicode(content): """ -- cgit v1.2.3