Add a function for authentication in SMTP connection

A think this is useful and esencial function.