From 3ffb3db7b629ea2dc84e0fcbef9f2b0725714bee Mon Sep 17 00:00:00 2001 From: bwarsaw <> Date: Fri, 31 Dec 2004 00:02:57 +0000 Subject: Secure_MakeRandomPassword(): Log an error when secure passwords were requested but urandom is not available. --- Mailman/Utils.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Mailman') diff --git a/Mailman/Utils.py b/Mailman/Utils.py index a6e07e10..18b1c468 100644 --- a/Mailman/Utils.py +++ b/Mailman/Utils.py @@ -325,6 +325,9 @@ def Secure_MakeRandomPassword(length): # We have no available source of cryptographically # secure random characters. Log an error and fallback # to the user friendly passwords. + from Mailman.Logging.Syslog import syslog + syslog('error', + 'urandom not available, passwords not secure') return UserFriendly_MakeRandomPassword(length) newbytes = os.read(fd, length - bytesread) bytes.append(newbytes) -- cgit v1.2.3