Test, validate and match regular expressions
This regular expression rigorously validates IPv4 addresses by ensuring they consist of four octets separated by dots. Each octet must be a number between 0 and 255, correctly handling ranges to avoid invalid values like 256. It uses the multiline and global flags to find and validate all IP addresses in a given text. It is ideal for extracting or verifying network configuration details, log parsing, or input validation.