Prevent rogue users from requesting multiple roomKeys
This commit is contained in:
parent
c9f57c6fa0
commit
67273bc418
1
index.js
1
index.js
|
@ -231,6 +231,7 @@ class PairDropServer {
|
|||
_onPairDeviceInitiate(sender) {
|
||||
let roomSecret = this.getRandomString(64);
|
||||
let roomKey = this._createRoomKey(sender, roomSecret);
|
||||
if (sender.roomKey) this._removeRoomKey(sender.roomKey);
|
||||
sender.roomKey = roomKey;
|
||||
this._send(sender, {
|
||||
type: 'pair-device-initiated',
|
||||
|
|
Loading…
Reference in New Issue