smtplib "authentication required" error
carl.reimann at gmail.com
carl.reimann at gmail.com
Fri Mar 31 21:20:27 EST 2006
In using a simple smtp routine:
# begin example
>>> import smtplib
>>> server = smtplib.SMTP('outgoing.verizon.net')
>>> server.sendmail('my at address.net', 'another at address.net',
"""To: another at address.net
From: my at address.net
Subject: Shakespeare Quote
Tis like the breath of an unfeed lawyer...
""")
>>> server.quit()
# end example
I find the following error:
raise SMTPSenderRefused(code, resp, from_addr)
smtplib.SMTPSenderRefused: (550, '5.7.1 Authentication Required',
'myuserid at verizon.net')
I have attempted to incorporate into the interactive session:
server.login = ('userid', 'password') # the same ones I use in my
email program
But I get the same error result. My objective is to have a simple way
to send email from the command line. To do this I will write a script
which can read in a file and send it to the address on top of the file.
What is the procedure for authentication?
Using the KMail email program (Linux, KDE desktop), I send mail through
my Verizon account. Under the Configure KMail / Accounts / Modify
Account / Extras tab, I clicked "Check what the server supports" and it
came back 'no encryption' and 'cleartext'. So it doesn't seem that it
would involve complex procedures.
Any help welcome.
More information about the Python-list
mailing list