Re: non operational question related to IP

2010-12-10 Thread Thomas Habets
On Mon, 22 Nov 2010, Greg Whynott wrote: osx-gwhynott:~ gwhynott$ ping 10.010.10.1 PING 10.010.10.1 (10.8.10.1): 56 data bytes You're entering land of weird, misdocumentation and bugs. http://seclists.org/nanog/2010/Feb/285 - typedef struct me_s { char name[] = { Thomas Habets

Re: non operational question related to IP

2010-12-09 Thread Peter Dambier
Mostly the input is done by a library implementing the Posix version of fprintf or fscanf. 10 = 10, 0xa, 012 010 = 8, 0x8, 010 0x10 = 16, 0x10, 020 and there are others. google( fscanf ) Mostly everything understands fscanf syntax. Cheers Peter Greg Whynott wrote: i was pinging a host

Re: non operational question related to IP

2010-11-22 Thread David Coulson
Prefixing the octet with 0 makes it interpret it as octal, not decimal. Pretty typical on a UNIX system. On 11/22/2010 2:52 PM, Greg Whynott wrote: i was pinging a host from a windows machine and made a typo which seemed harmless. the end result was it interpreted my input differently than

RE: non operational question related to IP

2010-11-22 Thread Matlock, Kenneth L
'Octal' (Base-8) :) The leading '0' is telling the box to interpret it as octal instead of decimal or hex. Ken Matlock Network Analyst Exempla Healthcare (303) 467-4671 matlo...@exempla.org -Original Message- From: Greg Whynott [mailto:greg.whyn...@oicr.on.ca] Sent: Monday, November

Re: non operational question related to IP

2010-11-22 Thread James Downs
On Nov 22, 2010, at 11:52 AM, Greg Whynott wrote: anyone happen to know how the OS's are interpreting the 010? doesn't appear work out in base[2-10] (1010,101,22,20,14,13,12,11,10,A) Looks base 8 to me. -j

Re: non operational question related to IP

2010-11-22 Thread Steven Bellovin
On Nov 22, 2010, at 2:52 52PM, Greg Whynott wrote: i was pinging a host from a windows machine and made a typo which seemed harmless. the end result was it interpreted my input differently than what I had intended. thinking this was a m$ issue I quickly took the opportunity to poke

Re: non operational question related to IP

2010-11-22 Thread Greg Whynott
thanks guys. I should of paid more attention in school. interesting cisco understands what we meant. 8) -g On Nov 22, 2010, at 2:56 PM, Matlock, Kenneth L wrote: 'Octal' (Base-8) :) The leading '0' is telling the box to interpret it as octal instead of decimal or hex. Ken Matlock

Re: non operational question related to IP

2010-11-22 Thread Michael Brown
On 11/22/2010 02:58 PM, Steven Bellovin wrote: 010 is how C represents an octal number. This one is known in decimal as 8. Obviously, what Greg meant to type was: $ ping 012.0xA.10.1 PING 012.0xA.10.1 (10.10.10.1) 56(84) bytes of data. M. -- Michael Brown | The true sysadmin does

Re: non operational question related to IP

2010-11-22 Thread William Herrin
On Mon, Nov 22, 2010 at 3:09 PM, Michael Brown mich...@supermathie.net wrote: On 11/22/2010 02:58 PM, Steven Bellovin wrote: 010 is how C represents an octal number.  This one is known in decimal as 8. Obviously, what Greg meant to type was: $ ping 012.0xA.10.1 PING 012.0xA.10.1 (10.10.10.1)

Re: non operational question related to IP

2010-11-22 Thread Brian Reichert
On Mon, Nov 22, 2010 at 12:56:00PM -0700, Matlock, Kenneth L wrote: 'Octal' (Base-8) :) The leading '0' is telling the box to interpret it as octal instead of decimal or hex. My guess you're seeing an interface that uses inet_addr() instead of inet_pton(); the latter is used more nowadays at

Re: non operational question related to IP

2010-11-22 Thread Mark Andrews
See man inet. All numbers supplied as ``parts'' in a `.' notation may be decimal, octal, or hexadecimal, as specified in the C language (i.e., a leading 0x or 0X implies hexadecimal; otherwise, a leading 0 implies octal; other- wise, the number is interpreted as decimal).