summary refs log tree commit diff
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-07-22 18:22:12 +0200
committerGitHub <noreply@github.com>2021-07-22 18:22:12 +0200
commit707e94614bb8cfe22b84ae338d5fe5472cb87dc4 (patch)
treea2d199aaa8533b28b950636c99fe41039cb966e9
parent:bug: fix 404 error return json instead of client (diff)
parentUpdate register.ts (diff)
downloadserver-707e94614bb8cfe22b84ae338d5fe5472cb87dc4.tar.xz
Merge pull request #174 from DankDumpster/72-char
Make password limit 72 to match discord's limit
-rw-r--r--src/routes/auth/login.ts2
-rw-r--r--src/routes/auth/register.ts4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/routes/auth/login.ts b/src/routes/auth/login.ts

index 82cefae8..af00a46d 100644 --- a/src/routes/auth/login.ts +++ b/src/routes/auth/login.ts
@@ -15,7 +15,7 @@ router.post( RateLimit({ count: 5, window: 60, onylIp: true }), check({ login: new Length(String, 2, 100), // email or telephone - password: new Length(String, 8, 64), + password: new Length(String, 8, 72), $undelete: Boolean, $captcha_key: String, $login_source: String, diff --git a/src/routes/auth/register.ts b/src/routes/auth/register.ts
index 25c7b3dd..41798552 100644 --- a/src/routes/auth/register.ts +++ b/src/routes/auth/register.ts
@@ -16,8 +16,8 @@ router.post( check({ username: new Length(String, 2, 32), // TODO: check min password length in config - // prevent Denial of Service with max length of 64 chars - password: new Length(String, 8, 64), + // prevent Denial of Service with max length of 72 chars + password: new Length(String, 8, 72), consent: Boolean, $email: new Length(Email, 5, 100), $fingerprint: String,