mirror of
https://github.com/python/cpython.git
synced 2025-11-25 04:34:37 +00:00
In the test SSL server, also output the cipher name
This commit is contained in:
parent
6099a03202
commit
fb0901c968
1 changed files with 5 additions and 1 deletions
|
|
@ -94,7 +94,11 @@ class StatsRequestHandler(BaseHTTPRequestHandler):
|
|||
"""Serve a GET request."""
|
||||
sock = self.rfile.raw._sock
|
||||
context = sock.context
|
||||
body = pprint.pformat(context.session_stats())
|
||||
stats = {
|
||||
'session_cache': context.session_stats(),
|
||||
'cipher': sock.cipher(),
|
||||
}
|
||||
body = pprint.pformat(stats)
|
||||
body = body.encode('utf-8')
|
||||
self.send_response(200)
|
||||
self.send_header("Content-type", "text/plain; charset=utf-8")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue