libsignal: Process @hosted conversions to @hosted.lid

This commit is contained in:
Rajeh Taher
2025-10-05 22:51:13 +03:00
parent dd93b641c9
commit 09263aa3d2
3 changed files with 22 additions and 14 deletions
+4 -3
View File
@@ -36,9 +36,10 @@ export class SenderKeyMessage extends CiphertextMessage {
this.messageVersion = (version & 0xff) >> 4
this.keyId = senderKeyMessage.id
this.iteration = senderKeyMessage.iteration
this.ciphertext = typeof senderKeyMessage.ciphertext === 'string'
? Buffer.from(senderKeyMessage.ciphertext, 'base64')
: senderKeyMessage.ciphertext
this.ciphertext =
typeof senderKeyMessage.ciphertext === 'string'
? Buffer.from(senderKeyMessage.ciphertext, 'base64')
: senderKeyMessage.ciphertext
this.signature = signature
} else {
const version = (((this.CURRENT_VERSION << 4) | this.CURRENT_VERSION) & 0xff) % 256