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
User avatar
Horst.Epp
Power Member
Power Member
Posts: 6450
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Re: New SFTP plugin available now

Post by *Horst.Epp »

hck wrote: 2022-11-26, 12:33 UTC TC SFTP has some kind of conflict with the latest Openwrt SSH server Dropbear v2022.xx.
It works fine with remote devices (several ms latency).
But it hangs in some situations with local devices (less 1ms latency).
Did you check the same connection and file transfers with another client, FileZilla for example ?
Windows 11 Home x64 Version 23H2 (OS Build 22631.3374)
TC 11.03 x64 / x86
Everything 1.5.0.1371a (x64), Everything Toolbar 1.3.2, Listary Pro 6.3.0.69
QAP 11.6.3.2 x64
hck
Junior Member
Junior Member
Posts: 2
Joined: 2022-11-26, 11:29 UTC

Re: New SFTP plugin available now

Post by *hck »

Horst.Epp wrote: 2022-11-26, 12:46 UTC Did you check the same connection and file transfers with another client, FileZilla for example ?
FileZilla doesn't support SCP protocol
pscp works fine
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: New SFTP plugin available now

Post by *ghisler(Author) »

Edit:
I have tried your image, and was only able to reproduce it by uploading about 10-20 files >32kByte each. One it was hanging, I attached the dll to a debugger. The function
libssh2_scp_send64()
was constantly returning LIBSSH2_ERROR_EAGAIN, which means that the LibSSH2 dll was waiting for something. So I attached that dll to the debugger too, and indeed it was waiting for a reply from the server after sending the SCP start command. I cannot find any bug in the LibSSH2 library, the server just isn't responding. :(
Author of Total Commander
https://www.ghisler.com
User avatar
Hacker
Moderator
Moderator
Posts: 13052
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Re: New SFTP plugin available now

Post by *Hacker »

Using v3.04, I can't get authentication using both password and password-protected keyfile to work.
User password: abc
Private key password: def

Based on the instructions in the connection config dialog, I set the password field as:

Code: Select all

"def","abc"
When I try to log in, I get this error from the SFTP plugin:

Code: Select all

Error: Authentication by password failed!
This is the log of the SFTP server:

Code: Select all

[Information] Session 18: Started on connection from 192.168.1.2:11655.
[Information] Session 18: Authentication for 'hacker' succeeded partially.
[Error] Error occurred in custom event handler: System.InvalidOperationException: The user has already supplied both the password and public key during this authentication session.
   at srzqn.qojzb.jdmui()
   at srzqn.qojzb.lqsnv(Object p0)
   at srzqn.tggfr.oieuc(Object p0, qojzb p1)
   at System.EventHandler`1.Invoke(Object sender, TEventArgs e)
   at srzqn.ysfat.iwlpf(cornw p0, String p1, String p2, pmeek p3, Boolean& p4)
[Information] Session 18: Closed connection from 192.168.1.2:11655.
[Information] Session 18: Connection close requested.
WinSCP connects absolutely fine, this is the log from the SFTP server when using WinSCP:

Code: Select all

[Information] Session 19: Started on connection from 192.168.1.2:11784.
[Information] Session 19: Authentication for 'hacker' succeeded partially.
[Information] Session 19: Authentication for 'hacker' succeeded.
[Information] Session 19: Attempting GetItemInfo FSO Read "/"
[Information] Session 19: Attempting OpenDirectory FSO List "/"
What am I doing wrong, please?

TIA
Roman
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.
mduran
Junior Member
Junior Member
Posts: 26
Joined: 2007-02-13, 08:55 UTC

Re: New SFTP plugin available now

Post by *mduran »

Hello,

I don't think having read anything new about the possibility to elevate the session with this plugin (I remember a reply from Christian about libssh2_sftp_init not allowing to do this), but I might have missed something in this long thread, hence my question: is there any recent development in ssh/sftp login via TC which would allow me to 'sudo su root/<any_other_user>'? I need this badly, so any tips are welcome.

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

Re: New SFTP plugin available now

Post by *ghisler(Author) »

2Hacker
1. Does it work when you don't save the passwords?
2. How do I need to configure SSHD to require both password and key authentication?

2mduran
SFTP runs as a session over SSH. I don't see how you can run that as root, sorry. Sending su over an interactive session will not elevate the separate SFTP session.
Author of Total Commander
https://www.ghisler.com
User avatar
Hacker
Moderator
Moderator
Posts: 13052
Joined: 2003-02-06, 14:56 UTC
Location: Bratislava, Slovakia

Re: New SFTP plugin available now

Post by *Hacker »

Christian,
Does it work when you don't save the passwords?
I am not 100% sure I tried, but I would guess I did and it didn't work. I had to reinstall the machine with the SFTP server and haven't yet reinstalled it. Will let you know as soon as I reinstall the SFTP server.
How do I need to configure SSHD to require both password and key authentication?
I am sorry, I have no idea, SSHD is for people who know what they are doing, which I am not. I am using the Rebex Buru SFTP Server with a non-commercial licence. There is a 30 day commercial trial available if you'd like to use it for testing. Just create the key pair, and then in the web management interface click Users - Add new user - and select Required for both Password authentication and Public key authentication.

TIA
Roman
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
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: New SFTP plugin available now

Post by *ghisler(Author) »

I have checked the sources and it should definitely work when storing the passwords as "def","abc".
Author of Total Commander
https://www.ghisler.com
YossiD
Junior Member
Junior Member
Posts: 9
Joined: 2011-04-05, 05:40 UTC

SFTP via TC & RDP

Post by *YossiD »

Not sure I understand this reply.

I use an SFTP connection on my desktop at work to access secure files being provided to me by a customer.

When I'm working from home, I connect to, and work on, my office computer using an RDP connection. Everything works fine except the SFTP connection via TC. I can connect to the SFTP server with my RDP connection using a browser, but not via TC. If your reply below is a workaround, can you walk me through it?

Thanks
Sob wrote: 2010-06-28, 22:50 UTC TC itself can't help you with Remote Desktop connections.

But you can save Remote Desktop Connection settings for 'staff' server to .rdp file and put a link to it to TC's toolbar. And similarly you can create .bat file with ssh2 command line and add it as another toolbar button. Then you'll need just two clicks to connect.
User avatar
Dalai
Power Member
Power Member
Posts: 9364
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: New SFTP plugin available now

Post by *Dalai »

2YossiD
Are you confusing SFTP with FTPS? The former is a protocol based on SSH, and I very much doubt that any browser supports it (except via some kind of extension). The latter is the secure variant of the unencrypted FTP, and it is supported by most browsers. But maybe it's not supported anymore since most browsers removed FTP support, not sure.

Anyway, if you mean FTPS, then TC's FTP feature (Ctrl+F) is the one you need. It also supports FTPS once the necessary DLLs are installed; TC will notify you if they're missing when enabling SSL/TLS for a connection.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
pyl0s
New Member
New Member
Posts: 1
Joined: 2023-04-19, 17:45 UTC

Re: New SFTP plugin available now

Post by *pyl0s »

Hello,

I would like to estabilish sftp connection directly from command line parameters including connection data like user, password, port and host name in new tab.

For example:

"%COMMANDER_EXE%" /O /T /L=(path to sftpplugin witch parameters)

Is it possible? How to do that?
JOUBE
Power Member
Power Member
Posts: 1448
Joined: 2004-07-08, 08:58 UTC

Suggestion: add parameter -p for server server copying

Post by *JOUBE »

I do not know how exactly server server copying works within the sftp-Plugin...
Anyway: if it works with routines similar to cp, scp... is it then possible to add parameter -p (or similar) to that server server copying? This will make server server copying more usefull when also copying the attribs (mode,ownership,timestamps). As it works at the moment it is of little use.

If this post belongs to the forum suggestions please move it there.

JO" As far as I know the cp option -p is part of POSIX standard, so all systems support it: wiki.archlinux.org/title/core_utilities "UBE
Last edited by JOUBE on 2023-04-25, 06:20 UTC, edited 9 times in total.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48021
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: New SFTP plugin available now

Post by *ghisler(Author) »

I would like to estabilish sftp connection directly from command line parameters including connection data
This isn't supported, it can only handle servers previously configured in the plugin. Maybe via changing the wcx_sftp.ini?
Author of Total Commander
https://www.ghisler.com
JOUBE
Power Member
Power Member
Posts: 1448
Joined: 2004-07-08, 08:58 UTC

Re: New SFTP plugin available now

Post by *JOUBE »

Maybe this is more of a suggestion for TC, not the sftp plugin itself, but because it's bundled with the sftp plugin I'm adding it here:

Nearly perfect is the sftp plugin's ability to run commands on the server from the TC's command line box and display the results in the status window at top (more of it can then be seen with a mouse double click in the lister). Very good and often (more and more...) used here.

But: In order to run a script at the current directory at the sever within the active TC window (e.g. with ./ at the beginning), it is necessary to type the command directly into the command line (or bring it into the command line from the command history list) and press the Enter key. Is it possible for the TC itself to detect the open sftp plugin in the active window and add (automatically) ./ to run the script by pressing Enter? That would be great.

If this post belongs to the forum suggestions please move it there.

JOUBE
Last edited by JOUBE on 2023-04-25, 05:56 UTC, edited 4 times in total.
JOUBE
Power Member
Power Member
Posts: 1448
Joined: 2004-07-08, 08:58 UTC

Re: New SFTP plugin available now

Post by *JOUBE »

It would be very useful for the sftp-plugin if you could always fetch commands in the command line box with the same handles and if there was therefore an option that the complete command line history list would always be opened: see this suggestion by fla$her:

https://www.ghisler.ch/board/viewtopic.php?p=429204#p429204

For fast work with the sftp plugin.

If this post belongs to the forum suggestions please move it there.

JOUBE
Post Reply