My recent move to a new employer meant that the ports I needed to get my IMAP mail over SSL were not open on the firewall. The first 4 to 5 weeks this was awesome because there was no checking personal email. This dramatically cut me off from people asking 'How's the new job going?' and set me away from the rss feeds that were wasting so much of my time.
However, as time went by I realized that newsgroups and those rss feeds and even those people asking how the new job was going were necessary to sanity survival. I decided to try to get my email client working.
I failed miserably. Then I talked to Schmonz. What follows are the results, not of our conversation... but, of my shutting up and just doing what he said.
Get Your Putty - Putty is a great windows client for ssh. I suppose it does other stuff too, but I tend to use it to VI my HTML dreams over to a web server. I googled putty and found this link for download. http://www.chiark.greenend.org.uk/~sgtatham/putty/ is the link that you need to get to the page to download the file. Under the section 'Site Map' look for 'Download PuTTY'. Then Then click the exe you need, most likely the old putty.exe right at the top under the For Windows Versions (most). Download and run it.
Are you used to sshing? Can you ssh to a machine somewhere? Let's find that out first. Open Putty. If it asks you any weird stuff just say yes. Tell them your Ol' Uncle DavidJ said it was okay. With Putty open you will see the main configuration screen.

Click on the SSH option on the right and watch the port change to 22. Then put the name of the server you ssh to in there and click open. You may be asked to add it to your key thing, take the Uncle DavidJ tip and do it. Then make sure your username and password get you through.
If you can't do this, you are out of luck, bud. Google Hard.
But if you can! Woot! Now we just need to set up your port forward options!
Set the Port Forward Options - To set the port forward options in Putty, open Putty, and instead of that main configuration screen go down to SSH and then click tunnel. Here you are going to add the two ports that you need.
According to Thunderbird, this is the port I need for IMAP:
Notice that I changed the server name to localhost! This
is what makes the port forwarding work. You use whatever port you use. I have a somewhat non-standard configuration.
So back in Putty, I put this in:
In the source port, I put 993. This is the localhost one. In the destination port I put mail.davidj.org:993 and then I clicked add. That put the entry up there for me.
According to Thunderbird, this is the port I need for SMTP over SSL:

Make sure you use whichever one you think you should be using, probably based on earlier settings.
So back in Putty, I put in port 465. Notice again the server name of localhost.
That is all the configuration I need to make this work for me. Let's start with everything closed. First I open putty, and then I go to the saved session that I call mail.davidj.org and open it. Then I put in my username and password and the session starts. I minimize it and leave it alone.
Now that that is running, I open up Thunderbird. With the settings I put in, Thunderbird checks the localhost for ports 465 and 993. Putty forwards that to the mail.davidj.org ports 465 and 993 over port 22 and returns the information back to Thunderbird.
The good news is that this is just enough hassle that I probably only check email once a day anyway. Hope it helped