C# Email Regular Expression — Any out there that adhere to the RFC 2822 guidelines?

后端 未结 4 1683
一个人的身影
一个人的身影 2021-01-01 02:43

I realize that there are a ton of regex email validations, but I can\'t seem to find one that adheres to the RFC 2822 standard.

The ones I find keep letting in junk

4条回答
  •  庸人自扰
    2021-01-01 03:17

    I would look at this: http://www.regular-expressions.info/email.html, which explains a lot about using regular expressions to match email addresses, and includes a full RFC 2822 expression which honestly I would almost never recommended using.

提交回复
热议问题