summaryrefslogtreecommitdiff
path: root/backends/leap.py
diff options
context:
space:
mode:
Diffstat (limited to 'backends/leap.py')
-rw-r--r--backends/leap.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/backends/leap.py b/backends/leap.py
index c019ed3f..9fbd49fe 100644
--- a/backends/leap.py
+++ b/backends/leap.py
@@ -37,7 +37,7 @@ class LeapDocument(Document):
"""
if not self._soledad:
raise NoSoledadInstance()
- ciphertext = self._soledad.encrypt_symmetric(self.get_json())
+ ciphertext = self._soledad.encrypt_symmetric(self.doc_id, self.get_json())
return json.dumps({'_encrypted_json' : ciphertext})
def set_encrypted_json(self, encrypted_json):
@@ -47,7 +47,7 @@ class LeapDocument(Document):
if not self._soledad:
raise NoSoledadInstance()
ciphertext = json.loads(encrypted_json)['_encrypted_json']
- plaintext = self._soledad.decrypt_symmetric(ciphertext)
+ plaintext = self._soledad.decrypt_symmetric(self.doc_id, ciphertext)
return self.set_json(plaintext)