New submission from Steffen Ullrich <>:

The current implementation of shared_ciphers uses the SSL_get_ciphers method. 
This method returns the list of configured ciphers (i.e. from the context) and 
not the list of ciphers shared between client and server. 

To get this list one can use the documented SSL_get_client_ciphers for OpenSSL 
>= 1.1.0, access ssl->sessions->ciphers directly or parse the result from the 
undocumented SSL_get_shared_ciphers for older versions of OpenSSL.

See also

messages: 311940
nosy: noxxi
priority: normal
severity: normal
status: open
title: SSL shared_ciphers implementation wrong - returns configured but not 
shared ciphers
type: behavior
versions: Python 3.5, Python 3.6, Python 3.7, Python 3.8

Python tracker <>
Python-bugs-list mailing list

Reply via email to