MERGE: Closes #15793: Stack corruption in ssl.RAND_egd()

This commit is contained in:
Jesus Cea 2012-09-11 02:08:48 +02:00
commit b7a2800831
3 changed files with 6 additions and 7 deletions

View file

@ -125,12 +125,8 @@ class BasicSocketTests(unittest.TestCase):
else:
self.assertRaises(ssl.SSLError, ssl.RAND_bytes, 16)
try:
ssl.RAND_egd(1)
except TypeError:
pass
else:
print("didn't raise TypeError")
self.assertRaises(TypeError, ssl.RAND_egd, 1)
self.assertRaises(TypeError, ssl.RAND_egd, 'foo', 1)
ssl.RAND_add("this is a random string", 75.0)
def test_parse_cert(self):