From 001dc1edaa4c5306fbb7c625202788458dadeafa Mon Sep 17 00:00:00 2001 From: J08nY Date: Sun, 2 Apr 2017 00:35:55 +0200 Subject: Python: Switch to a more general os.urandom for randomness source Signed-off-by: Jan Jancar --- python/olm/outbound_group_session.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'python/olm/outbound_group_session.py') diff --git a/python/olm/outbound_group_session.py b/python/olm/outbound_group_session.py index 56f0962..e888f41 100644 --- a/python/olm/outbound_group_session.py +++ b/python/olm/outbound_group_session.py @@ -1,4 +1,5 @@ import json +from os import urandom from ._base import * @@ -56,7 +57,7 @@ class OutboundGroupSession(object): self.ptr = lib.olm_outbound_group_session(self.buf) random_length = lib.olm_init_outbound_group_session_random_length(self.ptr) - random = read_random(random_length) + random = urandom(random_length) random_buffer = create_string_buffer(random) lib.olm_init_outbound_group_session(self.ptr, random_buffer, random_length) -- cgit v1.2.3