On 05/11/2024 18.31, Federico Kircheis wrote:
On 05/11/2024 18.29, ASSI via Cygwin wrote:
Federico Kircheis via Cygwin writes:
I also did a chmod/chown on the file to ensure that the permission
where correct.
The file with the permission unchanged worked without issues when
moved in ~/.ssh.
Whatever directory that file resides in must be readable only by the
owner or SSH will not use it.
Regard,
Achim.
Mhm, that could be it.
I did not try to modify the permission of the directory.
Nope.
Directory has permission 0700, file has permission 0600, just to be sure
I've execute chmod on both.
I can access they key but I still experienced the issue
~~~~
$ ls -la $SSH_KEY
-rw-------+ 1 Administrators None 3357 Dec 20 2019
/cygdrive/c/cygport-ps/ssh/id_rsa_cyg
$ ls -la /cygdrive/c/cygport-ps/ssh/
total 13
drws--S---+ 1 Administrators None 0 Jan 14 2023 .
drwxrwx---+ 1 Administrators None 0 Dec 18 10:55 ..
-rw-------+ 1 Administrators None 3357 Dec 20 2019 id_rsa_cyg
-rw-------+ 1 Administrators None 745 Jul 25 2018 id_rsa_cyg.pub
-rw-------+ 1 Administrators None 236 Mar 18 2020 known_hosts
~~~~
If I manually execute lftp
~~~~
$ lftp sftp://cygwin:@cygwin.com
lftp cygwin@cygwin.com:~> cd .
cd `.' [Connecting...]
~~~~
and hangs.
I'm not sure how to debug the issue further, and the relation between
all tools.
~~~~
$ sftp sftp://cygwin:@cygwin.com
cygwin:@cygwin.com: Permission denied (publickey).
Connection closed
~~~~
I guess lftp/sftp does not support the variable SSH_KEY, as I get the
same "Permission denied (publickey)." error with "ssh -v
sftp://cygwin:@cygwin.com", and I see that there is no attempt to use my
ssh key
Also following command does not report an error:
~~~~
sftp -i $SSH_KEY sftp://cygwin:@cygwin.com
Connection closed by 8.43.85.97 port 22
Connection closed
~~~~
--
Problem reports: https://cygwin.com/problems.html
FAQ: https://cygwin.com/faq/
Documentation: https://cygwin.com/docs.html
Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple