summaryrefslogtreecommitdiff
path: root/src/rexmpp.c
AgeCommit message (Collapse)Author
2023-12-07Provide a callback after socket creation, use _Booldefanor
The callback is provided to set socket options, instead of individual options such as path_mtu_discovery (which is now removed). Noticed that the Rust rexmpp structure's C representation does not match that of C, since Rust's "bool" maps to C99's "_Bool", while I thought that it maps to "int" (c_int). Adjusted C structures to use "bool" from stdbool.h as well, since C99 (GNU99) is used already.
2023-11-17Implement MUC self-ping (XEP-0410)defanor
2023-11-12Skip full capabilities string compositiondefanor
A hash is composed more directly now: parts of the string are fed into a hash function instead of being concatenated first.
2023-11-11Check realloc(3) return valuesdefanor
2023-10-22Fix a couple of bugs, refactor a littledefanor
Found a couple of issues with -fanalyzer, though CWE-401 (analyzer-malloc-leak) appears to produce false positives still.
2023-09-29Add more checks, tests, and documentationdefanor
2023-09-28Support Nettle and OpenSSL for hashing, in addition to Libgcryptdefanor
2023-09-26Support OpenSSL for DTLS-SRTPdefanor
2023-09-24Move GnuTLS operations from Jingle module into TLS moduledefanor
2023-09-21Handle audio I/O, codecs, and RTP for Jingle callsdefanor
2023-09-15Abstract out random generationdefanor
Still depending on gcrypt for hashing, but this is a step towards making that dependency optional.
2023-09-09Use rxml for XML parsing when building with Rustdefanor
2023-09-08Support libexpat as an alternative XML parserdefanor
2023-09-07Build rexmpp_xml_t directly on SAX parsingdefanor
Afterwards it is used for the input queue, too.
2023-09-07Implement XML serialization in C and in Rustdefanor
Continuing replacement of libxml2, planning to use libexpat or a Rust XML parser as an alternative for XML parsing.
2023-08-09Fix pingingdefanor
It was broken since commit 938963c1d1c6a9b929d28a90030332d4f397ca61, since seconds from monotonic clocks were compared to calendar ones. Now last_network_activity is a timespec, using monotonic clocks as well.
2023-06-14Use more pointers to other structures from struct rexmppdefanor
Instead of including them. Those structures can vary depending on configuration options, while for bindings it is easier if they stay the same, and are mere pointers. Besides, some of them may refer to opaque Rust-only structures in the future.
2023-06-09Avoid direct strdup of values returned by rexmpp_xml_find_attr_valdefanor
Better to check those to not be NULL first.
2023-05-23Replace libxml2's xmlNode with a custom XML structuredefanor
The new structure (rexmpp_xml) is simpler, and should allow manipulation from Rust without any dependency on libxml2 from the Rust code (while Rust has its own parsers, such as rxml). Alternative XML parsers (e.g., libexpat) now can be used from the C code. The replacement/abstraction is not quite complete yet: the parsing process itself (xmlParseChunk and friends) should be abstracted out.
2023-05-02Use timespec and monotonic clock for timersdefanor
2023-04-15Add a path MTU discovery setting for TCP socketsdefanor
2021-12-28Fix integer overflow on stanzas_out_acknowledged > stanzas_out_countdefanor
2021-10-13Implement Jingle RTP sessions with ICE-UDP and DTLS-SRTPdefanor
Works with Dino and Conversations, but currently relying on external players and streamers for actual audio playback and capture. For now requiring GnuTLS and libnice for calls; OpenSSL should be supported as an alternative to the former, and the latter should be made optional, maybe with libjuice as an alternative.
2021-10-03Return REXMPP_E_AGAIN upon scheduling a reconnectdefanor
So that an application would wait instead of giving up; perhaps other errors should be reserved for cases when a reconnect is undesirable and user intervention is needed.
2021-10-02Make libgsasl optionaldefanor
Only EXTERNAL and PLAIN mechanisms are supported without it for now.
2021-10-02Use a custom base64 implementationdefanor
Reducing dependency on gsasl.
2021-10-02Use libgcrypt for hashing and randomdefanor
Libgsasl will probably be made optional, so another source of random is needed. Libgsasl uses libgcrypt underneath. Gcrypt, unlike nettle, handles random seeding on its own, which would be annoying to implement for different platforms otherwise.
2021-10-01Add Jingle file transfer over IBBdefanor
2021-09-28Add request identifiers into the xmpp.el's XML interfacedefanor
Now the requests don't have to be queued, though xml_interface.c still expects responses from xmpp.el in reverse order.
2021-09-26Add xmpp-http-upload into xmpp.eldefanor
2021-09-25Implement XEP-0363: HTTP File Uploaddefanor
2021-09-25Add recursive feature search (rexmpp_disco_find_feature)defanor
2021-09-25Introduce IQ cachingdefanor
Aiming its usage for service discovery, and possibly similar information retrieval activities.
2021-09-24Pass user-provided pointers to <iq> callback functionsdefanor
2021-09-23Handle XEP-0092: Software Versiondefanor
2021-09-22Fix a few GCC warningsdefanor
2021-09-22Reintroduce c-ares as an option for DNS lookupsdefanor
2021-09-21Make libunbound optionaldefanor
Just use gethostbyname when it's disabled. Possibly will add c-ares, getaddrinfo_a, and other options in the future.
2021-09-21Make DNSSEC trust anchor file configurabledefanor
2021-09-20Restore client certificate (SASL EXTERNAL) authenticationdefanor
As well as the ability to set a trusted server certificate.
2021-09-19Make GPGME optionaldefanor
2021-09-19Fix the client name in discovery infodefanor
2021-09-19Introduce OpenSSL and no-TLS options, in addition to GnuTLSdefanor
Also an option to require TLS is added. There's no DANE TLSA checks with OpenSSL yet, TLS session resumptions and ALPN aren't used with it; just basic connections with certificate verification are added. And now SASL EXTERNAL authentication isn't quite usable.
2021-09-04Print names and shorter timestamps in xmpp.eldefanor
The conversation buffers now follow the <https://docs.modernxmpp.org/client/design/#names> recommendations for names, and the rexmpp_get_name function is adjusted to match those more closely.
2021-08-29Update to Debian 11 versions of dependenciesdefanor
Now it builds with newer compiler and library versions, the ones from Debian 11 repositories.
2021-05-07Free events on their removaldefanor
2021-05-05Free memory after parsing SASL-decoded datadefanor
2021-03-02Initiate connection from the rexmpp_run functiondefanor
It used to be handled in a callback, but now the callback is simplified, only storing the received data. This should make the control flow a bit easier to follow.
2021-02-13Don't try to reconnect on TCP errors while closing a streamdefanor
2021-02-12Set log_function on initialisationdefanor
rexmpp_init may write logs itself, so a logging function should be set for that.