Bug 1015935 - Bash completion handles HostName entries in .ssh/config that have "%h" incorrectly
Bash completion handles HostName entries in .ssh/config that have "%h" incorr...
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: bash-completion (Show other bugs)
19
All All
unspecified Severity low
: ---
: ---
Assigned To: Ville Skyttä
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-10-06 20:47 EDT by Michael
Modified: 2014-11-15 04:09 EST (History)
4 users (show)

See Also:
Fixed In Version: bash-completion-2.1-6.20141110git52d8316.fc21
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2014-11-15 04:09:47 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Michael 2013-10-06 20:47:14 EDT
Description of problem:

Bash completion handles HostName entries in .ssh/config that have "%h" in them incorrectly. It displays the string containing %h as a list of ssh targets, which is an error because hostnames of the form %h.domain.com never exist.

Version-Release number of selected component (if applicable):

bash-completion-2.1-2.fc19.noarch

How reproducible:

Always

Steps to Reproduce:
1. Add an entry to ~/.ssh/config like the following:

Host red green
    HostName %h.acmepaint.com

2. Type "ssh" and press tab to expand the list of known hosts

Actual results:

The string "%h.acmepaint.com" shows up in the list, ex:

  green %h.acmepaint.com red

Expected results:

It should either expand the %h entry as ssh does, or not show it at all. That is, either display

  green red

or display

  green green.acmepaint.com red red.acmepaint.com

Additional info:

The %h shorthand feature was added in OpenSSH 5.6 to let users create more concise .ssh/config files. The shortcut above replaces these two "spelled out" entries:
Host green
    HostName green.acmepaint.com
Host red
    HostName red.acmepaint.com
Comment 2 Fedora Update System 2014-11-10 16:32:28 EST
bash-completion-2.1-6.20141110git52d8316.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/bash-completion-2.1-6.20141110git52d8316.fc21
Comment 3 Fedora Update System 2014-11-11 21:36:46 EST
Package bash-completion-2.1-6.20141110git52d8316.fc21:
* should fix your issue,
* was pushed to the Fedora 21 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing bash-completion-2.1-6.20141110git52d8316.fc21'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-14732/bash-completion-2.1-6.20141110git52d8316.fc21
then log in and leave karma (feedback).
Comment 4 Fedora Update System 2014-11-15 04:09:47 EST
bash-completion-2.1-6.20141110git52d8316.fc21 has been pushed to the Fedora 21 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.