Bug 54770 - ssh doesn't work from tty console, only from xterm if not logged in as root
ssh doesn't work from tty console, only from xterm if not logged in as root
Status: CLOSED DUPLICATE of bug 54741
Product: Red Hat Linux
Classification: Retired
Component: openssh (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Nalin Dahyabhai
Depends On:
  Show dependency treegraph
Reported: 2001-10-18 09:38 EDT by Tim Woodall
Modified: 2008-05-01 11:38 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-10-18 18:34:02 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Backs out one of the changes made to login.c (1.03 KB, patch)
2001-10-18 18:31 EDT, Tim Woodall
no flags Details | Diff

  None (edit)
Description Tim Woodall 2001-10-18 09:38:17 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT)

Description of problem:
Yesterday I upgraded some machines to openssh2.9p2.

ssh-agent bash
ssh <url>
Everything works as expected provided public key logon works.

however today I had to connect to a site that didn't have my public key 
installed. Instead when I do ssh <site> I get:
You have no controlling tty. Cannot read passphrase.

Version-Release number of selected component (if applicable):
openssh-* 2.9p2-8.7
glibc-* 2.2.4-19

How reproducible:

Steps to Reproduce:
openssh 2.9p2 upgraded from ftp.mirror.ac.uk mirror of update.redhat.com. 
(I also upgraded glibc, nscd and util-linux at the same time. All other 
updates have been applied previously and the problem was not seen until 

1. Ctrl-Alt-F1 (To get to a console)
2. Login (not as root)
3. ssh <somehost>

Actual Results:  You have no controlling tty.  Cannot read passphrase.

Expected Results:  loginname@<somehost>'s password: 

(Works in an xterm)

Additional info:

The following works correctly:

Ctrl-Alt-F1 (for a tty)
ssh-agent bash
(enter passphrase for private key)
ssh <somehost>
Provided the private key allows login.

(always works in an xterm)

Everything works correctly when logged in as root:
This implies it is a permissions problem:

When logged in as tim /dev/tty1 has permissions:

crw--w---- 1 tim   tty   4   1 Oct 18 14:10 /dev/tty1

however changing this to mode 666 crw-rw-rw- does not fix the problem.

Doing an ssh from a host that I have ssh into (with agent forwarding 
disabled) does bring up the "tim@<hostname>'s password: " dialog.

tty = /dev/pty/0 with the same 640 permissions.

I have confirmed this on both the other systems I have console access to 
that I upgraded yesterday. (One does not have nscd installed so this can 
probably be eliminated - I didn't expect it to be the cause anyway :-) )
Comment 1 Tim Woodall 2001-10-18 16:21:38 EDT
I have now discovered that this appears to be a problem in 
util-linux-2.11f-11.7.1 as I have just upgraded just this package on a system 
running openssh-2.5.2p2-5 which worked previously and this problem occurs.

Note that you have to log out and then log back in after upgrading before this 
problem occurs. If you are logged in before upgrading util-linux then 
everything works until you log out.
Comment 2 Tim Woodall 2001-10-18 18:31:11 EDT
Created attachment 34382 [details]
Backs out one of the changes made to login.c
Comment 3 Tim Woodall 2001-10-18 18:33:58 EDT
The patch to login.c backs out one of the changes made to login.c between 
util-linux-2.10s and util-linux-2.11f and resolves this issue.
Comment 4 Tim Woodall 2001-10-19 04:39:44 EDT

*** This bug has been marked as a duplicate of 54741 ***

Note You need to log in before you can comment on or make changes to this bug.