OK - Google confiig is based on the page:
http://asimag.wordpress.com/2007/06/22/how-to-configure-gmail-account-on-your-n95n73/
For .mac - its pretty similar:
Personal server (debian etch):
This is talking to a courier imap with ssl (OpenSSL) and exim4 (GnuTLS)
The settings are all the same as above (replace user, pass and host etc as needed).
For secure IMAP or POP3 - just choose SSL/TLS. Self-generated certificate gives a warning on the phone but you can choose to continue.
NOTE: At present the n95 refuses to talk SSMTP to the exim4 server. Doesn't matter if I use StartTLS, SSL/TLS and whatever port. It just gives a long long wait at Connecting to mailbox 'mailbox name' followed by a General - Operation timed out error message.
I wonder if this is like the SonyEricsson p990i that could talk OpenSSL but not GnuTLS. But nothing is logged on the server at all :(