API Reference / @evolu/common / Evolu/Protocol / decryptDbChange

Function: decryptDbChange()

function decryptDbChange(deps): (change, key) => Result<DbChange, 
  | SymmetricCryptoDecryptError
| ProtocolInvalidDataError>;

Defined in: packages/common/src/Evolu/Protocol.ts:1557

Decrypts an EncryptedDbChange using the provided owner's encryption key.

Parameters

ParameterType
depsSymmetricCryptoDep

Returns

(change, key): Result<DbChange, 
  | SymmetricCryptoDecryptError
| ProtocolInvalidDataError>;

Parameters

ParameterType
changeEncryptedDbChange
keyUint8Array<ArrayBufferLike> & Brand<"Length32"> & Brand<"EncryptionKey">

Returns

Result<DbChange, | SymmetricCryptoDecryptError | ProtocolInvalidDataError>

Was this page helpful?