Question about sendmail by smtp

Hi all

   I try to send a email by smtp.
   format is : smtp = Net::SMTP.start '127.0.0.1','account
=xxx@xxxx.com', 'password = xxxxx', 'authtype =:plain' # i also test
authtype=:login
   but it returns SMTP-AUTH requested but missing secret phrase.
   who can help me resolve it?
    thanks everyone.

Sandy