Regular expression for email masking
I am trying to write a regular expression to mask an email address. Example below. input: [email protected] output: j*******@e*********.com I have tried the following but I just can't seem to get it working correctly. regex:(?<=.).(?=[^@]\*?@) output:j*******@example.en.com regex:(?<=.).(?=[^@]\*?)(?=[^\.]\*?\.) output:j******************.com Any help would be appreciated. demo
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.