The -r flag tells stunnel to redirect all traffic to address 127.0.0.1 port 143. Stunnel can be applied to many situations of this type. It can be applied to an IMAP server that doesn't support SSL, or even a news server. We'll not dig any further into the features. Instead, you're encouraged to look at the product documentation and the FAQ .
Final Thoughts Implementing TLS within a network is never easy.
From the technical skills and assets to the soft skills, the hurdles are many. Organization, tact, and a good plan for implementation are the keys to a successful transition. Of the mail retrieval protocols, picking the one best suited for your needs requires planning and evaluation of your surroundings. In a structured environment where all the clients are company employees, it's easy to plan for a group of users that will likely be using the same Mail User Agents. In a less structured environment where the client is a user that could be using any MUA, this problem is not as easily solved.