generated from bitwarden/template
-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BIT-2304: Fix pin unlock for new TDE accounts (#626)
- Loading branch information
1 parent
13b2739
commit 1006023
Showing
2 changed files
with
15 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -171,6 +171,10 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo | |
XCTAssertEqual(clientService.mockAuth.makeRegisterTdeKeysEmail, "[email protected]") | ||
XCTAssertEqual(clientService.mockAuth.makeRegisterTdeKeysOrgPublicKey, "MIIBIjAN...2QIDAQAB") | ||
XCTAssertEqual(clientService.mockAuth.makeRegisterTdeKeysRememberDevice, true) | ||
XCTAssertEqual( | ||
stateService.accountEncryptionKeys["1"], | ||
AccountEncryptionKeys(encryptedPrivateKey: "privateKey", encryptedUserKey: nil) | ||
) | ||
} | ||
|
||
/// `createNewSsoUser()` creates a new account for sso JIT user and don't trust device. | ||
|
@@ -200,6 +204,10 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo | |
XCTAssertNil(trustDeviceService.trustDeviceWithExistingKeysValue) | ||
XCTAssertEqual(clientService.mockAuth.makeRegisterTdeKeysOrgPublicKey, "MIIBIjAN...2QIDAQAB") | ||
XCTAssertEqual(clientService.mockAuth.makeRegisterTdeKeysRememberDevice, false) | ||
XCTAssertEqual( | ||
stateService.accountEncryptionKeys["1"], | ||
AccountEncryptionKeys(encryptedPrivateKey: "privateKey", encryptedUserKey: nil) | ||
) | ||
} | ||
|
||
/// `deleteAccount()` deletes the active account and removes it from the state. | ||
|