From d28e6eb598849cd4baec799166d08ef0f732a58b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?poljar=20=28Damir=20Jeli=C4=87=29?= Date: Sat, 24 Mar 2018 20:14:46 +0100 Subject: [PATCH] encryption: Add encrypt_enabled decorator to some functions. --- matrix/server.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/matrix/server.py b/matrix/server.py index 4d03480..eadf9b5 100644 --- a/matrix/server.py +++ b/matrix/server.py @@ -150,6 +150,7 @@ class MatrixServer: prefix=W.prefix("error"), error=error) W.prnt("", message) + @encrypt_enabled def create_olm(self): message = ("{prefix}matrix: Creating new Olm identity for " "{self_color}{user}{ncolor}" @@ -165,6 +166,7 @@ class MatrixServer: W.prnt(self.server_buffer, message) self.olm = Olm() + @encrypt_enabled def store_olm(self): self.olm.to_session_dir(self) @@ -461,6 +463,7 @@ class MatrixServer: message = MatrixSyncMessage(self.client, self.next_batch, limit) self.send_queue.append(message) + @encrypt_enabled def upload_keys(self, device_keys=False, one_time_keys=False): keys = self.olm.account.identity_keys() if device_keys else None