[ejabberd] Access denied by service policy

Александр icyhands at inbox.ru
Mon May 21 18:02:49 MSK 2018


I try to send stanza via XML-RPC to ejabberd service, and then receive message "Access denied by service policy". Wheh I send stanza by connected user (using perl module Net::XMPP) it works fine.
Sent (perl code):
my $r = $client->call("send_stanza", { 'from' => 'user at localhost/daemon', 'to' => 'room at muc.localhost/resource', 'stanza' => "<presence></presence>" })->result(); 
Received:
<presence from='room at muc.localhost/resource' to='user at localhost/daemon' type='error'> <error code='403' type='auth'> <forbidden xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/> <text xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'> Access denied by service policy </text> </error> </presence> 
I assume that I have a configuration error. But where is it?
ejabberd XML-RPC configuration:
- port: 4560 ip: "::" module: ejabberd_xmlrpc maxsessions: 10 timeout: 5000 access_commands: admin: commands: - send_stanza options: [] 
and
api_permissions: ... "public commands": who: - ip: "::FFFF:127.0.0.1/128" - ip: "127.0.0.1/8" what: - "*" - "!stop" - "!start" 
Ejabberd 17.07 Debian 9 Perl 5.24.1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.jabber.ru/pipermail/ejabberd/attachments/20180521/5964b3e5/attachment.html>


More information about the ejabberd mailing list