Pin user identity.

This commit is contained in:
Benoit Marty 2024-10-04 15:36:56 +02:00 committed by Benoit Marty
parent c69e5f47e5
commit d9fb0cf656
7 changed files with 69 additions and 22 deletions

View file

@ -7,6 +7,7 @@
package io.element.android.libraries.matrix.api.encryption
import io.element.android.libraries.matrix.api.core.UserId
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.StateFlow
@ -58,6 +59,11 @@ interface EncryptionService {
* Starts the identity reset process. This will return a handle that can be used to reset the identity.
*/
suspend fun startIdentityReset(): Result<IdentityResetHandle?>
/**
* Remember this identity, ensuring it does not result in a pin violation.
*/
suspend fun pinUserIdentity(userId: UserId): Result<Unit>
}
/**