summary refs log tree commit diff
path: root/synapse/push/mailer.py
diff options
context:
space:
mode:
authorDavid Baker <dbkr@users.noreply.github.com>2017-04-10 15:42:16 +0100
committerGitHub <noreply@github.com>2017-04-10 15:42:16 +0100
commit405ba4178a898d2d5b893a7ef7f8f4de514f6f1a (patch)
tree599527f8c0a06d093a3ac979477a75687d3a9cd5 /synapse/push/mailer.py
parentMerge pull request #2109 from matrix-org/erikj/send_queue_fix (diff)
parentSupport authenticated SMTP (diff)
downloadsynapse-405ba4178a898d2d5b893a7ef7f8f4de514f6f1a.tar.xz
Merge pull request #2102 from DanielDent/add-auth-email
Support authenticated SMTP
Diffstat (limited to 'synapse/push/mailer.py')
-rw-r--r--synapse/push/mailer.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/synapse/push/mailer.py b/synapse/push/mailer.py
index 3a50c72e0b..f83aa7625c 100644
--- a/synapse/push/mailer.py
+++ b/synapse/push/mailer.py
@@ -200,7 +200,11 @@ class Mailer(object):
         yield sendmail(
             self.hs.config.email_smtp_host,
             raw_from, raw_to, multipart_msg.as_string(),
-            port=self.hs.config.email_smtp_port
+            port=self.hs.config.email_smtp_port,
+            requireAuthentication=self.hs.config.email_smtp_user is not None,
+            username=self.hs.config.email_smtp_user,
+            password=self.hs.config.email_smtp_pass,
+            requireTransportSecurity=self.hs.config.require_transport_security
         )
 
     @defer.inlineCallbacks