iPhone, authenticated email: a HOWTO

I got authenticated email with the iPhone working, with no help from the experts on the postfix-users list. Yes to password authentication, no to SSL, and TLS just worksâ„¢.

This means I can send email from my handheld thingie regardless of what network (WiFi) or cellular I am on and that the mail server is hardened against spammers using it as a relay.

It took a lot of monkey work at the console but the tools to use are testsaslauthd, openssl, and mmencode (or anything than generate Base64 encoded text).