feat(preferences): password constraints for SQL sources

Initial implementation of some password policy support for SQL sources.
This commit is contained in:
Francis Lachapelle
2022-06-06 16:39:26 -04:00
parent 03cdc4f3b1
commit 2ef849ca65
7 changed files with 99 additions and 4 deletions
+12
View File
@@ -38,6 +38,7 @@
#import <SOGo/SOGoUser.h>
#import <SOGo/SOGoUserSettings.h>
#import <SOGo/SOGoSieveManager.h>
#import <SOGo/SOGoSource.h>
#import <SOGo/SOGoSystemDefaults.h>
#import <SOGo/SOGoUserFolder.h>
#import <SOGo/SOGoParentFolder.h>
@@ -250,6 +251,17 @@ static NSArray *reminderValues = nil;
return shortDateFormatText;
}
//
// Used by wox template
//
- (NSArray *) passwordPolicy
{
NSObject <SOGoSource> *userSource;
userSource = [user authenticationSource];
return [userSource userPasswordPolicy];
}
//
// Used internally
//
@@ -282,6 +282,13 @@
<label><var:string label:value="New password"/>
</label>
<input type="password" sg-no-dirty-check="true" ng-model="app.passwords.newPassword"/>
<div class="sg-hint">
<ul class="sg-padded">
<var:foreach list="passwordPolicy" item="item">
<li><var:string value="item.label"/></li>
</var:foreach>
</ul>
</div>
</md-input-container>
<md-input-container class="md-block" flex="flex">
<label><var:string label:value="Confirmation"/>