RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Regular Expression Details

Title Test Find Validates the most of the email formats
Expression
/^([a-zA-Z0-9])(([\-.]|[_]+)?([a-zA-Z0-9]+))*(@){1}([a-z0-9]|([a-z0-9][\-]))+[.]{1}(([a-z]{2,3})|([a-z]{2,3}[.]{1}[a-z]{2,3}))$/
Description
This expression will validates most of the email formats.
Matches
Non-Matches
Author Rating: The rating for this expression. Rafiq
Source Email
Your Rating
Bad Good

Enter New Comment

Title

Name

Comment

Spammers suck - we apologize. Please enter the text shown below to enable your comment (not case sensitive - try as many times as you need to if the first ones are too hard):

Existing User Comments

Title: vulnerable to ReDoS
Name: It breaks when input is: ccccccccccccccc [email protected]
Date: 12/12/2022 9:30:55 AM
Comment:
This regex is vulnerable to a ReDoS like the other one by the same author. In this case the "evil input" that will break it is like so: ccccccccccccccc [email protected]


Copyright © 2001-2024, RegexAdvice.com | ASP.NET Tutorials