FIX: calling emitPlayGlobalMessage in pusher without the admin tag will throw an error
This commit is contained in:
parent
faade46400
commit
5ebb0c94e6
2 changed files with 4 additions and 13 deletions
|
@ -364,6 +364,10 @@ export class SocketManager implements ZoneEventListener {
|
|||
}
|
||||
|
||||
emitPlayGlobalMessage(client: ExSocketInterface, playglobalmessage: PlayGlobalMessage) {
|
||||
if (!client.tags.includes('admin')) {
|
||||
//In case of xss injection, we just kill the connection.
|
||||
throw 'Client is not an admin!';
|
||||
}
|
||||
const pusherToBackMessage = new PusherToBackMessage();
|
||||
pusherToBackMessage.setPlayglobalmessage(playglobalmessage);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue