mirror of
https://github.com/bitwarden/server
synced 2025-12-29 22:54:00 +00:00
Comments and create async
This commit is contained in:
@@ -2,6 +2,10 @@
|
||||
|
||||
namespace Bit.Core.KeyManagement.Commands.Interfaces;
|
||||
|
||||
/// <summary>
|
||||
/// Command to set account keys for a new user that does not have keys yet.
|
||||
/// This is intended for the TDE and Key-connector account registration flows.
|
||||
/// </summary>
|
||||
public interface ISetAccountKeysForUserCommand
|
||||
{
|
||||
Task SetAccountKeysForUserAsync(Guid userId,
|
||||
|
||||
@@ -39,7 +39,7 @@ public class SetAccountKeysForUserCommand : ISetAccountKeysForUserCommand
|
||||
user.SignedPublicKey = accountKeysData.PublicKeyEncryptionKeyPairData.SignedPublicKey;
|
||||
user.SecurityState = accountKeysData.SecurityStateData.SecurityState;
|
||||
user.SecurityVersion = accountKeysData.SecurityStateData.SecurityVersion;
|
||||
await _userSignatureKeyPairRepository.UpsertAsync(new UserSignatureKeyPair
|
||||
await _userSignatureKeyPairRepository.CreateAsync(new UserSignatureKeyPair
|
||||
{
|
||||
Id = CoreHelpers.GenerateComb(),
|
||||
UserId = userId,
|
||||
|
||||
Reference in New Issue
Block a user