mirror of
https://github.com/bitwarden/server.git
synced 2025-04-14 09:38:16 -05:00

* feat(OPAQUE-KE): added entity * innovation(opaque-ke) : inital database changes * innovation(opaque-ke) : dapper implementation. Key rotation WIP. * Updating credential repository * feat : updating service to use repository to save credential * Fix table creation and make registration work --------- Co-authored-by: Bernd Schoolmann <mail@quexten.com>
27 lines
811 B
Transact-SQL
27 lines
811 B
Transact-SQL
-- Used for Key Rotation and Password Update
|
|
CREATE PROCEDURE [dbo].[OpaqueKeyExchangeCredential_Update]
|
|
@Id UNIQUEIDENTIFIER OUTPUT,
|
|
@UserId UNIQUEIDENTIFIER,
|
|
@CipherConfiguration VARCHAR(MAX),
|
|
@CredentialBlob VARCHAR(MAX),
|
|
@EncryptedPublicKey VARCHAR(MAX),
|
|
@EncryptedPrivateKey VARCHAR(MAX),
|
|
@EncryptedUserKey VARCHAR(MAX),
|
|
@CreationDate DATETIME2(7)
|
|
AS
|
|
BEGIN
|
|
SET NOCOUNT ON
|
|
|
|
UPDATE
|
|
[dbo].[OpaqueKeyExchangeCredential]
|
|
SET
|
|
[CipherConfiguration] = @CipherConfiguration,
|
|
[CredentialBlob] = @CredentialBlob,
|
|
[EncryptedPublicKey] = @EncryptedPublicKey,
|
|
[EncryptedPrivateKey] = @EncryptedPrivateKey,
|
|
[EncryptedUserKey] = @EncryptedUserKey,
|
|
[CreationDate] = @CreationDate
|
|
WHERE
|
|
[Id] = @Id AND [UserId] = @UserId
|
|
END
|