I am in the process of writing an application that sends mail via an valid GMail user ID and password.
I just wanted to simulate the SMTP connection on my Windows XP
For OSX' terminal:
openssl s_client -connect smtp.gmail.com:25 -starttls smtp