New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 729421 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner:
Closed: Jun 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug



Sign in to add a comment

Email validation for HTML input is incorrect

Reported by amarkon...@gmail.com, Jun 4 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36

Steps to reproduce the problem:
1. Create an HTML document with exactly one <input type="email"/>
2. Enter an email address with a single-character hostname into the input (`username@a`, for example), which is an invalid hostname according to RFC 952 

What is the expected behavior?
`document.querySelector('input').validity.valid` should return `false`, as a single-character hostname is not a valid hostname

What went wrong?
`document.querySelector('input').validity.valid` returns `true`

Did this work before? N/A 

Does this work in other browsers? No
 Identical in Firefox, have not attempted reproduction in Internet Explorer or Edge

Chrome version: 58.0.3029.110  Channel: stable
OS Version: OS X 10.12.1
Flash Version:
 
test.html
137 bytes View Download
Labels: Needs-Triage-M58
Cc: hdodda@chromium.org
Labels: Needs-Feedback
Tested the issue on mac os 10.12.5 using chrome M58 #58.0.3029.110 using below steps:

1. Launched chrome and downloaded given html file and opened it in chrome and entered "username@a" in text field.
2. and observed no error message in console 

Attached screenshot for reference.

@amarkon895-- Could you please confirm us if we have missed any steps in reproducing the issue and also please provide us the expected result screenshot.

Thanks!
729421.png
41.4 KB View Download
Components: -Blink>Input Blink>Forms

Comment 4 by tkent@chromium.org, Jun 6 2017

Components: -Blink>Forms Blink>Forms>Email
Labels: -Needs-Feedback -Needs-Triage-M58
Owner: tkent@chromium.org
Status: WontFix (was: Unconfirmed)
HTML's email definition is loose.  It allows hostnames without "."

https://html.spec.whatwg.org/multipage/forms.html#valid-e-mail-address

Sign in to add a comment