Vscode-remote-release: keywords in .ssh/config should be expected being case-insensitive

Created on 3 May 2019  路  5Comments  路  Source: microsoft/vscode-remote-release

  • VSCode Version: 1.34.0-insider
  • Local OS Version: Linux 4.18.0-16-generic / ubuntu cosmic
  • Remote OS Version: not relevant
  • Remote Extension/Connection Type: SSH

Steps to Reproduce:

  1. create .ssh/config with multiple hosts
Host host
  HostName host.name.tld
  User XXX

Host host1
  Hostname host1.name.tld
  User XXX

Host host2
  Hostname host2.name.tld
  User XXX

Host host1-host
  Hostname host1.name.tld
  User XXX
  ProxyJump host

Host host2-host
  Hostname host2.name.tld
  User XXX
  ProxyJump host
  1. click on 'remote extension' in side menu
  2. just first host ("host") in my case will be shown in "connections"
  3. click on 'refresh' icon
  4. just one host will be shown in connections

workaround

credits: TomFrost

keyword HostName ignored when written as Hostname.
According manpage, keywords are case-insensitive there in ssh_config.

expected behavior:

all hosts from .ssh/known_hosts will be shown in 'connections'.

screenshot

Screenshot_20190503_145602

bug ssh

Most helpful comment

@jose-d I'm not on the VSCode team, but this looks like a syntax error in your file. The first entry has HostName with a capital N, the rest do not. I just tested this-- Hostname with a lowercase N does not appear in the list, but uppercase it and it does.

All 5 comments

edit: it seems that in the bottom left remote button all hosts are included, so perhaps it would be enough to clarify what's the role of the menu "CONNECTIONS" and what one should expect to see there.

Experiencing the same issue/confusion.

@jose-d I'm not on the VSCode team, but this looks like a syntax error in your file. The first entry has HostName with a capital N, the rest do not. I just tested this-- Hostname with a lowercase N does not appear in the list, but uppercase it and it does.

The first entry has HostName with a capital N, the rest do not.

@TomFrost, nice, you found the trigger!

in man ssh_config they say:

The possible keywords and their meanings are as follows (note that keywords are case-insensitive and arguments are case-sensitive)

So both variants are acceptable.

EDIT: for standard ssh, scp, etc. both variants with 'H' and 'h' works.

TIL-- I thought they were case sensitive! Great catch.

Was this page helpful?
0 / 5 - 0 ratings