Jump to content

RegEx and IP Addresses


Recommended Posts

StringRegExp question,

Why does the search pattern:

([0-9]{1-3}\p[0-9]{1-3}\p[0-9]{1-3}\p[0-9]{1-3})

Not match with ip addresses? A few other variants I tried did not match either. What am I doing wrong?

-Simucal

Sidenote: LazyCats regex tester is pretty sweet.

http://www.autoitscript.com/forum/index.ph...hl=stringregexp

EDIT: I dont have a script to post as an example.. I suppose I could make one up if people wanted to further clarify.

Edited by Simucal
AutoIt Scripts:Aimbot: Proof of Concept - PixelSearching Aimbot with several search/autoshoot/lock-on techniques.Sliding Toolbar - Add a nice Sliding Toolbar to your next script. Click the link to see an animation of it in action!FontInfo UDF - Get list of system fonts, or search to see if a particular font is installed.Get Extended Property UDF - Retrieve a files extended properties (e.g., video/image dimensions, file version, bitrate of song/video, etc)
Link to comment
Share on other sites

StringRegExp question,

Why does the search pattern:

Not match with ip addresses? A few other variants I tried did not match either. What am I doing wrong?

-Simucal

Sidenote: LazyCats regex tester is pretty sweet.

http://www.autoitscript.com/forum/index.ph...hl=stringregexp

EDIT: I dont have a script to post as an example.. I suppose I could make one up if people wanted to further clarify.

for the length, use {1,3} that's an inclusive range... to identify that as the issue (because i couldn't just look at it and see that) i used \p for the pattern on an ip, and received an array of periods, so it wasn't the issue i assumed at first (that maybe the \p was documented but not implemented), then i was trying to recreate and spotted it...
Link to comment
Share on other sites

Thanks camersonsdad.. I feel like an idiot. Missed that typo.

AutoIt Scripts:Aimbot: Proof of Concept - PixelSearching Aimbot with several search/autoshoot/lock-on techniques.Sliding Toolbar - Add a nice Sliding Toolbar to your next script. Click the link to see an animation of it in action!FontInfo UDF - Get list of system fonts, or search to see if a particular font is installed.Get Extended Property UDF - Retrieve a files extended properties (e.g., video/image dimensions, file version, bitrate of song/video, etc)
Link to comment
Share on other sites

Thanks camersonsdad.. I feel like an idiot. Missed that typo.

no problem man, always glad to help. personally i always think typo's like that are the hardest to catch, and the easiest to make. that's why i wrote what it took for me to even notice it. don't feel like an idiot for mistakes, i know that i, for one, assumed you to be human and capable of error even before this.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...