mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-28 03:29:20 +03:00
Added "Enforce 2-Step verification" setting
This commit is contained in:
parent
b7709c8117
commit
acb013fbb5
47 changed files with 1271 additions and 908 deletions
|
|
@ -28,11 +28,27 @@
|
|||
this.weakPassword = AppAdminStore.weakPassword;
|
||||
|
||||
this.capaOpenPGP = CapaAdminStore.openPGP;
|
||||
|
||||
this.capaTwoFactorAuth = CapaAdminStore.twoFactorAuth;
|
||||
this.capaTwoFactorAuthForce = CapaAdminStore.twoFactorAuthForce;
|
||||
|
||||
this.capaTwoFactorAuth.subscribe(function (bValue) {
|
||||
if (!bValue)
|
||||
{
|
||||
this.capaTwoFactorAuthForce(false);
|
||||
}
|
||||
}, this);
|
||||
|
||||
this.verifySslCertificate = ko.observable(!!Settings.settingsGet('VerifySslCertificate'));
|
||||
this.allowSelfSigned = ko.observable(!!Settings.settingsGet('AllowSelfSigned'));
|
||||
|
||||
this.verifySslCertificate.subscribe(function (bValue) {
|
||||
if (!bValue)
|
||||
{
|
||||
this.allowSelfSigned(true);
|
||||
}
|
||||
}, this);
|
||||
|
||||
this.adminLogin = ko.observable(Settings.settingsGet('AdminLogin'));
|
||||
this.adminLoginError = ko.observable(false);
|
||||
this.adminPassword = ko.observable('');
|
||||
|
|
@ -126,6 +142,12 @@
|
|||
});
|
||||
});
|
||||
|
||||
this.capaTwoFactorAuthForce.subscribe(function (bValue) {
|
||||
Remote.saveAdminConfig(Utils.emptyFunction, {
|
||||
'CapaTwoFactorAuthForce': bValue ? '1' : '0'
|
||||
});
|
||||
});
|
||||
|
||||
this.useLocalProxyForExternalImages.subscribe(function (bValue) {
|
||||
Remote.saveAdminConfig(null, {
|
||||
'UseLocalProxyForExternalImages': bValue ? '1' : '0'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue