Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hook s2s_out_unauthenticated_features crashed when running mod_s2s_bidi:s2s_out_unauthenticated_features/2 #4300

Open
licaon-kter opened this issue Oct 29, 2024 · 3 comments
Assignees

Comments

@licaon-kter
Copy link
Contributor

licaon-kter commented Oct 29, 2024

Environment

  • ejabberd version: HEAD ( 601fcba )
  • Erlang version: Erlang (SMP,ASYNC_THREADS) (BEAM) emulator version 15.1.1 self built arm64
  • OS: Debian 11 arm64
  • Installed from: source

Configuration (only if needed): grep -Ev '^$|^\s*#' ejabberd.yml

will clean up if needed

Errors from error.log/crash.log

https://gist.github.com/licaon-kter/5adf043e301f818d6afc8e791e2a0e54

Seeing this error when trying to join some MUCs on other domains, and in regards to info pulled from some contacts (avatar, presence etc) on those domains and others.

fyi I don't have mod_s2s_dialback activated, and https://docs.ejabberd.im/admin/configuration/modules#mod_s2s_bidi does not say it needs it.

Reading https://xmpp.org/extensions/xep-0288.html it seems to say that both SASL and Dialback should work separately

/LE: clarified

@prefiks prefiks self-assigned this Oct 29, 2024
@mwild1
Copy link

mwild1 commented Oct 30, 2024

Looking at logs from attempted s2s with a Prosody instance with bidi enabled, it looks like ejabberd may be sending (and expecting) the wrong namespace. This causes an unsupported-stanza-type error on both sides (depending who initiates the connection).

XEP-0288 says to send <bidi xmlns='urn:xmpp:bidi'/> but I think ejabberd is sending <bidi xmlns='urn:xmpp:features:bidi'/>.

The urn:xmpp:features:bidi namespace should only used for the <bidi/> element that appears inside stream:features.

@licaon-kter
Copy link
Contributor Author

@Neustradamus
Copy link
Contributor

@mwild1: Good catch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants