summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--client/src/leap/soledad/client/_database/blobs.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/client/src/leap/soledad/client/_database/blobs.py b/client/src/leap/soledad/client/_database/blobs.py
index 91914380..de0b2d08 100644
--- a/client/src/leap/soledad/client/_database/blobs.py
+++ b/client/src/leap/soledad/client/_database/blobs.py
@@ -20,6 +20,7 @@ Clientside BlobBackend Storage.
from urlparse import urljoin
+import binascii
import errno
import os
import base64
@@ -297,7 +298,9 @@ class SQLiteBlobBackend(object):
if not key:
raise ValueError('key cannot be None')
backend = 'pysqlcipher.dbapi2'
- opts = sqlcipher.SQLCipherOptions('/tmp/ignored', key)
+ opts = sqlcipher.SQLCipherOptions(
+ '/tmp/ignored', binascii.b2a_hex(key),
+ is_raw_key=True, create=True)
pragmafun = partial(pragmas.set_init_pragmas, opts=opts)
openfun = _sqlcipherInitFactory(pragmafun)