Finding IPs using wingrep

I use WinGrep to search for IP addresses in a TXT file, but I cannot figure out how to make it use a regular expression to search. Does anyone have any experience with this?

+3
source share
2 answers

If you do not need to consider IPv6, you only need numeric IP addresses without port numbers and you do not need to check addresses (i.e. do not match illegal address strings 321.456.299.999), then you can use

\b\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\b

If you need to do any of the above, please update your question.

+2
source

What worked for me using WinGrep:

[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+

I tried more complex regex'es, but none of them work with WinGrep

Hope this helps Relationship

+2

Source: https://habr.com/ru/post/1756294/


All Articles