ashkulz / NppFTP

Plugin for Notepad++ allowing FTP, FTPS, FTPES and SFTP communications
https://ashkulz.github.io/NppFTP/
320 stars 93 forks source link

SFTP: Error during authentication: Access denied for 'none'. Authentication that can continue: publickey #270

Closed rdk-pmis closed 4 years ago

rdk-pmis commented 4 years ago

Description of the Issue

Can't login using private key authentication. I am using a ppk private key. The public key is added to the authorized_keys file, I can connect using Putty using the same key.

Steps to Reproduce the Issue

  1. Add a new server with privatekey authentication to the serverlist in Notepad++, fill in the username and add a putty format private key.
  2. Connect to the server
  3. Enter password for private key

Expected Behavior

Successful connection

Actual Behavior

Connecting [SFTP] Host key accepted [SFTP] Invalid private key file or incorrect passphrase [SFTP] Error during authentication: Access denied for 'none'. Authentication that can continue: publickey Unable to connect Disconnected

Debug Information

Notepad++ v7.8.1 (64-bit) Build time : Oct 27 2019 - 22:57:19 Path : C:\Program Files\Notepad++\notepad++.exe Admin mode : OFF Local Conf mode : OFF OS Name : Windows 10 Pro (64-bit) OS Version : 1809 OS Build : 17763.864 Plugins : DSpellCheck.dll mimeTools.dll NppConverter.dll NppExport.dll NppFTP.dll NPPFTP version: 0.30.1 Unicode Type of connection: SFTP Type of authentication: Privatekey file

chcg commented 4 years ago

Could you please try version https://github.com/ashkulz/NppFTP/releases/tag/v0.29.2 (v0.30.0-v0.30.2 are set back to draft/beta version due to issue #265 Regression for FTPES, FTPS on directory changes).

This version contains https://www.libssh.org/2019/10/25/libssh-0-9-1/ which contains multiple SFTP related fixes.

But probably the ppk format is the problem, see https://stackoverflow.com/questions/26900746/libssh-trying-to-authenticate-with-public-and-private-keys and https://the.earth.li/~sgtatham/putty/0.73/htmldoc/Chapter8.html#puttygen-conversions

rdk-pmis commented 4 years ago

Issue was indeed the ppk key. I used the normal OpenSSH privatekey and now I can connect.