KeyServiceImpl

class KeyServiceImpl(userInfo: UserInfo, keyStore: KeyStore, olmCryptoStore: OlmCryptoStore, globalAccountDataStore: GlobalAccountDataStore, roomService: RoomService, signService: SignService, keyBackupService: KeyBackupService, keyTrustService: KeyTrustService, api: MatrixClientServerApiClient) : KeyService

Constructors

Link copied to clipboard
constructor(userInfo: UserInfo, keyStore: KeyStore, olmCryptoStore: OlmCryptoStore, globalAccountDataStore: GlobalAccountDataStore, roomService: RoomService, signService: SignService, keyBackupService: KeyBackupService, keyTrustService: KeyTrustService, api: MatrixClientServerApiClient)

Functions

Link copied to clipboard
open suspend override fun bootstrapCrossSigning(recoveryKey: ByteArray, secretKeyEventContentGenerator: suspend () -> SecretKeyEventContent): KeyService.BootstrapCrossSigning

This allows you to bootstrap cross signing. Be aware, that this could override an existing cross signing setup of the account. Be aware, that this also creates a new key backup, which could replace an existing key backup.

Link copied to clipboard
open suspend override fun bootstrapCrossSigningFromPassphrase(passphrase: String, secretKeyEventContentGenerator: suspend () -> Pair<ByteArray, SecretKeyEventContent>): KeyService.BootstrapCrossSigning

This allows you to bootstrap cross signing. Be aware, that this could override an existing cross signing setup of the account. Be aware, that this also creates a new key backup, which could replace an existing key backup.

Link copied to clipboard
open override fun getCrossSigningKeys(userId: UserId): Flow<List<CrossSigningKeys>?>
Link copied to clipboard
open override fun getDeviceKeys(userId: UserId): Flow<List<DeviceKeys>?>
Link copied to clipboard
open override fun getTrustLevel(userId: UserId): Flow<UserTrustLevel>
open override fun getTrustLevel(roomId: RoomId, eventId: EventId): Flow<DeviceTrustLevel?>
open override fun getTrustLevel(userId: UserId, deviceId: String): Flow<DeviceTrustLevel>

Properties

Link copied to clipboard
open override val bootstrapRunning: StateFlow<Boolean>