diff --git a/web/packages/base/crypto/index.ts b/web/packages/base/crypto/index.ts index eceea2408d..48f7a9526b 100644 --- a/web/packages/base/crypto/index.ts +++ b/web/packages/base/crypto/index.ts @@ -193,7 +193,8 @@ export const encryptMetadataJSON = async (r: { : sharedCryptoWorker().then((w) => w.encryptMetadataJSON(r)); /** - * Decrypt a box encrypted using {@link encryptBoxB64}. + * Decrypt a box encrypted using {@link encryptBoxB64} and returns the decrypted + * bytes. */ export const decryptBox = (box: EncryptedBox, key: BytesOrB64) => inWorker() diff --git a/web/packages/base/crypto/libsodium.ts b/web/packages/base/crypto/libsodium.ts index 25ff0057e9..225b5efe72 100644 --- a/web/packages/base/crypto/libsodium.ts +++ b/web/packages/base/crypto/libsodium.ts @@ -390,7 +390,7 @@ export async function encryptFileChunk( } /** - * Decrypt the result of {@link encryptBoxB64}. + * Decrypt the result of {@link encryptBoxB64} and return the decrypted bytes. */ export const decryptBox = async ( { encryptedData, nonce }: EncryptedBox, diff --git a/web/packages/base/session-store.ts b/web/packages/base/session-store.ts index 2493467348..989375941d 100644 --- a/web/packages/base/session-store.ts +++ b/web/packages/base/session-store.ts @@ -3,7 +3,7 @@ import { decryptBox } from "./crypto"; import { toB64 } from "./crypto/libsodium"; /** - * Return the user's master key (as a base64 string) from session storage. + * Return the user's master key from session storage. * * Precondition: The user should be logged in. */