Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit 842b43c

Browse files
committed
Do not check for internal account lock for MSC3861 delegated auth
1 parent 1827963 commit 842b43c

File tree

2 files changed

+1
-11
lines changed

2 files changed

+1
-11
lines changed

changelog.d/16215.bugfix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix a bug where admin tokens stopped working with MSC3861 auth delegation was enabled.

synapse/api/auth/msc3861_delegated.py

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -282,17 +282,6 @@ async def get_user_by_req(
282282
"Impersonation not possible by a non admin user",
283283
)
284284

285-
# Deny the request if the user account is locked.
286-
if not allow_locked and await self.store.get_user_locked_status(
287-
requester.user.to_string()
288-
):
289-
raise AuthError(
290-
401,
291-
"User account has been locked",
292-
errcode=Codes.USER_LOCKED,
293-
additional_fields={"soft_logout": True},
294-
)
295-
296285
if not allow_guest and requester.is_guest:
297286
raise OAuthInsufficientScopeError([SCOPE_MATRIX_API])
298287

0 commit comments

Comments
 (0)