diff --git a/apps/web/src/app/auth/settings/security/change-kdf/change-kdf.component.ts b/apps/web/src/app/auth/settings/security/change-kdf/change-kdf.component.ts index 2a615ef397a..af65acc1d53 100644 --- a/apps/web/src/app/auth/settings/security/change-kdf/change-kdf.component.ts +++ b/apps/web/src/app/auth/settings/security/change-kdf/change-kdf.component.ts @@ -26,30 +26,9 @@ export class ChangeKdfComponent implements OnInit { protected formGroup = this.formBuilder.group({ kdf: new FormControl(KdfType.PBKDF2_SHA256, [Validators.required]), kdfConfig: this.formBuilder.group({ - iterations: [ - this.kdfConfig.iterations, - [ - Validators.required, - Validators.min(PBKDF2KdfConfig.ITERATIONS.min), - Validators.max(PBKDF2KdfConfig.ITERATIONS.max), - ], - ], - memory: [ - null as number, - [ - Validators.required, - Validators.min(Argon2KdfConfig.MEMORY.min), - Validators.max(Argon2KdfConfig.MEMORY.max), - ], - ], - parallelism: [ - null as number, - [ - Validators.required, - Validators.min(Argon2KdfConfig.PARALLELISM.min), - Validators.max(Argon2KdfConfig.PARALLELISM.max), - ], - ], + iterations: [this.kdfConfig.iterations], + memory: [null as number], + parallelism: [null as number], }), }); @@ -72,7 +51,7 @@ export class ChangeKdfComponent implements OnInit { async ngOnInit() { this.kdfConfig = await this.kdfConfigService.getKdfConfig(); - this.formGroup.get("kdf").setValue(this.kdfConfig.kdfType, { emitEvent: false }); + this.formGroup.get("kdf").setValue(this.kdfConfig.kdfType); this.setFormControlValues(this.kdfConfig); this.formGroup