In our application we send email to user of applications. When our user email address is like [email protected]@company, it fails with exception of system.net.mime.mailbnfhelper.readmailaddress
So can a email address have multiple '@' symbol and can .net MailMessege object handle it?
No, that's not a valid e-mail address. See RFC-5322, section 3.4.1 and section 3.2.3 for the lists of characters allowed in each of the parts (the definition of the atoms).
In order to have multiple '@' symbols you need to use quoted strings. Apparently MailAddress
does not support these (but does not document it). I'm running .NET 3.5 on a Win7 machine and MailAddress
throws a FormatException
when fed one of these.
It is possible to have few @ signs, but you have to put other one in quotes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With