Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Can you post on-prem and Azure logs, with both using 6.1.2?
Corey10e

WinSCP 6.1.2 GUI is fine
PuTTY is not, but that being said I have never used PuTTY to connect to anything because I always use WinSCP. With PuTTY I get "Server refused to allocate pty".
martin

So do I understand right that the actual problem is not on-prem vs. Azure, but 5.21.7 vs. 6.1.2?
Can you connect with WinSCP 6.1.2 GUI? Can you connect with PuTTY 0.79?
Corey10e

Old version works fine, we prefer to constantly have the most recent version of course. Attached is the log from the old. We connect to both USBank and Wells Fargo... USBank works fine with the new version but not Wells Fargo... thats whats in the original file. Please let me know if I can provide anything else.
martin


  1. You are using different versions of WinSCP on Azure and on "OnPrem". Plase post consistent logs from the same versions of WinSCP.
  2. The Azure log contains 16 sessions, some of which succeeded to connect and some did not. So is it problem intermittent?
Corey10e

Thanks Martin, files attached privately.
martin

Re: Failed to get reply from Pageant - Server refused public-key signature despite accepting key!

Please attach full logs both from "on-prem server" and "Azure Web App service".
Corey10e

Failed to get reply from Pageant - Server refused public-key signature despite accepting key!

WinSCP 6.1.2 (.NET assembly)

I am able to connect to this via the GUI just fine. So using the .NET NuGet package is where I am having the issue. Furthermore this works on an on-prem server, but not on Azure Web App service. Here is the code I have
SessionOptions sessionOptions = new SessionOptions();
if (loginPPK != null)
{
    sessionOptions = new SessionOptions
    {
        SshPrivateKeyPath = loginPPK,
        PortNumber = port,
        HostName = hostName,
        UserName = userName,
        Password = password,
        Protocol = Protocol.Sftp,
        SshHostKeyFingerprint = sshFingerprint
    };
}
else
{
    sessionOptions = new SessionOptions
    {
        PortNumber = port,
        HostName = hostName,
        UserName = userName,
        Password = password,
        Protocol = Protocol.Sftp,
        SshHostKeyFingerprint = sshFingerprint
    };
}
 
if (useOldSCP)
{
    sessionOptions.AddRawSettings("SFTPMaxVersion", "3");
}
 
using (WinSCP.Session session = new WinSCP.Session())
{
    session.SessionLogPath = logPath;
 
    // Connect
    session.Open(sessionOptions);
 
    // Download files
    TransferOptions transferOptions = new TransferOptions
    {
        TransferMode = TransferMode.Binary,
        FileMask = fileMask
    };
 
    TransferOperationResult transferResult;
    transferResult = session.GetFiles(remotePath, localPath, false, transferOptions);
 
    // Throw on any error
    transferResult.Check();
    results.Success = transferResult.IsSuccess;
}

Here is a piece of the log:
2023-10-11 13:48:40.242 Reading key file "C:\local\Temp\jobs\triggered\PROGRAM\KEYS\key_name_priv.ppk"
. 2023-10-11 13:48:40.262 Pageant is running. Requesting keys.
. 2023-10-11 13:48:40.262 Failed to get reply from Pageant
! 2023-10-11 13:48:40.262 Using username "*******".
< 2023-10-11 13:48:40.273 Script: Using username "*******".
. 2023-10-11 13:48:40.320 Server offered these authentication methods: publickey,password
. 2023-10-11 13:48:40.320 Offered public key
. 2023-10-11 13:48:40.382 Offer of public key accepted
! 2023-10-11 13:48:40.382 Authenticating with public key "rsa-key-20180709"
< 2023-10-11 13:48:40.382 Script: Authenticating with public key "rsa-key-20180709".
. 2023-10-11 13:48:40.712 Sent public key signature
! 2023-10-11 13:48:40.835 Server refused public-key signature despite accepting key!
< 2023-10-11 13:48:40.835 Script: Server refused public-key signature despite accepting key!
. 2023-10-11 13:48:40.851 Server refused public-key signature despite accepting key!
. 2023-10-11 13:48:40.898 Server offered these authentication methods: publickey,password
. 2023-10-11 13:48:40.898 Prompt (password, "SSH password", <no instructions>, "&Password: ")
. 2023-10-11 13:48:40.898 Prompting user for the credentials.
. 2023-10-11 13:48:40.914 Prompt cancelled.
. 2023-10-11 13:48:40.914 User aborted at password prompt
. 2023-10-11 13:48:40.914 Attempt to close connection due to fatal exception:

I have tried the useOldSCP on and off.