You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The EmailAddress class uses the fast_chemail crate, which rejects emails that are valid according to RFCs 5322 and 6532:
use async_smtp::EmailAddress;#[test]fnaccepts_valid_email_addresses(){assert!(EmailAddress::new(r#""deliver able"@example.crustytoothpaste.net"#.into()).is_ok());assert!(EmailAddress::new("🔵@example.crustytoothpaste.net".into()).is_ok());assert!(EmailAddress::new("pingüino@example.crustytoothpaste.net".into()).is_ok());assert!(EmailAddress::new("sandals@example.crustytoothpaste.net".into()).is_ok());}
All of these addresses are deliverable (to me) if you remove the example.. Only the last is accepted.
Moreover, it appears that this library intentionally does not support the full range of valid email addresses:
A library to validate the email as it is defined in the HTML specification. The RFC 5322 is too lax (allowing comments, whitespace characters, and quoted strings in manners unfamiliar to most users) to be of practical use.
I should point out that the HTML specification is not involved in the sending of email and therefore what it defines as a valid email is totally irrelevant. Moreover, SMTPUTF8 is seeing increasing adoption, and the HTML specification rejects all internationalized email addresses, which is unhelpful since most people on the planet don't speak English at all.
A different implementation, supporting the full range of options specified in RFC 6532, should be used instead.
The text was updated successfully, but these errors were encountered:
The
EmailAddress
class uses thefast_chemail
crate, which rejects emails that are valid according to RFCs 5322 and 6532:All of these addresses are deliverable (to me) if you remove the
example.
. Only the last is accepted.Moreover, it appears that this library intentionally does not support the full range of valid email addresses:
I should point out that the HTML specification is not involved in the sending of email and therefore what it defines as a valid email is totally irrelevant. Moreover, SMTPUTF8 is seeing increasing adoption, and the HTML specification rejects all internationalized email addresses, which is unhelpful since most people on the planet don't speak English at all.
A different implementation, supporting the full range of options specified in RFC 6532, should be used instead.
The text was updated successfully, but these errors were encountered: