New SFTP plugin available now

Discuss and announce Total Commander plugins, addons and other useful tools here, both their usage and their development.

Moderators: white, Hacker, petermad, Stefan2

Post Reply
cpp64
Junior Member
Junior Member
Posts: 83
Joined: 2023-05-12, 16:03 UTC

[ Misspelling ][ SFTP Plugin ] LoginPasswor(t) --> (d)

Post by *cpp64 »

--------------------
[ Help ]
For security reasons, you should ...
...
"KeyPassword","LoginPasswor(t)"
--------------------

// Misspelling
LoginPasswor(t) --> LoginPasswor(d)
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: [ Misspelling ][ SFTP Plugin ] LoginPasswor(t) --> (d)

Post by *ghisler(Author) »

Could you please be more specific where you found the word Passwort with a "t"? I checked the entire SFTP plugin sources, and it can only be found in the German translation file. There is also no "Help" button in the SFTP plugin. I therefore also checked the html help in Total Commander for Android and the web page ghisler.com, but could only find it on the German pages. What am I missing?
Author of Total Commander
https://www.ghisler.com
cpp64
Junior Member
Junior Member
Posts: 83
Joined: 2023-05-12, 16:03 UTC

Re: [ Misspelling ][ SFTP Plugin ] LoginPasswor(t) --> (d)

Post by *cpp64 »

ghisler(Author) wrote: 2023-12-10, 08:39 UTC Could you please be more specific where you found the word Passwort with a "t"? I checked the entire SFTP plugin sources, and it can only be found in the German translation file. There is also no "Help" button in the SFTP plugin. I therefore also checked the html help in Total Commander for Android and the web page ghisler.com, but could only find it on the German pages. What am I missing?
My apologies.

It's a problem with the TC-Windows-SFTP-Plugin-v3.05.

Android FTP & SFTP Plugin subconsciously led me to this Android board.
I thought it was an Android issue until just before I posted this.

// TC-Windows-SFTP-Plugin-v3.05
SFTP-Plugin --> Property --> [Password: [?]] // click [?]
----------------------------------------
[ Help ]
[!] For security reasons, you should only save passwords protected by a master password.
If you need 2 passwords (for private key and login), enter them as follows:
"KeyPassword","LoginPasswor(( t ))" // <-- here
----------------------------------------

// sftpplug.rc : 803
----------------------------------------
IDS_HELP_PASSWORD "For security reasons, you should only save passwords protected by a master password.\n\nIf you need 2 passwords (for private key and login), enter them as follows:\n\n""KeyPassword"",""LoginPasswor(( t ))"""
----------------------------------------


- Edit -

viewtopic.php?p=444157#p444157
Already reported.

ps.
Would you move this topic to the " Plugins and addons: devel.+support (English)" or delete this topic? // Already reported.
User avatar
white
Power Member
Power Member
Posts: 4623
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Re: [ Misspelling ][ SFTP Plugin ] LoginPasswor(t) --> (d)

Post by *white »

cpp64 wrote: 2023-12-10, 09:15 UTC viewtopic.php?p=444157#p444157
Already reported.

ps.
Would you move this topic to the " Plugins and addons: devel.+support (English)" or delete this topic? // Already reported.

Moderator message from: white » 2023-12-10, 10:32 UTC

Merged with SFTP plugin thread.
Bug has already been fixed in new beta.
JOUBE
Power Member
Power Member
Posts: 1477
Joined: 2004-07-08, 08:58 UTC

Re: New SFTP plugin available now

Post by *JOUBE »

ghisler(Author) wrote: 2023-11-28, 16:45 UTC A new beta version (3) is available now:
https://www.totalcommander.ch/beta/sftpplug310b3.zip
....
- Remote copying files with F5 between two folders on the server: Use parameter -p to keep the file timestamp (retry without in case of error, turn off if error recognized)
Thank you again for this new feature, which is very, very usefull.


TC crash during file operation with Dropbear ssh server:
ghisler(Author) wrote: 2023-12-04, 11:20 UTC Thanks, I can confirm the problem. Unfortunately it seems to be a bug in Total Commander, nit the plugin. I will check it.
Is it possible to fix the part within the plugin of this problem before the next release of the plugin, so that the problem is fixed with the next release of Tc (TCv11.03 or so)?


SFTP sehr langsam (vor allem Upload):
I can confirm that. The plugin takes up to 3x as long. But and that's why the plugin is still very usefull: All file manager operations (reading directories, etc.) run much faster and better in the plugin than in other tools. Is it possible in the new year to solve some speed brakes in the area of file transfer (only there) of the plugin?

Joube
CoolWater
Power Member
Power Member
Posts: 737
Joined: 2003-03-27, 16:33 UTC

Re: New SFTP plugin available now

Post by *CoolWater »

I tested FileZilla, too. Indeed, it is much more faster than the SFTP plugin, no matter if SFTP or SCP mode is activated. In my setup, SFTP via FileZilla is 3-4x faster than SFTP via plugin.

I took a quick look at the FileZilla sources and it pretty much seems to be all about chunk sizes. SFTP plugin uses a static buffer size of 32K for download and 16K for upload. That seems to be the "performance killer". FileZilla uses dynamic chunk sizes depending on transfer time/size.

In theory there might be a negative effect on UI responsibility when trying to cancel an operation but in real life i think this can be ignored.

Maybe we should give it a try?
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: New SFTP plugin available now

Post by *ghisler(Author) »

SCP transfers (which are usually much faster than SFTP) are entirely handled within libssh2, in functions libssh2_scp_recv2 and libssh2_scp_send64/libssh2_scp_send_ex, so it can't be improved within the plugin itself.
Author of Total Commander
https://www.ghisler.com
CoolWater
Power Member
Power Member
Posts: 737
Joined: 2003-03-27, 16:33 UTC

Re: New SFTP plugin available now

Post by *CoolWater »

Talking about buffer sizes while sending/receiving data, this surely can be improved. libssh2_scp_recv2 and libssh2_scp_send64/libssh2_scp_send_ex only return the channel to read or write to. So this is the point where dynamic buffer sizes could/would improve read/write performance. Same applies for libssh2_sftp_read/libssh2_sftp_write.
CoolWater
Power Member
Power Member
Posts: 737
Joined: 2003-03-27, 16:33 UTC

Re: New SFTP plugin available now

Post by *CoolWater »

For testing, I made some changes concerning the buffer sizes. They are now dynamically calculated. Here are my results:

Line speed: 1000 Mbit DL, 50 Mbit UL

Download speed before:
SFTP: ~7.7 MB/s
SCP: ~23 MB/s

Download speed with dynamic buffers:
SFTP: ~20 MB/s
SCP: ~28 MB/s

Download speed FileZilla:
30 MB/s

Upload speed before:
SFTP: ~2.7 MB/s
SCP: ~5.5 MB/s

Upload speed with dynamic buffers:
SFTP: ~5.3 MB/s
SCP: ~5.5 MB/s

Upload speed FileZilla:
6 MB/s
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: New SFTP plugin available now

Post by *ghisler(Author) »

Would you be willing to share your code changes?
Author of Total Commander
https://www.ghisler.com
CoolWater
Power Member
Power Member
Posts: 737
Joined: 2003-03-27, 16:33 UTC

Re: New SFTP plugin available now

Post by *CoolWater »

Sure, I just sent the changes via email.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: New SFTP plugin available now

Post by *ghisler(Author) »

Got it, thanks a lot! I will check it as soon as possible.
Author of Total Commander
https://www.ghisler.com
gpant
Junior Member
Junior Member
Posts: 21
Joined: 2006-11-19, 19:58 UTC
Location: Athens, Greece
Contact:

Re: New SFTP plugin available now

Post by *gpant »

Windows supports a native implementation of openssh for some years now, would you think it would be possible to use the ssh agent thats native in the OS instead of pageant in the future ?
I know I can use keepassxc to push the keys to both openssh & pageant but I dont want to have to manage both agents just for TC.

BR,
GP
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: New SFTP plugin available now

Post by *ghisler(Author) »

Sorry, I couldn't find any information on how to communicate with Windows ssh agent. If anyone can find documentation, please let me know.
Author of Total Commander
https://www.ghisler.com
gpant
Junior Member
Junior Member
Posts: 21
Joined: 2006-11-19, 19:58 UTC
Location: Athens, Greece
Contact:

Re: New SFTP plugin available now

Post by *gpant »

its fully compatible with the openssh agent, the source: https://github.com/PowerShell/openssh-portable/

I am using keys from the agent in my own software using this go library golang.org/x/crypto/ssh/agent if you want to checkout their implementation, but I noticed you use libssh2 which has already support for the ssh-agent in its API https://libssh2.org/libssh2_agent_connect.html

Edit:
The windows documentation for enabling/starting the service in the OS https://learn.microsoft.com/en-us/windows-server/administration/openssh/openssh_overview you can ignore the server part, openssh agent + server are part of windows 10+

BR,
GP
Post Reply