File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -1500,6 +1500,29 @@ def set_cipher_list(self, cipher_list: bytes) -> None:
1500
1500
],
1501
1501
)
1502
1502
1503
+
1504
+ @_require_not_used
1505
+ def set_ciphersuites_list (self , ciphersuites_list : bytes ) -> None :
1506
+ """
1507
+ Set the list of TLS 1.3 ciphers to be used in this context.
1508
+ OpenSSL maintains a separate list of TLS 1.3+ ciphers to
1509
+ ciphers for TLS 1.2 and lowers.
1510
+
1511
+ See the OpenSSL manual for more information (e.g.
1512
+ :manpage:`ciphers(1)`).
1513
+
1514
+ :param bytes cipher_list: An OpenSSL cipher string.
1515
+ :return: None
1516
+ """
1517
+ cipher_list = _text_to_bytes_and_warn ("ciphersuites_list" , cipher_list )
1518
+
1519
+ if not isinstance (cipher_list , bytes ):
1520
+ raise TypeError ("cipher_list must be a byte string." )
1521
+
1522
+ _openssl_assert (
1523
+ _lib .SSL_CTX_set_ciphersuites (self ._context , cipher_list ) == 1
1524
+ )
1525
+
1503
1526
@_require_not_used
1504
1527
def set_client_ca_list (
1505
1528
self , certificate_authorities : Sequence [X509Name ]
You can’t perform that action at this time.
0 commit comments