On Mon, 2009-02-02 at 23:06 +0100, Iñaki Baz Castillo wrote: 
> Hi, accorsing to the BNF grammar in:
>   http://tools.ietf.org/html/draft-ietf-sip-ipv6-abnf-fix-02
> the following IPv4 address is not valid:
> 
>   1.2.3.04
> 
> This is, adding an useles "0" makes the IP invalid. While in some manner it 
> makes sense, I wonder how useful is being so strict in this case.

Since this is a "sip" I-D, you should probably inquire on the SIP
mailing list for the history of this change.

But one possible reason is that there is software that will interpret a
leading zero in one of the 4 numbers to mean that the number is in
octal.  That is, "010" means eight, but "10" means ten.

For example (using Fedora Core 8 Linux, which contains the Gnu
inet_aton() function, which I believe is responsible), if I execute:

   ssh 147.020.90.165

I get the same effect as:

   ssh 147.16.90.165

and it is different from:

   ssh 147.20.90.165

Given the Unix "digits to integer" conventions, I suspect that this is
the expected behavior.

I've also seen some early RFCs that use octal numbers in the
numbers-and-dots notation.

Dale



_______________________________________________
Sip-implementors mailing list
[email protected]
https://lists.cs.columbia.edu/cucslists/listinfo/sip-implementors

Reply via email to