[xsstl-users] ip4v regexp error?

Boris Kolpackov boris at codesynthesis.com
Wed Oct 11 16:21:41 EDT 2006


Hi, Peter

HolliePeter KounalisGiles <h_and_p at hotmail.com> writes:

> Looks to me like there is an error in the regexp for ipv4 addresses:
>
> ((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])
>
> one of your cases for an octet is [1-9][0-9]|[0-9], which could match 999,
> so 999.999.999.999 would be accepted as a valid address.

It would match '999' is it were [1-9][0-9][0-9], but since it is
[1-9][0-9] -or- [0-9] then it won't match 999. I just tested it in perl
everything works as expected. Or am I missing something? ;-)

-boris

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 652 bytes
Desc: Digital signature
Url : http://codesynthesis.com/pipermail/xsstl-users/attachments/20061011/04a4974b/attachment.pgp


More information about the xsstl-users mailing list