python-email-validator icon indicating copy to clipboard operation
python-email-validator copied to clipboard

Ability to disallow confusing unicode characters to prevent homoglyph phishing attacks

Open alanhamlett opened this issue 8 months ago • 1 comments

When emails contain unicode characters that look similar to ascii characters, an attack vector is possible anytime we display the unicode email as an identifier of a user without punycode encoding the displayed email.

It would be nice to have an option to make confusing unicode characters fail email validation, but might be outside the scope of this library since it depends on the external confusables.txt data file from unicode.org?

The Unicode Consortium's Visual Spoofing Recommendations agree with this solution as a better alternative than blocking all unicode characters in domains and emails.

alanhamlett avatar May 23 '25 07:05 alanhamlett