From 2d37ae498f5913dd1418431cce56d9c4c419162a Mon Sep 17 00:00:00 2001 From: Codehhh Date: Mon, 9 Oct 2017 02:51:27 -0400 Subject: [PATCH 1/3] Fixed typo (#1551) --- .../ClientApp/app/usermanagement/updatedetails.component.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Ombi/ClientApp/app/usermanagement/updatedetails.component.html b/src/Ombi/ClientApp/app/usermanagement/updatedetails.component.html index f76f01959..9e48290d2 100644 --- a/src/Ombi/ClientApp/app/usermanagement/updatedetails.component.html +++ b/src/Ombi/ClientApp/app/usermanagement/updatedetails.component.html @@ -41,7 +41,7 @@
Email address format is incorrect
The Password is required
The Confirm New Password is required
-
Your current passowrd is required
+
Your current password is required
- \ No newline at end of file + From 899934c3078a754b7ea1d6c4c27336ea31465cc1 Mon Sep 17 00:00:00 2001 From: Jeffrey Peters Date: Mon, 9 Oct 2017 02:52:59 -0400 Subject: [PATCH 2/3] This adds two fields to the Email Notifications settings page. It allows for the disabling of TLS/SSL as well as the ability to disable certificate validation when sending notification emails. (#1552) --- .../GenericEmailProvider.cs | 36 +++++++++++++++++-- .../EmailNotificationSettings.cs | 2 ++ .../app/interfaces/INotificationSettings.ts | 2 ++ .../emailnotification.component.html | 12 +++++++ .../emailnotification.component.ts | 2 ++ 5 files changed, 52 insertions(+), 2 deletions(-) diff --git a/src/Ombi.Notifications/GenericEmailProvider.cs b/src/Ombi.Notifications/GenericEmailProvider.cs index ec6160e12..de8742137 100644 --- a/src/Ombi.Notifications/GenericEmailProvider.cs +++ b/src/Ombi.Notifications/GenericEmailProvider.cs @@ -47,10 +47,30 @@ namespace Ombi.Notifications message.From.Add(new MailboxAddress(settings.SenderAddress, settings.SenderAddress)); message.To.Add(new MailboxAddress(model.To, model.To)); + + + using (var client = new SmtpClient()) { - client.Connect(settings.Host, settings.Port); // Let MailKit figure out the correct SecureSocketOptions. + if (settings.DisableCertificateChecking) + { + // Disable validation of the certificate associated with the SMTP service + // Helpful when the TLS certificate is not in the certificate store of the server + // Does carry the risk of man in the middle snooping + client.ServerCertificateValidationCallback += (sender, certificate, chain, sslPolicyErrors) => true; + } + if (settings.DisableTLS) + { + // Does not attempt to use either TLS or SSL + // Helpful when MailKit finds a TLS certificate, but it unable to use it + client.Connect(settings.Host, settings.Port, MailKit.Security.SecureSocketOptions.None); + } + else + { + client.Connect(settings.Host, settings.Port); // Let MailKit figure out the correct SecureSocketOptions. + } + // Note: since we don't have an OAuth2 token, disable // the XOAUTH2 authentication mechanism. client.AuthenticationMechanisms.Remove("XOAUTH2"); @@ -92,7 +112,19 @@ namespace Ombi.Notifications using (var client = new SmtpClient()) { - client.Connect(settings.Host, settings.Port); // Let MailKit figure out the correct SecureSocketOptions. + if (settings.DisableCertificateChecking) + { + client.ServerCertificateValidationCallback += (sender, certificate, chain, sslPolicyErrors) => true; + } + + if (settings.DisableTLS) + { + client.Connect(settings.Host, settings.Port, MailKit.Security.SecureSocketOptions.None); + } + else + { + client.Connect(settings.Host, settings.Port); // Let MailKit figure out the correct SecureSocketOptions. + } // Note: since we don't have an OAuth2 token, disable // the XOAUTH2 authentication mechanism. diff --git a/src/Ombi.Settings/Settings/Models/Notifications/EmailNotificationSettings.cs b/src/Ombi.Settings/Settings/Models/Notifications/EmailNotificationSettings.cs index 2e222de29..9ea8cc492 100644 --- a/src/Ombi.Settings/Settings/Models/Notifications/EmailNotificationSettings.cs +++ b/src/Ombi.Settings/Settings/Models/Notifications/EmailNotificationSettings.cs @@ -11,5 +11,7 @@ public string Username { get; set; } public bool Authentication { get; set; } public string AdminEmail { get; set; } + public bool DisableTLS { get; set; } + public bool DisableCertificateChecking { get; set; } } } \ No newline at end of file diff --git a/src/Ombi/ClientApp/app/interfaces/INotificationSettings.ts b/src/Ombi/ClientApp/app/interfaces/INotificationSettings.ts index 270de2a9e..6be671eb0 100644 --- a/src/Ombi/ClientApp/app/interfaces/INotificationSettings.ts +++ b/src/Ombi/ClientApp/app/interfaces/INotificationSettings.ts @@ -13,6 +13,8 @@ export interface IEmailNotificationSettings extends INotificationSettings { username: string; authentication: boolean; adminEmail: string; + disableTLS: boolean; + disableCertificateChecking: boolean; notificationTemplates: INotificationTemplates[]; } diff --git a/src/Ombi/ClientApp/app/settings/notifications/emailnotification.component.html b/src/Ombi/ClientApp/app/settings/notifications/emailnotification.component.html index d4b698c50..d73c76f06 100644 --- a/src/Ombi/ClientApp/app/settings/notifications/emailnotification.component.html +++ b/src/Ombi/ClientApp/app/settings/notifications/emailnotification.component.html @@ -18,6 +18,18 @@ + +
+
+ +
+
+ +
+
+ +
+
diff --git a/src/Ombi/ClientApp/app/settings/notifications/emailnotification.component.ts b/src/Ombi/ClientApp/app/settings/notifications/emailnotification.component.ts index e1db94cae..6e7d5a889 100644 --- a/src/Ombi/ClientApp/app/settings/notifications/emailnotification.component.ts +++ b/src/Ombi/ClientApp/app/settings/notifications/emailnotification.component.ts @@ -35,6 +35,8 @@ export class EmailNotificationComponent implements OnInit { senderName: [x.senderName], username: [x.username], adminEmail: [x.adminEmail, [Validators.required, Validators.email]], + disableTLS: [x.disableTLS], + disableCertificateChecking: [x.disableCertificateChecking], }); if (x.authentication) { From c12061d035ca9f6da958c0772baab6a8db895902 Mon Sep 17 00:00:00 2001 From: Jeffrey Peters Date: Fri, 13 Oct 2017 02:47:25 -0400 Subject: [PATCH 3/3] Fixes an issue with Movie caching not working on develop branch of Radarr (#1567) --- src/Ombi.Api.Radarr/Models/MovieResponse.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Ombi.Api.Radarr/Models/MovieResponse.cs b/src/Ombi.Api.Radarr/Models/MovieResponse.cs index 6f23545dd..74d5c75ea 100644 --- a/src/Ombi.Api.Radarr/Models/MovieResponse.cs +++ b/src/Ombi.Api.Radarr/Models/MovieResponse.cs @@ -32,8 +32,8 @@ namespace Ombi.Api.Radarr.Models public List tags { get; set; } public string added { get; set; } public Ratings ratings { get; set; } - public List alternativeTitles { get; set; } + //public List alternativeTitles { get; set; } public int qualityProfileId { get; set; } public int id { get; set; } } -} \ No newline at end of file +}