Jump to content
UBot Underground

Find Gmail Address With Multiple Periods Only


Recommended Posts

Hello all

I am trying to work out the regex to find a gmail address similar to u.ser.nam.e@gmail.com.  It has to return only addresses that contain multiple periods in them instead of the traditional username@gmail.com.  I can only figure out how to match multiple periods in a row as opposed to anywhere within the string.
Help would be much appreciated.

Link to post
Share on other sites

try.

add list to list(%Gmail,$find regular expression("u.ser.nam.e@gmail.com
user_name@gmail.com
username@gmail.com",".*?@gmail.com"),"Delete","Global")

 

  • Like 1
Link to post
Share on other sites

find the "Right" regular expression or email validation expression is notoriously difficult,unfortunately for you I absolutely suck at regular expressions,what might be easier is use a normal regular expression for emails

 

 

and at the end of the operation loop through the list and add any list item that contains a "." before the @ to a new list,but hopefully somebody will post the expression that you need

  • Like 1
Link to post
Share on other sites

if you want convert "u.ser.nam.e@gmail.com" to "username@gmail.com"

set(#mail,$replace($find regular expression("u.ser.nam.e@gmail.com
us.ername@gmail.com
username@gmail.com",".*?@gmail.com"),".",""),"Global")
add list to list(%Gmail,$list from text(#mail,$new line),"Delete","Global")

if find only have "."

alert($find regular expression("u.ser.nam.e@gmail.com
us.ername@gmail.com
username@gmail.com",".*\\..*?@gmail.com"))

 

Link to post
Share on other sites

 

if you want convert "u.ser.nam.e@gmail.com" to "username@gmail.com"

set(#mail,$replace($find regular expression("u.ser.nam.e@gmail.com
us.ername@gmail.com
username@gmail.com",".*?@gmail.com"),".",""),"Global")
add list to list(%Gmail,$list from text(#mail,$new line),"Delete","Global")

if find only have "."

alert($find regular expression("u.ser.nam.e@gmail.com
us.ername@gmail.com
username@gmail.com",".*\\..*?@gmail.com"))

That should work since it's using look ahead to find any periods within the username.  For whatever reason it doesn't though.  I have never been able to figure out why some expressions work in rubular but not in ubot. 

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...