You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
OpenSSH treats configuration directives case-insensitively, but ssh-config does not. For example:
Host example
hOsTnaME 1.2.3.4
% ssh -G examplehost examplehostname 1.2.3.4
However, SSHConfig.compute() keeps case and developer should be consider it.
Proposal
Add a mechanism to handle directives in a case-insensitive manner to match OpenSSH. Possible approaches include:
Always normalize directive names to lowercase internally.
Add an option such as ignoreCase: true for compute() to unify case.
Maintain both the original and lowercase versions of the directive.
It would be great if ssh-config could support case-insensitive directives to better align with OpenSSH behavior. I'd be happy to contribute a PR if there's a preferred approach.
The text was updated successfully, but these errors were encountered:
I'd prefer the second approach, such as compute(host, { lowerCase: true }), to ignore case sensitivity and to convert the parameter names in the result to lower case. Future major release may opt in this flag by default.
Summary
OpenSSH treats configuration directives case-insensitively, but
ssh-config
does not. For example:However,
SSHConfig.compute()
keeps case and developer should be consider it.Proposal
Add a mechanism to handle directives in a case-insensitive manner to match OpenSSH. Possible approaches include:
It would be great if ssh-config could support case-insensitive directives to better align with OpenSSH behavior. I'd be happy to contribute a PR if there's a preferred approach.
The text was updated successfully, but these errors were encountered: