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

Add support for a certificate file to be passed to asyncssh.connect() #63

Open
Andrew-S-Rosen opened this issue Apr 25, 2023 · 0 comments
Labels
feature New feature or functionality

Comments

@Andrew-S-Rosen
Copy link

Andrew-S-Rosen commented Apr 25, 2023

What should we add?

This is essentially a mimic of AgnostiqHQ/covalent-slurm-plugin#45, and the PR there (AgnostiqHQ/covalent-slurm-plugin#47) would work equally well here.

Currently, client_keys in asyncssh.connect() is set to client_keys=[self.ssh_key_file], and self.ssh_key_file is coded such that it can only be a single path, as shown below. However, the authentication process on some machines requires a list[tuple(str, str)] to be passed that has the SSH key and a certificate file, respectively.

conn = await asyncssh.connect(
self.hostname,
username=self.username,
client_keys=[self.ssh_key_file],
known_hosts=None,
)

Describe alternatives you've considered.

There are no alternatives if you require a certificate to SSH because the current code is hard-coded to only accept an SSH key as the authentication method.

@Andrew-S-Rosen Andrew-S-Rosen added the feature New feature or functionality label Apr 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or functionality
Projects
None yet
Development

No branches or pull requests

1 participant