Commit Graph
1759 Commits
Author SHA1 Message Date
timedout 98466e5243 style: Remove unsafe arithmetic 2026-08-20 00:57:11 +00:00
timedout 8c1a84e907 fix: Don't honour unhealthy hits unless the block period has already expired 2026-08-20 00:57:11 +00:00
timedout 8f66cbb6b9 feat: Clear remote health tracking map when cache is cleared 2026-08-20 00:57:11 +00:00
timedout e1866df682 feat: Trace why remotes get health marked 2026-08-20 00:57:11 +00:00
timedout 213bf6fb70 feat: Refuse to send requests to unhealthy servers
Also marks them as online if a request succeeds
2026-08-20 00:57:11 +00:00
timedout 785db0bdba chore: Move health tracking to federation service
Otherwise federation would have to depend on sender
2026-08-20 00:57:11 +00:00
timedout 6ae66eed1b feat: Mark servers as online/offline based on transaction responses 2026-08-20 00:57:11 +00:00
timedout 0c8b51c0f4 feat: Add server health tracking 2026-08-20 00:57:11 +00:00
Erwan Leboucher 1ecfb21aea fix(spaces): Correct hierarchy traversal 2026-08-19 03:33:41 +00:00
Erwan Leboucher 3efb66c76c fix: Do not make late-arriving events forward extremities 2026-08-18 16:55:47 +00:00
timedout 7b3e3a26bb fix: Don't panic when receiving PDUs with illegal auth events
Apparently some servers do this??
2026-08-18 17:50:18 +01:00
Erwan Leboucher 1d655fda53 fix(timeline): Keep extremities a local event did not reference 2026-08-18 15:38:43 +00:00
timedout a148174c59 style: Rephrase error message 2026-08-15 16:10:39 +00:00
timedout 2dc6051d67 fix(federation): Make transactions infallible
Previously, a transaction panicking in the handle() call would cause the
transaction to be indefinitely logged as "running" in the transaction
handler. This means subsequent transactions from the sending server
would be met with the "You're still sending me a txn!" 429 response,
forever, effectively causing defederation between the two servers, until
continuwuity is fully restarted.

I could just fix the known panics in the handle function and internal
calls, however there's so many subsystems that could reasonably panic
that it is just better to have a safer approach and ensure that the
handle call is infallible.
2026-08-15 16:10:39 +00:00
Erwan Leboucher 918070c512 fix(spaces): Expose restricted children over federation 2026-08-14 12:51:09 +02:00
Ginger 7377074f6d fix: SEC28 2026-08-11 17:56:29 -04:00
Erwan Leboucher 7472faa096 fix(sync): Remove sync wake before membership commit point 2026-08-11 14:10:23 +00:00
Michel-Marie MAUDET f0493a7ba8 fix(oauth): Use unauthorized_client for unregistered grant types
The token endpoint already refused grant types the client had not
registered, but reported it as `invalid_grant`. RFC 6749 section 5.2
reserves `invalid_grant` for an authorization grant which is "invalid,
expired, revoked, does not match the redirection URI used in the
authorization request, or was issued to another client", and defines
`unauthorized_client` for a client which "is not authorized to use this
authorization grant type".

Report the condition with the error code the specification assigns to it,
matching the device authorization endpoint.
2026-08-07 08:52:20 +00:00
Michel-Marie MAUDET 8c1bbf3d1a fix(oauth): Reject device code requests from unauthorised clients
The device authorization endpoint issued a device code to any registered
client, without checking that the client had registered the
`urn:ietf:params:oauth:grant-type:device_code` grant type. Such a client
could therefore start a device authorization flow and have the server
show an approval prompt to a user, even though the subsequent token
request was always going to be refused.

RFC 8628 section 3.2 states that, in the event of an error such as an
invalidly configured client, the device authorization endpoint responds
in the same way as the token endpoint specified in RFC 6749 section 5.2,
which defines `unauthorized_client` as "the authenticated client is not
authorized to use this authorization grant type".

Apply the same grant type check the token endpoint already performs, and
add the `unauthorized_client` error code it requires.
2026-08-07 08:52:20 +00:00
Erwan Leboucher 1b6bc83b9f fix(sync): Preserve batched read receipts 2026-08-06 14:01:52 +00:00
timedout 21ea9d3ea7 feat: Validate event references in prev and auth events
Also threw in some lovely unit tests, as a treat.
2026-08-05 21:11:05 +00:00
timedout 8f0c7a99d7 fix: Don't accidentally continue with fallback room version
Fixes a potential issue where continuwuity correctly defaults to room v1
when encountering an unknown room version, but then fails to *stop*
processing when it encounters the room version it doesn't actually
understand.
2026-08-05 21:11:05 +00:00
timedout 98bc859023 fix: Actually default to core count for sender_workers
Closes #2092
2026-08-03 14:18:32 +01:00
Erwan Leboucher 43197f695c feat(sync): Add MSC4354 sticky events 2026-08-02 17:28:00 +00:00
Erwan Leboucher 27a559a751 fix(sync): Wake sync loops on typing updates 2026-08-02 18:05:27 +02:00
Erwan Leboucher 74591d24e5 fix(sync): Avoid missed long-poll wake-ups 2026-08-02 15:22:18 +00:00
Jacob Taylor 4146e0f1da fix: Resolve membership service by correct name for auto-join 2026-08-01 22:32:25 -07:00
Erwan Leboucher 8481efb482 chore(deps): Update Ruma 2026-08-01 23:50:48 +02:00
timedout b0c1381f03 fix: Re-introduce residency check when handling incoming transactions 2026-07-30 18:02:34 +00:00
timedout 14ff018b9f fix: Don't soft-fail valid redactions 2026-07-30 18:33:47 +01:00
timedout 7920127391 fix: Explicit type error 2026-07-27 16:01:33 +00:00
timedout 65ff23bd48 fix: Don't treat policy server signing keys as required for signature verification 2026-07-27 16:01:33 +00:00
timedout 399005abc6 chore: Move registration notice logic 2026-07-27 16:46:36 +01:00
Ginger 9a3496ae70 feat: Add admin command to issue access tokens 2026-07-27 14:21:38 +00:00
Renovate BotandGinger 8addb41b5a chore(deps): Update ruma digest to 04d5d68
Co-authored-by: Ginger <ginger@gingershaped.computer>
2026-07-26 22:54:42 +00:00
Erwan Leboucher e161b5f01e perf: Fetch joined member count once per event when notifying 2026-07-26 14:40:34 +00:00
Erwan Leboucher 08c22b5fcc fix(sync): Wake local target user after membership changes are committed 2026-07-26 14:12:37 +00:00
new-years-eve 7f8c2aedc8 refactor: Use a shared helper function for submitting state events at room creation
On room creation, A list of initial state events may be provided that
should be submitted to the room after creation. These events
should be treated as any other state event and submitted to
the same checks.

With this change, state events submitted on room creation will be
submitted through the same helper as those through the usual endpoint.

The submission helper is moved to the timeline service to make it
available everywhere. This will be useful for implementing MSC4140
(issue #903).
2026-07-26 15:06:38 +01:00
Ginger 8cde2ad0cc fix: Fix missing migration logic 2026-07-25 15:18:13 -04:00
reaster fb7a378d63 deduplicate rooms in hierarchy traversal 2026-07-25 13:55:30 +00:00
Erwan Leboucher 4727f07e26 fix: Correct roomuserid_lastnotificationread table alias
roomuserid_lastnotificationread was mapped to userroomid_highlightcount
instead of its own table, so last_notification_read() read the highlight
count and reset_notification_counts clobbered the highlight table when
setting a read marker. Add the missing table definition and fix the alias.
2026-07-24 01:13:42 +00:00
Ginger 8f60648009 fix: Use correct error code for invalid client ID 2026-07-21 13:42:50 +00:00
Ginger 4c9426a13f feat: Add support for OAuth2 device auth flow 2026-07-21 13:42:50 +00:00
timedout 8b3be67860 feat: Increase access token length
Reviewed-By: ginger <ginger@gingershaped.computer>
2026-07-19 15:06:23 +01:00
Erwan Leboucher b1632ee60b fix(register): Resolve alias service by correct name for auto-join 2026-07-17 17:57:51 +00:00
Ginger 3e55d08488 fix: Only return create prompt if registration is enabled 2026-07-17 12:49:15 +00:00
Erwan Leboucher e2eb980b5e fix(sync): Stop waking sync loops when removing to-device events 2026-07-16 22:15:27 +02:00
Erwan Leboucher 7ecd2aa5e2 fix(pdu): Exempt m.room.create from auth_events check 2026-07-14 19:27:46 +02:00
Ginger 1f5e178c3f fix: Properly handle appservice device creation 2026-07-13 08:50:48 -04:00
theS1LV3R baef3289fe fix(service/admin): Prevent console from being spawned when no TTY is available 2026-07-12 20:22:18 +02:00