From 48f80b37ed39365774cef09765a7980c063875cf Mon Sep 17 00:00:00 2001 From: Tyler Todd Date: Mon, 13 Feb 2023 15:38:33 +0000 Subject: [PATCH] potential regex code fix for email validation --- powerdnsadmin/routes/index.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/powerdnsadmin/routes/index.py b/powerdnsadmin/routes/index.py index cd93181..2c2dfbd 100644 --- a/powerdnsadmin/routes/index.py +++ b/powerdnsadmin/routes/index.py @@ -665,7 +665,7 @@ def register(): email = request.form.get('email', '').strip() rpassword = request.form.get('rpassword', '') - is_valid_email = re.compile(r'[\w\.-]+@[\w\.-]+') + is_valid_email = re.compile(r'^[a-zA-Z0-9_.+-]+@[a-zA-Z0-9-]+\.[a-zA-Z0-9-.]+$') error_messages = {} if not firstname: