> On 7 Nov 2019, at 03:24, Veek M <v...@dont-use-this.com> wrote: > > Could someone suggest some introductory reading material that will allow > me to use 'telnetlib' with 'ssl' or 'ssltelnet'. > (currently using Pan since Knode is dropped on Debian) > > I'm trying to write something that will download the NNTP headers over > TLS. > > The idea is to > 1. telnet to port 119, send 'CAPABILITIES\r\n' using telnetlib > 2. then switch to TLS using STARTTLS > 3. I tried just connecting to port 119 using a new TLS connection NOT > OVER telnet and it didn't work. Apparently you need to pass the TLS > context to telnetlib or vice versa. > ... Any reason you're not using nntplib from the Python Standard Library? It supports the STARTTLS command. If you don't want to use nntplib you could look at its code to see how it works. -- Colin -- https://mail.python.org/mailman/listinfo/python-list
Re: SSL/TLS in Python using STARTTLS and ssl/ssltelnet and telnetlib
Colin McPhail via Python-list Thu, 07 Nov 2019 02:22:10 -0800
- SSL/TLS in Python using STARTTLS and ssl/ssl... Veek M
- Re: SSL/TLS in Python using STARTTLS an... Colin McPhail via Python-list
- Re: SSL/TLS in Python using STARTTLS an... Jon Ribbens via Python-list
- Re: SSL/TLS in Python using STARTTL... Grant Edwards