25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-12-22 17:28:25 +01:00

If stanza is type error, allow it passing (#3290)

This commit is contained in:
Badlop 2020-05-29 12:43:28 +02:00
parent 0f43c2c528
commit 5318bf3743

View File

@ -208,9 +208,10 @@ need_check(Pkt) ->
_ ->
false
end,
IsError = (error == xmpp:get_type(Pkt)),
AllowLocalUsers = mod_block_strangers_opt:allow_local_users(LServer),
Access = mod_block_strangers_opt:access(LServer),
not (IsSelf orelse IsEmpty
not (IsSelf orelse IsEmpty orelse IsError
orelse acl:match_rule(LServer, Access, From) == allow
orelse ((AllowLocalUsers orelse From#jid.luser == <<"">>)
andalso ejabberd_router:is_my_host(From#jid.lserver))).