I implemented the match exec. Can you try if it works for you as expected in your use case? There are several commits adjusting the tests and as well as I had to implement new token parsing function, but my basic tests looked good. This code also does not work on windows since I am not Windows developer, but if interested, I believe there will be somebody who could implement that.
Needs Triage (10)
- T176 I have upgraded libssh from 0.7.6 to 0.9.0 to use diffie-hellman-group-exchange-sha256 kex algo both in client and server, but I found that memory leak , see details
- Restricted Project
- Mon, Sep 16, 10:33 AM
The original issue should be resolved in master now.
Aris, can you open a new bug for this, ideally with more debug information as proposed by @ansasaki?
Sun, Sep 15
I like the proposed wording, @Jakuje.
If the semantics get changed later, the documentation will change with it. But I'd prefer not waiting for the refactoring and just update the description now, as the first step.
I like the proposed wording, @Jakuje.
Fri, Sep 13
That code is awfully old (probably 2004-2005). The idea was probably separating the SSH part and the SFTP parts. Today it makes little sense. Also both calls are synchronous and blocking. Your proposed patch describes well what it does today. Given the time I'd improve the actual implementation and move everything that handles network into sftp_init() and leave sftp_new() to memory allocation only like it's standard in the rest of the library.
Can you check the following patch if t addresses the issue for you?
I am getting exactly the same result as the OP when I remove the /usr/bin/nc, which is used in the respective failing test so I assume that this is the issue, but the error should be more properly reported and the test probably skipped in case the netcat is not in place. I will submit a patch.
Thank you for having a look into that. In that case, I am wondering why it did work for me and for the CI we run, but I think most of that is on Fedora, which might be a difference. Can you check whether the netcat (nc) is installed in your system?
Closed it by mistake
cc @Jakuje, git blame says you touched that code last :)
I found this problem too when trying to set up the test environment on Ubuntu 18.04. The root cause is that the test calls the ssh binary from the fake root user. It fails because ssh can't find uid 0 in /etc/passwd, then fails because of missing known hosts keys and authentication keys. I don't know how that test could work elsewhere.
I made a patch that assumes it's running as root and create the missing keys. A better way would be to force the test cases to run as bob but I haven't found the proper way of doing this.
I just tested the ssh-client from examples, which is using channel_open with sshd configured with MaxSessions 0 and it is correctly failing and not hanging for me. Can you test with current libssh master or 0.9 and provide more ellaborate reproducer?
The file doc/sftp.dox contains the following information (not sure whether it is rendered somewhere on the web):
This should be addressed by using the new API even inside of the deprecated functions without the change of functionality. Can you try the following patch?
I wanted to compile the lib with the bcc32 compiler ( Win32 / Borland / Embarcadero ).
The modification of the libssh.h is breaking other applications (for example the applications in example directory) using this header file not defining HAVE_INTTYPES_H and HAVE_UNISTD_H themselves. Can you clarify what problem are you solving by this and on what system you do not have these header files?
Did you try the latest libssh 0.9 . Not sure what went wrong with the old version, but the windows builds are part of CI and they should work in recent version
Mon, Sep 9
Thu, Aug 22
This was fixed in master by 5b18bcb0ac39c3c366dd769e893af381ddb5deb2
Wed, Aug 21
Tue, Aug 20
I think the multi-criteria matches are generally supported, but I agree that they are not tested and that should be fixed.
Aug 12 2019
Aug 9 2019
How the issue was ended? Is there working fix for unplug calble during file transfer?
I will be grateful for any advice :)