Brian Matchick has asked for the wisdom of the Perl Monks concerning the following question:
I'm trying to automate our net abuse report and am having a tough time extracting a list of IP addresses from a file. All I want to do is go though the file and build a list of every IP address contained within. I've worked out the regex to match lines containing ip addresses, but am having some trouble finding a way to actually obtain the IP numbers that it matches. The $1, $2 business is turning out to be a bit confusing.
Can anyone help me out with a code example?
Thanks a lot!
Brian
bmatchick@mindspring.com
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Extracting IP addresses from a file...
by the_slycer (Chaplain) on Jul 04, 2001 at 23:46 UTC | |
Re: Extracting IP addresses from a file...
by damian1301 (Curate) on Jul 04, 2001 at 23:38 UTC | |
by tachyon (Chancellor) on Jul 05, 2001 at 00:02 UTC | |
Re: Extracting IP addresses from a file...
by rrwo (Friar) on Jul 04, 2001 at 23:43 UTC |
Back to
Seekers of Perl Wisdom