As Alan says, cast to ipv4prefix. In the worst case use your regex with unlang but whatever you do, don't use huntgroup , it's extremely slow by many factors! alan