From a27eddae56b37804e58276ff2e11ed89decc462a Mon Sep 17 00:00:00 2001
From: Vincent Salucci <26154748+vincentsalucci@users.noreply.github.com>
Date: Wed, 26 Feb 2020 18:32:57 -0600
Subject: [PATCH] Enforce Password Generator Policy Options (#469)
* Initial commit for enforcing password generator policy options
* Revert to previous isDev URL setup
---
.../manage/policy-edit.component.html | 6 +++---
src/app/services/services.module.ts | 2 +-
src/app/tools/password-generator.component.html | 16 ++++++++--------
src/app/tools/password-generator.component.ts | 8 ++++++++
src/app/vault/add-edit.component.ts | 2 +-
5 files changed, 21 insertions(+), 13 deletions(-)
diff --git a/src/app/organizations/manage/policy-edit.component.html b/src/app/organizations/manage/policy-edit.component.html
index a5f4024efd..5c8143e1fa 100644
--- a/src/app/organizations/manage/policy-edit.component.html
+++ b/src/app/organizations/manage/policy-edit.component.html
@@ -59,19 +59,19 @@
+ min="5" max="128" [(ngModel)]="passGenMinLength">
diff --git a/src/app/services/services.module.ts b/src/app/services/services.module.ts
index 3b5f729180..63394e5e87 100644
--- a/src/app/services/services.module.ts
+++ b/src/app/services/services.module.ts
@@ -113,7 +113,7 @@ const lockService = new LockService(cipherService, folderService, collectionServ
const syncService = new SyncService(userService, apiService, settingsService,
folderService, cipherService, cryptoService, collectionService, storageService, messagingService, policyService,
async (expired: boolean) => messagingService.send('logout', { expired: expired }));
-const passwordGenerationService = new PasswordGenerationService(cryptoService, storageService);
+const passwordGenerationService = new PasswordGenerationService(cryptoService, storageService, policyService);
const totpService = new TotpService(storageService, cryptoFunctionService);
const containerService = new ContainerService(cryptoService);
const authService = new AuthService(cryptoService, apiService,
diff --git a/src/app/tools/password-generator.component.html b/src/app/tools/password-generator.component.html
index 33aab74eb0..f77f748229 100644
--- a/src/app/tools/password-generator.component.html
+++ b/src/app/tools/password-generator.component.html
@@ -53,34 +53,34 @@
-
+
-
+