SFTP plugin > Synchronize directories: the "by content" checkbox should be grayed out

Please report only one bug per message!

Moderators: white, sheep, Hacker, Stefan2

Post Reply
tarest
Junior Member
Junior Member
Posts: 12
Joined: 2020-07-25, 14:24 UTC

SFTP plugin > Synchronize directories: the "by content" checkbox should be grayed out

Post by *tarest »

If SFTP plugin is used to connect to a Secure FTP server, then the "by content" checkbox in the Synchronize directories window should be grayed out and the checkbox should be treated as if it was unchecked, because comparing FTP/SFTP folder by content isn't currently supported by Total Commander.

Unfortunately, it is not grayed out now. If it is checked by default, then I obtain exclamation marks "?".
Image: https://i.ibb.co/jhxhYdv/Synchronize-directories-Secure-FTP-plugin.png

If I connect to an FTP server without using this plugin, then the checkbox is grayed out, the files are compared, and I obtain "=". It is preferred behavior.
Image: https://i.ibb.co/rf16ck9/Synchronize-directories-FTP.png
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 41696
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: SFTP plugin > Synchronize directories: the "by content" checkbox should be grayed out

Post by *ghisler(Author) »

Synchronize directories actually supports compare by content with the SFTP plugin since plugin version 2.0. It does need one of the following commands on the server side, though:
md5sum, sha1sum, sha256sum, sha512sum
To check this, the plugin sends:
"echo md5\nmd5sum\necho sha1\nsha1sum\necho sha256\nsha256sum\necho sha512\nsha512sum\n"
and checks what the server returns.
Author of Total Commander
http://www.ghisler.com
tarest
Junior Member
Junior Member
Posts: 12
Joined: 2020-07-25, 14:24 UTC

Re: SFTP plugin > Synchronize directories: the "by content" checkbox should be grayed out

Post by *tarest »

I enabled logging by checking the following checkboxes:
Configuration > Options > Operation > Log file > Create a log file: %TEMP%\totalcmd.log
Configuration > Options > Operation > FTP > Create a log file: %TEMP%\tcftp.log

I connected to my server using SFTP plugin, changed directory to \home\user123\www\iw-components\brad\hotel, and pressed the "Compare" button.

The following lines were written to the %TEMP%\tcftp.log file:

Code: Select all

========================
Connecting to: ftp.cluster002.hosting.ovh.net
IP address: 51.68.11.188:22
Server fingerprint:
C3 91 9C 2B 2D F7 E3 E4 12 F2 08 4E 3B FB 81 07
Supported authentication methods: publickey,password
Authentication via password for user: user123
Session startup (SFTP)
CONNECT \OVH - my
Get directory: \home\user123\www\iw-components
Get directory: \home\user123\www\iw-components\brad
Get directory: \home\user123\www\iw-components\brad\hotel
Get directory: \home\user123\www\iw-components\brad\hotel
Get directory: \home\user123\www\iw-components\brad\hotel\css
Get directory: \home\user123\www\iw-components\brad\hotel\img
Check whether the server supports checksum functions...
What is wrong?
tarest
Junior Member
Junior Member
Posts: 12
Joined: 2020-07-25, 14:24 UTC

Re: SFTP plugin > Synchronize directories: the "by content" checkbox should be grayed out

Post by *tarest »

I see a new "Check whether the server supports checksum functions..." line in the log every time I press the "Compare" button. Maybe it would be better to check if an SFTP server has one of md5sum, sha1sum, sha256sum, sha512sum commands immediately after opening the "Synchronize directories" window, not after pressing the "Compare" button. Doing so, if the server doesn't have one of these commands, the Total Commander can gray out the "by content" checkbox, and don't compare files by content.

Edit:
Maybe it would be even better to check if an SFTP server has one of md5sum, sha1sum, sha256sum, sha512sum commands imemdiately after connecting to the SFTP server?
Isn't it that if the server supports md5sum, sha1sum, sha256sum, sha512sum commands, then it supports them for all files in all directories?
megaboy2k
Junior Member
Junior Member
Posts: 5
Joined: 2021-10-25, 00:24 UTC

Re: SFTP plugin > Synchronize directories: the "by content" checkbox should be grayed out

Post by *megaboy2k »

Hi tarest,

How were you able to get that log filled with connection details?
When I enable logging in my TC10: Configuration > Options > Operation > Log file > Create a log file: %TEMP%\totalcmd.log
I then can see the log file after SFTP session but it conains only a simpe events like TC started or a file deleted but not any network related activity.
In the options I set all possible checkboxes with the same result.
User avatar
sqa_wizard
Power Member
Power Member
Posts: 3725
Joined: 2003-02-06, 11:41 UTC
Location: Germany

Re: SFTP plugin > Synchronize directories: the "by content" checkbox should be grayed out

Post by *sqa_wizard »

How were you able to get that log filled with connection details?
Log file creation for sftp-plugin is done by "Configuration - Options - FTP: [x] Create a log file"
#5767 Personal license
Post Reply