]> granicus.if.org Git - ejabberd/log
ejabberd
5 years agoImprove some validators
Evgeny Khramtsov [Mon, 15 Jul 2019 06:59:07 +0000 (09:59 +0300)]
Improve some validators

5 years agomod_http_fileserver: Unregister 'reopen_log_hook'
Holger Weiss [Sun, 14 Jul 2019 13:16:13 +0000 (15:16 +0200)]
mod_http_fileserver: Unregister 'reopen_log_hook'

Unregister the global 'reopen_log_hook' on termination if the module isn't
loaded for another host.

5 years agoUse correct virtual host when consulting trusted_proxies
Evgeny Khramtsov [Sat, 13 Jul 2019 09:20:06 +0000 (12:20 +0300)]
Use correct virtual host when consulting trusted_proxies

5 years agoMerge branch 'master' of github.com:processone/ejabberd
Evgeny Khramtsov [Sat, 13 Jul 2019 07:35:06 +0000 (10:35 +0300)]
Merge branch 'master' of github.com:processone/ejabberd

5 years agoFix broken ejabberd_cluster:call/5
Evgeny Khramtsov [Sat, 13 Jul 2019 07:34:59 +0000 (10:34 +0300)]
Fix broken ejabberd_cluster:call/5

5 years agoMake sure that configure is run before pc:compile on rebar3
Paweł Chmielowski [Fri, 12 Jul 2019 13:00:12 +0000 (15:00 +0200)]
Make sure that configure is run before pc:compile on rebar3

5 years agoDowngrade jose to version that works with rebar2 and del warning_as_error from it...
Paweł Chmielowski [Fri, 12 Jul 2019 12:55:01 +0000 (14:55 +0200)]
Downgrade jose to version that works with rebar2 and del warning_as_error from it's config

5 years agoBump jose version
Paweł Chmielowski [Fri, 12 Jul 2019 11:02:10 +0000 (13:02 +0200)]
Bump jose version

5 years agoDon't crash when attempt to get an option for unknown virtual host
Evgeny Khramtsov [Fri, 12 Jul 2019 10:59:33 +0000 (13:59 +0300)]
Don't crash when attempt to get an option for unknown virtual host

Log a warning instead and retry with a global scope

5 years agoAdd call/5 and multicall/5 to ejabberd_cluster
Evgeny Khramtsov [Fri, 12 Jul 2019 10:58:46 +0000 (13:58 +0300)]
Add call/5 and multicall/5 to ejabberd_cluster

5 years agoUse ejabberd_cluster:call() instead of rpc:call()
Evgeny Khramtsov [Fri, 12 Jul 2019 09:30:38 +0000 (12:30 +0300)]
Use ejabberd_cluster:call() instead of rpc:call()

5 years agoProcess unexpected messages uniformly
Evgeny Khramtsov [Fri, 12 Jul 2019 08:55:36 +0000 (11:55 +0300)]
Process unexpected messages uniformly

5 years agoImprove previous commit
Evgeny Khramtsov [Wed, 10 Jul 2019 21:13:39 +0000 (00:13 +0300)]
Improve previous commit

5 years agoGracefully report invalid encoding of a translation file
Evgeny Khramtsov [Wed, 10 Jul 2019 21:04:32 +0000 (00:04 +0300)]
Gracefully report invalid encoding of a translation file

5 years agoFix formatting
Evgeny Khramtsov [Wed, 10 Jul 2019 20:46:42 +0000 (23:46 +0300)]
Fix formatting

5 years agoMerge pull request #2900 from aquarhead/protect-muc-owner
Evgeny Khramtsov [Wed, 10 Jul 2019 20:46:08 +0000 (23:46 +0300)]
Merge pull request #2900 from aquarhead/protect-muc-owner

Protect against bad muc#owner requests

5 years agoMake sure configuration file path always represented as binary()
Evgeny Khramtsov [Wed, 10 Jul 2019 20:35:53 +0000 (23:35 +0300)]
Make sure configuration file path always represented as binary()

Fixes #2936

5 years agoFix Elixir modules detection in the configuration file
Evgeny Khramtsov [Wed, 10 Jul 2019 20:17:53 +0000 (23:17 +0300)]
Fix Elixir modules detection in the configuration file

Fixes #2937

5 years agoGracefully close inbound s2s connections
Evgeny Khramtsov [Wed, 10 Jul 2019 09:15:58 +0000 (12:15 +0300)]
Gracefully close inbound s2s connections

5 years agoAdd/improve type specs
Evgeny Khramtsov [Wed, 10 Jul 2019 07:31:51 +0000 (10:31 +0300)]
Add/improve type specs

5 years agoImprove error handling/reporting when loading language translations
Evgeny Khramtsov [Wed, 10 Jul 2019 07:30:11 +0000 (10:30 +0300)]
Improve error handling/reporting when loading language translations

Also speed up loading on multi-core machines

5 years agoFall back to map/2 and foreach/2 on single-core machines
Evgeny Khramtsov [Wed, 10 Jul 2019 07:28:37 +0000 (10:28 +0300)]
Fall back to map/2 and foreach/2 on single-core machines

5 years agoAdd type specs for mod_adhoc
Evgeny Khramtsov [Tue, 9 Jul 2019 14:02:54 +0000 (17:02 +0300)]
Add type specs for mod_adhoc

5 years agoImprove type specs for ejabberd_s2s
Evgeny Khramtsov [Tue, 9 Jul 2019 13:42:24 +0000 (16:42 +0300)]
Improve type specs for ejabberd_s2s

Also minor code cleanup

5 years agoImprove type specs of mod_muc_room
Evgeny Khramtsov [Tue, 9 Jul 2019 12:21:17 +0000 (15:21 +0300)]
Improve type specs of mod_muc_room

5 years agoImprove type specs of mod_roster
Evgeny Khramtsov [Tue, 9 Jul 2019 11:30:59 +0000 (14:30 +0300)]
Improve type specs of mod_roster

5 years agoAvoid returning 'stopped' from ejabberd_hooks:run_fold()
Evgeny Khramtsov [Tue, 9 Jul 2019 11:30:25 +0000 (14:30 +0300)]
Avoid returning 'stopped' from ejabberd_hooks:run_fold()

5 years agoGet rid of unused API functions in ejabberd_hooks
Evgeny Khramtsov [Mon, 8 Jul 2019 22:26:48 +0000 (01:26 +0300)]
Get rid of unused API functions in ejabberd_hooks

Also improve code formatting and type specs

5 years agoDon't expose internal FSM API of ejabberd_c2s
Evgeny Khramtsov [Mon, 8 Jul 2019 22:01:56 +0000 (01:01 +0300)]
Don't expose internal FSM API of ejabberd_c2s

5 years agoDon't expose internal FSM API of mod_muc_room
Evgeny Khramtsov [Mon, 8 Jul 2019 21:47:54 +0000 (00:47 +0300)]
Don't expose internal FSM API of mod_muc_room

5 years agoCheck virtual host before running the command
Evgeny Khramtsov [Mon, 8 Jul 2019 20:14:31 +0000 (23:14 +0300)]
Check virtual host before running the command

5 years agoIgnore late arrival of an already cancelled timer
Evgeny Khramtsov [Mon, 8 Jul 2019 16:32:37 +0000 (19:32 +0300)]
Ignore late arrival of an already cancelled timer

5 years agoAvoid crashing of ejabberd_iq process on invalid callback
Evgeny Khramtsov [Mon, 8 Jul 2019 07:45:13 +0000 (10:45 +0300)]
Avoid crashing of ejabberd_iq process on invalid callback

5 years agoDebug hooks
Evgeny Khramtsov [Mon, 8 Jul 2019 06:57:33 +0000 (09:57 +0300)]
Debug hooks

5 years agoUse maps instead of dict
Evgeny Khramtsov [Mon, 8 Jul 2019 06:55:32 +0000 (09:55 +0300)]
Use maps instead of dict

5 years agoUse ets and maps instead of dict
Evgeny Khramtsov [Mon, 8 Jul 2019 06:46:50 +0000 (09:46 +0300)]
Use ets and maps instead of dict

5 years agoImprove formatting of exceptions
Evgeny Khramtsov [Sun, 7 Jul 2019 19:12:14 +0000 (22:12 +0300)]
Improve formatting of exceptions

5 years agoFix return type in try_set_password()
Evgeny Khramtsov [Sun, 7 Jul 2019 09:16:04 +0000 (12:16 +0300)]
Fix return type in try_set_password()

Fixes #2932

5 years agoAvoid routing packets through a single process
Evgeny Khramtsov [Sat, 6 Jul 2019 09:30:57 +0000 (12:30 +0300)]
Avoid routing packets through a single process

5 years agoFix validator of option ejabberd_service->hosts
Evgeny Khramtsov [Sat, 6 Jul 2019 07:38:25 +0000 (10:38 +0300)]
Fix validator of option ejabberd_service->hosts

Fixes #2929

5 years agoDo not call the same function twice
Evgeny Khramtsov [Sat, 6 Jul 2019 07:21:01 +0000 (10:21 +0300)]
Do not call the same function twice

5 years agoRestore room when receiving message or generic iq for not started room
Paweł Chmielowski [Fri, 5 Jul 2019 11:46:48 +0000 (13:46 +0200)]
Restore room when receiving message or generic iq for not started room

5 years agoLimit number of rooms that we return for disco_items from muc
Paweł Chmielowski [Fri, 5 Jul 2019 09:08:32 +0000 (11:08 +0200)]
Limit number of rooms that we return for disco_items from muc

We will limit it to max_room_discoitems and return rsm that would allow
fetching more

5 years agoAdd forgotten file
Evgeny Khramtsov [Fri, 5 Jul 2019 07:49:27 +0000 (10:49 +0300)]
Add forgotten file

5 years agoDistribute routing of MUC messages accross all CPU cores
Evgeny Khramtsov [Fri, 5 Jul 2019 07:35:31 +0000 (10:35 +0300)]
Distribute routing of MUC messages accross all CPU cores

Also relay as less stanzas as possible through mod_muc workers

5 years agoPropagate max_fsm_queue to all modules started as gen_server
Evgeny Khramtsov [Thu, 4 Jul 2019 07:26:59 +0000 (10:26 +0300)]
Propagate max_fsm_queue to all modules started as gen_server

5 years agoMake return type of sql_transaction() consistent
Evgeny Khramtsov [Thu, 4 Jul 2019 06:27:51 +0000 (09:27 +0300)]
Make return type of sql_transaction() consistent

5 years agoDon't call ejabberd_option from ejabberd_options
Evgeny Khramtsov [Wed, 3 Jul 2019 16:23:05 +0000 (19:23 +0300)]
Don't call ejabberd_option from ejabberd_options

5 years agoFix jwt_key option processing
Evgeny Khramtsov [Wed, 3 Jul 2019 16:16:54 +0000 (19:16 +0300)]
Fix jwt_key option processing

5 years agoUse correct virtual host
Evgeny Khramtsov [Wed, 3 Jul 2019 16:08:38 +0000 (19:08 +0300)]
Use correct virtual host

5 years agoFix formatting
Evgeny Khramtsov [Wed, 3 Jul 2019 09:58:59 +0000 (12:58 +0300)]
Fix formatting

5 years agoMonitor routes
Evgeny Khramtsov [Wed, 3 Jul 2019 07:39:03 +0000 (10:39 +0300)]
Monitor routes

Clean route table from the process that died unexpectedly.
This usually may happen when the corresponding process
gets killed by OOM killer during overload.

5 years agoFix 'request_handlers' transformation
Evgeny Khramtsov [Wed, 3 Jul 2019 06:54:56 +0000 (09:54 +0300)]
Fix 'request_handlers' transformation

Fixes #2925

5 years agoAvoid using ! in ejabberd_router and mod_offline
Evgeny Khramtsov [Wed, 3 Jul 2019 06:42:18 +0000 (09:42 +0300)]
Avoid using ! in ejabberd_router and mod_offline

5 years agoRead jwt_key from file
Alexey Shchepin [Wed, 3 Jul 2019 02:32:58 +0000 (05:32 +0300)]
Read jwt_key from file

5 years agoAvoid last handled stanzas cache to grow indefinitely
Evgeny Khramtsov [Mon, 1 Jul 2019 17:43:57 +0000 (20:43 +0300)]
Avoid last handled stanzas cache to grow indefinitely

5 years agoUpdate Spanish and Catalan translations
Badlop [Mon, 1 Jul 2019 15:50:57 +0000 (17:50 +0200)]
Update Spanish and Catalan translations

5 years agoInvalidate proper cache when using mam for offline in pop_messages
Paweł Chmielowski [Mon, 1 Jul 2019 12:30:21 +0000 (14:30 +0200)]
Invalidate proper cache when using mam for offline in pop_messages

5 years agoFix a condition in ejabberd_auth_jwt
Alexey Shchepin [Mon, 1 Jul 2019 11:44:17 +0000 (14:44 +0300)]
Fix a condition in ejabberd_auth_jwt

5 years agoMake count_offline_messages cache work when offline uses mam for storage
Paweł Chmielowski [Mon, 1 Jul 2019 11:36:05 +0000 (13:36 +0200)]
Make count_offline_messages cache work when offline uses mam for storage

This also replace existing cache for checking if spool is empty with this
cache.

5 years agoGet rid of useless dialyzer instructions
Evgeny Khramtsov [Mon, 1 Jul 2019 07:36:20 +0000 (10:36 +0300)]
Get rid of useless dialyzer instructions

5 years agoBump cache_tab version
Evgeny Khramtsov [Mon, 1 Jul 2019 06:26:56 +0000 (09:26 +0300)]
Bump cache_tab version

5 years agoFix ejabberd_auth_jwt return types and regenerate ejabberd_option.erl
Evgeny Khramtsov [Mon, 1 Jul 2019 06:05:33 +0000 (09:05 +0300)]
Fix ejabberd_auth_jwt return types and regenerate ejabberd_option.erl

5 years agoAuthentication using JWT tokens
Alexey Shchepin [Mon, 1 Jul 2019 02:01:55 +0000 (05:01 +0300)]
Authentication using JWT tokens

5 years agoCache number of offline messages
Evgeny Khramtsov [Sun, 30 Jun 2019 18:14:37 +0000 (21:14 +0300)]
Cache number of offline messages

5 years agoUse new ets_cache API in ejabberd_auth
Evgeny Khramtsov [Sun, 30 Jun 2019 14:15:43 +0000 (17:15 +0300)]
Use new ets_cache API in ejabberd_auth

5 years agoAvoid using broad p1_queue:queue() type wherever possible
Evgeny Khramtsov [Fri, 28 Jun 2019 19:16:29 +0000 (22:16 +0300)]
Avoid using broad p1_queue:queue() type wherever possible

5 years agoUse yconf validator for custom Mnesia schemas
Evgeny Khramtsov [Thu, 27 Jun 2019 12:23:21 +0000 (15:23 +0300)]
Use yconf validator for custom Mnesia schemas

5 years agoAvoid using broad map() type wherever possible
Evgeny Khramtsov [Thu, 27 Jun 2019 12:22:27 +0000 (15:22 +0300)]
Avoid using broad map() type wherever possible

5 years agoUse correct rr_type()
Evgeny Khramtsov [Thu, 27 Jun 2019 08:35:56 +0000 (11:35 +0300)]
Use correct rr_type()

5 years agoFix type specs
Evgeny Khramtsov [Thu, 27 Jun 2019 08:32:54 +0000 (11:32 +0300)]
Fix type specs

5 years agoMake sure queue bouncing doesn't yield into infinite recursion
Evgeny Khramtsov [Wed, 26 Jun 2019 08:56:25 +0000 (11:56 +0300)]
Make sure queue bouncing doesn't yield into infinite recursion

5 years agoDeprecate 'route_subdomains' option
Evgeny Khramtsov [Wed, 26 Jun 2019 07:40:30 +0000 (10:40 +0300)]
Deprecate 'route_subdomains' option

This option was introduced to fulfill requirement of RFC3920 10.3,
but in practice it was very inconvenient and many admins were
forced to change its value to 's2s' (i.e. to behaviour that
violates the RFC). Also, it seems like in RFC6120 this requirement
no longer presents.

Those admins who used this option to block s2s with their subdomains
can use 's2s_access' option for the same purpose.

5 years agoUse correct stacktrace in logging macros
Evgeny Khramtsov [Tue, 25 Jun 2019 21:05:41 +0000 (00:05 +0300)]
Use correct stacktrace in logging macros

By calling erlang:get_stacktrace() inside a lager function
we obtain actually a stacktrace of the lager function, not
the one we got during exception. This is not a problem for
newest Erlang versions though.

5 years agoUse proper loglevel to log resumption failures
Evgeny Khramtsov [Tue, 25 Jun 2019 17:42:54 +0000 (20:42 +0300)]
Use proper loglevel to log resumption failures

5 years agoStore muc_subscribers in process dict if get_subscribed_rooms not available
Paweł Chmielowski [Tue, 25 Jun 2019 14:41:47 +0000 (16:41 +0200)]
Store muc_subscribers in process dict if get_subscribed_rooms not available

5 years agoDon't propagate downstream already handled message
Evgeny Khramtsov [Tue, 25 Jun 2019 11:36:17 +0000 (14:36 +0300)]
Don't propagate downstream already handled message

5 years agoCall ejabberd_s2s:allow_host/2 with correct virtual host
Evgeny Khramtsov [Mon, 24 Jun 2019 18:18:57 +0000 (21:18 +0300)]
Call ejabberd_s2s:allow_host/2 with correct virtual host

5 years agoReport invalid translation strings
Evgeny Khramtsov [Mon, 24 Jun 2019 18:09:29 +0000 (21:09 +0300)]
Report invalid translation strings

5 years agoMake logging messages more consistent
Evgeny Khramtsov [Mon, 24 Jun 2019 17:32:34 +0000 (20:32 +0300)]
Make logging messages more consistent

5 years agoCheck if mod_last is loaded before calling its functions
Evgeny Khramtsov [Mon, 24 Jun 2019 15:47:51 +0000 (18:47 +0300)]
Check if mod_last is loaded before calling its functions

5 years agoUse "begin ... end" in logging macros
Evgeny Khramtsov [Mon, 24 Jun 2019 15:47:19 +0000 (18:47 +0300)]
Use "begin ... end" in logging macros

5 years agoDeprecated access_commands option
Evgeny Khramtsov [Mon, 24 Jun 2019 14:20:29 +0000 (17:20 +0300)]
Deprecated access_commands option

5 years agoMake ejabberd_xmlrpc working as a listening module again
Evgeny Khramtsov [Mon, 24 Jun 2019 14:13:34 +0000 (17:13 +0300)]
Make ejabberd_xmlrpc working as a listening module again

Fixes #2915

5 years agoDon't crash on empty avatar data
Evgeny Khramtsov [Mon, 24 Jun 2019 14:00:51 +0000 (17:00 +0300)]
Don't crash on empty avatar data

5 years agoUse correct virtual host for s2s options
Evgeny Khramtsov [Sun, 23 Jun 2019 16:37:54 +0000 (19:37 +0300)]
Use correct virtual host for s2s options

5 years agoAvoid code duplication in gen_mod
Evgeny Khramtsov [Sun, 23 Jun 2019 14:06:53 +0000 (17:06 +0300)]
Avoid code duplication in gen_mod

5 years agoLet it crash on unspecified option
Evgeny Khramtsov [Sun, 23 Jun 2019 13:54:01 +0000 (16:54 +0300)]
Let it crash on unspecified option

5 years agoUpdate Russian msg file
Evgeny Khramtsov [Sun, 23 Jun 2019 11:19:57 +0000 (14:19 +0300)]
Update Russian msg file

5 years agoUpdate Russian PO file
Evgeny Khramtsov [Sun, 23 Jun 2019 11:19:15 +0000 (14:19 +0300)]
Update Russian PO file

5 years agoRespond with 'Bad Request' to unexpected 'Host' header
Evgeny Khramtsov [Sun, 23 Jun 2019 10:12:00 +0000 (13:12 +0300)]
Respond with 'Bad Request' to unexpected 'Host' header

Where "unexpected" means the host in 'Host' header is not
a registered route. The rationale is to avoid propagation
of uknown "Host" further in the code, which may lead to
nasty errors related to reading configuration values, calling
functions from ejabberd_router.erl, etc.

5 years agoValidate and set 'version' option at an earlier stage
Evgeny Khramtsov [Sun, 23 Jun 2019 09:23:22 +0000 (12:23 +0300)]
Validate and set 'version' option at an earlier stage

5 years agoRun "make translations"
Evgeny Khramtsov [Sat, 22 Jun 2019 15:15:35 +0000 (18:15 +0300)]
Run "make translations"

5 years agoGenerate paths for poedit
Evgeny Khramtsov [Sat, 22 Jun 2019 15:07:36 +0000 (18:07 +0300)]
Generate paths for poedit

5 years agoUpdate extract-tr.sh script
Evgeny Khramtsov [Sat, 22 Jun 2019 14:24:15 +0000 (17:24 +0300)]
Update extract-tr.sh script

5 years agoImprove extraction of translated strings
Evgeny Khramtsov [Sat, 22 Jun 2019 14:08:45 +0000 (17:08 +0300)]
Improve extraction of translated strings

Now every such string MUST be encapsulated into ?T() macro.
The macro itself is defined in include/translate.hrl.
Example:

-module(foo).
-export([bar/1]).
-include("translate.hrl").

bar(Lang) ->
    translate:translate(Lang, ?T("baz")).

5 years agoChange Travis OTP platform from 19.1 to 19.3
Evgeny Khramtsov [Sat, 22 Jun 2019 10:15:11 +0000 (13:15 +0300)]
Change Travis OTP platform from 19.1 to 19.3

Seems like Travis has problems with OTPs below 19.3

5 years agoDisable Elixir in Travis tests
Evgeny Khramtsov [Sat, 22 Jun 2019 08:03:29 +0000 (11:03 +0300)]
Disable Elixir in Travis tests

5 years agoFix shaper selection in ejabberd_c2s
Evgeny Khramtsov [Sat, 22 Jun 2019 07:19:17 +0000 (10:19 +0300)]
Fix shaper selection in ejabberd_c2s

5 years agoMake option 'validate_stream' global
Evgeny Khramtsov [Fri, 21 Jun 2019 18:06:32 +0000 (21:06 +0300)]
Make option 'validate_stream' global