fieldrndservices / libssh2lv Goto Github PK
View Code? Open in Web Editor NEWA LabVIEW friendly C library for libssh2
License: Other
A LabVIEW friendly C library for libssh2
License: Other
Investigate converting the very manual, but well documented, process of building the library using GitHub Actions for Windows, macOS, and Linux. The build process is pretty straight-forward with a CMake-based build. However, I current have to manually build on each of the platforms, bundle together, and upload to the Releases page for this project. It would be nice to just git push --tags
and have a release created from the tag branch.
The integration tests use the old namespace ("labssh2") and functions. The integration and units tests are severely lacking and a more complete test suite needs to be implemented.
Hi!
I'm having trouble using the labview library, the problem could be with my ssh server... I noticed a major update on libssh2 1.11 May 30 2023 and your DLL is from 2022.
I'm having trouble with VS 2019, I'm not much familiar with that... Is it a good idea to recompile the DLL to benefit the libssh2 updates or its worthless?
I'll see where I can get with visual studio, it's a good learning opportunity for me actually. But if you may release a new build I'd be more than happy.
Hello,
I have problem with unloading libssh2lv.dll
in LabView. When i use this example from Ni.COM
about How to Load and Unload a DLL Dynamically in LabView
it doesn't Unload properly with initialize
function. I cannot remove or replace this dll from harddrive until LabView is Closed.
The problem first occured when I used fieldrndservices/libssh2-labview
toolkit and example from its README.md
. After executing the code something was still holding this library until LabView is closed.
I don't think it should act like that - these shutdown functions should unload this library properly but it doesn't.
Is there any chance to fix it?
libssh2 v1.9.0 introduced the libssh2_agent_get_identity_path
and libssh2_agent_set_identity_path
functions. LabVIEW-friendly wrapper functions should be created for each of these functions.
However, as of 2020-03-31, there is no documentation for either of these functions and it is unclear on their functionality. The documentation links at the libssh2 for each functions result in a 404 response. It might be worth holding off on implementing these functions until after some investigation and research has been conducted.
The libssh2.org library provides the libssh2_trace()
function to aid in debugging. This function is currently not available in this library, which makes it hard to debug and troubleshoot. A LabVIEW-friendly wrapper function should be added.
The default is to write debugging statements to STDERR. This can cause a problem with LabVIEW because there is no STDERR. In other words, I am not sure if the debugging statements will appear if tracing is turned on. Will a CMD console display automatically? Will the debugging statements only appear if LabVIEW is started from the command line (CMD)?
There is the libssh2_trace_sethandler
which can be used to redirect the debugging output from STDERR to another location, like a buffer or log file. To truly implement the debugging facility a LabVIEW-friendly output will need to be implemented. Most likely a wrapper function that takes a path to a file and this library automatically creates the function pointer to pass to the libssh2
library.
Enabling debugging during the build of the library also needs to be enabled for the libssh2_trace
to be available.
Hello
I have had great success with building dependencies for libraries like this using vcpkg from Microsoft - it integrates with CMake (but needs to be version 3.20 or so) but does all the heavy lifting when it comes to building OpenSSL etc on Windows, Linux and Mac.
It really simplified the building for my project asynchronous system exec library if you wanted to get a preview
Cheers
John
A new version of LIBSSH2 was released on August 28th, 2021. This newer version should be integrated into this library. Note, there appears to be some new errors and possibly some new functions that will need some wrappers.
Different errors are possible if the libssh2_scp_recv2
function returns a NULL value. Currently, any time NULL is return, only the LIBSSH2_ERROR_ALLOC
is returned. Instead, the libssh2_session_last_error
function should be used to obtain the last error code and return the appropriate possible error. This has lead to connectivity and/or protocol errors being miss identified as memory allocation errors.
Is there a way to determine if there are bytes available at the port before doing a read or is my only option to try to read and use the timeout output?
libssh2 v1.9.0 was released on June 20, 2019. It includes support for ECDSA and ED25519 keys with OpenSSL along with a some fixes for building with OpenSSL, specifically v1.1.1. These features, among others, and fixes would be appreciated in in upstream dependent projects.
Note, libssh2 v1.9.0, also includes the addition two new functions to the Agent-related functions.
The current version of OpenSSL is v1.1.1l. A new version, v1.1.1m, was released. There is also the new main branch of OpenSSL v3.0. The libssh2 library added support for OpenSSL v3.0 as of v1.10.0. It might be time to bump to the v3 of OpenSSL.
when I use putty for SSH comms, I can read the prompt from the device I am talking to. I can easily see that my last command was completed and the device is ready for the next. Is this possible using libssh2lv tools?
The underlying libssh2 library released a new minor version, v1.11.0, in May 2023. The last release was v1.10.0 back in 2022. A new build of this library using v1.11.0 should be created.
The libssh2_keepalive_config and libssh2_keepalive_send functions should be added to the library.
Related: fieldrndservices/libssh2-labview#53
Hello,
I am currently struggling with the following issue:
I am using the toolkit to connect to linux based device. Normally, communication works okay. However, it happens from time to time that given device goes off. In this case, I am expected to wait until it restarts and connect back. Problem is, that toolkits API sometimes does not indicate that connection is lost, at least not immediately. The functions for read and write still behaves as if the connection was on. One problem is therefore that I would need some sort of indication for this. Whats more, when trying to write/read when the disconnect happens, it causes labview to crash (apparently because of DLL). Do you please have any suggestions, what might be the root cause and what can I do to avoid this?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.