The title pretty much describes the question.
Currently, I am using SMTPlib in python 3.6 and my code, shown below, sends an email with the name changed, but the real sending email address is till there. How would I remove that?
import smtplib
to = 'toemail@hotmail.co.uk'
gmail_user = 'fromemail@gmail.com'
gmail_pwd = 'pass'
smtpserver = smtplib.SMTP("smtp.gmail.com",587)
smtpserver.ehlo()
smtpserver.starttls()
smtpserver.ehlo
smtpserver.login(gmail_user, gmail_pwd)
header = 'To:' + to + '\n' + 'From: ' + "Hello World! <test@spam.com>" + '\n' + 'Subject: Test\n'
print(header)
msg = header + '\nSending a test message!\n\n'
smtpserver.sendmail(gmail_user, to, msg)
print('done!')
smtpserver.close()
Oh, and if there are any better libraries for sending spoof emails, then please tell me.
Thanks in advance.