EOL in stderr of ssh - Linux

Knox, Bill wknox at mitre.org
Tue Jul 15 02:06:24 EST 2008


Not on my Fedora Core 7 or my CentOS 5.2 box - both of them terminate
with just 0x0A, as is shown below:

ssh -v 2>&1 | xxd
0000000: 4f70 656e 5353 485f 342e 3370 322c 204f  OpenSSH_4.3p2, O
0000010: 7065 6e53 534c 2030 2e39 2e38 6220 3034  penSSL 0.9.8b 04
0000020: 204d 6179 2032 3030 360a 7573 6167 653a   May 2006.usage:
0000030: 2073 7368 205b 2d31 3234 3641 6143 6667   ssh [-1246AaCfg
0000040: 6b4d 4e6e 7173 5474 5676 5878 595d 205b  kMNnqsTtVvXxY] [
0000050: 2d62 2062 696e 645f 6164 6472 6573 735d  -b bind_address]
0000060: 205b 2d63 2063 6970 6865 725f 7370 6563   [-c cipher_spec
0000070: 5d0a 2020 2020 2020 2020 2020 205b 2d44  ].           [-D
0000080: 205b 6269 6e64 5f61 6464 7265 7373 3a5d   [bind_address:]
0000090: 706f 7274 5d20 5b2d 6520 6573 6361 7065  port] [-e escape
00000a0: 5f63 6861 725d 205b 2d46 2063 6f6e 6669  _char] [-F confi
00000b0: 6766 696c 655d 0a20 2020 2020 2020 2020  gfile].
00000c0: 2020 5b2d 6920 6964 656e 7469 7479 5f66    [-i identity_f
00000d0: 696c 655d 205b 2d4c 205b 6269 6e64 5f61  ile] [-L [bind_a
00000e0: 6464 7265 7373 3a5d 706f 7274 3a68 6f73  ddress:]port:hos
00000f0: 743a 686f 7374 706f 7274 5d0a 2020 2020  t:hostport].
0000100: 2020 2020 2020 205b 2d6c 206c 6f67 696e         [-l login
0000110: 5f6e 616d 655d 205b 2d6d 206d 6163 5f73  _name] [-m mac_s
0000120: 7065 635d 205b 2d4f 2063 746c 5f63 6d64  pec] [-O ctl_cmd
0000130: 5d20 5b2d 6f20 6f70 7469 6f6e 5d20 5b2d  ] [-o option] [-
0000140: 7020 706f 7274 5d0a 2020 2020 2020 2020  p port].
0000150: 2020 205b 2d52 205b 6269 6e64 5f61 6464     [-R [bind_add
0000160: 7265 7373 3a5d 706f 7274 3a68 6f73 743a  ress:]port:host:
0000170: 686f 7374 706f 7274 5d20 5b2d 5320 6374  hostport] [-S ct
0000180: 6c5f 7061 7468 5d0a 2020 2020 2020 2020  l_path].
0000190: 2020 205b 2d77 2074 756e 6e65 6c3a 7475     [-w tunnel:tu
00001a0: 6e6e 656c 5d20 5b75 7365 7240 5d68 6f73  nnel] [user@]hos
00001b0: 746e 616d 6520 5b63 6f6d 6d61 6e64 5d0a  tname [command].

                          Bill Knox
                          Lead Infosec Engineer/Scientist
                          The MITRE Corporation


-----Original Message-----
From: openssh-unix-dev-bounces+wknox=mitre.org at mindrot.org
[mailto:openssh-unix-dev-bounces+wknox=mitre.org at mindrot.org] On Behalf
Of Stanislaw Kaminski
Sent: Monday, July 14, 2008 10:27 AM
To: openssh-unix-dev at mindrot.org
Subject: EOL in stderr of ssh - Linux

Hello everyone,
recently I've found something I consider a bug.

Correct me if I'm wrong, but I always thought that Linux' EOL is 0x0A.
Imagine my surprise when I saw that all messages that are being output
on to the stderr (on any Linux I've tested - Fedora and Ubuntu) are
terminated with 0x0D, 0x0A.

Maybe that's standard behaviour of all stderr messages in all Linux
software, but I have to admin it's the first time I saw something like
this.

So, can anybody tell me if it's for a purpose, or is it just a plain
bug?

yours sincerely,
Stanislaw Kaminski
_______________________________________________
openssh-unix-dev mailing list
openssh-unix-dev at mindrot.org
https://lists.mindrot.org/mailman/listinfo/openssh-unix-dev


More information about the openssh-unix-dev mailing list