Hello,

is there - by standard - a definition on how to represent an IPv4 address?

I have (for example) the IP address "73.0.255.229", which can IMHO also be 
written as "073.000.255.229" as the leading zeroes
are not giving any changes to the binary representation of this address. Am I 
right on this?

But: When I lookup this IP address on https://stat.ripe.net/073.000.255.229 the 
first octet is internally getting swapped to "59".
This can be explained, if you take "073" as an octal value and convert it to a 
decimal value.
It is definitely a octal-to-decimal conversion thing, as for example also the 
value "010" is getting replaced by "8" and so on.

Now I'm puzzled: Of course, writing IPv4 octets with leading zeroes is not very 
common.
But: Is it officially prohibited or discouraged?

This weird conversion also happens inside the "geoiplookup" tool by MaxMind and 
I'm not sure if I'm going to be the moron in this story
or if I found the same bug inside multiple softwares at once ;-)


Thanks and greetings from Wuppertal
 Max

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to