Thank you for your prompt response. The colon and other hex characters will always follow the last octet. I Tried your suggestion, and it still matches other ips that begin the same way on the fourth octet. Here is how I modified my code
if ($linebuf =~ /\d+\.$oc1\.$oc2\.$oc3\.$oc4:*/In reply to Re^2: Regex to match an IP address that is embedded inside of another string
by adamZ88
in thread Regex to match an IP address that is embedded inside of another string
by adamZ88
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |