Commit Graph

33 Commits

Author SHA1 Message Date
dbeae3751f xmpp: Fix the Stream Management implementation
There was a bug that on resumption messages would be received again.
The cause of this was probably that we send a <resume /> with an
h equal to the stanzas we sent. If we sent and received an equal amount,
no problem. But if we receive more than we sent, then duplicates will
start flooding in.
2022-01-23 13:41:51 +01:00
3073321ecd style: Fix filename issues 2022-01-23 12:18:30 +01:00
f8acf98ebd style: Spent 6h fixing linter warnings 2022-01-21 17:44:48 +01:00
72db9039f8 test: Add tests for the XEP-0352 implementation 2022-01-21 11:36:12 +01:00
1b4872f016 xmpp: Improve tests and fix our first vulnerability
In order to test the [RosterManager], I decided to add a test to ensure
vulnerabilities like CVE-2015-8688 won't happen. But as it turns out,
I got the logic wrong in the [RosterManager] base implementation which
would've allowed a malicious actor to inject a roster push. oof.
2022-01-21 11:23:09 +01:00
abadc0214f xmpp: Implement plain resource binding 2022-01-21 09:34:38 +01:00
5abb3059bf xmpp: Re-implement read-only support of chat markers 2022-01-20 22:06:01 +01:00
c09184597c xmpp: Make StanzaHandler callbacks async 2022-01-20 17:55:26 +01:00
71357e1409 test: Fix SM test 2022-01-20 17:13:52 +01:00
a37ae65588 test: Fix them 2022-01-20 13:18:34 +01:00
adc9979df8 xmpp: Huge rework of stanza handling
Instead of putting everything into [XmppConnection], let's put
everything into its own [XmppManagerBase] base subclass.

- Improves testability
- Makes extensions easier
- Allows easier usage of lib/xmpp as its own library
2022-01-19 15:59:48 +01:00
7cf0a8a826 xmpp: Implement XEP-0115 2022-01-18 12:07:50 +01:00
dd76e219ea xmpp: Improve the socket 2022-01-17 14:12:04 +01:00
54cf44706a xmpp: Make reconnecting work 2022-01-17 14:04:30 +01:00
870869c3a1 test: Modularize the StubSocket 2022-01-16 13:33:52 +01:00
b02a344fb3 xmpp: Fix removing roster items 2022-01-09 23:38:28 +01:00
09d9d52a5b xmpp: Rework 2022-01-09 22:50:15 +01:00
5eed04290e xmpp: Factor out the stream buffering for testing 2022-01-02 14:44:31 +01:00
1acc2630b4 xmpp: RECEIVE MESSAGES! 2022-01-01 21:24:27 +01:00
0c1714f6b9 xmpp: Fix tests 2021-12-31 23:14:07 +01:00
127a91120d test: Fix the build-parse test 2021-12-31 12:24:06 +01:00
293af5b360 xmpp: Make PLAIN auth configurable 2021-12-30 23:26:03 +01:00
df258df2e4 xmpp: Migrate to stringxml 2021-12-30 22:57:19 +01:00
d093c74680 xmpp: Implement XEP-0368 lookup 2021-12-30 20:43:52 +01:00
b8efef3497 xmpp: Use classes instead of strings for the JID 2021-12-30 20:06:20 +01:00
23f9c48200 xmpp: Implement my own XMPP library 2021-12-30 19:49:01 +01:00
2338648afb ui: Add missing test for validateJid 2021-12-27 18:09:03 +01:00
f2206f62c9 ui: Add basic JID validation 2021-12-26 20:57:22 +01:00
402cbb3738 ui: Nicely format the message timestamps 2021-12-26 13:41:36 +01:00
fac5d6414c ui: Add timestamp strings for conversations 2021-12-26 13:30:34 +01:00
20f17179e1 ui: Fix crash when adding a chat if one is already open 2021-12-26 12:34:02 +01:00
22ecadf865 tests: Fix padInt not padding 9 2021-12-24 23:26:45 +01:00
27e543016f Initial commit 2021-12-21 16:15:45 +01:00