Issue 10127: ssl.SSLSocket().close() does not close the connection (original) (raw)

Issue10127

Created on 2010-10-16 21:14 by r.david.murray, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Messages (3)
msg118896 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2010-10-16 21:14
Quoting PoltoS from issue 8293: If I do sock.close() (sock is instance of ssl.SSLSocket), the connection is not closed: I see it as Established in netstat and nothing is sent over network: tcpdump show nothing going thru the network.
msg118898 - (view) Author: PoltoS (PoltoS) Date: 2010-10-16 21:24
After some investigations it seems that a dup() is called in ssl wrap_socket(), so on sock.close() the socket is not really closed, since there is still one more reference (file descriptor) in the kernel's tcp/ip stack. Can someone confirm this? Have not done this, but it is possible to check my supposition using linux lsof command before and after .close().
msg118899 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2010-10-16 21:30
I cannot reproduce with 2.7, 3.1 or 3.2. It seems the issue is obsolete, many changes having been made to the ssl module since 2.6.
History
Date User Action Args
2022-04-11 14:57:07 admin set github: 54336
2010-10-18 11:40:37 pitrou set status: pending -> closed
2010-10-16 21:30:45 pitrou set status: open -> pendingresolution: out of datemessages: +
2010-10-16 21:24:50 PoltoS set messages: +
2010-10-16 21:14:32 r.david.murray create