How to telnet to a POP server that requires SSL

If you are anything like me, then every now and then you want to access a mail (POP3) server directly to sort out a problem without having a "helpful" email client get in the way. In these cases connecting to port 110 with telnet is the way to go.

But what about when the mail server has been set up to not allow plan-text connections (i.e. an SSL connection must be used)?


While you could use telnet to connect directly to port 995, the thought of attempting SSL key exchange using only the keyboard fills me with all kinds of dread, not to mention the work involved in doing the on-the-fly encryption and decryption of the data stream. [shiver]. No, telnet is a non-starter here.

Turns out there is an easy way. One of openssl's more obscure options (well, it was obscure to me) comes to the rescue.

openssl s_client -connect <server_name>:995

Using the above command will get openssl to setup a secure, interactive, SSL tunnel between your terminal and the server on port 995 (the port normally used for POP3+SSL).

Very useful.

Comments

Thanks a million!

Thanks a million!

Thanks!

This is GREAT to know!!!

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <i> <b> <br> <hr>
  • Lines and paragraphs break automatically.
  • Highlight terms in this textarea.

More information about formatting options

CAPTCHA
This question is used to make sure you are a human visitor and to prevent spam submissions. It is a five digit code, if you can't work it out you can try a different code by reloading the page.
Image CAPTCHA
Copy the characters (respecting upper/lower case) from the image.