This repository was archived by the owner on May 18, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +11
-8
lines changed
components/views/dialogs/security Expand file tree Collapse file tree 4 files changed +11
-8
lines changed Original file line number Diff line number Diff line change @@ -348,7 +348,7 @@ export default abstract class BasePlatform {
348348 /**
349349 * Create and store a pickle key for encrypting libolm objects.
350350 * @param {string } userId the user ID for the user that the pickle key is for.
351- * @param {string } userId the device ID that the pickle key is for.
351+ * @param {string } deviceId the device ID that the pickle key is for.
352352 * @returns {string|null } the pickle key, or null if the platform does not
353353 * support storing pickle keys.
354354 */
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ limitations under the License.
2020import { createClient } from 'matrix-js-sdk/src/matrix' ;
2121import { InvalidStoreError } from "matrix-js-sdk/src/errors" ;
2222import { MatrixClient } from "matrix-js-sdk/src/client" ;
23- import { decryptAES , encryptAES } from "matrix-js-sdk/src/crypto/aes" ;
23+ import { decryptAES , encryptAES , IEncryptedPayload } from "matrix-js-sdk/src/crypto/aes" ;
2424
2525import { IMatrixClientCreds , MatrixClientPeg } from './MatrixClientPeg' ;
2626import SecurityCustomisations from "./customisations/Security" ;
@@ -303,7 +303,7 @@ export interface IStoredSession {
303303 hsUrl : string ;
304304 isUrl : string ;
305305 hasAccessToken : boolean ;
306- accessToken : string | object ;
306+ accessToken : string | IEncryptedPayload ;
307307 userId : string ;
308308 deviceId : string ;
309309 isGuest : boolean ;
@@ -350,7 +350,7 @@ export async function getStoredSessionVars(): Promise<IStoredSession> {
350350}
351351
352352// The pickle key is a string of unspecified length and format. For AES, we
353- // need a 256-bit Uint8Array. So we HKDF the pickle key to generate the AES
353+ // need a 256-bit Uint8Array. So we HKDF the pickle key to generate the AES
354354// key. The AES key should be zeroed after it is used.
355355async function pickleKeyToAesKey ( pickleKey : string ) : Promise < Uint8Array > {
356356 const pickleKeyBuffer = new Uint8Array ( pickleKey . length ) ;
Original file line number Diff line number Diff line change @@ -16,6 +16,8 @@ limitations under the License.
1616*/
1717
1818import React from 'react' ;
19+ import { CrossSigningKeys } from 'matrix-js-sdk/src/client' ;
20+
1921import { MatrixClientPeg } from '../../../../MatrixClientPeg' ;
2022import { _t } from '../../../../languageHandler' ;
2123import Modal from '../../../../Modal' ;
@@ -71,7 +73,7 @@ export default class CreateCrossSigningDialog extends React.PureComponent<IProps
7173
7274 private async queryKeyUploadAuth ( ) : Promise < void > {
7375 try {
74- await MatrixClientPeg . get ( ) . uploadDeviceSigningKeys ( null , { } ) ;
76+ await MatrixClientPeg . get ( ) . uploadDeviceSigningKeys ( null , { } as CrossSigningKeys ) ;
7577 // We should never get here: the server should always require
7678 // UI auth to upload device signing keys. If we do, we upload
7779 // no keys which would be a no-op.
Original file line number Diff line number Diff line change @@ -16,11 +16,12 @@ limitations under the License.
1616
1717import EventEmitter from 'events' ;
1818import { VerificationRequest } from "matrix-js-sdk/src/crypto/verification/request/VerificationRequest" ;
19- import { IKeyBackupVersion } from "matrix-js-sdk/src/crypto/keybackup" ;
19+ import { IKeyBackupInfo } from "matrix-js-sdk/src/crypto/keybackup" ;
2020import { ISecretStorageKeyInfo } from "matrix-js-sdk/src/matrix" ;
21+ import { PHASE_DONE as VERIF_PHASE_DONE } from "matrix-js-sdk/src/crypto/verification/request/VerificationRequest" ;
22+
2123import { MatrixClientPeg } from '../MatrixClientPeg' ;
2224import { accessSecretStorage , AccessCancelledError } from '../SecurityManager' ;
23- import { PHASE_DONE as VERIF_PHASE_DONE } from "matrix-js-sdk/src/crypto/verification/request/VerificationRequest" ;
2425
2526export enum Phase {
2627 Loading = 0 ,
@@ -35,7 +36,7 @@ export class SetupEncryptionStore extends EventEmitter {
3536 private started : boolean ;
3637 public phase : Phase ;
3738 public verificationRequest : VerificationRequest ;
38- public backupInfo : IKeyBackupVersion ;
39+ public backupInfo : IKeyBackupInfo ;
3940 public keyId : string ;
4041 public keyInfo : ISecretStorageKeyInfo ;
4142 public hasDevicesToVerifyAgainst : boolean ;
You can’t perform that action at this time.
0 commit comments