diff --git a/ts/textsecure/downloadAttachment.ts b/ts/textsecure/downloadAttachment.ts index 63640b9e44..c5b08ec580 100644 --- a/ts/textsecure/downloadAttachment.ts +++ b/ts/textsecure/downloadAttachment.ts @@ -38,6 +38,7 @@ import { getBackupMediaRootKey, deriveBackupMediaKeyMaterial, type BackupMediaKeyMaterialType, + deriveBackupThumbnailTransitKeyMaterial, } from '../services/backups/crypto'; import { backupsService } from '../services/backups'; import { @@ -72,7 +73,7 @@ function getBackupThumbnailInnerEncryptionKeyMaterial( ): BackupMediaKeyMaterialType { const mediaId = getMediaIdForAttachmentThumbnail(attachment); const backupKey = getBackupMediaRootKey(); - return deriveBackupMediaKeyMaterial(backupKey, mediaId.bytes); + return deriveBackupThumbnailTransitKeyMaterial(backupKey, mediaId.bytes); } function getBackupThumbnailOuterEncryptionKeyMaterial( attachment: BackupableAttachmentType