Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
conduwuit
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
🥺
conduwuit
Commits
dd8a6ede
Commit
dd8a6ede
authored
1 year ago
by
🥺
Committed by
🥺
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
dont allow guest registration if registration disabled with token configured
Signed-off-by:
strawberry
<
strawberry@puppygock.gay
>
parent
6664259e
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/api/client_server/account.rs
+3
-2
3 additions, 2 deletions
src/api/client_server/account.rs
with
3 additions
and
2 deletions
src/api/client_server/account.rs
+
3
−
2
View file @
dd8a6ede
...
...
@@ -89,9 +89,10 @@ pub async fn register_route(body: Ruma<register::v3::Request>) -> Result<registe
if
is_guest
&&
(
!
services
()
.globals
.allow_guest_registration
()
||
!
services
()
.globals
.allow_registration
())
||
(
!
services
()
.globals
.allow_registration
()
&&
services
()
.globals.config.registration_token
.is_some
()))
{
info!
(
"Guest registration disabled / registration
fully
disabled, rejecting guest registration, initial device name: {:?}"
,
body
.initial_device_display_name
);
info!
(
"Guest registration disabled / registration disabl
ed with token configur
ed, rejecting guest registration, initial device name: {:?}"
,
body
.initial_device_display_name
);
return
Err
(
Error
::
BadRequest
(
ErrorKind
::
GuestAccessForbidden
,
"Guest registration is disabled."
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment