From 7c7c2ba2f0ac0789bbc52af93f715dee10d329af Mon Sep 17 00:00:00 2001 From: Phil Davis Date: Sun, 4 Jan 2015 22:22:23 +0545 Subject: [PATCH] Support for Office365 Mail https://redmine.pfsense.org/issues/4176 Allow the user to choose SMTP authentication mechanism PLAIN or LOGIN. For existing configs with this option not set, PLAIN is the default, and will appear first in the dropdown box, so next time the user saves the SMTP Notification settings, PLAIN will be the value selected and saved. --- .../www/system_advanced_notifications.php | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/usr/local/www/system_advanced_notifications.php b/usr/local/www/system_advanced_notifications.php index df4d52af01..da0c418568 100644 --- a/usr/local/www/system_advanced_notifications.php +++ b/usr/local/www/system_advanced_notifications.php @@ -75,6 +75,8 @@ if ($config['notifications']['smtp']['username']) $pconfig['smtpusername'] = $config['notifications']['smtp']['username']; if ($config['notifications']['smtp']['password']) $pconfig['smtppassword'] = $config['notifications']['smtp']['password']; +if ($config['notifications']['smtp']['authentication_mechanism']) + $pconfig['smtpauthmech'] = $config['notifications']['smtp']['authentication_mechanism']; if ($config['notifications']['smtp']['fromaddress']) $pconfig['smtpfromaddress'] = $config['notifications']['smtp']['fromaddress']; @@ -126,6 +128,7 @@ if ($_POST) { $config['notifications']['smtp']['notifyemailaddress'] = $_POST['smtpnotifyemailaddress']; $config['notifications']['smtp']['username'] = $_POST['smtpusername']; $config['notifications']['smtp']['password'] = $_POST['smtppassword']; + $config['notifications']['smtp']['authentication_mechanism'] = $_POST['smtpauthmech']; $config['notifications']['smtp']['fromaddress'] = $_POST['smtpfromaddress']; if($_POST['disable_smtp'] == "yes") @@ -307,6 +310,23 @@ include("head.inc"); + + + + +
+ + +