24
1
mirror of https://github.com/processone/ejabberd.git synced 2024-06-02 21:17:12 +02:00
Commit Graph

174 Commits

Author SHA1 Message Date
Paweł Chmielowski
50f93023f5 Fix last commit 2019-05-24 15:18:15 +02:00
Paweł Chmielowski
226c09f031 Make mod_admin_extra add/delete_rosteritem reuse code from mod_roster 2019-05-24 14:02:17 +02:00
Badlop
e996579dd1 Preliminary support for SQL in process_rosteritems, and move code (#2448) 2019-05-15 10:57:55 +02:00
Badlop
cbac8a604a cache_size not applied to mod_roster on reload_config (#2769) 2019-04-02 19:52:07 +02:00
Paweł Chmielowski
538f35d05a Replace code using p1_time_compat wrapper with native functions
Since we now require R19, we shouldn't need that anymore.

There are still couple places where p1_time_compat:unique_timestamp() is
used as there is no direct equivalent.
2019-02-27 09:56:31 +01:00
Badlop
7074a39ff3 Handle versioning result when shared roster group has remote account (#2692) 2019-02-06 12:36:01 +01:00
Badlop
55417dfb37 Update copyright to 2019 (#2756) 2019-01-08 22:53:27 +01:00
Paweł Chmielowski
c88a2d0569 Add code for handling deprecations of get_stacktrace() 2018-12-13 11:46:53 +01:00
Holger Weiss
1c1694c6bf mod_roster: Don't set version to "not_found"
Don't include a "ver" attribute with roster pushes if no roster version
is available.
2018-12-10 21:38:14 +01:00
Badlop
f2bd2f6e37 When unknown roster version, return an acceptable version ID binary (#2709) 2018-12-10 20:30:42 +01:00
Badlop
0ae3f624ca Revert "Let deliver unsubscribe stanza when no roster push is required (#2598)"
This reverts commit 86048f8a25.
2018-12-05 12:17:16 +01:00
Badlop
86048f8a25 Let deliver unsubscribe stanza when no roster push is required (#2598) 2018-12-05 11:45:54 +01:00
Evgeniy Khramtsov
88d0b71d58 Get stacktrace out of lager context
Calling erlang:get_stacktrace() inside lager functions produces
stacktraces of the logging function itself, not the function which has failed.
2018-09-01 19:37:26 +03:00
Evgeniy Khramtsov
ed1ee6061e Move move randoms module to p1_utils repo 2018-07-05 11:51:49 +03:00
Evgeniy Khramtsov
8879d1d533 Avoid code duplication when checking presence subscription 2018-06-28 10:37:20 +03:00
Evgeniy Khramtsov
fd8e07af47 Get rid of ejabberd.hrl header
The header consisted of too many unrelated stuff and macros misuse.
Some stuff is moved into scram.hrl and type_compat.hrl.
All macros have been replaced with the corresponding function calls.

TODO: probably type_compat.hrl is not even needed anymore since
we support only Erlang >= OTP 17.5
2018-06-14 14:00:47 +03:00
Holger Weiss
3cf4fbc7b0 mod_roster: Use 'lserver' for configuration lookup 2018-04-13 00:12:07 +02:00
Evgeniy Khramtsov
bb20e5f3fa Apply some dirty hacks for mod_shared_roster
Probably this fixes #1846
2018-03-19 12:32:43 +03:00
Alexey Shchepin
e15595df64 Add 'new_sql_schema' config option, --enable-new-sql-schema now sets its default value to true (#2239) 2018-03-15 17:55:05 +03:00
Evgeniy Khramtsov
66fc1bf3b6 Remove 'iqdisc' option
Since we got rid of all bottle-neck processes and we have
a connection pool for every database, the option is no longer
needed and in fact is detrimental: in practice what you get
is just a bunch of overloaded processes in the IQ handlers pool
no matter how much you increase the `iqdisc` value.

Given that there are close to zero operators understanding
the meaning of the option and, hence, not using it all,
it's not simply deprecated but completely removed.

The commit also deprecates the following functions:
- gen_iq_handler:add_iq_handler/6
- gen_iq_handler:handle/5
- gen_iq_handler:iqdisc/1
2018-02-11 12:54:15 +03:00
Evgeniy Khramtsov
6e5439db5c Find and fix typos using 'codespell' 2018-01-27 19:35:38 +03:00
Evgeniy Khramtsov
4b012a99d2 Introduce option 'captcha' for mod_block_strangers
When the option is set to `true`, the module will generate
CAPTCHA challenges for incoming subscription requests. The option
also implies that option `drop` is set to `true`. Note that
the module won't generate CAPTCHA challenges for messages: they
will still be rejected if `drop` is set to `true`.

Fixes #2246
2018-01-26 15:02:06 +03:00
Evgeniy Khramtsov
ba2b650464 Introduce new gen_mod callback: mod_options/1
The callback is supposed to provide known options and their default
values, as long as the documentation. Passing default values into
get_mod functions is now deprecated: all defaults should be provided
by the Mod:mod_options/1 callback.
2018-01-23 10:54:52 +03:00
Evgeniy Khramtsov
cdc7c1d1ed Update copyright dates 2018-01-05 23:18:58 +03:00
Paweł Chmielowski
e6d1ff85f1 Use bare jid when processing roster subscriptions 2017-12-27 16:14:47 +01:00
Alexey Shchepin
78dfb832b8 Add SQL_INSERT macro and update SQL queries to use server_host field 2017-11-02 18:21:40 +03:00
Evgeniy Khramtsov
d7250111ce Reuse some translation strings 2017-09-24 14:32:37 +03:00
Badlop
101e808124 Fix warning in previous commit 2017-08-04 13:09:17 +02:00
Badlop
0516a3dc0e Remove unused 'managers' option, related to the deferred XEP-0321 (#1443) 2017-08-04 12:29:15 +02:00
Evgeniy Khramtsov
35d19b32f4 Implement cache for mod_privacy/mod_blocking 2017-05-20 22:36:32 +03:00
Evgeniy Khramtsov
fc794b680a Add cache options to the validator 2017-05-17 16:03:41 +03:00
Evgeniy Khramtsov
7165196211 Get rid of unused variable 2017-05-17 15:24:32 +03:00
Evgeniy Khramtsov
f782955c06 Implement cache for roster 2017-05-17 14:47:35 +03:00
Evgeniy Khramtsov
cf53d834e9 Introduce 'iqdisc' global option 2017-05-04 12:24:47 +03:00
Evgeniy Khramtsov
fddd6110e0 Don't validate an option in gen_mod:get*opt() functions
The changes are very similar to those from previous commit:
* Now there is no need to pass validating function in
  gen_mod:get_opt() and gen_mod:get_module_opt() functions,
  because the modules' configuration keeps already validated values.
* New functions gen_mod:get_opt/2 and gen_mod:get_module_opt/3 are
  introduced.
* Functions gen_mod:get_opt/4 and get_module_opt/5 are deprecated.
  If the functions are still called, the "function" argument is
  simply ignored.
* Validating callback Mod:listen_opt_type/1 is introduced to validate
  listening options at startup.
2017-04-30 19:01:47 +03:00
Alexey Shchepin
069d28b1ed Get rid of p1_sha calls 2017-03-14 02:31:51 +03:00
Evgeniy Khramtsov
c1439ddd5b Get rid of jid:to_string/1 and jid:from_string/1 2017-02-26 10:07:12 +03:00
Evgeniy Khramtsov
603ec9cb19 Don't pass empty resource to jid:make() 2017-02-25 10:01:01 +03:00
Evgeniy Khramtsov
3c4057ff55 Reload modules when reloading configuration file 2017-02-22 19:46:47 +03:00
Evgeniy Khramtsov
940ca9311d Fix some dialyzer warnings 2017-02-18 09:36:27 +03:00
Evgeniy Khramtsov
8b2d308498 Change routing API
Now 'From' and 'To' arguments must be omitted in functions
and structures related to routing.
The commit deprecates the following functions:
     ejabberd_router:route/3 in favor of ejabberd_router:route/1
     ejabberd_router:route_error/4 in favor of ejabberd_router:route_error/2
     ejabberd_local:route_iq/4 in favor of ejabberd_local:route_iq/2
     ejabberd_local:route_iq/5 in favor of ejabberd_local:route_iq/3
The format of {route, From, To, Packet} is changed in favor of {route, Packet}
2017-02-16 11:10:24 +03:00
Evgeniy Khramtsov
435e5e6263 Make test suite working again 2017-01-23 13:51:05 +03:00
Evgeniy Khramtsov
d5d906184f Merge branch 'new_stream'
Conflicts:
	src/cyrsasl.erl
	src/ejabberd_c2s.erl
	src/ejabberd_cluster.erl
	src/ejabberd_frontend_socket.erl
	src/ejabberd_node_groups.erl
	src/ejabberd_router.erl
	src/mod_bosh.erl
	src/mod_ip_blacklist.erl
	src/mod_muc_mnesia.erl
	src/mod_offline.erl
	src/mod_proxy65_sm.erl
2017-01-20 19:35:46 +03:00
Evgeniy Khramtsov
0baaad30b1 Implement database backend interface for MUC, BOSH and auth_anonyous 2017-01-13 12:03:39 +03:00
Evgeniy Khramtsov
1e55e018e5 Adopt remaining code to support new hooks 2017-01-09 17:02:17 +03:00
Badlop
5fdd1c39fe Update copyright date automatically (#1442) 2017-01-02 21:42:06 +01:00
Evgeniy Khramtsov
309bdfbe28 Add xmpp_stream_out behaviour and rewrite s2s/SM code 2016-12-28 09:47:11 +03:00
Evgeniy Khramtsov
5cc8e807df Initial version of new XMPP stream behaviour (for review) 2016-12-11 15:03:37 +03:00
Christophe Romain
fbfbb96872 Improve ODBC import 2016-11-22 14:48:01 +01:00
Evgeniy Khramtsov
b8dcc911a3 Make common tests working again 2016-11-18 13:38:08 +03:00