Disallow SCP fallback via API

Advertisement

Thusitha
Guest

Disallow SCP fallback via API

Hi,

I'm using winscp.exe and the API to upload files.
I'm using SFTP and I'm unable to upload files to one of mySFTP servers.
However, I'm able to upload to the same server when 'Allow SCP fallback' option is unchecked.

Is there any way to set this option using the API, so I hope my file upload would work?

Reply with quote

Advertisement

Guest

Re: Disallow SCP fallback via API

Thusitha wrote:

Hi,

I'm using winscp.exe and the API to upload files.
I'm using SFTP and I'm unable to upload files to one of mySFTP servers.
However, I'm able to upload to the same server when 'Allow SCP fallback' option is unchecked.

Is there any way to set this option using the API, so I hope my file upload would work?


This is for winscp 5.5.5

Reply with quote

thusithagh
Joined:
Posts:
1

Re: Disallow SCP fallback via API

Thusitha wrote:

Hi,

I'm using winscp.exe and the API to upload files.
I'm using SFTP and I'm unable to upload files to one of mySFTP servers.
However, I'm able to upload to the same server when 'Allow SCP fallback' option is unchecked.

Is there any way to set this option using the API, so I hope my file upload would work?

WinSCP version 5.5.5

Reply with quote

ByteMyzer
Guest

Re: Disallow SCP fallback via API

martin wrote:

Your duplicate (and answered) post on Stack Overflow:
https://stackoverflow.com/q/32991278/850848
The answer on stackoverflow is false. The WinSCP .NET assembly behaves like the "Allow SCP fallback" is checked, by default. The option must be "unchecked" with the following additional line of code:
sessionOptions.AddRawSettings("FSProtocol", "2"); // SFTPOnly

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
40,476
Location:
Prague, Czechia

Re: Disallow SCP fallback via API

ByteMyzer wrote:

The answer on stackoverflow is false. The WinSCP .NET assembly behaves like the "Allow SCP fallback" is checked, by default. The option must be "unchecked" with the following additional line of code:
sessionOptions.AddRawSettings("FSProtocol", "2"); // SFTPOnly
No, it's not false. If you have a different experience, please post your code and a matching log file.

Reply with quote

Advertisement

You can post new topics in this forum