From 4428c9b929d266915ece2c5a13f41dfe9fa7b641 Mon Sep 17 00:00:00 2001 From: "Nathaniel J. Smith" Date: Tue, 26 Oct 2021 20:39:43 -0700 Subject: [PATCH] get_cleartext_mtu doesn't exist on decrepit old openssl --- tests/test_ssl.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tests/test_ssl.py b/tests/test_ssl.py index 7e99802dd..3338e687f 100644 --- a/tests/test_ssl.py +++ b/tests/test_ssl.py @@ -4274,6 +4274,12 @@ def c_handler(): # Check that the MTU set/query functions are doing *something* c.set_ciphertext_mtu(1000) - assert 500 < c.get_cleartext_mtu() < 1000 + try: + assert 500 < c.get_cleartext_mtu() < 1000 + except NotImplementedError: # OpenSSL 1.1.0 and earlier + pass c.set_ciphertext_mtu(500) - assert 0 < c.get_cleartext_mtu() < 500 + try: + assert 0 < c.get_cleartext_mtu() < 500 + except NotImplementedError: # OpenSSL 1.1.0 and earlier + pass