25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-12-18 17:24:31 +01:00
Commit Graph

515 Commits

Author SHA1 Message Date
Evgeniy Khramtsov
69de1780a0 Introduce --enable-stun and --enable-sip configure options
STUN/TURN and SIP is not compiled by default anymore.
Use --enable-stun, --enable-sip or --enable-all to enable them.
2017-05-23 13:12:48 +03:00
Evgeniy Khramtsov
3e35d44b0f Replace 'if_version_above' directive with 'if_have_fun' 2017-05-17 19:37:06 +03:00
Evgeniy Khramtsov
f782955c06 Implement cache for roster 2017-05-17 14:47:35 +03:00
Evgeniy Khramtsov
061d5f2380 Shut up dialyzer/xref if public_key:short_name_hash/1 is not available 2017-05-13 13:11:08 +03:00
Evgeniy Khramtsov
633b68db11 Use cache for authentication backends
The commit introduces the following API incompatibilities:

In ejabberd_auth.erl:
* dirty_get_registered_users/0 is renamed to get_users/0
* get_vh_registered_users/1 is renamed to get_users/1
* get_vh_registered_users/2 is renamed to get_users/2
* get_vh_registered_users_number/1 is renamed to count_users/1
* get_vh_registered_users_number/2 is renamed to count_users/2

In ejabberd_auth callbacks
* plain_password_required/0 is replaced by plain_password_required/1
  where the argument is a virtual host
* store_type/0 is replaced by store_type/1 where the argument is
  a virtual host
* set_password/3 is now an optional callback
* remove_user/3 callback is no longer needed
* remove_user/2 now should return `ok | {error, atom()}`
* is_user_exists/2 now must only be implemented for backends
  with `external` store type
* check_password/6 is no longer needed
* check_password/4 now must only be implemented for backends
  with `external` store type
* try_register/3 is now an optional callback and should return
  `ok | {error, atom()}`
* dirty_get_registered_users/0 is no longer needed
* get_vh_registered_users/1 is no longer needed
* get_vh_registered_users/2 is renamed to get_users/2
* get_vh_registered_users_number/1 is no longer needed
* get_vh_registered_users_number/2 is renamed to count_users/2
* get_password_s/2 is no longer needed
* get_password/2 now must only be implemented for backends with
  `plain` or `scram` store type

Additionally, the commit introduces two new callbacks:
* use_cache/1 where the argument is a virtual host
* cache_nodes/1 where the argument is a virtual host

New options are also introduced: `auth_use_cache`, `auth_cache_missed`,
`auth_cache_life_time` and `auth_cache_size`.
2017-05-11 14:37:21 +03:00
Konstantinos Kallas
02dbe39b06 Examining jose functionality 2017-05-09 23:27:37 +03:00
Evgeniy Khramtsov
3241c2506b Introduce 'sql_connect_timeout' option (#1698) 2017-05-05 16:25:10 +03:00
Evgeniy Khramtsov
6658c0d386 Bump cache_tab version 2017-04-27 20:07:44 +03:00
Evgeniy Khramtsov
0b93cb7ece Store options using p1_options module 2017-04-27 19:44:58 +03:00
Badlop
c0eb85ce53 Allow a room admin also to subscribe another JID 2017-04-26 01:30:12 +02:00
Evgeniy Khramtsov
18433e289f Add clear_cache admin command 2017-04-22 11:33:39 +03:00
Evgeniy Khramtsov
a26f90a346 Use new cache API in mod_caps 2017-04-20 18:18:26 +03:00
Holger Weiss
3adf720bc1 Use #jid{} type for #muc_unsubscribe.jid 2017-04-19 22:18:23 +02:00
Evgeniy Khramtsov
e40baf0bda Use cache in front of Redis/SQL RAM backends 2017-04-14 13:57:52 +03:00
Paweł Chmielowski
aa7d5df6a0 Bump xmpp dependency, it's required by previous commit 2017-04-14 09:47:25 +02:00
Christophe Romain
265aa54bc2 Use p1_utils 1.0.8 2017-04-11 08:11:29 +02:00
Evgeniy Khramtsov
e30d41e5f0 Merge branch 'new_queue'
Conflicts:
	rebar.config
	src/mod_muc_admin.erl
2017-03-24 13:27:56 +03:00
Christophe Romain
232cb3dd45 Update dependencies 2017-03-22 10:06:21 +01:00
Christophe Romain
b6e1858ce6 Update xmpp and fast_tls versions 2017-03-20 15:33:55 +01:00
Evgeniy Khramtsov
f3ecba0445 Use new xdata compiler API 2017-03-20 09:57:11 +03:00
Evgeniy Khramtsov
91245141e9 Set translation callback on startup 2017-03-17 21:35:02 +03:00
Evgeniy Khramtsov
4b1bdb563e Improve overloaded S2S queue processing 2017-03-10 20:21:04 +03:00
Evgeniy Khramtsov
02064ae12a Add support for file-based queues
It's now possible to use files as internal packet queues.
The following options are introduced:

* queue_type: the option can be set to `ram` (default) or `file`.
  The option can be set per virtual host.
* queue_dir: path to the directory where queues will be allocated.
  The default is 'queue' directory inside Mnesia directory.
  This is a global option and cannot be set per virtual host.
2017-03-10 15:12:43 +03:00
Evgeniy Khramtsov
8b29af629b Best Practices for Use of SASL EXTERNAL with Certificates (XEP-0178) support
It is now possible for client connections to login using PKIX certificates.
This is disabled by default, to enable it:

- either set 'tls_verify: true' and 'cafile: /path/to/CAfile'
  in the corresponding listener's section
- or set equivalent per-vhost options 'c2s_tls_verify' and 'c2s_cafile'
2017-03-07 14:20:50 +03:00
Evgeniy Khramtsov
719b4d1183 Don't perform useless resourceprep 2017-02-27 13:58:57 +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
Christophe Romain
1030f041e3 Update dependencies 2017-02-23 18:13:10 +01:00
Evgeniy Khramtsov
bbfd089b7e Don't count resent stanzas
Thanks to Holger Weiß for an advise
2017-02-21 08:44:39 +03:00
Paweł Chmielowski
5b019ab48c Disable undefined_function_calls xref_check
It looks like it will calling undefined function still will be catched
by xref_queries
2017-02-15 14:12:07 +01:00
Paweł Chmielowski
0b304731c5 Use newer p1_utils 2017-02-14 15:06:00 +01:00
Paweł Chmielowski
cad02bb1b0 Add more check to make xref 2017-02-14 14:39:24 +01:00
Christophe Romain
85eb8f022c Depend on fast_xml-1.1.20 2017-01-31 11:02:23 +01:00
Paweł Chmielowski
326e8da06d Use newer version of epam 2017-01-29 14:51:03 +01:00
Paweł Chmielowski
44a9ceac0b More changes that are required from p1_pam -> epam 2017-01-29 14:35:22 +01:00
Paweł Chmielowski
5c1168c33f Change name of pam dep from p1_pam to epam
We need to use same name as .app file or rebar complains
2017-01-29 14:26:46 +01:00
Paweł Chmielowski
2f3f6f8b71 Improve compilation with rebar3 2017-01-26 16:45:04 +01:00
Alexey Shchepin
8b5e6e4a13 Compatibility with R17 in mod_block_strangers 2017-01-23 19:04:22 +03:00
Christophe Romain
39cfee239d Use xmpp 1.1.6 2017-01-20 11:51:56 +01:00
Evgeniy Khramtsov
03667d0c73 Add SSL support for SQL connections
Currently only PostgreSQL is supported.
This requires p1_pgsql-1.1.2 and higher.
2017-01-10 17:40:38 +03:00
Christophe Romain
f2acf57412 update deps 2017-01-10 15:11:41 +01:00
Badlop
5fdd1c39fe Update copyright date automatically (#1442) 2017-01-02 21:42:06 +01:00
Christophe Romain
ed679279fd Cleanup file headers 2016-12-27 10:57:50 +01:00
Paweł Chmielowski
08f73a5aeb Update deps 2016-12-22 15:10:57 +01:00
Mickael Remond
1c8edd07a1
Update xmpp lib version and fix path when using deps.get and compile in same commande 2016-12-06 17:54:21 +01:00
Paweł Chmielowski
23786c95c9 Grab new version of xmpp dep 2016-12-02 16:28:14 +01:00
Christophe Romain
3ac73f9607 Update dependencies 2016-11-25 13:02:31 +01:00
Evgeniy Khramtsov
993cbcb133 Use new version of xmpp 2016-11-25 09:39:09 +03:00
Paweł Chmielowski
b14843d098 Add missing -callbacks 2016-11-24 12:44:21 +01:00
Holger Weiss
d12210f4e1 Use new versions of fast_xml and xmpp 2016-11-24 10:45:57 +01:00
Evgeniy Khramtsov
13c6039700 Use xmpp_util.erl from XMPP library 2016-11-19 13:57:25 +03:00
Evgeniy Khramtsov
9aff7e52a8 Switch to stand-alone XMPP library 2016-11-19 13:03:33 +03:00
Paweł Chmielowski
d00a634025 Fix includes in eunit compilation flags 2016-11-18 14:02:47 +01:00
Christophe Romain
45e77ea483 Remove useless NO_EXT_LIB flag 2016-11-18 12:25:01 +01:00
Paweł Chmielowski
41794c57d6 Use new version of fast_xml 2016-11-15 10:02:21 +01:00
Christophe Romain
309962fb8b Use p1_http from p1_utils 1.0.6 2016-11-14 16:52:03 +01:00
Evgeniy Khramtsov
75c15d3853 Make xref working again if elixir is disabled 2016-11-13 14:29:52 +03:00
Evgeniy Khramtsov
4c5460f0bd Get rid of compile warnings for random/crypto modules on R19 2016-10-18 08:17:21 +03:00
Christophe Romain
662b6f1020 Update riakc to support r19 2016-09-16 14:59:06 +02:00
Paweł Chmielowski
4bd45bada7 Start elixir config code only if elixir was enabled in configure script 2016-09-08 16:29:45 +02:00
Peter Lemenkov
e13edff6ae Remove no longer necessary p1_xmlrpc
Ths module was superceded by fast_xml in commit
processone/ejabberd@dfc29ea03c. So let's remove it entirely to
avoid any confusion.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
2016-08-17 18:32:09 +03:00
Mickael Remond
c4b14d045a
Update to released version 2016-08-07 18:31:55 +02:00
Paweł Chmielowski
d969e917c6 Use newer samerlib/moka 2016-08-05 13:03:22 +02:00
Paweł Chmielowski
c2753cd51c Use different version of elixir depending on erlang version 2016-07-20 10:12:00 +02:00
Mickael Remond
490a758050
Upgrade Elixir version to 1.2 in rebar config
This matches the version used in mix.exs
2016-07-19 13:05:01 +02:00
Mickael Remond
1a62d4e04b
Update stringprep and iconv 2016-07-08 18:28:51 +02:00
Mickael Remond
febbc2bb5a
Update dependencies 2016-07-08 11:40:28 +02:00
Paweł Chmielowski
16b1d8541a Grab new p1_utils that has fix for R19 2016-07-01 21:41:12 +02:00
Paweł Chmielowski
0737958b45 Fix compilation issues on R19 2016-07-01 21:20:10 +02:00
Mickael Remond
88ac1dc56b
Update dependencies 2016-06-30 11:33:38 +02:00
Christophe Romain
94461948db Update dependencies for 16.06x 2016-06-24 11:12:18 +02:00
Jerome Sautret
a9b456ccb3 xref was broken when Elixir wasn't enabled 2016-06-23 10:23:02 +02:00
Paweł Chmielowski
2ebdd8915e Compile gen_mod early to help with undefined behaviour warnings 2016-06-23 10:22:01 +02:00
Paweł Chmielowski
db240413ab Disable cover analyzys on R17 as this causes problems with elixir tests 2016-05-31 11:29:19 +02:00
Mickael Remond
d18fe138aa
Update esip and stun to match Fast TLS version 2016-04-27 16:22:47 +02:00
Christophe Romain
d6f02a51e4 Use fast_tls 1.0.3 2016-04-27 16:18:24 +02:00
Mickael Remond
26d3a978cc
Update stun and esip dependencies 2016-04-27 12:19:55 +02:00
Mickael Remond
d1db9f92c4
We now use fast_tls 1.0.2 2016-04-27 11:54:50 +02:00
Paweł Chmielowski
86dfbe6ece Make sure that ejabberd_sm sid are unique 2016-04-08 10:52:29 +02:00
richp10
acc11195f8 upgrade stringprep to 1.03 2016-04-06 08:40:10 +00:00
Mickael Remond
3290a5ff15 Force protobuffs version to be able to use new meck release 2016-03-31 16:05:18 +02:00
Mickael Remond
91233eafaa Use version of moka that do not depend on proper 2016-03-31 14:36:30 +02:00
Alexey Shchepin
3dc55c6d47 Commands refactor, first pass.
- add API versionning
- changed error handling, based on exception
- commands moved/merged from mod_admin_p1 to mod_admin_extra
- command bufixes
- add some elixir unit test cases

Squashed commit of the following:

commit dd59855b3486f78a9349756e4f102e79b3accff8
Merge: 14e8ffc 506e08e
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Fri Oct 30 11:43:18 2015 +0100

    Merge branch '3.2.x' into api

commit 14e8ffce78cbea6c8605371d1fc50a0c1d1e012c
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Tue Oct 27 16:35:17 2015 +0100

    Added OAuth tests to ejabberd_commands

commit f81c550c14628edfe4861c228576cb767924366a
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Tue Oct 27 16:34:55 2015 +0100

    Added some mod_http_api tests

commit 6a64578d5b2ba532a2feb6503ed98561e56d5d53
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Mon Oct 26 15:29:36 2015 +0100

    Fix get_last command test

    Previous version won't work with dst.

commit 27e0cde9e9c1f001effe68f8424a365ad947c068
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Fri Oct 23 17:59:34 2015 +0200

    Add tests on admin command policy

commit 19dad8d54f54c9fabd454280483cccfb06c8e78a
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Fri Oct 23 16:49:36 2015 +0200

    Added command related tests (http api & user policy)

commit e0e596ab4a3f3a70aba5f374f028939ab794de33
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Fri Oct 23 16:49:16 2015 +0200

    Fix command call.

commit 128cd7d1ede3c47a34f8ec3a750c980ccad2c61d
Merge: 60c4c4c 447313c
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Thu Oct 22 14:48:39 2015 +0200

    Merge branch '3.2.x' into api

commit 60c4c4c0751302524c14219c6bc8c56a6069a689
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Thu Oct 22 14:45:57 2015 +0200

    Fix ejabberd_commands spec.

commit 8e145c28c5da762c2b93ee32327eff1db94ebfed
Merge: 397273a f13dc94
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Wed Oct 21 18:26:07 2015 +0200

    Merge branch '3.2.x' into api

commit 397273a23ed415feac87aed33da6452229793387
Merge: c30e89b f289e27
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Wed Oct 21 15:27:45 2015 +0200

    Merge branch '3.2.x' into api

commit c30e89bb8a0013bff37e61e4c6953350c9c1f313
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Wed Oct 21 12:47:02 2015 +0200

    Merge mod_http_api

commit 7b0db22b4acd48ff6fabce41c1b2525e6580a3c5
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Fri Oct 16 11:55:48 2015 +0200

    Fix exunit tests to run with common_test suites

commit d8b1a89800ac7379a57a7eb4a09c3c93c3e1e5eb
Merge: 2879ae8 63455b3
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Thu Oct 15 11:39:45 2015 +0200

    Merge branch '3.2.x' into api

commit 2879ae87ff3eee369ef3d780136b96ecff5285d1
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Wed Oct 14 14:53:44 2015 +0200

    Fix update_roster command.

commit a1d453dd7a3afda9861a8d747494a45057ad574b
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Tue Oct 13 16:14:28 2015 +0200

    API commands refactor

    Moving and/or merging commands from mod_admin_p1 to mod_admin_extra

commit b709ed26b0fc0ca4f3bdd5a59fa58ec7e3db97fa
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Wed Oct 7 15:10:01 2015 +0200

    Add tests on commands

commit 6711687bee9c672cb3d5aed0744e13420ecf6dbd
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Tue Sep 29 15:58:16 2015 +0200

    Add ejabberd_commands tests

commit df8682f419cf3877e77e36a19bca0fc55dc991f8
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Mon Sep 28 14:54:39 2015 +0200

    Added API versioning for ejabberdctl and rest commands

commit cd017b0e3aac431bc3ee807ceb7f8641e1523ef5
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Fri Sep 18 11:21:45 2015 +0200

    Better error handling of HTTP API commands.

commit ca5cb6acd8e4643f9d6c484d2277b0d7e88471e5
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Tue Sep 15 15:03:05 2015 +0200

    add commands to mod_admin_extra:
    - get_offline_count
    - get_presence
    - change_password

commit 7f583fa099e30ac2b0915669fd8f102ac565b833
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Tue Sep 15 15:02:16 2015 +0200

    Improve REST API error handling

commit 14753b1c02cdce434a786b7f80f6c09f0d210075
Author: Jerome Sautret <jerome.sautret@process-one.net>
Date:   Mon Sep 14 10:51:17 2015 +0200

    Change REST API return codes for integer type.
2016-03-31 14:53:31 +03:00
Mickael Remond
54ddc990c2 Use new fast_yaml 2016-03-29 09:21:24 +02:00
Evgeny Khramtsov
494e638f03 Merge pull request #1024 from rbarlow/luerl_release
Use the v0.2 release of luerl instead of a commit.
2016-03-25 21:29:19 +04:00
Mickael Remond
ef04dd75aa Add Coveralls support 2016-03-21 12:01:20 +01:00
Randy Barlow
7b5825a205 Use the v0.2 release of luerl instead of a commit.
The luerl project has made a tag for v0.2, which should be usable
by ejabberd. Discussion about the v0.2 release is here:

https://github.com/rvirding/luerl/issues/60
2016-03-18 14:22:59 -04:00
Mickael Remond
74053b114e When building Elixir inside ejabberd, rely on version 1.1 for Erlang R17 compliance 2016-03-16 09:01:40 +01:00
Paweł Chmielowski
304afd75ac Compile ejabberd_config early to stop undefined behaviour warnings 2016-03-04 11:32:34 +01:00
Christophe Romain
3ecd7e850c Use Elixir v1.2.3 2016-03-03 10:36:13 +01:00
Christophe Romain
fee5873310 Minor format cleanup 2016-03-03 10:34:45 +01:00
Alexey Shchepin
968576d4f2 Update p1_pgsql tag 2016-03-02 00:12:49 +03:00
Paweł Chmielowski
8c49d1e1af Disable back undefined_function_calls xref check 2016-02-29 14:56:28 +01:00
Paweł Chmielowski
59fe967ebb Enable undefined_function_calls xref option 2016-02-29 13:51:59 +01:00
Paweł Chmielowski
24617b5e25 Split long lines 2016-02-25 12:23:23 +01:00
Paweł Chmielowski
d9ec923357 Elixir want {src_dirs, ["include"]} on top of a config 2016-02-25 12:23:23 +01:00
Mickael Remond
dfc29ea03c Switch to Fast XML module 2016-02-03 19:03:17 +01:00
Mickael Remond
5539db37b6 Remove reference to p1_logger 2016-02-03 16:26:15 +01:00
Mickael Remond
71ee0d56fa Switch to fast_tls and update app names 2016-02-03 16:13:16 +01:00
Mickael Remond
9ae1371c6e Convert more dependencies to new repository / packages 2016-02-03 12:30:12 +01:00
Mickael Remond
b137ee3beb Move to new dependencies for SIP and STUN 2016-02-03 11:26:14 +01:00
Mickael Remond
99b5c5712c Move to new iconv package 2016-02-03 11:17:24 +01:00
Mickael Remond
bad50b8dd1 Move database dependencies to new repository / modules 2016-02-03 11:10:11 +01:00
Mickael Remond
ba11165fb4 Syntax highlight file + comment on rebar_elixir_plugin 2016-02-03 11:00:12 +01:00
Mickael Remond
9b837860cd Switch a few version to hex.pm version 2016-02-03 10:55:40 +01:00
Mickael Remond
e8ba7bce24 Use stringprep app name 2016-02-03 10:12:25 +01:00
Evgeniy Khramtsov
b20db3b736 Initial version of migration script from Prosody to ejabberd 2016-01-28 14:23:51 +03:00
Paweł Chmielowski
239b1c6f74 Always use lagger 2016-01-26 14:34:58 +01:00
Mickael Remond
0b492f43fe If lager is false, we will use p1_logger 2016-01-25 10:47:20 +01:00
Mickael Remond
7cc951ab1b Make sure all version are consistent before big repositories changes 2016-01-23 18:42:16 +01:00
Paweł Chmielowski
ee1cf939c5 Make --disable-debug work again 2016-01-18 13:10:28 +01:00
Badlop
f448ff608a Update copyright to 2016 (#901) 2016-01-13 12:29:14 +01:00
Christophe Romain
006e96612c We need to checkout elixir first when elixir enabled 2016-01-06 16:03:10 +01:00
Christophe Romain
efda70e73a Update dependencies 2016-01-05 16:00:47 +01:00
Paweł Chmielowski
48909bdbee Add --enable-latest-deps to configure
This option make 'rebar get-deps' command to always fetch latest versions
of deps that are developed together with ejabberd instead of using frozen
commit/branch/tag.
2015-12-18 17:20:41 +01:00
Paweł Chmielowski
99fdba0745 Convert rebar.config.script to more declarative format 2015-12-18 17:20:41 +01:00