Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make ssh connections via paramiko more configurable #2567

Closed
totaam opened this issue Jan 27, 2020 · 13 comments
Closed

make ssh connections via paramiko more configurable #2567

totaam opened this issue Jan 27, 2020 · 13 comments
Labels

Comments

@totaam
Copy link
Collaborator

totaam commented Jan 27, 2020

Issue migrated from trac ticket # 2567

component: network | priority: major | resolution: fixed

2020-01-27 17:13:25: antoine created the issue


OpenSSH supports configuration options, both in its config file and using the command line.
We should provide a similar way of setting options:

  • reading the openssh ssh_config if present
  • handling options in URL strings

See also:

@totaam
Copy link
Collaborator Author

totaam commented Jan 27, 2020

2020-01-27 17:14:08: antoine changed status from new to assigned

@totaam
Copy link
Collaborator Author

totaam commented Jan 27, 2020

2020-01-27 17:14:08: antoine edited the issue description

@totaam
Copy link
Collaborator Author

totaam commented Jan 27, 2020

2020-01-27 18:08:16: antoine changed status from assigned to closed

@totaam
Copy link
Collaborator Author

totaam commented Jan 27, 2020

2020-01-27 18:08:16: antoine set resolution to fixed

@totaam
Copy link
Collaborator Author

totaam commented Jan 27, 2020

2020-01-27 18:08:16: antoine edited the issue description

@totaam
Copy link
Collaborator Author

totaam commented Jan 27, 2020

2020-01-27 18:08:16: antoine commented


Done in r25103.

Self-explanatory examples (add --debug=ssh for debugging):

xpra attach ssh://localhost/ --ssh=paramiko:verify-hostkey=no,auth=none+password
xpra attach ssh://localhost/ --ssh=paramiko:verify-hostkey=yes,verifyhostkeydns=yes,auth=agent+key
xpra attach ssh://localhost/ --ssh=paramiko:verifyhostkeydns=no,auth=password,numberofpasswordprompts=5

@totaam
Copy link
Collaborator Author

totaam commented Feb 6, 2020

2020-02-06 13:00:58: antoine changed status from closed to reopened

@totaam
Copy link
Collaborator Author

totaam commented Feb 6, 2020

2020-02-06 13:00:58: antoine removed resolution (was fixed)

@totaam
Copy link
Collaborator Author

totaam commented Feb 6, 2020

2020-02-06 13:00:58: antoine commented


Let's also make it possible to specify the keyfile to use.

@totaam
Copy link
Collaborator Author

totaam commented Feb 8, 2020

2020-02-08 05:36:31: antoine changed status from reopened to closed

@totaam
Copy link
Collaborator Author

totaam commented Feb 8, 2020

2020-02-08 05:36:31: antoine set resolution to fixed

@totaam
Copy link
Collaborator Author

totaam commented Feb 8, 2020

2020-02-08 05:36:31: antoine commented


As of r25180, we can also specify paramiko attributes on the URI, including the key:

XPRA_SSH_DEFAULT_KEYFILES="" xpra attach "ssh://localhost/?key=$HOME/.ssh/id_rsa&auth=key"

The same options can still be specified as a general paramiko attribute:

XPRA_SSH_DEFAULT_KEYFILES="" xpra attach "ssh://localhost/" --ssh="paramiko:key=/home/antoine/.ssh/id_rsa,auth=key"

The new XPRA_SSH_DEFAULT_KEYFILES env var is used in these examples to disable the default ssh key locations.

-Important*: the old URI format ssh:host/DISPLAY is no longer supported. Parsing such strings was becoming increasingly unwieldy.

See also #2582.

@totaam totaam closed this as completed Feb 8, 2020
@totaam
Copy link
Collaborator Author

totaam commented Feb 12, 2020

2020-02-12 14:49:00: antoine commented


r25180 caused a regression when there is no host config, fixed in r25214

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant