Skip to content

Commit

Permalink
fix: random decryption errors after ending 1:1 on SFT (WPB-11213) πŸ’ πŸ’ (…
Browse files Browse the repository at this point in the history
…#3039)

* fix: Ignore MLSException (#3022) (#3025)

Co-authored-by: Oussama Hassine <[email protected]>
Co-authored-by: Mohamad Jaara <[email protected]>

* chore: empty commit

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Oussama Hassine <[email protected]>
Co-authored-by: Mohamad Jaara <[email protected]>
  • Loading branch information
3 people authored Sep 26, 2024
1 parent ba79287 commit f2dc281
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ actual fun mapMLSException(exception: Exception): MLSFailure =
is CryptoError.StaleCommit -> MLSFailure.StaleCommit
is CryptoError.ConversationAlreadyExists -> MLSFailure.ConversationAlreadyExists
is CryptoError.MessageEpochTooOld -> MLSFailure.MessageEpochTooOld
is CryptoError.MlsException -> MLSFailure.InternalErrors
else -> MLSFailure.Generic(exception)
}
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ interface MLSFailure : CoreFailure {
data object ConversationDoesNotSupportMLS : MLSFailure
data object StaleProposal : MLSFailure
data object StaleCommit : MLSFailure
data object InternalErrors : MLSFailure

data class Generic(internal val exception: Exception) : MLSFailure {
val rootCause: Throwable get() = exception
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ internal object MLSMessageFailureHandler {
is MLSFailure.StaleProposal -> MLSMessageFailureResolution.Ignore
is MLSFailure.StaleCommit -> MLSMessageFailureResolution.Ignore
is MLSFailure.MessageEpochTooOld -> MLSMessageFailureResolution.Ignore
is MLSFailure.InternalErrors -> MLSMessageFailureResolution.Ignore
else -> MLSMessageFailureResolution.InformUser
}
}
Expand Down

0 comments on commit f2dc281

Please sign in to comment.