Native SSH and SFTP in LabVIEW

At the risk of re-opening a can of worms, is there any consideration for adding native SSH and SFTP support for LabVIEW?
Using PuTTy/plink is cumbersome and not cross-platform.
Calling a .NET (or any other) external assembly is cumbersome and not cross-platform.
Labwerx SSH has a terrible licensing model (not to mention the additional cost).
It is 2015, and SSH/SFTP is ubiquitous and not going away. These protocols should be natively supported in LabVIEW.
I have seen this idea on the exchange (http://forums.ni.com/t5/LabVIEW-Idea-Exchange/Native-SSH-and-SFTP-Support/idi-p/1141529), but there hasn't been any movement in 5 years. I would appreciate any news from NI here, even in the negative. If LabVIEW isn't going to support SSH anytime soon, it would be better to find out now.
Solved!
Go to Solution.

I doubt it is likely to happen any time soon - the LabSSH toolkit is pretty reasonably priced when you compare it to how long it would take you to implement the functionality yourself and there is nothing to stop you from implementing it yourself using the TCP/IP functions which are in LabVIEW. You can of course use the command-line interface to something like WinSCP / PuTTy as well.
I did also find a wrapper that someone had made for an Open Source .NET SSH library called Renci
I downloaded a copy from this thread: http://forums.ni.com/t5/LabVIEW/Plink-PuTTY-works-30-of-the-time-using-System-Exec-vi/td-p/3002261
There is also another implementation of the wrapper here: https://decibel.ni.com/content/docs/DOC-41388
Certified LabVIEW Architect, Certified TestStand Developer
NI Days (and A&DF): 2010, 2011, 2013, 2014
NI Week: 2012, 2014
Knowledgeable in all things Giant Tetris and WebSockets

Similar Messages

  • Mounting samba share starts avahi, ssh and sftp at client

    The problem is at the client. When i mount a samba share (with # mount), avahi is started, which starts ssh and sftp. This is wrong on many levels.
    Not sure how long this has been going on, someone else already asked this on stackexchange on 11.2.15, but didn't get any answers.
    Journal output immediatly after mounting (hostname, ip etc. removed):
    Mär 18 01:35:51 hostname dbus[434]: [system] Activating via systemd: service name='org.freedesktop.Avahi' unit='dbus-org.freedesktop.Avahi.service'
    Mär 18 01:35:51 hostname systemd[1]: Cannot add dependency job for unit boot.automount, ignoring: Unit boot.automount is masked.
    Mär 18 01:35:51 hostname systemd[1]: Listening on Avahi mDNS/DNS-SD Stack Activation Socket.
    Mär 18 01:35:51 hostname systemd[1]: Starting Avahi mDNS/DNS-SD Stack Activation Socket.
    Mär 18 01:35:51 hostname systemd[1]: Starting Avahi mDNS/DNS-SD Stack...
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Found user 'avahi' (UID 84) and group 'avahi' (GID 84).
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Successfully dropped root privileges.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: avahi-daemon 0.6.31 starting up.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
    Mär 18 01:35:51 hostname dbus[434]: [system] Successfully activated service 'org.freedesktop.Avahi'
    Mär 18 01:35:51 hostname systemd[1]: Started Avahi mDNS/DNS-SD Stack.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Successfully called chroot().
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Successfully dropped remaining capabilities.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Loading service file /services/sftp-ssh.service.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Loading service file /services/ssh.service.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Joining mDNS multicast group on interface enp1234.IPv4 with address myip.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: New relevant interface enp1234.IPv4 for mDNS.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Network interface enumeration completed.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Registering new address record for myip on enp1234.IPv4.
    Mär 18 01:35:51 hostname avahi-daemon[2583]: Registering HINFO record with values 'X86_64'/'LINUX'.
    Mär 18 01:35:52 hostname avahi-daemon[2583]: Server startup complete. Host name is hostname.local. Local service cookie is 123.
    Mär 18 01:35:53 hostname avahi-daemon[2583]: Service "hostname" (/services/ssh.service) successfully established.
    Mär 18 01:35:53 hostname avahi-daemon[2583]: Service "hostname" (/services/sftp-ssh.service) successfully established.

    Thanks for your answer.
    snakeroot wrote:Are you sure it is actually starting ssh and ssftp or is it just having avahi advertise them as existing?
    I'm not sure if anything is started, the term "Service ssh successfully established" sounds like the ssh serrver is started to me, but it might just be strange wording. What does "advertise as existing" mean?
    From the snippet you quoted, it looks like the latter. Unless you have alread started socket activation for ssh or sftp, whether via systemd *.socket or inetd, I'm not sure it would actually be started.
    I didn't enable anything manually.
    I think you can rm/mv the sftp-ssh.service and ssh.service files /etc/avahi/services/ and prevent those services from being advertised.
    OK thanks for the hint. Nontheless i would rather stop avahi from starting than configuring it.
    Begin rant...
    I'm a bit annoyed that avahi is starting without my permission. Seems like systemd is getting a bit overzealous with starting services. Interestingly this was one of the big problems with upstart, and was supposed to be solved with systemd. I still like systemd.

  • JDev 11.1.1.4.0 Support for SSH and SFTP

    Using JDeveloper 11.1.1.4.0
    I've tried researching Oracle docs, but find nothing on Secure FTP (SFTP). Does Oracle ADF have built-in SSH and SFTP Java libraries? If not, has anyone had success with the Java libraries from SourceForge or is there something better out there?
    Thanks,
    Troy

    There is no build in ftp or ssh library in jdev. I used http://commons.apache.org/net/ in one of my project.
    Timo

  • [Solved for me]Distinguishing SSH and SFTP (for QoS purposes)

    Hi there,
    I'm thinking about shutting down the FTP on my homeserver and use SFTP instead. There is only one thing I couldn't solve so far: In my router I have QoS-rules that make FTP low priority traffic so my normal activities don't get affected by the file transfers. I would like to have the same setup for the SFTP. Now the problem is this: SFTP and SSH are both coming from the same ssh server, listening on port 22. So there is no way of distinguishing them on a ip/port basis. Is there any way of distinguishing SFTP and SSH? Like using iptables to tag one of them and then doing QoS based on the tag or something along those lines? I don't want to slow down my ssh-connections together with the sftp. If anyone has an idea how to accomplish this I would be really glad to hear about it.
    Thanks in advance
    seiichiro0185
    Last edited by seiichiro0185 (2010-08-22 11:27:32)

    briest wrote:Well, a simple, though definitely not bulletproof solution: define multiple ports in sshd_config, then use one of them for sftp, and another for ssh?
    Thanks for this hint, I didn't know that ssh could listen on multiple ports. Its not totally bulletproof, but good enough for my case. The only people who will have access to the server are trustworthy and won't fiddle with the settings to circumvent my restrictions.
    Thanks to all of you for your suggestions.

  • SCP, SSH and SFTP in CMD / File-Explorer and SSH key management with Windows Credential Manger

    Please add SSH, SFTP and SCP in CMD and File Explorer.
    Also, allow us to copy to FTP in File Explorer.
    Would be nice to have the SSH credentials managed by Windows Credentials Manager.

    Even with the RHEL firewall completely disabled, it has the same upper limit. SCP between the Solaris systems, with ipfilter running on both systems and both systems on completely different networks, is not a problem. Between Solaris and RHEL, same network but different subnet, RHEL with no firewall running (only while troubleshooting this, don't panic), still a problem. Using PuTTY SFTP from/to any of the systems is fine, even though on different networks. The mtu on the RHEL was the same as the Solaris systems (1500) - changing values on the RHEL increased the upper limit but still hit a ceiling. Only have one RHEL system so I can't see whether RHEL-RHEL transfers are affected, only those between Solaris, PuTTY on Windows, and the one RHEL system.

  • Java Caps 5.1.3. and SFTP (FTP over SSH)

    Hi,
    I'm trying to use the BatchSFTP option from the batch eway to setup FTP over SSH. I'm having trouble in setting up the keyfile. I've generated a trusted_hosts file using openSSH via CYGWIN (I'm running on W2003 server). The error I get is: Batch SFTP eWay connection failed, method=[connect()], message=[Exception when connect(), e=java.io.IOException: Invalid SSH1 public key format].
    Has anyone experience with FTP over SSH and can help me out on this.
    Thank you very much,
    Cor Zijlstra
    [email protected]

    You need to convert the server public key for the server that you are connecting with to the IETF SECSH format. If you have access to do that, you can run the command ssh-keygen -f myServerPublickey.pub -e > myIETFServerPublicKey.pub. Otherwise, your UNIX server admin will need to run that. Put the ITEF key in your .ssh directory and have CAPS reference that IETF format and you should be set. Make sure the connectivity map/env explorer is set to public key authentication.
    I think there is a bug in CAPS with how it is handling the SSH formated key. I have been unable to prove it to support. Furthermore, more pressing issues have taken up my time (aka, other projects).
    John

  • Proxy auto-config (PAC) impacts ssh, scp, sftp

    Dear all,
    I have this problem I am trying to find leads on how to understand and eventually solve it.
    I am doing a lot of development under Unix. I'm spending most of my time at work on X11 (XQuartz) logged in on remote Unix servers using all "S" versions of standard protocols.  I'm under Snow Leopard because Lion is no good to my workflow (sorry to say this).
    Since my employer has contracted an external company to filter all outgoing HTTPS traffic - and has updated the legacy proxy PAC file accordingly - I encounter huge latency problems with my ssh, scp and sftp traffic with my remote Unix servers : all "S" protocols are routed through the external company HTTPS filter.
    I have created one Network Location (network sys prefs) that uses "Automatic Proxy Configuration" to point to the PAC file server (a).
    I have create another Network Location that activates a distinct proxy setting for HTTP and the same for HTTPS protocols. I've set up as Web Proxy server the one defined as PROXY  in the PAC file (b).
    Using (a) Network preference, all my ssh and scp traffic initiated under X11 is slow as a drag (10kb/s on a 100baseT full duplex to the server in the same building) because it gets piped through the external https traffic filter.
    Using (b) Network preference, no problem at all with ssh and scp, and Safari can browse both http and https sites as per company rules.
    My question is how can this setting of Network preference - combined with a PAC file - can influence a traffic that is secured through ssl but is not HTTP nor HTTPS ! 
    I am looking for some documentation that would help me understand how Proxy auto-config is implemented in the network layer and if there are any recommendations I can do to my network team to fix their PAC file, perhaps, to restrict the proxy configuration to only http and https.
    Any lead will help.
    Thanks,
    Thierry
    The PAC file (stripped of restricted info). Note: The remote servers I'm working on are in the 10/24 IP range and a segment of a Class B my company owns.
    function FindProxyForURL(url, host)
              var proxy = "PROXY XXX.YYY.ZZZ.1:80; PROXY XXX.YYY.ZZZ.2:80" ;
    if (
              shExpMatch(host, "10.*.*.*")  ||
              shExpMatch(host, "192.168.*.*")
              return "DIRECT";
    else
              return proxy;

    Ooops. Sorry, I meant "10/8", not "10/24" IP range.

  • ASA 5505 + ASA 5540 static VPN, ssh and rdp problems

    Greetings!
    I've recentely set up a VPN between Cisco ASA 5540(8.4) ana 5505(8.3).
    Everything works fine, but there is a small problem that is really annoying me.
    From the inside network behind ASA 5505 I connect via rdp or ssh to a host inside ASA 5540.
    Then I minimize ssh and rdp windows and don't use it for ten minutes. But I still use VPN for downloading some files.
    Then I open ssh window - the session is inactive, open rdp window - I see a black screen (for 10-15 seconds, and then it shows RDP)
    There are no timeouts on ssh or rdp hosts configured, via GRE tunnel it works perfectly without any hangs.
    What can I do to get rid of this problem?
    Thanks in advance.

    Dear Fedor,
    You could try adding the following commands to your configuration (on both ASAs) in order to increase the timeout values of the specific TCP sessions:
    access-l rdp_ssh permit tcp 1.1.1.0 255.255.255.0 2.2.2.0 255.255.255.0 eq 22
    access-l rdp_ssh permit tcp 1.1.1.0 255.255.255.0 2.2.2.0 255.255.255.0 eq 3389
    class-map TCP_TIMEOUT
          match access-list rdp_ssh
    policy-map global_policy
         class TCP_TIMEOUT
              set connection timeout idle 0:30:00
              set connection timeout half 0:30:00
    * Please make sure you define the specific RDP and SSH ports in the ACL and avoid the use of "permit ip any any".
    Let me know.
    Portu.
    Please rate any post you find useful.

  • Problem with ssh and bash-completion

    I and a co-worker are having a weird problem with ssh and bash-completion. We have a local config in .ssh/config with hosts we connect everyday. An example:
    host foo
    hostname foo.org
    user foobar
    host foobar
    hostname foobar.org
    user foobar
    When we try to type
    ssh foo<tab><tab>b<tab>
    the console just freeze and we can't type anything, everything we type is ignored, but after about 30 seconds the host is completed.
    This works a some time ago, so some upgrade make this happen. Anyone can reproduce this?

    quigybo wrote:
    Actually thinking about it, rather than using the semi-dodgy fix posted on the bug tracker, we can just test if the daemon is running since we are not on MacOS X. It is cleaner and 250 ms quicker.
    --- bash_completion.orig 2010-09-14 05:33:22.000000000 +0930
    +++ bash_completion 2010-09-14 05:45:04.000000000 +0930
    @@ -1316,10 +1316,12 @@
    # contains ";", it may mistify the result. But on Gentoo (at least),
    # -k isn't available (even if mentioned in the manpage), so...
    if type avahi-browse >&/dev/null; then
    - COMPREPLY=( "${COMPREPLY[@]}" $( \
    - compgen -P "$prefix$user" -S "$suffix" -W \
    - "$( avahi-browse -cpr _workstation._tcp 2>/dev/null | \
    - awk -F';' '/^=/ { print $7 }' | sort -u )" -- "$cur" ) )
    + if [ -n "$(pidof avahi-daemon)" ]; then
    + COMPREPLY=( "${COMPREPLY[@]}" $( \
    + compgen -P "$prefix$user" -S "$suffix" -W \
    + "$( avahi-browse -cpr _workstation._tcp 2>/dev/null | \
    + awk -F';' '/^=/ { print $7 }' | sort -u )" -- "$cur" ) )
    + fi
    fi
    # Add results of normal hostname completion, unless
    This is the same test as was used in bash-completion 1.1.
    Thanks  quigybo, I use your patch, the issue is gone
    Why does so many packages depends on Avahi? Maybe make it optdepends is
    enough?
    my laptop $ pacman -Qi avahi
    Required By : gnome-disk-utility gnome-vfs libcups mpd sane

  • After writing an html report on a floppy disk and removing it, labview shows an error message window: disk not present

    after writing an html report on a floppy disk and removing it, labview shows an error message window: disk not present.
    My pc is based on asus motherboard. Labview 7 and Windows 2000 sp4 installed.
    The error message continue also if i stop the application that generated report on a: .
    I've got this problem only on a pc: on other machines i don't have this problem (Labview only continues to access floppy but it doesn't show any window).
    Find below an example: first press the button to create a report on a: then remove the floppy, after 30-35 sec i've got the error message
    Attachments:
    prova.vi ‏55 KB

    Hi,
    I tried your vi: I don't get any error message after removing the disk but LV7 keeps on accessing the drive at regular intervals even if you stop the vi and close it!!! This is not supposed to happen.
    The only way to stop it is exit LV7.
    If you don't use the file dialog and you wire a full path, you don't get any problem.
    I also created a very simple vi that conditionally writes a text file on a: and I got the same behaviour.
    This problem occurs only with LV7, I tried the same examples in LV6.1 and everything was fine.
    If anybody wants to try I attach this simple example,
    Alberto
    Attachments:
    salva_testo1.vi ‏22 KB

  • Lion server on Mac mini server stop responding to ssh and VNC (other services like mail, ical works well)

    Lion server on Mac mini server stop responding to ssh and VNC (other services like mail, ical works well)
    Version is Lion server 10.7.4
    When I attach a monitor to it, I saw all the buttons and menus stopped responding too. I can only push and hold the power button on the box to shutdown.
    It only started happening recently.
    Anyone has any clue?
    Thanks for the help in advance!!!

    Found that the second hard drive is broken. I have to go to the apple store to have it replaced.
    I had to press the power button to turn the server off for several times, then the broken hard drive went disappeared. After that, I had to disable the Spotlight. Then the server went back to work normally.
    Now I made a CCC copy of the primary hard drive, and would like to have the server run on the external raid disk (connected through thunderbolt). Does anyone have previous experience with it? Any expectable drawback or issue with this setup?

  • Can I run 64 bit LabVIEW and 32 bit LabVIEW on the same machine?

    If I have a 64 bit OS (Windows 7 64 bit or Server 2008 64 bit) can I install and run 32 and 64 bit LabVIEW on the same machine?
    John

    LabVIEW 64-Bit vs. 32-Bit Applications FAQ
    Q. Can I have both LabVIEW 32-bit and LabVIEW 64-bit installed on the same 64-bit machine?
    A. Yes.
    The FAQ will likely answer other questions you have regarding the restrictions and issues you will have with having both versions and compiling in one vs the other.

  • Storing carriage return and other special characters in a TestStand variable and passing to LabVIEW

    I am using TestStand step to call a LabVIEW VI that writes commands to a serial device.  The device expects a carriage return at the end of the command.  I can create a constant string in TestStand with the carriage return, e.g., "ATA\x0D" and pass that to a LabVIEW string control which shows ATA\r and the VI works properly.
    To provide consistency and flexibility in my code, I want to store the terminator character(s) in a TestStand variable.  However, when I try to use an expression to create the command string, i.e. "ATA" + "Locals.Terminator", where Locals.Terminator is set to "\x0D", my LabVIEW VI string control shows "ATA\\x0D" which doesn't work.  And when I try Locals.Terminator set to "\r", the LabVIEW string control shows "ATA\\r" which doesn't work either.
    Is there a way to store special characters in a TestStand variable and pass them to LabVIEW as special characters?  I saw in another post that if you edit the TestStand variable by pressing Cntl-Enter, it will store  the newline \n properly and it can be sent to LabVIEW - that works for me as well for \n.  But  I need to send a carriage return.
    I've attached my test sequence and the corresponding LabVIEW VI with a string control.
    Hans
    Attachments:
    Special Chars.seq ‏27 KB
    String Passing.vi ‏13 KB

    Hi Hans, 
    Thanks for your detailed explanation and examples.  In TestStand, change the String parameter's String Type to Binary String instead of ASCII.  Then it will pass the desired value.
    Cheers,
    David Goldberg
    National Instruments
    Software R&D

  • Please explian what is native compilation and how to use it

    hi all.
    please explian what is native compilation and how to use it
    regards

    It's explained well in the PL/SQL User's Guide and Reference
    Compiling PL/SQL Code for Native Execution
    http://download-uk.oracle.com/docs/cd/B10501_01/appdev.920/a96624/12_tune.htm#48419

  • Native extensions and captive runtime

    I'm trying to use native extensions and captive runtime. When I try to create a release, the IDE shows this message "Native extensions are being used in the project but are not supported by the CAPTIVE_RUNTIME_BUNDLE package type. Runtime issues can occur." and I can't continue.
    I've been able to compile it using the command-line, but I'm worried about the "runtime issues" that can occur.

    Hi,
    Sorry, just verified that export release build, with Native Extensions and Captive Runtime bundled for Desktop projects has been fixed and is available in the final release of Flash Builder 4.7.
    Thanks,
    Hari

Maybe you are looking for