I am using below regular expression pattern
pattern=\"^(\\d|[1-9]\\d|1\\d\\d|2([0-4]\\d|5[0-5]))\\.(\\d|[1-9]\\d|1\\d\\d|2([0-4]\\d|5[0-5]))\\.(\\d|[1-9]\\d
([1-9]\d?\d?(\.\d{1,3}){2}\.\d{1,3},?)+
A little over Reductionist perhaps, but that should handle it. (you will need to trim out the commas from the matches though) Edited to restrict matches to the range of 1...* -> 999...*