This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 819896 - host-based ssh authentication does not work because sshd-keygen does not set group readable bit on host keys to enable ssh-keysign to read them
host-based ssh authentication does not work because sshd-keygen does not set ...
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: openssh (Show other bugs)
19
All Unspecified
unspecified Severity high
: ---
: ---
Assigned To: Petr Lautrbach
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-05-08 10:30 EDT by Andrew J. Schorr
Modified: 2013-04-17 02:56 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-04-17 02:56:43 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
Enable group read on ssh host keys (1.07 KB, application/octet-stream)
2012-05-08 10:30 EDT, Andrew J. Schorr
no flags Details

  None (edit)
Description Andrew J. Schorr 2012-05-08 10:30:01 EDT
Created attachment 583009 [details]
Enable group read on ssh host keys

Description of problem: The /usr/libexec/openssh/ssh-keysign is setgid, not setuid as it used to be.  The group is set to ssh_keys.  In the /usr/sbin/sshd-keygen script, the keys are created with the group set to ssh_keys, but the group read bit is disabled.  Thus, only root can read the keys, and host-based authentication does not work.


Version-Release number of selected component (if applicable):
openssh-5.9p1-22.fc17.src.rpm

How reproducible:  Try to use host-based authentication.  You get an error like this:

could not open any host key
ssh_keysign: no reply
key_sign failed
Permission denied (publickey,hostbased)


Steps to Reproduce:
1. Install Fedora.
2. Look at permissions on /etc/ssh/ssh_host_*key
3.
  
Actual results:
bash-4.2$ ls -l /etc/ssh/ssh_host_*key
-rw------- 1 root ssh_keys  668 May  7 15:22 /etc/ssh/ssh_host_dsa_key
-rw------- 1 root ssh_keys  965 May  7 15:22 /etc/ssh/ssh_host_key
-rw------- 1 root ssh_keys 1679 May  7 15:22 /etc/ssh/ssh_host_rsa_key


Expected results:
bash-4.2$ ls -l /etc/ssh/ssh_host_*key
-rw-r----- 1 root ssh_keys  668 May  7 15:22 /etc/ssh/ssh_host_dsa_key
-rw-r----- 1 root ssh_keys  965 May  7 15:22 /etc/ssh/ssh_host_key
-rw-r----- 1 root ssh_keys 1679 May  7 15:22 /etc/ssh/ssh_host_rsa_key



Additional info:
Comment 1 Petr Lautrbach 2012-05-09 08:00:25 EDT
Given that openssh package is built with openssh-5.8p1-keyperm.patch, which enables key files owned by ssh_keys group with 0640 permissions, I've reverted 81da99ed9bb19f029edfb92f6a8839886777db49 in git. 

Thanks for the report.
Comment 2 Fedora End Of Life 2013-04-03 16:30:03 EDT
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19

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