devise icon indicating copy to clipboard operation
devise copied to clipboard

Devise::email_regexp rejects unusual but valid email

Open kimgb opened this issue 10 years ago • 3 comments

"example@tt" =~ Devise.email_regexp
# => nil

Compare to: http://isemail.info/example%40tt

I figure the intent of the Devise::email_regexp is to conduct minimal validation, and it should "first do no harm". Note the above @tt address is an example of a TLD that does, in fact, have MX records on it. Dominic Sayers on isemail.info also reports encountering an in-use email on the Ukrainian @ua TLD.

Do I misunderstand the spec of the Devise default behaviour here?

kimgb avatar Mar 17 '16 21:03 kimgb

Good catch, please send a PR? :)

josevalim avatar Mar 17 '16 22:03 josevalim

Will do

kimgb avatar Mar 18 '16 05:03 kimgb

Done in #4001

ulissesalmeida avatar Apr 26 '16 18:04 ulissesalmeida