mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-03-01 06:07:37 +00:00
Perform a legacy session reset if you fail to decrypt a sync message.
This commit is contained in:
committed by
Cody Henthorne
parent
5688d85789
commit
72e5532c6c
@@ -271,6 +271,16 @@ object MessageDecryptor {
|
||||
val receivedTimestamp: Long = System.currentTimeMillis()
|
||||
val sender: Recipient = Recipient.external(context, protocolException.sender)
|
||||
|
||||
if (sender.isSelf) {
|
||||
Log.w(TAG, "${logPrefix(envelope)} Decryption error for a sync message! Enqueuing a session reset job.")
|
||||
|
||||
followUpOperations += FollowUpOperation {
|
||||
AutomaticSessionResetJob(sender.id, senderDevice, envelope.timestamp)
|
||||
}
|
||||
|
||||
return Result.Ignore(envelope, serverDeliveredTimestamp, followUpOperations)
|
||||
}
|
||||
|
||||
followUpOperations += FollowUpOperation {
|
||||
buildSendRetryReceiptJob(envelope, protocolException, sender)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user