Bug 450891

Summary: Konsole SSH Manager does not parse options from ssh config file properly
Product: [Applications] konsole Reporter: ioo+kde
Component: sshmanagerAssignee: Konsole Developer <konsole-devel>
Status: REPORTED ---    
Severity: normal    
Priority: NOR    
Version: 21.12.2   
Target Milestone: ---   
Platform: Neon   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: attachment-20841-0.html

Description ioo+kde 2022-02-26 21:11:51 UTC
SUMMARY
Konsole SSH Manager does not parse directives from ssh config file properly. Opening the SSH Manager plugin and pressing "Import" button does successfully import the host list from ~/.ssh/config however only the user and host name are successfully imported.

STEPS TO REPRODUCE
Example 1 from ~/.ssh/config

Host myhost
    HostName myhost.com
    User myuser
    Port 3000

Result when clicking on the myhost entry in SSH Manager:

ssh myhost.com
ssh: connect to host myhost.com port 22: Connection refused

Here the SSH plugin failed to parse the "Port" directive correctly.

Example 2:

Host pi
    HostName myhost2
    User myuser2
    IdentityFile ~/.ssh/id_rsa

Result when clicking on the myhost2 entry:

ssh myhost2.com
ssh: connect to host myhost2.com: Permission denied (publickey).

Here the SSH plugin failed to parse "IdentityFile" directive correctly.

EXPECTED RESULT
The expected result is that the ssh plugin will parse each host entry and use the option directives correctly, by ignoring them, this plugin is not useful.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: KDE Neon 5.24
KDE Plasma Version: 5.24.1
KDE Frameworks Version: 5.91.0
Qt Version: 5.15.3
Comment 1 tcanabrava 2022-02-27 11:18:44 UTC
Created attachment 147165 [details]
attachment-20841-0.html

Aha, sorry for that.
I’ll fix that today, looks easy.

Le sam. 26 févr. 2022 à 22:12, <bugzilla_noreply@kde.org> a écrit :

> https://bugs.kde.org/show_bug.cgi?id=450891
>
>             Bug ID: 450891
>            Summary: Konsole SSH Manager does not parse options from ssh
>                     config file properly
>            Product: konsole
>            Version: 21.12.2
>           Platform: Neon Packages
>                 OS: Linux
>             Status: REPORTED
>           Severity: normal
>           Priority: NOR
>          Component: sshmanager
>           Assignee: konsole-devel@kde.org
>           Reporter: ioo+kde@posteo.net
>   Target Milestone: ---
>
> SUMMARY
> Konsole SSH Manager does not parse directives from ssh config file
> properly.
> Opening the SSH Manager plugin and pressing "Import" button does
> successfully
> import the host list from ~/.ssh/config however only the user and host
> name are
> successfully imported.
>
> STEPS TO REPRODUCE
> Example 1 from ~/.ssh/config
>
> Host myhost
>     HostName myhost.com
>     User myuser
>     Port 3000
>
> Result when clicking on the myhost entry in SSH Manager:
>
> ssh myhost.com
> ssh: connect to host myhost.com port 22: Connection refused
>
> Here the SSH plugin failed to parse the "Port" directive correctly.
>
> Example 2:
>
> Host pi
>     HostName myhost2
>     User myuser2
>     IdentityFile ~/.ssh/id_rsa
>
> Result when clicking on the myhost2 entry:
>
> ssh myhost2.com
> ssh: connect to host myhost2.com: Permission denied (publickey).
>
> Here the SSH plugin failed to parse "IdentityFile" directive correctly.
>
> EXPECTED RESULT
> The expected result is that the ssh plugin will parse each host entry and
> use
> the option directives correctly, by ignoring them, this plugin is not
> useful.
>
> SOFTWARE/OS VERSIONS
> Linux/KDE Plasma: KDE Neon 5.24
> KDE Plasma Version: 5.24.1
> KDE Frameworks Version: 5.91.0
> Qt Version: 5.15.3
>
> --
> You are receiving this mail because:
> You are the assignee for the bug.