fix: Updates token verification hooks priority. (#11105)

* fix: Updates token verification hooks priority.

Set it as the highest priorities, if denying access, better do it earlier.

* squash: Updates values.
pull/11108/head jitsi-meet_7026
Дамян Минков 3 years ago committed by GitHub
parent f0f135ac7d
commit 14cad060cb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      resources/prosody-plugins/mod_token_verification.lua

@ -78,7 +78,7 @@ module:hook("muc-room-pre-create", function(event)
if not verify_user(origin, stanza) then if not verify_user(origin, stanza) then
return true; -- Returning any value other than nil will halt processing of the event return true; -- Returning any value other than nil will halt processing of the event
end end
end); end, 99);
module:hook("muc-occupant-pre-join", function(event) module:hook("muc-occupant-pre-join", function(event)
local origin, room, stanza = event.origin, event.room, event.stanza; local origin, room, stanza = event.origin, event.room, event.stanza;
@ -86,7 +86,7 @@ module:hook("muc-occupant-pre-join", function(event)
if not verify_user(origin, stanza) then if not verify_user(origin, stanza) then
return true; -- Returning any value other than nil will halt processing of the event return true; -- Returning any value other than nil will halt processing of the event
end end
end); end, 99);
for event_name, method in pairs { for event_name, method in pairs {
-- Normal room interactions -- Normal room interactions

Loading…
Cancel
Save