jfinn 2 роки тому
джерело
коміт
78c185cd86
1 змінених файлів з 10 додано та 2 видалено
  1. 10
    2
      modules/e2ee/ManagedKeyHandler.js

+ 10
- 2
modules/e2ee/ManagedKeyHandler.js Переглянути файл

@@ -36,16 +36,21 @@ export class ManagedKeyHandler extends KeyHandler {
36 36
      * Build a new AutomaticKeyHandler instance, which will be used in a given conference.
37 37
      */
38 38
     constructor(conference) {
39
+        
39 40
 
40 41
         super(conference);
41 42
         console.log("ManagedKeyHandler _CONSTRUCTED???????")
42 43
         if (glob_rx?.ljm?.i){
43 44
             glob_rx.ljm.i.mkh_inst = this
44
-            clog("ManagedKeyHandler ljm constructed,??.")
45
+            clog("ManagedKeyHandler ljm constructed,??...,")
45 46
             console.trace("mkh_trc.")
46 47
         }
47 48
         glob_rx?.fns?.loadEvent?.("mkh constructed",{that:this})
48 49
 
50
+        if (glob_rx?.fns?.glob_dev_fncb("mkh_dev")){
51
+            this._fakeKey = undefined
52
+            this.mkh_dev =true
53
+        }
49 54
         this._key = undefined;
50 55
         this._conferenceJoined = false;
51 56
 
@@ -195,7 +200,10 @@ export class ManagedKeyHandler extends KeyHandler {
195 200
 
196 201
         this._key = new Uint8Array(newKey);
197 202
 
198
-        const index = this._olmAdapter.updateCurrentKey(this._key);
203
+
204
+        // updateCurrentKey updateCurrentMediaKey
205
+        const index = this._olmAdapter.updateCurrentMediaKey(this._key);
206
+        // const index = this._olmAdapter.updateCurrentKey(this._key);
199 207
 
200 208
         this.e2eeCtx.setKey(this.conference.myUserId(), this._key, index);
201 209
     }

Завантаження…
Відмінити
Зберегти