Skip to content

Admin user registration and EMAIL_DOMAIN_ALLOWLIST #27457

Closed
@TineHorvat

Description

@TineHorvat

Description

Hello,
we have a local installation of Gitea and have recently upgraded to 1.20.4 and experienced a feature or functionality that was not present before on in the versions before. I can see there was a security enchantment (https://github.com/go-gitea/gitea/releases/tag/v1.20.4) about checking the blocklist.

The issue:
After the upgrade to 1.20.4 we are not able (through administrator dashboard) to add users that have emails on domains that are not listed on the ALLOWLIST. If you use the any other domain, we get the error message: "The email address is invalid."

We have user registration enabled, and set EMAIL_DOMAIN_ALLOWLIST for our organization and some business partners domains, which is working fine and they can register trough the form. For any other domains, only Gitea administrators added new users, so we can avoid spam users as much as possible. This was working for any domains, also those that are not on the ALLOWLIST in the previous version of Gitea.

We want to keep the "open" registration for the domains that are allowed, but also allow the administrators to add users with emails from any other domains. The main reason is we don't want to disable the registration for "our" domains because those users are under our organization policy and they can register by themself, but still be able that admins can add users with any domain if needed.

Is there a new configuration combination that allows this settings or is this a "feature/bug", that checks only the ALLOWLIST also when an administrator is adding a new user?

Can you please look into in?

Thanks,
Tine

Gitea Version

1.20.4

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Screenshots

No response

Git Version

No response

Operating System

No response

How are you running Gitea?

We are running on Windows Server, its running as a windows service.

Database

None

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions