digitalocean / digitalocean/doctl

doctl compute ssh ask for password with provided passwordless key

Open
#462 0 comments 0 reactions 0 assignees View on GitHub
windows
Dominant language
Go
Stars
3.4k
Forks
496
Avg merge
1d 2h
Merged PRs (30d)
31

Description

Hi,

When I try:
```
C:\Users\Niki\Downloads>.\doctl.exe compute ssh ubuntu@dsk3.nikigmtest
ubuntu@104.248.yyy.xxx's password:
```
The prompt should not appear:
1. There is no password set for the account, only public key access
2. I have ssh agent activated:
```
C:\Users\Niki\Downloads>ssh-add -l
2048 SHA256:5XHDr28PzqMP63FvvCeC+pzJYlQc58traugbTBhRnBo C:\Users\Niki\Documents\ubuntu-docker.key (RSA)
```
3. When I try to login from CMD it works fine:
```
C:\Users\Niki\Downloads>ssh ubuntu@104.248.yyy.xxx
...
ubuntu@dsk3:~$
```
4. When I delete the keys from ssh agent it do not ask for password - expected:
```
C:\Users\Niki\Downloads>ssh-add -D
All identities removed.

C:\Users\Niki\Downloads>ssh-add -l
The agent has no identities.

C:\Users\Niki\Downloads>ssh ubuntu@104.248.yyy.xxx
ubuntu@104.248.yyy.xxx: Permission denied (publickey).
```
5. It do not works with explicit path as well:
```
C:\Users\Niki\Downloads>.\doctl.exe compute ssh ubuntu@dsk3.nikigmtest --ssh-key-path=c:\Users\Niki\Documents\ubuntu-docker.key
ubuntu@104.248.yyy.xxx's password:
```
OS is Windows 10 1903. I can use doctl compute droplet list dsk3.nikigmtest, get the IP from there and login, but it is not comfortable. The same works fine under Linux (Ubuntu 18.04.2)
Doctl is latest:
```
C:\Users\Niki\Downloads>doctl.exe version
doctl version 1.19.0-release
Git commit hash: e6718644
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.