Post a reply

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

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

kuzyaka wrote:

OK!
I hope, that on my Cygwin SSH server the syntax /cygdrive/d/Apache24/htdocs/new_year/ in the SSH_FXP_REALPATH call, will WinSCP always support?

There's no restriction on WinSCP side. It's all about the server.
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin wrote:

I do not know. Maybe it's not even possible.

OK!
I hope, that on my Cygwin SSH server the syntax /cygdrive/d/Apache24/htdocs/new_year/ in the SSH_FXP_REALPATH call, will WinSCP always support?
martin

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

kuzyaka wrote:

Tell me, what do I need to configure on my server to support D:/Apache24/htdocs/new_year/ syntax in the SSH_FXP_REALPATH call?

I do not know. Maybe it's not even possible.
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin wrote:

It's a bug (or misconfiguration) of your SFTP server.
The server does not support D:/Apache24/htdocs/new_year/ syntax in SSH_FXP_REALPATH call.

OK!
I'm using the Cygwin SSH server.
Tell me, what do I need to configure on my server to support D:/Apache24/htdocs/new_year/ syntax in the SSH_FXP_REALPATH call?
martin

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

kuzyaka wrote:

Do you expect that in the next updates WinSCP will also correctly support the SFTP specification in the session.ListDirectory and session.GetFiles commands?

I do not plan to change their implementation, unless it brings some benefit. It would not help you either, right? So why are you asking?
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin wrote:

Your understanding of the problem.

Do you expect that in the next updates WinSCP will also correctly support the SFTP specification in the session.ListDirectory and session.GetFiles commands?
martin

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

kuzyaka wrote:

Sorry, I did not understand.
What exactly is correct?

Your understanding of the problem.
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin wrote:

Yes, that's correct.

Sorry, I did not understand.
What exactly is correct?
martin

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

Yes, that's correct.
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin wrote:

5.13 follows SFTP specification more correctly than 5.11.3 did.

martin, I understood you.
Only it turns out that 5.13 follows the SFTP specification more correctly only when executing the command session.PutFiles, and when executing the session.ListDirectory or session.GetFiles commands, does it not correctly follow the SFTP specification?
After all, teams
session.ListDirectory ("D:/")
session.GetFiles ("D:/*.pdf","D:\",False,transferOptions)
in WinSCP 5.13 are executed without errors.

And this is how to understand?
martin

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

I've answered this directly in my previous post:

martin wrote:

5.11.3 didn't use SSH_FXP_REALPATH call in this case. 5.13 does. SFTP client is not only allowed to use SSH_FXP_REALPATH for any valid path, it's actually required to do so (while most SFTP clients actually fail to do that).


In other words, 5.13 follows SFTP specification more correctly than 5.11.3 did. And your buggy or misconfigured SFTP server cannot cope with that.
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin, you never answered the main question:
Why in WinSCP 5.11.3 and earlier versions of the command
transferResult = session.PutFiles("D:\*.pdf", "D:/", False, transferOptions)

was executed without errors, and in WinSCP 5.13 there was an error?

Please answer directly to the question posed.
martin

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

kuzyaka wrote:

When I worked with WinSCP 5.11.3, he supported it, and when working with WinSCP 5.13 it stopped supporting it?

Do not you find this strange?

5.11.3 didn't use SSH_FXP_REALPATH call in this case. 5.13 does. SFTP client is not only allowed to use SSH_FXP_REALPATH for any valid path, it's actually required to do so (while most SFTP clients actually fail to do that).
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin wrote:

No, it's not a bug in WinSCP. It's a bug (or misconfiguration) of your SFTP server.
The server does not support D:/Apache24/htdocs/new_year/ syntax in SSH_FXP_REALPATH call.

You claim that my SFTP server does not support D:/Apache24/htdocs/new_year/ syntax in the SSH_FXP_REALPATH call.
When I worked with WinSCP 5.11.3, he supported it, and when working with WinSCP 5.13 it stopped supporting it?

Do not you find this strange?
martin

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

kuzyaka wrote:

martin, I believe that this is just a bug in WinSCP 5.13 and it just needs to be fixed.

No, it's not a bug in WinSCP. It's a bug (or misconfiguration) of your SFTP server.
The server does not support D:/Apache24/htdocs/new_year/ syntax in SSH_FXP_REALPATH call.
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin, I believe that this is just a bug in WinSCP 5.13 and it just needs to be fixed.
Guest

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

martin wrote:

If you login to the server in WinSCP GUI and navigate to your target directory, what path to you see on the top of the file list?

In the WinSCP GUI in my target directory at the top of the file list, I see: "/cygdrive/d/Apache24/htdocs/ShiShi/". This I see in all editions of WinSCP. And if I specify this path in session.PutFiles, the file is passed without error. But when specifying the target directory as "D:/Apache24/htdocs/shishi/" the error appears only in WinSCP 5.13 and only when the file is transferred (session.PutFiles). Functions (session.GetFiles and session.ListDirectory) in WinSCP 5.13 are executed without errors when specifying the target directory as "D:/Apache24/htdocs/shishi/".
Why is the session.PutFiles and session.GetFiles functions in WinSCP 5.13 behaving differently?
martin

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

If you login to the server in WinSCP GUI and navigate to your target directory, what path to you see on the top of the file list?
kuzyaka

Re: Error Code 2 in the Winscp 5.13 at PutFiles.

Anonymous wrote:

Sending session log files both from 5.13 and 5.11.3.

martin, this is not "Anonymous," it's me, "kuzyaka", attached the session log files.
Sorry, I have error number winscp, correct 5.13 and 5.11.3, not 15.13 and 15.11.3.
Guest

Re: Error Code 2 in the Winscp 15.13 at PutFiles.

martin wrote:

Please attach a full session log files both from 5.13 and 5.11.3.

Sending session log files both from 5.13 and 5.11.3.
martin

Re: Error Code 2 in the Winscp 15.13 at PutFiles.

Please attach a full session log files both from 5.13 and 5.11.3.

To generate the session log file, set Session.SessionLogPath. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
kuzyaka

Error Code 2 in the Winscp 5.13 at PutFiles.

In the Winscp 5.13, in the execution:
Dim transferResult As TransferOperationResult 

transferResult = session.PutFiles("D:\*.pdf", "D:/", False, transferOptions)

I get an error:
cannot get real path for 'D:/'
no such file or directory

though
Dim transferResult As TransferOperationResult 

transferResult = session.GetFiles("D:/*.pdf", "D:\", False, transferOptions)

runs without errors.
In Winscp 5.11.3 and earlier, everything worked without errors.
Tell me, what's the problem?