So instead of telnet, here you use:
openssl s_client -host pop.example.com -port 995For the STARTTLS variant:
openssl s_client -starttls pop3 -host pop.example.com -port 110
There you get the same prompt a telnet connection to plain 110 port would give you but running over a secure connection. BTW same technique can be used as well for SMTP, IMAP, HTTP or other connection you're testing on the command line. Nice and easy, no?