Bug 1051490 - ssh-keygen fails to generate key when the host name is 64 byte
Summary: ssh-keygen fails to generate key when the host name is 64 byte
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: openssh
Version: 20
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Petr Lautrbach
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-01-10 12:29 UTC by Attila Fazekas
Modified: 2014-07-22 03:30 UTC (History)
5 users (show)

Fixed In Version: openssh-6.4p1-5.fc20
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-07-22 03:30:49 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
OpenSSH Project 2239 0 None None None Never

Internal Links: 1187689

Description Attila Fazekas 2014-01-10 12:29:56 UTC
Description of problem:

sshd fails to start when the hostname is 64 byte.


Version-Release number of selected component (if applicable):
openssh-6.3p1-5.fc20.x86_64, openssh-server-6.4p1-3.fc20.x86_64, openssh-6.2p2-7.fc19.x86_64

How reproducible:
always

Steps to Reproduce:
1. hostname abcdeabcdeabcdeabcdeabcdeabcdeabcdeabcdeabcdeabcdeabcdeabcdeabcd
2. /usr/bin/ssh-keygen -q -t "ecdsa" -f /tmp/foo-$RANDOM  -C "" -N ""

Actual results:
$ /usr/bin/ssh-keygen -q -t "ecdsa" -f /tmp/foo-$RANDOM  -C "" -N ""
gethostname: File name too long

The above command called by:
$ sshd-keygen 
Generating SSH2 ECDSA host key:                            [FAILED]

$ service sshd restart
Redirecting to /bin/systemctl restart  sshd.service
Job for sshd.service failed. See 'systemctl status sshd.service' and 'journalctl -xn' for details.

From the journalctl -xn:
# sshd-keygen[17739]: Generating SSH2 ECDSA host key: [FAILED]
# systemd[1]: sshd.service: control process exited, code=exited status=1
# systemd[1]: Failed to start OpenSSH server daemon.

The ssh server does not able to start.

Expected results:
The key file can be generated, and the sshd starts up.

Additional info:

Comment 1 Fedora Update System 2014-07-18 07:11:34 UTC
openssh-6.4p1-5.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/openssh-6.4p1-5.fc20

Comment 2 lnie 2014-07-18 08:47:36 UTC
openssh-6.4p1-5.fc20 works

Comment 3 Fedora Update System 2014-07-19 06:01:19 UTC
Package openssh-6.4p1-5.fc20:
* should fix your issue,
* was pushed to the Fedora 20 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing openssh-6.4p1-5.fc20'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-8504/openssh-6.4p1-5.fc20
then log in and leave karma (feedback).

Comment 4 Fedora Update System 2014-07-22 03:30:49 UTC
openssh-6.4p1-5.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.


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