Email validation: do not authorize email like xx@xx

Created on 14 December 2022, almost 2 years ago
Updated 11 December 2023, 12 months ago

Problem/Motivation

Currently an email address like xx@xx passes clientside validation but it is rejected by server side validation.

This is due to the fact that the JS validation provided by the jQuery validation library is done on RFC1123 (https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address), which authorizes this possibility.

Whereas Drupal Core validation, done with PHP library egulias/email-validator is against another RFC which does not authorize that.

Proposed resolution

Override jquery validate email validation regex to avoid this possibility.

Remaining tasks

Create MR.

Feature request
Status

Needs review

Version

4.0

Component

Field Validation

Created by

🇫🇷France Grimreaper France 🇫🇷

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024