From 1348a964026d10319a27824f13d584d0c8da89ad Mon Sep 17 00:00:00 2001 From: Dlurak <84224239+Dlurak@users.noreply.github.com> Date: Sun, 25 Aug 2024 13:54:14 +0200 Subject: [PATCH] Allow for all special chars in a password --- src/routes/auth/register.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/routes/auth/register.ts b/src/routes/auth/register.ts index 5cada5e..8209d8b 100644 --- a/src/routes/auth/register.ts +++ b/src/routes/auth/register.ts @@ -53,7 +53,7 @@ export const registerRouter = new Elysia({ prefix: "/register" }) description: "Password must contain at least 8 characters, one uppercase letter, one lowercase letter, one number, and one special character", pattern: - "^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[#?!@$ %^&*-]).{8,}$", + "^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[^a-zA-Z0-9]).{8,}$", }), // t.RegExp(), }),