To get sendmail to relay thru a smarthost that requires authentication, in /etc/mail/sendmail.mc
define(`SMART_HOST’, `host.to.relay.thorugh.com‘)dnl
In /etc/mail/access:
AuthInfo:host.to.relay.thorugh.com "U:username" "I:username" "P:password" "M:PLAIN"
Activate the changes
make
service sendmail restart
Reference: sendmail_relaying_to_isp_with_authentication_with_no_dns_lookup
