46fdd9cdfa
tokio-xmpp: rustfmt pass in examples
...
Build / lint (push) Waiting to run
Build / test-stable (push) Blocked by required conditions
Build / test-nightly (push) Blocked by required conditions
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2024-06-18 20:21:23 +02:00
Jonas Schäfer
079379a178
Fix build with nightly rust
...
Nightly rust complains about `cfg(..)` tests against undeclared
features and other unknown cfgs. They need to be explicitly declared
now.
The nightly/stable features don't exist, so I removed them and
substitutes the currently correct number for the single test where they
were used.
The `xmpprs_doc_build` cfg flag is now declared as expectable.
2024-06-17 19:49:26 +00:00
Parker
eb0bc1b82f
Changed name to XmppCodec
2024-06-15 13:02:15 -04:00
Parker
56dc1c6e60
Added XmppCodec
usage example
2024-06-15 13:02:10 -04:00
Parker
6d449e9aaa
Make XmppCodec public
2024-06-15 13:02:02 -04:00
Jonas Schäfer
84de007640
Update rxml to 0.11.0
2024-06-15 12:58:39 +02:00
Jonas Schäfer
2097b9685f
Update rxml to 0.10.1
...
rxml 0.10.0 (and earlier) had a bug which caused it to reject valid XML
documents if an UTF-8 sequence straddled the token size boundary (8192
bytes by default) of a text event.
2024-06-08 07:29:57 +02:00
xmppftw
aabd19f78c
State is disconnected, not invalid
2024-06-06 19:44:53 +00:00
xmppftw
034976748a
Add serde feature for xmpp crate
2024-06-05 11:20:33 +02:00
Emmanuel Gil Peyrot
002c2803d4
Fix typos across the codebase (thanks codespell!)
2024-05-14 05:46:02 +00:00
Emmanuel Gil Peyrot
f725994fe0
Bump all dependencies but rustls and webpki-roots
...
The latter have changed their API a bit, while everything else is still
compatible.
2024-05-04 12:42:53 +02:00
Astro
6c3081d656
tokio-xmpp: let happy_eyeballs connect to records in parallel
2024-05-02 22:24:54 +02:00
Astro
598ffdbecf
tokio-xmpp: set resolve ip_strategy to Ipv4AndIpv6
...
The happy_eyeballs implementation should try to connect on both address
families. The default of Ipv4thenIpv6 wouldn't query for AAAA if it got
A.
2024-05-02 22:24:54 +02:00
Jonas Schäfer
0298caf97a
tokio-xmpp: allow docs build with --all-features
...
This affects only the docs and is quite an ugly hack, but seems to be
the only way for now.
2024-04-23 19:22:04 +02:00
Jonas Schäfer
b648b4668b
Fix broken build with tls-native feature
2024-04-23 19:22:04 +02:00
Jonas Schäfer
fb63ac8e50
Update rxml to 0.10.0
...
See release notes [1] for details.
[1]: https://codeberg.org/jssfr/rxml/releases/tag/v0.10.0
2024-03-16 17:39:55 +01:00
Jonas Schäfer
7fce1146e0
Offer {Resource,Node,Domain}Ref on Jid API
...
This provides a non-copying API, which is generally favourable. The
other accessors were removed, because the intent was to provide this
"most sensible" API via the "default" (i.e. shortest, most concisely
named) functions.
2024-03-10 10:51:01 +01:00
Emmanuel Gil Peyrot
1bab5c3cd9
Remove redundant imports
...
These became warnings in a recent nightly.
The TryFrom/TryInto imports were missed in
4089891f6c
, but the rest are truly
redundant.
2024-02-27 22:57:18 +01:00
famfo
28ab91f46a
Add Sync to ServerConnectError
2024-01-27 17:26:07 +00:00
famfo
060088be29
Implement function to get stream features
2024-01-23 16:09:07 +01:00
moparisthebest
019450ff4b
Add disabled-by-default insecure-tcp feature to tokio-xmpp for use by component connections
2024-01-03 19:34:03 -05:00
moparisthebest
733d005f51
DNS/TLS deps are now optional, component now also uses ServerConnector
2024-01-01 02:09:41 -05:00
moparisthebest
e784b15402
ServerConnector and AsyncClient support channel binding, SimpleClient uses ServerConnector
2024-01-01 02:08:40 -05:00
moparisthebest
3cab603a4c
Add AsyncServerConnector to AsyncClient to be able to support any stream
...
Unfortunately API breaking unless we do some export mangling
2024-01-01 02:08:13 -05:00
xmppftw
ac4ffd2268
Use relative cargo paths when using local copy
2023-12-18 13:06:22 +01:00
4089891f6c
Update edition to 2021
...
- Remove TryFrom/Into and FromIterator imports
- Prevent impl_validator_using_provider macro in sasl crate from
constructing trait object
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-12-15 19:40:09 +00:00
Emmanuel Gil Peyrot
372234b912
tokio-xmpp: Remove workaround for Debian oldoldstable
...
hickory-resolver’s MSRV is 1.67, those super old toolchain versions
wouldn’t build a recent version of tokio-xmpp anyway.
This effectively reverts 52a2d962ee
.
2023-12-04 15:34:26 +01:00
Emmanuel Gil Peyrot
2d11ada30f
tokio-xmpp, xmpp: Remove regex support from env_logger
...
This bloats our binaries by 1.1 MiB after stripping, for very minimal
additional features. People who need that feature can enable it
themselves.
2023-10-25 18:11:33 +00:00
Emmanuel Gil Peyrot
faabc2984a
tokio-xmpp: Support channel binding on TLS 1.3
...
This is defined in RFC 9266, and relies on the Exported Keying Material
to be passed to the SASL implementation.
2023-10-25 20:03:11 +02:00
115edf6f25
tokio-xmpp: Update hickory-dns dep (previously trust-dns)
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-10-25 11:37:04 +00:00
Emmanuel Gil Peyrot
c56dbe8903
tokio-xmpp: Remove unneeded clones
2023-10-25 00:16:28 +02:00
adeb4154de
tokio-xmpp: bump to 3.5
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-10-24 20:35:03 +02:00
079ca7dd90
tokio-xmpp: Also compile_error when no tls-* feature is enabled
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-10-24 19:59:45 +02:00
Link Mauve
57517692ba
Use jid's domain_str method instead of format!.
2023-10-24 17:56:53 +00:00
34b50d32c9
tokio-xmpp: Update tls-rust feature for jid changes
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-10-24 16:51:08 +00:00
5338d2f99a
tokio-xmpp: Replace deprecated rustls method (add_server_trust_anchors)
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-10-24 16:51:08 +00:00
25c319b2db
tokio-xmpp: Update for webpki_roots release in tls-rust feature
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-10-24 16:51:08 +00:00
a16f670ee6
tokio-xmpp: Error out when both tls-native and tls-rust features are enabled
...
If the user enables the tls-rust feature and forgets to disable
default-features (which includes tls-native), tell them and bail out.
The code was made to work anyway when both are enabled, and here it
defaults to tls-native. It does seem better to have one explicitely
choose one though hence the compile_error! message.
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-10-24 16:51:08 +00:00
Guus der Kinderen
fc16b7919b
fix: typo in AsyncConfig comment
2023-10-10 19:15:55 +02:00
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
6c8855a6d5
tokio-xmpp: Update Changelog
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-08-20 21:34:04 +02:00
96f6de787f
tokio-xmpp: Re-export jid structs, minidom::Element, and parsers module
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-08-20 21:34:04 +02:00
a13f05037c
tokio-xmpp: update dependencies (jid, webpki-roots)
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-08-20 21:34:04 +02:00
xmppftw
4266368a98
JIDs now have typed and stringy methods for node/domain/resource access
...
Jid now has typed with_resource and stringy with_resource_str
Jid now has is_full, is_bare
2023-06-21 18:30:25 +02:00
Emmanuel Gil Peyrot
85bdcdb131
tokio-xmpp: Bump idna dependency
2023-06-21 12:05:33 +00:00
Emmanuel Gil Peyrot
6ccc5ccace
tokio-xmpp: Poll packets in a loop
...
This needs to be a loop in order to ignore packets we don’t care about,
or those we want to handle elsewhere. Returning something isn’t correct
in those two cases because it would signal to tokio that the XMPPStream
is also done, while there could be additional packets waiting for us.
The proper solution is thus a loop which we exit once we have something
to return.
Fixes a deadlock when we ignore some packets.
2023-06-21 11:55:42 +00:00
ac22765f21
tokio-xmpp: Remove newline after stream:stream
...
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2023-06-21 12:21:52 +02:00
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
Emmanuel Gil Peyrot
3c9df12606
tokio-xmpp: Update to the new jid crate
...
This helps a bit thanks to fewer clones, but otherwise there are very
few changes.
2023-06-20 18:59:26 +02:00
Emmanuel Gil Peyrot
17335136fe
tokio-xmpp: Add syntax highlighting to debug logs
...
This uses syntect, and has been checked to have zero overhead when it is
disabled.
2023-06-19 19:52:38 +02:00