25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-06 15:37:52 +01:00
Commit Graph

7272 Commits

Author SHA1 Message Date
Badlop
dbf1cabdcd Fix: mod_offline:store_offline_msg/1 expects a message, not list (#2312) 2018-03-02 11:44:10 +01:00
Badlop
ad0fd1eac1 Simplify result of get_room_affiliation command (#2301) 2018-03-01 19:45:16 +01:00
badlop
3003307e60
Merge pull request #2301 from tsaqova/ejabberd_commands_get_room_affiliation
add ejabberd_command to get affiliation of a user in MUC room
2018-03-01 19:37:55 +01:00
Evgeniy Khramtsov
76f827ac83 Increase log level for DIGEST-MD5 FQDN
SASL DIGEST-MD5 anyway deprecated anyway, so not point in
logging this. This is now logged in `debug` mode.
2018-02-28 21:43:43 +03:00
Evgeny Khramtsov
b5138a8ddb
Merge pull request #2311 from nosnilmot/validate-listen-opts
Validate additional listen opts
2018-02-28 19:37:57 +03:00
Stu Tomlinson
da81590fef Validate additional listen opts
The options "inet", "inet6" and "backlog" are valid listen options, but are
currently logged as errors (even though they do work):

2018-02-28 16:08:44.141 [error] <0.338.0>@ejabberd_listener:validate_module_option:630 unknown listen option 'backlog' for 'ejabberd_c2s' will be likely ignored, available options are: access, shaper, certfile, ciphers, dhfile, cafile, client_cafile, protocol_options, tls, tls_compression, starttls, starttls_required, tls_verify, zlib, max_fsm_queue

This adds the necessary validators so they are correctly recognized.
2018-02-28 16:14:35 +00:00
Yusro Tsaqova
8a41cfc0f5 add ejabberd_command to get affiliation of a user in MUC room 2018-02-28 20:22:27 +07:00
Badlop
5054a9933f Support for default values in default_room_opts 2018-02-26 17:22:37 +01:00
Paweł Chmielowski
5912c573ea Use length on fields in mysql indexes 2018-02-26 09:43:04 +01:00
Paweł Chmielowski
b2095ebcfe Simplify code for splitting auth string in cyrsasl
This may fix problem from issue #2296
2018-02-26 09:36:56 +01:00
Evgeny Khramtsov
0a67cdfb16
Merge pull request #2304 from weiss/run-auth-callbacks-earlier
Run SASL result callbacks earlier
2018-02-26 09:04:32 +03:00
Holger Weiss
c2235860ab xmpp_stream_in: Run auth result callbacks earlier
Call Mod:handle_auth_success/4 and Mod:handle_auth_failure/4 before
sending the SASL response rather than afterwards.  This way, callbacks
can send a custom response and disconnect.
2018-02-26 00:06:35 +01:00
Holger Weiss
22e43ebd8a mod_stream_mgmt: Cope with exit during resumption
Don't crash if the old process exits while it is queried for the session
state.
2018-02-24 21:50:54 +01:00
Evgeny Khramtsov
35be7d2718
Merge pull request #2299 from weiss/add-username-to-indexes
Add username to peer indexes for MAM lookups
2018-02-24 07:41:44 +03:00
Holger Weiss
f7566bd00e sql/*: Add username to peer indexes
The username is available for all MAM queries in question, and adding it
to the indexes can improve the lookup performance significantly.
2018-02-24 00:50:20 +01:00
Evgeny Khramtsov
5bf753fd2d
Merge pull request #2297 from af8a524db1/move_make_rand_string
Move make_rand_string() to 'randoms' module
2018-02-23 20:35:37 +03:00
Marc Schink
c1e5ae5308 Move make_rand_string() to 'randoms' module 2018-02-23 18:32:34 +01:00
Holger Weiss
ea87bdfbe5 mod_carboncopy: Apply cosmetic change
The xmpp:has_subtag/2 function returns a boolen() value, so it can be
used with the 'not' operator.
2018-02-22 00:46:47 +01:00
Holger Weiss
7a1ed065fe mod_carboncopy: Copy outgoing MUC PMs
Incoming MUC PMs aren't carbon-copied, as the MUC service usually forks
them.  However, don't suppress copying of outgoing PMs, where no such
forking takes place.
2018-02-22 00:40:09 +01:00
Evgeniy Khramtsov
ec0f0f7c72 Move some log messages to debug level 2018-02-21 17:12:50 +03:00
Evgeniy Khramtsov
0acc69e303 Use nicks in disco#items or disco#info report 2018-02-21 10:25:15 +03:00
Evgeniy Khramtsov
4bf4193d55 Add 'negotiation_timeout' to the known options list 2018-02-20 19:47:50 +03:00
Evgeniy Khramtsov
d625e24029 Introduce 'negotiation_timeout'
The option can be used to specify a period (in seconds) for a stream
negotiation to complete. If the timer fires, the stream is considered
as failed and the underlying connection gets closed. This is a global
option (you cannot set it per domain) and the default is 30 seconds.
2018-02-20 11:38:00 +03:00
Holger Weiss
a875195940 mod_admin_extra: Fix srg_get_info with '@all@'
Don't let the srg_get_info command crash if the roster group has '@all@'
or the '@online@' users as members.
2018-02-20 00:44:47 +01:00
Evgeniy Khramtsov
06c480106f Don't emit validator's warning if the module is not found 2018-02-19 22:07:09 +03:00
Evgeniy Khramtsov
e070e6bccb Replace ?MYLANG with connection's language wherever possible 2018-02-19 21:47:20 +03:00
Evgeniy Khramtsov
de49e7631f Push blocking related IQs from bare JID
Fixes #2287
2018-02-18 18:00:20 +03:00
Evgeniy Khramtsov
25abf8b634 Don't inject node name inside "id" attribute
Fixes #2284
2018-02-18 11:54:40 +03:00
Evgeniy Khramtsov
ff06bdf144 Don't ask other nodes to invalidate cache when the key is not updated 2018-02-18 09:02:23 +03:00
Evgeniy Khramtsov
d5afc767e6 Fix 'badmatch' crash
The crash was introduced in 4b012a99d2
2018-02-17 20:06:50 +03:00
Evgeniy Khramtsov
5704a980c5 Introduce 'access' option for mod_block_stranger
The option is supposed to be used when `allow_local_users`
and `allow_transports` are not enough. It's an ACL where `deny`
means the message will be rejected (or a CAPTCHA would be
generated for a presence), and `allow` means the sender is
whitelisted and the stanza will pass through.

The default value is `none`, which means nothing is whitelisted.
2018-02-17 18:53:35 +03:00
Evgeniy Khramtsov
cffdb06b66 Cache 'isuser' queries to external auth program 2018-02-16 20:50:22 +03:00
Evgeniy Khramtsov
f5d208441d Improve example extauth script 2018-02-16 20:34:09 +03:00
Paweł Chmielowski
71a856deaa Handle gracefully that mnesia is already loaded when starting tests 2018-02-16 16:49:48 +01:00
Christophe Romain
7e1df0752a Export helper function 2018-02-16 09:53:38 +01:00
Christophe Romain
f0ccdebf7f Export helper functions 2018-02-16 09:52:29 +01:00
Evgeniy Khramtsov
32e5a3255d Export aux functions from mod_muc_room 2018-02-16 08:28:33 +03:00
Evgeniy Khramtsov
c102a45fac Rename some keys and functions for clarity 2018-02-15 15:50:20 +03:00
Evgeniy Khramtsov
52ded14b7f Update incoming stanzas counter on invalid XML 2018-02-15 15:42:55 +03:00
Evgeniy Khramtsov
e5ba7c3f3c Better solution for a previous fix 2018-02-15 10:48:59 +03:00
Evgeniy Khramtsov
51aa9d98a7 Don't forget to add invalid XML responses to sending queue 2018-02-15 10:18:06 +03:00
Evgeniy Khramtsov
a65500b6aa Fix external components unregistration 2018-02-14 13:09:27 +03:00
Evgeniy Khramtsov
032f796292 Introduce option 'global_routes' for ejabberd_service
The option emulates legacy behaviour which registers all routes
defined in `hosts` on a component connected. This behaviour
is considered harmful in the case when it's desired to multiplex
different components on the same port, so, to disable it,
set `global_routes` to `false`. The default value is `true`,
e.g. legacy behaviour is emulated: the only reason for this is
to maintain backward compatibility with existing deployments.
2018-02-14 11:53:52 +03:00
Evgeniy Khramtsov
516f4d03a1 Fix indentation 2018-02-14 11:42:43 +03:00
Paweł Chmielowski
60a8623929 Change formatting of commands markdown documentation 2018-02-13 16:27:39 +01:00
Christophe Romain
9dbdeba6c1 Add case on create_room, avoid useless call 2018-02-13 11:08:13 +01:00
Evgeniy Khramtsov
4632f5520f Really run use_cache/1 and cache_nodes/1 callbacks for mod_mam 2018-02-13 11:38:41 +03:00
Evgeniy Khramtsov
ffe02c46e4 Let a MUC room to route presences from its bare JID
The goal for this is to provide entity capabilities (XEP-0115) and
vCard-based avatar hash (XEP-0153)
2018-02-12 17:37:36 +03:00
Evgeny Khramtsov
42794ce4e4
Merge pull request #2274 from Torxen/feature/fixed-return-value-mod_muc
Issue: mod_muc.erl expect wrong return value
2018-02-12 17:36:47 +03:00
Tobias Koch
9188a7b838 Dialyzer checks always failed because the return value of the function 'get_subscribed_rooms' in 'mod_muc_sql' is different to the defined value in 'mod_muc'. Fix was to update the return value in 'mod_muc.erl'. 2018-02-12 15:12:46 +01:00