fix: Hydra bugfix sweep #1099

Merged
nex merged 7 commits from nex/fix/event-auth into main 2025-10-28 17:40:48 +00:00
Owner

fixes #1097, fixes #1093, closes #1060 (by removing the logic for now, which was then ultimately fixed by #1126, pending a future replacement via #1061)

Fixes:

  • Banning, unbanning, and then inviting someone did not permit them to join in v12 rooms
  • Being unable to kick or unban a target in a v12 room if you were a creator
  • Being unable to redact events in a v12 room if you were a creator
  • Restricted join rules did not care if the joining user was invited when providing a federated join (make_join)
  • v12-style ownership checks being incorrectly applied to v11 and below room versions, resulting in fleeting authorization errors
fixes #1097, fixes #1093, closes #1060 (by removing the logic for now, which was then ultimately fixed by #1126, pending a future replacement via #1061) Fixes: - Banning, unbanning, and then inviting someone did not permit them to join in v12 rooms - Being unable to kick or unban a target in a v12 room if you were a creator - Being unable to redact events in a v12 room if you were a creator - Restricted join rules did not care if the joining user was invited when providing a federated join (`make_join`) - v12-style ownership checks being incorrectly applied to v11 and below room versions, resulting in fleeting authorization errors
nex requested review from Jade 2025-10-04 20:58:22 +00:00
nex added this to the 0.5.0 milestone 2025-10-04 20:58:23 +00:00
Jade approved these changes 2025-10-04 22:02:16 +00:00
Dismissed
nex changed title from fix: Unbans and kicks incorrectly checked creatorship in !v12 to WIP: fix: Several event auth issues 2025-10-04 23:33:47 +00:00
nex dismissed Jade's review 2025-10-04 23:33:53 +00:00
Reason:

PR scope changed

nex changed title from WIP: fix: Several event auth issues to WIP: fix: Hydra bugfix sweep 2025-10-08 20:46:26 +00:00
nex force-pushed nex/fix/event-auth from 0842b8945a
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Successful in 52s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m38s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 7m33s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 7m18s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Successful in 16s
Checks / Prek / Clippy and Cargo Tests (pull_request) Failing after 10m22s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 14m17s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 14m25s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 13s
to c4e7e7c655
Some checks failed
Documentation / Build and Deploy Documentation (pull_request) Successful in 44s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m44s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 6m8s
Checks / Prek / Clippy and Cargo Tests (pull_request) Failing after 6m55s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 6m56s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Successful in 14s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 11m37s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 11m40s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 12s
2025-10-08 21:06:57 +00:00
Compare
Author
Owner

Waiting until #1094 is fixed before un-drafting this (aiming to tackle it in this PR also)

Waiting until #1094 is fixed before un-drafting this (aiming to tackle it in this PR also)
nex force-pushed nex/fix/event-auth from 57e905b7b1
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m3s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m44s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 5m55s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 5m51s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Successful in 14s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 9m16s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 12m21s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 12m35s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 13s
to e7b4b45ec4
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m48s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 8m11s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 7m21s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Successful in 22s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 19m21s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 15m59s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 16m4s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 20s
2025-10-15 02:50:02 +00:00
Compare
Author
Owner

dont merge v12 is broken again lol

dont merge v12 is broken again lol
nex force-pushed nex/fix/event-auth from e7b4b45ec4
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Successful in 1m5s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m48s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 8m11s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 7m21s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Successful in 22s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 19m21s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 15m59s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 16m4s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 20s
to 25fe03731a
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Successful in 49s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m43s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 8m49s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 8m39s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Successful in 16s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 18m22s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 15m53s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 15m57s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 26s
2025-10-23 17:48:23 +00:00
Compare
Author
Owner

#1094 should be fixed by another PR and likely won't make it into this one.

#1094 should be fixed by another PR and likely won't make it into this one.
Author
Owner

This should now be ready for merge. I've tested everything I fixed and everything seems to work as expected

This should now be ready for merge. I've tested everything I fixed and everything seems to work as expected
nex changed title from WIP: fix: Hydra bugfix sweep to fix: Hydra bugfix sweep 2025-10-23 20:46:41 +00:00
nex requested review from Owners 2025-10-23 20:46:47 +00:00
Jade approved these changes 2025-10-23 21:21:39 +00:00
@ -81,2 +89,2 @@
)),
}
Ok(room_create.sender() == sender
|| redacting_event
Owner

Additional creators? Unless it's handled earlier

Additional creators? Unless it's handled earlier
Author
Owner

Handled on line 54

Handled on line 54
Owner

Code locality? Never heard of it 😭

Code locality? Never heard of it 😭
Author
Owner

it doesnt make sense to check ownership twice (in both the "has power level event" branch and the "doesnt have a power level event" branch), but rather just check it before even caring. Also technically saves us a lookup if the room is v12 and the sender is a creator.
Plus it's 30 lines up it's within eye shot 😭

it doesnt make sense to check ownership twice (in both the "has power level event" branch *and* the "doesnt have a power level event" branch), but rather just check it before even caring. Also technically saves us a lookup if the room is v12 and the sender is a creator. Plus it's 30 lines up it's within eye shot 😭
nex marked this conversation as resolved
tcpipuk force-pushed nex/fix/event-auth from f22016edee
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Successful in 50s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m38s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 7m36s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 7m21s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Successful in 19s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 15m47s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 15m1s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 14m57s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 14s
to fbf48addc7
All checks were successful
Documentation / Build and Deploy Documentation (pull_request) Successful in 45s
Checks / Prek / Pre-commit & Formatting (pull_request) Successful in 1m30s
Release Docker Image / Build linux-amd64 (release) (pull_request) Successful in 5m56s
Release Docker Image / Build linux-arm64 (release) (pull_request) Successful in 6m14s
Release Docker Image / Create Multi-arch Release Manifest (pull_request) Successful in 15s
Release Docker Image / Build linux-amd64 (max-perf) (pull_request) Successful in 14m55s
Release Docker Image / Build linux-arm64 (max-perf) (pull_request) Successful in 14m56s
Release Docker Image / Create Max-Perf Manifest (pull_request) Successful in 15s
Checks / Prek / Clippy and Cargo Tests (pull_request) Successful in 24m14s
Documentation / Build and Deploy Documentation (push) Successful in 52s
Checks / Prek / Pre-commit & Formatting (push) Successful in 1m41s
Release Docker Image / Build linux-amd64 (release) (push) Successful in 8m5s
Release Docker Image / Build linux-arm64 (release) (push) Successful in 7m36s
Release Docker Image / Create Multi-arch Release Manifest (push) Successful in 15s
Checks / Prek / Clippy and Cargo Tests (push) Successful in 33m24s
Release Docker Image / Build linux-amd64 (max-perf) (push) Successful in 15m38s
Release Docker Image / Build linux-arm64 (max-perf) (push) Successful in 14m47s
Release Docker Image / Create Max-Perf Manifest (push) Successful in 16s
2025-10-27 14:34:53 +00:00
Compare
nex merged commit fbf48addc7 into main 2025-10-28 17:40:48 +00:00
nex deleted branch nex/fix/event-auth 2025-10-28 17:40:48 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
continuwuation/continuwuity!1099
No description provided.