From 828d5ea91109654e733ae0a3ef3cd82f91147de9 Mon Sep 17 00:00:00 2001 From: Vincent Salucci <26154748+vincentsalucci@users.noreply.github.com> Date: Thu, 27 Feb 2020 12:13:55 -0600 Subject: [PATCH] Enforce password generator policy options in the UI (#393) --- src/app/services.module.ts | 2 +- src/app/vault/password-generator.component.html | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/app/services.module.ts b/src/app/services.module.ts index 852588db64..1d49a7e9f2 100644 --- a/src/app/services.module.ts +++ b/src/app/services.module.ts @@ -114,7 +114,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/vault/password-generator.component.html b/src/app/vault/password-generator.component.html index 4e424aef59..46baf59b7c 100644 --- a/src/app/vault/password-generator.component.html +++ b/src/app/vault/password-generator.component.html @@ -70,22 +70,22 @@
+ [disabled]="enforcedPolicyOptions?.useUppercase" [(ngModel)]="options.uppercase">
+ [disabled]="enforcedPolicyOptions?.useLowercase" [(ngModel)]="options.lowercase">
+ [disabled]="enforcedPolicyOptions?.useNumbers" [(ngModel)]="options.number">
+ [disabled]="enforcedPolicyOptions?.useSpecial" [(ngModel)]="options.special">
@@ -93,12 +93,12 @@
-
-