Hack N3
Hack N3
def main():
print("Welcome to the Email Automation Script!")
# Security Warning
print("\n** SECURITY WARNING **")
print("Entering your email password directly in the script can be a security
risk.")
print("Consider using app passwords for Gmail or other secure authentication
methods.")
print("Do not share your scripts containing passwords with others.")
print("Continue only if you understand and accept these risks.\n")
print('If you have 2-factor authentication turned on, make sure to generate an
app password. \nOtherwise, enter your password.')
sender_password = input('Enter the Password: ')
# Send email
server.sendmail(sender_email, receiver_emails, message.as_string())
except Exception as e:
print('Error sending mail:', str(e))
if __name__ == "__main__":
main()