sFTP Plugin and TC 7.56a

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

Moderators: white, Hacker, petermad, Stefan2

chbwien
Junior Member
Junior Member
Posts: 3
Joined: 2011-02-08, 15:32 UTC

sFTP Plugin and TC 7.56a

Post by *chbwien »

Using the current sFTP Plugin 1.0 moving (F6) files, a copy operation is done, not a move operation. This worked with the previous putty-based plugin.
User avatar
Hacker
Moderator
Moderator
Posts: 13052
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Post by *Hacker »

[mod]Moved to the Plugins forum.

Hacker (Moderator)[/mod]
Mal angenommen, du drückst Strg+F, wählst die FTP-Verbindung (mit gespeichertem Passwort), klickst aber nicht auf Verbinden, sondern fällst tot um.
User avatar
karlchen
Power Member
Power Member
Posts: 4601
Joined: 2003-02-06, 22:23 UTC
Location: Germany

Post by *karlchen »

Hello, chbwien.

Telling from the term "putty-based plugin", I assume that you may accidentally mix up the two unrelated sFTP plugins for Total Commander: The latter uses libCurl DLLs, whereas the former is based on putty.
To the best of my knowledge the following is true for renaming / moving with the help of Christian's sFTP Plugin: press <shift><F6> and type in the new name (renaming) or the new path and new name (moving).

Kind regards,
Karl
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Moving between PC and SFTP server isn't currently supported by my SFTP plugin because I think that the risk of data loss is too high. You should verify that everything was copied all right before deleting the source files.
Author of Total Commander
https://www.ghisler.com
vilik1
Junior Member
Junior Member
Posts: 3
Joined: 2011-02-15, 08:21 UTC

Post by *vilik1 »

Hello,
I tried to use this SFTP plugin v1.0 and it works fine for some servers.

But I am not able to connect to server, which have double autentization.
(Double autentization is required)

Firstly, I must connect via SSH key, secondly the password is necessary to enter.

Can you help me, to set up the connection for this double autentization, if this is possible ?

UPDATE:
I am not able to connect to server by using SSH KEY, so my problem is quit bigger then it firstly appear :-(
Neither Key, nor PAGEANT.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

I have never seen a site with double authentication, that's why it's currently not implemented. Do you know how to configure SSH on Linux to force double authentication? I have enabled SSH key authentication on Ghisler.com, but when I use the key I don't need the password and vice versa...
I am not able to connect to server by using SSH KEY, so my problem is quit bigger then it firstly appear Sad
Neither Key, nor PAGEANT.
Are you able to login with Putty via Pageant?
Author of Total Commander
https://www.ghisler.com
vilik1
Junior Member
Junior Member
Posts: 3
Joined: 2011-02-15, 08:21 UTC

Post by *vilik1 »

thanks for your answer,

Add Pageant => Mea Culpa = I entered wrong username :-(

Pageant and SSH key works perfect !

Add double autentization, I don't know, if linux can do it, on that server is AIX and it is made by configuration parameter in SSH2_config file

RequiredAuthentications= publickey,password

I tried to search the internet and OpenSSH probably don't support this feature :-(
Sob
Power Member
Power Member
Posts: 941
Joined: 2005-01-19, 17:33 UTC

Post by *Sob »

OpenSSH needs patch from:
https://bugzilla.mindrot.org/show_bug.cgi?id=983

But libssh2, which sftpplug is based on, doesn't support it yet. But it's planned feature and seems to be close to release. I missed that at first, so I played with it myself and result can be found at:

http://web.hisoftware.cz/sob/download/sftpplug100-doubleauth-test.zip

It contains both patches and binaries for libssh2 and sftpplug and it works for me. But I don't recommend it for anything except testing.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Nice, thanks! For the moment, going via Pageant is sufficient. Hopefully it will be added to openssh soon.
Author of Total Commander
https://www.ghisler.com
Sob
Power Member
Power Member
Posts: 941
Joined: 2005-01-19, 17:33 UTC

Post by *Sob »

ghisler(Author) wrote:For the moment, going via Pageant is sufficient.
Not for vilik1 if his server requires double authentication now and he can't change it. But before libssh2 officially supports it, sftpplug can't do anything (except for unofficial modification like mine above).
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Unfortunately I cannot test it myself because I cannot enable double authentication on my server. Does your modification work also with Pageant for the client certificate? May I include your modification in my code?
Author of Total Commander
https://www.ghisler.com
Sob
Power Member
Power Member
Posts: 941
Joined: 2005-01-19, 17:33 UTC

Post by *Sob »

ghisler(Author) wrote:Unfortunately I cannot test it myself because I cannot enable double authentication on my server.
If you use OpenSSH, you would have to recompile it with above mentioned patch. But IMHO it's waste of your time at this point, because neither libssh2 supports chained authentication yet. According to their bug tracker they have the fix ready and with some luck it may be included in next release. Adding support to sftpplug before that won't help anyone. Moreover, official libssh2 version will be at least slightly different from mine, because I didn't bother checking if something is already available and instead made quick-test modification myself. Why not, didn't take long and was fun. :)
Does your modification work also with Pageant for the client certificate?
It's primarily tested with Pageant. When the key authentication succeeds, it loops to beginning and continues with password authentication (because publickey gets automatically removed from supported authentication methods at this point). But whole thing will need more testing, to see how it works with differently ordered method, etc..
May I include your modification in my code?
As usual (= anything you want).
vilik1
Junior Member
Junior Member
Posts: 3
Joined: 2011-02-15, 08:21 UTC

Post by *vilik1 »

many thanks for all, I will test the patches of Sob and I will wait for official version after next release of libssh2

Update: After replacing libssh2.dll with the new one, TotalCmd don't see it and write error "Put the libraries into the same directory as plugin..."
Sob
Power Member
Power Member
Posts: 941
Joined: 2005-01-19, 17:33 UTC

Post by *Sob »

I used VC++ 2008, so the dll depends on msvcr90.dll. It's possible you don't have it. Check Windows Event log under System and if there are some errors about Microsoft.VC90.CRT (assembly not installed or something like that), then you need:

http://www.microsoft.com/downloads/en/details.aspx?FamilyID=A5C84275-3B97-4AB7-A40D-3802B2AF5FC2

Installing it should solve the loading problem.
omniignorant
Junior Member
Junior Member
Posts: 4
Joined: 2009-08-27, 09:54 UTC

Post by *omniignorant »

ghisler(Author) wrote:Moving between PC and SFTP server isn't currently supported by my SFTP plugin because I think that the risk of data loss is too high. You should verify that everything was copied all right before deleting the source files.
I know this thread is old but I couldn't find an answer to my question (which follows) elsewhere in the forum. I apologize in advance if it has already been answered (in which case please provide a link!).

How is moving between PC and SFTP server risky? In theory there shouldn't be any reasonable risk (data integrity should be guaranteed by the crypto protocol). Do you have any reasons to believe that the implementation has serious bugs? I'm not asking whether the implementation contains bugs or not -all programs contain bugs unless proven otherwise, which, is not very easy to do..-, I'm just asking if you think the implementation is flawed or unstable.

If this is the case, I think there should be a warning or some kind of version labeling indicating that the plugin is in beta/alpha/testing mode.

Best,
omniignorant
Post Reply