(?<IPV4>(?:(?:25[0-5]|(?:2[0-4]|1\d|[1-9]|)\d)\.?\b){4})
Originating from ^((25[0-5]|(2[0-4]|1\d|[1-9]|)\d)\.?\b){4}$ at only 43 chars Source: Danail Gabenski
^((25[0-5]|(2[0-4]|1\d|[1-9]|)\d)\.?\b){4}$