Jason Volk
732e8b82aa
Abstract password hashing into util.
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-05 03:00:23 +00:00
strawberry
919735b4ce
remove usages of &String and &Owned[..]
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-06-03 14:17:42 -04:00
strawberry
f6fa2a4f65
use swap_remove instead of remove in a few places
...
`swap_remove` is faster if we don't care about the order (O(1))
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-06-03 00:10:28 -04:00
strawberry
9a5f1dac57
drop unnecessarily verbose get_alias_helper logging
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-06-03 00:10:28 -04:00
strawberry
9b096cc67b
fix: check if you've left the room before forgetting it
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-06-02 23:53:31 -04:00
strawberry
f0533e07ef
fed: remove unnecessary mutables, use with_capacity in couple more places
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-06-02 23:53:31 -04:00
strawberry
68f42f5a2f
fed: relax read receipt EDU check
...
so in theory: guest users, peaking over federation,
and world readable rooms should be allowed to send
read receipts even if they're not joined.
relaxing this check to only allow the read receipt if
the server has at least 1 member in the room makes
some of this still work
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-06-02 23:53:31 -04:00
strawberry
4aead5de7a
reflax a couple restrictions on custom room IDs and aliases
...
🙃
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-06-02 23:53:31 -04:00
Jason Volk
887496d040
consolidate default cargo features
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 23:01:12 +00:00
Jason Volk
c2586737ae
accept receipts prior to events
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 23:01:12 +00:00
Jason Volk
102bd1b4a6
use debug_warn for parse_incoming_pdu err results.
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 23:01:12 +00:00
Jason Volk
90d9a997a5
split / cleanup core utils.
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 20:17:45 +00:00
Jason Volk
5fe5ab279c
split RouterExt impl related into ruma_wrapper unit.
...
slightly restrict client_server mod index.
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 20:17:45 +00:00
Jason Volk and June 🍓🦴
68cbf19154
Fix items-after-statements
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 12:34:05 -04:00
Jason Volk and June 🍓🦴
02081b66c4
Fix some unnecessary-unwraps w/ addl cleanup/simplification.
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 12:34:05 -04:00
Jason Volk and June 🍓🦴
b3fc8516ed
Fix unnested-or-patterns
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 12:34:05 -04:00
Jason Volk and June 🍓🦴
eed8a2a801
add and sort incomplete package metadata
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-06-02 12:34:05 -04:00
strawberry and June 🍓🦴
a41a60ef07
media: dont ignore requested filename on /download for Content-Disposition
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
Jason Volk and June 🍓🦴
b94045a468
dissolve key_value/*
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-05-27 18:16:23 -04:00
Jason Volk and June 🍓🦴
3122648767
split ruma_wrapper from_request() related.
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-05-27 18:16:23 -04:00
Jason Volk and June 🍓🦴
3f5349ad76
simplify RumaHandler for Router building.
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-05-27 18:16:23 -04:00
Jason Volk and June 🍓🦴
27dcf213f1
tweak error strings.
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-05-27 18:16:23 -04:00
Jason Volk and June 🍓🦴
a1b526b3b7
tweak log levels
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-05-27 18:16:23 -04:00
Jason Volk and June 🍓🦴
dc614e11d6
check invite target is our server.
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-05-27 18:16:23 -04:00
Jason Volk and June 🍓🦴
c5569b4c6e
dedup acl checks
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-05-27 18:16:23 -04:00
Jason Volk and June 🍓🦴
71a1285c7b
hoist receipt ACL check
...
Signed-off-by: Jason Volk <jason@zemos.net >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
abdda6cf32
check invited user's server against ACLs on /invite
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
4d21f9d962
use ok_or_else instead of ok_or for function calls in server_server.rs
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
1013fe5a42
check for membership join state at /send_join
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
f31b7b9420
ignore inbound EDUs for users that dont belong to origin server
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
e5e358cc68
compare X-Matrix origin + body origin and check PDU/EDU length at /send txn
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
50bc7cc005
check state_key matches sender user at /send_leave
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
445015e9ea
check user ID server against ACLs at /send_leave
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
7a38c12e5d
check for member event type at /send_leave
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
2a77951152
check for membership leave state at /send_leave
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
0256c27363
check if we know about room at /make_leave
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
826edc0a3a
check state_key matches sender user at /send_join
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
a5043a38e1
only allow membership event types at /send_join
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
bfd471a863
check user ID server against ACLs for /send_join
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
3981e77ec6
check user ID server against ACLs for /make_join
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
81bf4b7150
check user ID server against ACLs for /make_leave
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
b8ec763a7c
ignore read receipts from ACL'd servers and users not joined
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
003d4edbfa
debug log receiving typing EDUs for users not in room
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
4f0006d18a
ignore typing EDUs from ACL'd user's servers
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
7328ed7509
rename misleading sender_servername to origin
...
this is the X-Matrix origin/server, NOT the `"sender"``
user's server name.
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-27 18:16:23 -04:00
strawberry and June 🍓🦴
6269822613
actually fix all let_underscore_must_use lints
...
CI caught some more
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-25 22:28:43 -04:00
strawberry and June 🍓🦴
dc9fe657d5
fix guest accounts being logged still
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-25 22:28:43 -04:00
strawberry and June 🍓🦴
1c7c5bc09c
feat: add /_conduwuit/local_user_count endpoint
...
only enabled if federation is enabled
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-25 22:28:43 -04:00
strawberry and June 🍓🦴
32161801ed
use/enable let_underscore_must_use lint
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-25 22:28:43 -04:00
strawberry and June 🍓🦴
e098448b9d
init a few vecs in event_handler using with_capacity
...
Signed-off-by: strawberry <strawberry@puppygock.gay >
2024-05-25 22:28:43 -04:00