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

9659 Commits

Author SHA1 Message Date
Kirill A. Korinsky
1b77abcc9c
ejabberdctl: support OpenBSD su
OpenBSD has a different than Linux su:
 1. `-c` before username is treated as login class;
 2. it doesn't require `--` as arguments separator.

Without (1) it complains as:

    su: no such login class: exec "$0" "$@"

and without (2):

    -: --: not found

Here, I've added detection of OS via `uname -s` which routes to the
right `su`. I really think that other BSD may need it as well.
2024-11-28 10:30:30 +01:00
Badlop
7d0c20e133 mod_shared_roster: The name of a new group is lowercased
Until now it was possible to create a shared roster group with name
"Group1", and it was a different group that "group1".

From now on, new group names will be stored lowercase,
just like the username in a Jabber ID.

This only affects commands srg_add and srg_create.
All the other commands are still case sensitive, to allow admins of
existing databases with case-sensitive groups manage them.
2024-11-27 16:20:53 +01:00
Badlop
ab5a2e8d10 mod_shared_roster: Get back support for groupid@vhost in displayed
Feature first implemented by 262157c in ejabberd 2.1.10
Bug introduced with cache improvements by 5b0f0d8 in ejabberd 21.07
2024-11-27 13:54:02 +01:00
Badlop
e34c1ebcba WebAdmin: Fix link to displayed group when it is from another vhost 2024-11-27 13:54:00 +01:00
Badlop
73dbc01c2e WebAdmin: Shared group names are case sensitive, use original case instead of lowercase 2024-11-27 13:53:58 +01:00
Badlop
f0773c4ab8 mix:exs: When development tools is enabled, add debugger and wx 2024-11-25 17:23:32 +01:00
Badlop
cc5c9f6008 Fix problems introduced in two recent commits 2024-11-25 17:23:28 +01:00
Badlop
da9c591eed Improve create_rooms_file command to support vhosts with different config
Until now it created all the rooms in the storage of the first vhost
listed in the ejabberd configuration file. Similarly, it used only
the default room options defined for the first vhost.
2024-11-25 16:20:30 +01:00
Badlop
6790ab01e8 Improve example Elixir modules 2024-11-25 16:20:19 +01:00
Badlop
f9cecca362 Rename mod_presence_demo.ex to mod_example.ex 2024-11-25 16:20:16 +01:00
badlop
f4009939a6
Merge pull request #4315 from Quobis/support-loading-elixir-modules-for-auth
feat: support loading Elixir modules for auth
2024-11-25 16:08:54 +01:00
Marcos de Vera Piquero
17b5b34e3c feat: support loading Elixir modules for auth
Allow to specify an Elixir module name in `auth_method`.

If the referenced module, `M`,  cannot be loaded as `ejabberd_auth_M`,
try to load it as `Elixir.M`.
2024-11-25 15:31:27 +01:00
Badlop
c291c20a3b Fix problem starting ejabberd when first host uses SQL, other one mnesia
The problem appeared when there are several vhosts,
the first vhost uses SQL for persistent data (and RAM for volatile),
and another vhost wants to use Mnesia

Example config to trigger the problem:

  hosts:
    - mysql.localhost
    - localhost
  host_config:
    mysql.localhost:
      default_db: sql

In that case, ejabberd crashed at start with an error like:
[critical] Internal error of module mod_muc has occurred during start:
...
** exception exit: {aborted,
                     {no_exists,
                         [muc_room,
                          [{{muc_room,{'_',<<"conference.localhost">>},'_'},
                            [],
                            ['$_']}]]}}
2024-11-22 19:25:52 +01:00
Badlop
22e7ce37d4 Fix typos in previous commit 2024-11-22 19:25:49 +01:00
Badlop
2137602a6a Makefile: Add support to run "make format" when compiling with mix 2024-11-22 10:53:43 +01:00
dependabot[bot]
c7b29b5a9a Bump dialyxir from 1.4.4 to 1.4.5
Bumps [dialyxir](https://github.com/jeremyjh/dialyxir) from 1.4.4 to 1.4.5.
- [Release notes](https://github.com/jeremyjh/dialyxir/releases)
- [Changelog](https://github.com/jeremyjh/dialyxir/blob/master/CHANGELOG.md)
- [Commits](https://github.com/jeremyjh/dialyxir/compare/1.4.4...1.4.5)

---
updated-dependencies:
- dependency-name: dialyxir
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-11-22 10:53:04 +01:00
Badlop
715b5b64c6 Runtime: Test Dialyzer in Rebars jobs (#4281)
The CI workflow uses ubuntu-24.04 and setup-beam action,
so it can test only Erlang/OTP 24 and higher.

To ensure Dialyzer is also ran with older Erlang versions,
let's add Dialyzer testing to the Runtime workflow,
which uses the erlang container, and that allows
to run Erlang/OTP 20 in ubuntu-24.04.
2024-11-14 13:58:14 +01:00
Badlop
c20ed8c7b3 Runtime: Try using elixir container for Rebar3+Elixir and Mix jobs (#4281) 2024-11-14 13:58:11 +01:00
Badlop
d3baacd78e Workflows: Bump ubuntu from 22.04 to 24.04 when possible (#4281) 2024-11-14 13:58:07 +01:00
Badlop
07e20784cb New evacuate_kindly command: kick users and prevent login (#4309) 2024-11-14 13:57:47 +01:00
Badlop
9eb8bb6c40 mod_matrix_gw_s2s probably works correctly only in Erlang/OTP >= 25
In Erlang/OTP 25, the function inet_res:getbyname/3
returns {ok, Hostent} where the last tuple element of Hostent
may be h_addr_list = [inet:ip_address()]}
or H_addr_list :: [dns_data()]}

However, in Erlang/OTP 24.1 and older, that element was only of type
h_addr_list = [inet:ip_address()]}

https://erlang.org/documentation/doc-13.0-rc3/lib/kernel-8.4/doc/html/inet_res.html#getbyname-3
https://erlang.org/documentation/doc-12.1/lib/kernel-8.1/doc/html/inet_res.html#getbyname-3
2024-11-14 13:57:47 +01:00
Badlop
e10c0f3120 Bump Expat to 2.6.4 2024-11-14 13:57:47 +01:00
Badlop
6f7efebb56 Only delete offline msgs when user has MAM enabled (#4287) 2024-11-14 13:57:43 +01:00
Badlop
a657778065 Result of running "make doap" 2024-11-14 13:57:43 +01:00
Badlop
3650d94bb5 Remove XEPs that are only a client thing 2024-11-14 13:57:43 +01:00
Badlop
6a428f3d02 Add ejabberd version and implementation status for many XEPs 2024-11-14 13:57:43 +01:00
Badlop
abe1d96c58 Announce support for XEP-0384 OMEMO Encryption (#4305)
The last required piece to support XEP-0384 was
supporting max_items=max, which was added for ejabberd 21.12 in commit
8f8de0403b
2024-11-14 13:57:39 +01:00
Badlop
29a59cfe48 Add "XMPP Date and Time Profiles" implemented by xmpp and used everywhere 2024-11-14 13:49:41 +01:00
Holger Weiss
18c54f4e9e ejabberd.yml.example: Use non-standard STUN port
STUN via UDP can easily be abused for reflection/amplification DDoS
attacks.  Suggest a non-standard port to make it harder for attackers to
discover the service.

Modern XMPP clients discover the port via XEP-0215, so there's no
advantage in sticking to the standard port.
2024-11-14 12:21:58 +01:00
Paweł Chmielowski
c7d967a2b5 Fix dialyzer issue 2024-11-05 17:10:09 +01:00
Paweł Chmielowski
b50ea7ef1f Make mod_privilge properly handle roster iq 2024-11-05 16:57:52 +01:00
Holger Weiss
4843cd432f Disable the systemd watchdog by default
Some users reported ejabberd being restarted by systemd due to missing
watchdog pings despite the actual service operating just fine.  So far,
we weren't able to track down the issue, so we'll no longer enable the
watchdog in our example service unit.

Closes #4054.
2024-11-05 15:37:21 +01:00
Paweł Chmielowski
d56eae809d Catch extra case in check for s2s bidi element 2024-11-05 13:26:42 +01:00
Metalhearf
af97211ecc Update URLs in docs/conf files for consistency. 2024-10-31 17:30:20 +01:00
Badlop
601fcba4cb Set version to 24.10 2024-10-28 17:02:10 +01:00
Badlop
cc3a9f7722 Update Changelog to 24.10 2024-10-28 16:34:25 +01:00
Badlop
296ef8287f Remove mod_tombstone from man, it's in ejabberd-contrib (thanks to Licaon_Kter) 2024-10-28 16:34:22 +01:00
Paweł Chmielowski
b5dab24679 Update dependencies 2024-10-28 16:21:44 +01:00
Badlop
319414b985 Update man page to 24.10 2024-10-28 13:50:02 +01:00
Badlop
6b0058c89c Add two more version notes 2024-10-28 13:50:02 +01:00
Badlop
855c828d1f Update Spanish and Catalan translations 2024-10-28 13:35:49 +01:00
Badlop
c72ef537ee Update Chinese (Simplified) translation (thanks to Sketch6580) 2024-10-28 13:35:47 +01:00
Badlop
11e86811a0 Update Portuguese (Brazil) translation (thanks to Wellington Uemura) 2024-10-28 13:35:46 +01:00
Badlop
2183f60917 Update Italian translation (thanks to Ermete Melchiorre) 2024-10-28 13:35:45 +01:00
Badlop
05f0fbf195 Update Bulgarian translation (thanks to MrEddX) 2024-10-28 13:35:43 +01:00
Badlop
853da159de ejabberd.yml.example: Enable mod_s2s_bidi in default configuration 2024-10-28 12:06:56 +01:00
Badlop
643ae7e5f9 Result of running "make doap options" 2024-10-28 12:06:55 +01:00
Badlop
322e25d18e CI: Get again continue-on-error for XMPP Interop Tests
See explanations following the comment
https://github.com/processone/ejabberd/pull/4285#issuecomment-2397047355

This partially reverts commit 94c2a115d5.
2024-10-28 12:06:53 +01:00
Badlop
bdd8ba115e Document ejabberd version of the new modules 2024-10-28 12:06:51 +01:00
Badlop
71ad7c368d Minor improvements to support mod_tombstones
New check_register_user hook in ejabberd_auth.erl
to allow blocking account registration when a tombstone exists.

Modified room_destroyed hook in mod_muc_room.erl
Until now the hook passed as arguments: LServer, Room, Host.
Now it passes: LServer, Room, Host, Persistent
That new Persistent argument passes the room persistent option,
required by mod_tombstones because only persistent rooms should generate
a tombstone, temporary ones should not.
And the persistent option should not be completely overwritten, as we must
still known its real value even when room is being destroyed.

mod_tombstones is available in experimental mode in ejabberd-contrib git.

Initial feature request: #2546
2024-10-28 12:06:48 +01:00