Browse Source

fix: Enforces namespace for json-message.

master
damencho 3 months ago
parent
commit
86b762276c
2 changed files with 2 additions and 2 deletions
  1. 1
    1
      modules/xmpp/ChatRoom.js
  2. 1
    1
      modules/xmpp/xmpp.js

+ 1
- 1
modules/xmpp/ChatRoom.js View File

1281
             }
1281
             }
1282
         }
1282
         }
1283
 
1283
 
1284
-        const jsonMessage = $(msg).find('>json-message').text();
1284
+        const jsonMessage = $(msg).find('>json-message[xmlns="http://jitsi.org/jitmeet"]').text();
1285
 
1285
 
1286
         if (jsonMessage) {
1286
         if (jsonMessage) {
1287
             const parsedJson = this.xmpp.tryParseJSONAndVerify(jsonMessage);
1287
             const parsedJson = this.xmpp.tryParseJSONAndVerify(jsonMessage);

+ 1
- 1
modules/xmpp/xmpp.js View File

1082
             return true;
1082
             return true;
1083
         }
1083
         }
1084
 
1084
 
1085
-        const jsonMessage = $(msg).find('>json-message')
1085
+        const jsonMessage = $(msg).find('>json-message[xmlns="http://jitsi.org/jitmeet"]')
1086
             .text();
1086
             .text();
1087
         const parsedJson = this.tryParseJSONAndVerify(jsonMessage);
1087
         const parsedJson = this.tryParseJSONAndVerify(jsonMessage);
1088
 
1088
 

Loading…
Cancel
Save