Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Add password length validatio to password

fowczarek0858de200157
diff --git a/saleor/settings.py b/saleor/settings.py
index ad585fe300..f53924e73e 100644
--- a/saleor/settings.py
+++ b/saleor/settings.py
@@ -345,6 +345,13 @@ AUTH_USER_MODEL = "account.User"
LOGIN_URL = "/account/login/"
+AUTH_PASSWORD_VALIDATORS = [
+ {
+ "NAME": "django.contrib.auth.password_validation.MinimumLengthValidator",
+ "OPTIONS": {"min_length": 8},
+ }
+]
+
DEFAULT_COUNTRY = os.environ.get("DEFAULT_COUNTRY", "US")
DEFAULT_CURRENCY = os.environ.get("DEFAULT_CURRENCY", "USD")
DEFAULT_DECIMAL_PLACES = get_currency_fraction(DEFAULT_CURRENCY)