mirror of
https://github.com/zulip/zulip.git
synced 2025-10-23 16:14:02 +00:00
signup: Add "airsi.de" as an allowed email domain.
Renames WHITELISTED_EMAIL_DOMAINS to OVERRIDE_ALLOW_EMAIL_DOMAINS as the set of email domains that are allowed even if they are in the set of disposable email domains.
This commit is contained in:
committed by
Tim Abbott
parent
aebc9081b8
commit
a4fff91e96
@@ -21,7 +21,7 @@ def is_reserved_subdomain(subdomain: str) -> bool:
|
||||
|
||||
|
||||
def is_disposable_domain(domain: str) -> bool:
|
||||
if domain.lower() in WHITELISTED_EMAIL_DOMAINS:
|
||||
if domain.lower() in OVERRIDE_ALLOW_EMAIL_DOMAINS:
|
||||
return False
|
||||
return domain.lower() in DISPOSABLE_DOMAINS
|
||||
|
||||
@@ -371,7 +371,8 @@ GENERIC_RESERVED_SUBDOMAINS = {
|
||||
|
||||
DISPOSABLE_DOMAINS = set(blocklist)
|
||||
|
||||
WHITELISTED_EMAIL_DOMAINS = {
|
||||
OVERRIDE_ALLOW_EMAIL_DOMAINS = {
|
||||
"airsi.de",
|
||||
# Controlled by https://www.abine.com; more legitimate than most
|
||||
# disposable domains
|
||||
"opayq.com",
|
||||
|
@@ -4683,7 +4683,7 @@ class TwoFactorAuthTest(ZulipTestCase):
|
||||
|
||||
|
||||
class NameRestrictionsTest(ZulipTestCase):
|
||||
def test_whitelisted_disposable_domains(self) -> None:
|
||||
def test_override_allow_email_domains(self) -> None:
|
||||
self.assertFalse(is_disposable_domain("OPayQ.com"))
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user