use Net::SMTP_auth; my $smtp = Net::SMTP_auth->new( 'smtp.att.yahoo.com', Hello => '826michigan.org', Debug => 1); my $auth_return = $smtp->auth('PLAIN', 'info@826michigan.org', 'plaintext_pw_here'); my $mail_return = $smtp->mail($ENV{USER}); my $to_return = $smtp->to('info@826michigan.org'); $smtp->data(); $smtp->datasend("hi\n"); $smtp->dataend(); $smtp->quit; print "\nauth_return = $auth_return\n"; print "mail_return = $mail_return\n"; print "to_return = $to_return\n"; #### Net::SMTP_auth>>> Net::SMTP_auth(0.08) Net::SMTP_auth>>> Net::SMTP(2.31) Net::SMTP_auth>>> Net::Cmd(2.29) Net::SMTP_auth>>> Exporter(5.63) Net::SMTP_auth>>> IO::Socket::INET(1.31) Net::SMTP_auth>>> IO::Socket(1.31) Net::SMTP_auth>>> IO::Handle(1.28) Net::SMTP_auth=GLOB(0x86eea0)<<< 220 smtp123.sbc.mail.re3.yahoo.com ESMTP Net::SMTP_auth=GLOB(0x86eea0)>>> EHLO 826michigan.org Net::SMTP_auth=GLOB(0x86eea0)<<< 250-smtp123.sbc.mail.re3.yahoo.com Net::SMTP_auth=GLOB(0x86eea0)<<< 250-AUTH LOGIN PLAIN XYMCOOKIE Net::SMTP_auth=GLOB(0x86eea0)<<< 250-PIPELINING Net::SMTP_auth=GLOB(0x86eea0)<<< 250 8BITMIME Net::SMTP_auth=GLOB(0x86eea0)>>> AUTH PLAIN Net::SMTP_auth=GLOB(0x86eea0)<<< 334 ok, go on Net::SMTP_auth=GLOB(0x86eea0)>>> aW5mb0A4MjZtaWNoaWdhbi5vcmcAaW5mb0A4MjZtaWNoaWdhbi5vcmcAbW9uc3RlcjgyNg== Net::SMTP_auth=GLOB(0x86eea0)<<< 530 Access denied Net::SMTP_auth=GLOB(0x86eea0)>>> MAIL FROM:<826michigan> Net::SMTP_auth: Unexpected EOF on command channel at email.txt line 9 auth_return = mail_return = to_return = 0 #### You cannot inherit from a Moose Role (Email::Sender::Transport) at /Users/826michigan/Library/ActivePerl-5.10/lib/Moose.pm line 53 .... #### use Email::Sender::Transport::SMTP::TLS; use Email::Simple; use Email::Simple::Creator; my $message = Email::Simple->create( header => [ To => 'info@826michigan.org', From => 'info@826michigan.org', Subject => "hi\n", ], body => "just hi\n" ); my $sender = Email::Sender::Transport::SMTP::TLS->new( host => 'smtp.att.yahoo.com', port => 465, username => 'info@826michigan.org', password => 'plaintext_pw_here' ); $sender->send( $message, { from => 'info@826michigan.org', to => 'info@826michigan.org' } );