|
I have a perl/expect script, that ssh's into my Linode machine: Ubuntu 12.04 64-bit.
I noticed that the stty settings are different between 2 users: "root" and "other".
This Linode machine is a virgin machine, and I added one "other" user account.
When using this expect/perl script, I do make a call to set the tty settings to raw on the expect object: $exp->raw_pty(1);
Then I ssh in to the machine, etc.
When running "stty" via this connection when logged in as "other", I get:
speed 38400 baud; line = 0; min = 1; time = 0; -brkint -icrnl -imaxbel -opost -onlcr -isig -icanon -iexten -echo -echoe -echok -echoctl -echoke
(I'm particularly interested in and happy with the setting of: -icrnl anBut it seems that the "root" account, resets itself.d -echo)
When running "stty" via this connection when logged in as "root", I get:
speed 38400 baud; line = 0; -brkint -imaxbel
(note the scarcity of many settings)
I can certainly send in a command of `stty raw -noecho` when ssh-ing in as root in this perl/expect script to change the stty settings to how they should already be. So this "root" account's tty settings are setable.
Does anyone know why the "root" account (which is normally disabled on an Ubuntu machine) ignored the stty settings that the perl/expect script does behind the scenes?
or does anyone know what secret login script that the "root" account sources that may undo or reset the stty settings?
|