Description
The IPV6 compressed format regex allows 0-6 hex groups before and after the ::.
This does not detect too many groups (there should be at most 7 surrounding groups in total).
It also allows no groups, i.e "::" which is not permitted AFAIK. Edit: this is allowed, see http://tools.ietf.org/html/rfc4291#section-2.2
The first issue could be detected by counting the number of ':' characters in the string.
There should be no more than 7 colons.