Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 21 May 2023 06:49:33 -0700
From:      bob prohaska <fbsd@www.zefox.net>
To:        freebsd-current@freebsd.org
Cc:        bob prohaska <fbsd@www.zefox.net>
Subject:   Stray characters in command history
Message-ID:  <ZGohbTVTRwfJkqyk@www.zefox.net>

next in thread | raw e-mail | index | archive | help
Lately I've been playing with buildworld on a Pi3 running -current. The same machine
acts as a terminal server for a second Pi3 also running -current in my "cluster". 
I ssh into the first Pi3, su to root and run tip to pick up a serial connection to 
the second Pi's console. Both machines are within a week of up-to-date.

While building world on the first Pi3 the ssh connection frequently drops and must be
re-established. If there was a shell running on the serial console of the second
Pi3 it typically keeps running and when the tip session is restarted disgorges a
stream of accumulated console message. 

This morning the same thing happened, but I noticed something odd. The stream of
messages (all login failure announcements from ssh) ended with

....
May 21 06:15:00 www sshd[33562]: error: Fssh_kex_exchange_identification: banner line contains invalid characters
*+May 21 06:15:19 www sshd[33565]: error: Fssh_kex_exchange_identification: Connection closed by remote host
May 21 06:15:33 www sshd[33613]: error: Protocol major versions differ: 2 vs. 1

At that point I hit carriage return and got
*+: No match.

I did not type the *+ so it looks like the characters were somehow introduced elsewhere,
possibly from the ssh failure message. How they got into the command stream is unclear.

This strikes me as undesirable at best and possibly much worse. The shell reporting
the "no match" was a regular user shell, but if I'd been su'd to root it appears that
the unmatched characters would be seen by the root shell as input.

This more-or-less fits with the pattern seen earlier with reboots observed via serial
console halting on un-typed keystrokes. Those halts were attributed to electrical noise
on the serial line, but this looks like something injected via part of the network
login process. Reboot pauses have been an ongoing phenomenon for months, this is the 
first time I've noticed the "invalid characters" message from ssh on the console.

Thanks for reading, apologies if I'm being a worrywart.

bob prohaska

 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?ZGohbTVTRwfJkqyk>