Skip to content
Snippets Groups Projects
Commit bfe58c82 authored by Pavel Břoušek's avatar Pavel Břoušek
Browse files

fix: use SMTP without starttls

parent 5c0ddc26
No related branches found
No related tags found
No related merge requests found
Pipeline #455114 passed
......@@ -211,8 +211,8 @@ gui:
all_mails_attribute: "urn:perun:user:attribute-def:virt:tcsMails:mu" # OPTIONAL mails where notification about the MFA reset will be sent if configured
helpdesk_mail: "it@muni.cz" # REQUIRED mail where request to reset MFA will be forwarded after being confirmed by the user
mail_login_credentials_filepath: path_to_credentials # OPTIONAL credentials to email from which the MFA reset link and notifications will be sent in a newline-delimited file like username<\n>password, the username is also used as the FROM address
smtp_server: smtp.example.com # REQUIRED server from which the signed emails will be sent
smtp_port: 487
smtp_server: smtp.example.com # REQUIRED server from which the signed emails will be sent over plain SMTP (MTA)
smtp_port: 25
cert_filepath: certificate_filepath # REQUIRED for S/MIME signatures used in emails
private_key_filepath: private_key_filepath # REQUIRED for S/MIME signatures used in emails
mfa_reset_translations: # OPTIONAL: options below need to be filled out in order for mfa-reset page text to appear
......
......@@ -33,9 +33,6 @@ class EmailService:
def __send_email_message(self, message: MIMEMultipart) -> None:
with smtplib.SMTP(self.__SMTP_SERVER, self.__SMTP_PORT) as smtp_server:
smtp_server.ehlo()
smtp_server.starttls()
smtp_server.ehlo()
if self.__LOGIN_EMAIL and self.__LOGIN_PASS:
smtp_server.login(self.__LOGIN_EMAIL, self.__LOGIN_PASS)
smtp_server.send_message(message)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment