summaryrefslogtreecommitdiffhomepage
path: root/tests/test_util.py
diff options
context:
space:
mode:
authorJeff Forcier <jeff@bitprophet.org>2014-04-14 10:49:13 -0400
committerJeff Forcier <jeff@bitprophet.org>2014-04-14 10:49:54 -0400
commit59a696cef2639b65adbf47321171bbfea98f7df0 (patch)
treeaf35c0e1234d2f61d3f606bc2799c7d6cc27b3ac /tests/test_util.py
parentd31373f0efac2976af80380e16136c1a7831b6a7 (diff)
parent160e2c08e0b7652a92d879c0e481ce72cddafef7 (diff)
Merge branch '295-int'
Diffstat (limited to 'tests/test_util.py')
-rw-r--r--tests/test_util.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/test_util.py b/tests/test_util.py
index 6bde4045..af6eceb5 100644
--- a/tests/test_util.py
+++ b/tests/test_util.py
@@ -23,7 +23,8 @@ Some unit tests for utility functions.
from binascii import hexlify
import errno
import os
-from Crypto.Hash import SHA
+from hashlib import sha1
+
import paramiko.util
from paramiko.util import lookup_ssh_host_config as host_config
from paramiko.py3compat import StringIO, byte_ord
@@ -136,7 +137,7 @@ class UtilTest(ParamikoTest):
)
def test_4_generate_key_bytes(self):
- x = paramiko.util.generate_key_bytes(SHA, b'ABCDEFGH', 'This is my secret passphrase.', 64)
+ x = paramiko.util.generate_key_bytes(sha1, b'ABCDEFGH', 'This is my secret passphrase.', 64)
hex = ''.join(['%02x' % byte_ord(c) for c in x])
self.assertEqual(hex, '9110e2f6793b69363e58173e9436b13a5a4b339005741d5c680e505f57d871347b4239f14fb5c46e857d5e100424873ba849ac699cea98d729e57b3e84378e8b')