Browse files

patch from sugarc0de to call Random.atfork() when starting up, so par…

…amiko can be used in multiprocess code
  • Loading branch information...
1 parent 2260854 commit 5d9eeaedccd6321d182881b26961bbc8198e0aa9 Robey Pointer committed May 22, 2011
Showing with 2 additions and 5 deletions.
  1. +2 −5 paramiko/
@@ -45,11 +45,7 @@
from paramiko.sftp_client import SFTPClient
from paramiko.ssh_exception import SSHException, BadAuthenticationType, ChannelException
-# these come from PyCrypt
-# i believe this on the standards track.
-# PyCrypt compiled for Win32 can be downloaded from the HashTar homepage:
+from Crypto import Random
from Crypto.Cipher import Blowfish, AES, DES3, ARC4
from Crypto.Hash import SHA, MD5
@@ -456,6 +452,7 @@ def start_client(self, event=None):
# synchronous, wait for a result
self.completion_event = event = threading.Event()
+ Random.atfork()
while True:
if not

0 comments on commit 5d9eeae

Please sign in to comment.