Commit graph xmpp-rs/tokio-xmpp/ChangeLog
Author SHA1 Message Date
famfo
10f1b3663c tokio-xmpp: add option to split client
Adds an option to split the `tokio-xmpp::Client` into a Sender and
Receiver. To enable this, a client worker is added which drives the
stream in the background.
2026-05-24 17:07:56 +00:00
famfo
d84cb261e4 tokio-xmpp: add StreamFeatures to Online event 2026-05-24 17:07:56 +00:00
famfo
8f03661acb tokio-xmpp: split StanzaStream into Sender and Receiver 2026-05-24 17:07:56 +00:00
famfo
697d4d3bef
tokio-xmpp: update hickory-dns to 0.26 2026-05-21 13:21:46 +02:00
Jonas Schäfer
e2dcd8ac66 Stop being pedantic by default
Up to now, the xmpp-rs projects have been very strict about incoming
data. This has served us, as developers of the libraries, well,
uncovering bugs in our and remote implementations which we could then
get fixed.

However, this behaviour is unexpected to users of the library. In the
XMPP world, unexpected child elements and attributes are generally
expected to be ignored. While this could be opted-into previously, the
feature flag for that sounded more dangerous than it was
("disable-validation"). In addition, the tribal knowledge needed to know
about that feature flag may not have reached some people who tried the
library and gave up because of that.

With this change, we make the non-pedantic behaviour the default. For
development and debugging purposes, users can always opt into the
pedantic behaviour as needed, using the newly-introduced `pedantic`
feature flags on all affected crates.
2026-03-27 12:51:51 +01:00
famfo
628c2113d0 tokio-xmpp: add option to disable xmpp_parsers validation 2026-02-18 16:53:38 +00:00
famfo
4316bb02a5 tokio-xmpp: implicitly add bound_jid on received IQs 2026-02-18 17:33:31 +01:00
Jonas Schäfer
a1ade974b0 stanzastream: actually count stanzas in stream management
Looks like a horrible oversight. And this will need tests, but I'm short
on time right now.

Fixes #170.
2026-02-11 10:10:46 +01:00
Jonas Schäfer
3bda04124e tokio-xmpp: publish auth method 2026-02-11 08:23:29 +01:00
famfo
f7931e95b6 tokio-xmpp: implicitly add bound_jid to IQs 2026-01-27 21:23:51 +00:00
pep
d910cb9944
tokio-xmpp: Update Changelog for AsRawFd
Signed-off-by: pep <pep@bouah.net>
2026-01-25 16:41:57 +01:00
pep
77acd92c62 tokio-xmpp: Ignore missing "version" stream attribute for 0114 components
From the prosody@ room:
- 0114 doesn't mention the removal of @version on the stream, and it
  refers to 3920 which has it as a MUST.
- 0114 streams have historically never used @version="1.0"
- @version="1.0" implies stream features which 0114 doesn't have.
- There was a proposal years ago to fix this but a new XEP was preferred
  (0225).

The change here uses a compile-time check, and may have to change when
support for 0225 arrives if it's still gated behind the "component"
feature (even though it may be weird to have both under the same
feature). We'll see when we get there.

Signed-off-by: pep <pep@bouah.net>
2025-11-30 16:21:28 +01:00
pep
0e7ac066d4 tokio-xmpp: Bump to 5.0.0
Signed-off-by: pep <pep@bouah.net>
2025-11-01 17:34:37 +01:00
pep
db0ce5859b tokio-xmpp: Document TlsStream type behind 'ktls' feature
Signed-off-by: pep <pep@bouah.net>
2025-10-21 23:40:00 +02:00
pep
e526b49636 tokio-xmpp: Remove warning when rustls-any-backend feature isn't enabled
Signed-off-by: pep <pep@bouah.net>
2025-10-21 23:40:00 +02:00
lemonsh
468171517a
update changelogs 2025-10-12 22:20:29 +02:00
Saarko
e3b167687f tokio-xmpp: remove code duplicates for direct tls and starttls connectors 2025-07-25 18:50:44 +02:00
Saarko
c674c14597 tokio-xmpp/client: add directTLS connection method 2025-07-25 18:50:30 +02:00
Maxime “pep” Buquet
02a70edf99
Fix 'elided lifetime' warning from nightly
Nightly 1.90. The fix passes on stable 1.88.

Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2025-07-20 16:01:44 +02:00
Maxime “pep” Buquet
6fe7f92e7d tokio-xmpp: derive Debug on multiple structures
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2025-05-10 22:11:12 +02:00
Jonas Schäfer
fc8b581593 Clean up tls-related feature flags
This provides a clear and consistent interface for selecting TLS-related
features on both (xmpp and tokio-xmpp) crates. All feature checks have
been revamped. All working combinations have been tested (including a
connectivity test + --all-features docs build) using:

```
set -xeuo pipefail
features=(aws_lc_rs ring ktls,aws_lc_rs ktls,ring aws_lc_rs,ring aws_lc_rs,ring,ktls native-tls rustls-any-backend)
export RUSTFLAGS=" -D warnings"
cargo test --no-default-features
cargo test
for feature in ${features[@]}; do
  echo ">>> BUILDING with $feature" 2>&1
  # Running code or building examples cannot succeed with rustls-any-backend.
  features="starttls,$feature"
  if [ "$feature" != 'rustls-any-backend' ]; then
    if ! cargo test --no-default-features --features="$features"; then
      echo ">>> BUILD FAILED for tls feature set: $features" >&2
      exit 1
    fi
    set +e
    timeout -sINT -p -k 2 3 cargo run --no-default-features --features="$features" --example keep_connection -- test@hub.sotecware.net "$(pass xmpp/test@hub.sotecware.net)"
    status="$?"
    set -e
    if [ $status -ne 0 ]; then
      echo ">>> keep_connection did not shut down cleanly! (status: $status)" >&2
      exit 1
    fi
  else
    if ! cargo build --no-default-features --features="$feature"; then
      echo ">>> BUILD FAILED for tls feature set: $features" >&2
      exit 1
    fi
  fi
done
RUSTDOCFLAGS="--cfg docsrs" RUSTFLAGS="--cfg xmpprs_doc_build" cargo +nightly doc -Zrustdoc-map --all-features
```
2025-05-10 22:02:39 +02:00
Jonas Schäfer
4e9e18444c Avoid enabling multiple rustls backends by accident
For this, we had to:

- Make the choice(s) of backend explicit in tokio-xmpp features
- Avoid picking a backend through transitive dependencies in xmpp
  (reqwest->hyper->rustls).

In addition, we choose the default rustls backend by default and adapt
the examples so that they can cope with either situation.
2025-05-10 11:39:21 +02:00
Jonas Schäfer
78714475b2 tokio-xmpp: re-export rustls if using rustls backend
The user may have to call some global rustls functions depending on the
exact feature set of rustls enabled. Hence, we have to expose it.

Concretely, if the user somehow ends up with more than one rustls
backend, they have to configure one of the backends as default backend
at startup.
2025-05-10 11:09:58 +02:00
Jonas Schäfer
70d635b0fb Bump rxml to 0.13.1
rxml 0.13.0 changed the quoting style to make it consistent, so we have
to patch up all affected places where we match exact strings.
2025-04-22 17:47:45 +02:00
Emmanuel Gil Peyrot
b8f64037a9 tokio-xmpp: Fix build on insecure-tcp
insecure-tcp requires the io-util feature of tokio, so let’s enable it
there.

Fixes this error:
5   | use tokio::{io::BufStream, net::TcpStream};
    |             ^^^^^^^^^^^^^ no `BufStream` in `io`
2025-02-10 15:40:53 +01:00
Jonas Schäfer
8a4d548d9a tokio_xmpp: implement IQ tracking 2025-01-26 17:15:41 +01:00
Emmanuel Gil Peyrot
f8347165fd tokio-xmpp: Add forgotten ChangeLog entry for ktls support 2024-12-18 18:33:42 +00:00
Jonas Schäfer
c723897326 tokio_xmpp: introduce xmlstream module
This module provides XSO-based parsing, proper typestates and will
soon replace the proto module.
2024-08-29 16:42:57 +02:00
9f4af1625d Component is now behind insecure-tcp feature flag 2024-08-10 18:09:12 +02:00
0b58561003 Rename AsyncClient to Client 2024-08-10 16:57:51 +02:00
311e7406f0 Make Client and Component more unified, and connectors too 2024-08-10 16:57:49 +02:00
fde4c2b640 Move XmppCodec and XmppStream to proto module 2024-08-10 16:49:26 +02:00
a3fbd77050 Remove tokio_xmpp::SimpleClient 2024-08-10 16:49:24 +02:00
2fc8e1c1dd AsyncClient::new reconnects by default, fixes disconnect logic 2024-08-08 15:33:17 +02:00
84511b54a0 Only expose one error type in crate root 2024-08-04 18:17:17 +02:00
34796c90d4 Only expose one error type in crate root 2024-08-04 16:04:09 +00:00
5de1891f06 Merged starttls::ConnectorError into starttls::Error 2024-08-04 12:39:56 +00:00
b9fc15977b Replace tokio_xmpp::stream_features with parsers 2024-08-02 18:25:32 +00:00
ee3d86ec42 Remove tokio_xmpp::ParseError and tokio_xmpp::starttls::ParseError 2024-08-01 12:55:17 +00:00
Maxime “pep” Buquet
6995961d38 tokio-xmpp: Update ChangeLog
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2024-07-27 19:04:03 +02:00
034976748a Add serde feature for xmpp crate 2024-06-05 11:20:33 +02:00
Maxime “pep” Buquet
adeb4154de
tokio-xmpp: bump to 3.5
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-10-24 20:35:03 +02:00
Maxime “pep” Buquet
68a8c043a2 tokio-xmpp: bump to 3.4.0
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-08-20 21:34:04 +02:00
Maxime “pep” Buquet
6c8855a6d5 tokio-xmpp: Update Changelog
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-08-20 21:34:04 +02:00
Maxime “pep” Buquet
e9cbeb1863 tokio-xmpp: debug print stream:stream too
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-06-21 12:21:52 +02:00
3ac741d666 RUST_LOG=debug can now be used in tokio-xmpp examples to see XMPP network traffic 2023-06-05 15:02:35 +00:00
209bab1441 tokio_xmpp::AsyncClient and xmpp::Agent take a fully parsed Jid (#72) 2023-06-01 16:55:53 +02:00