Remote Shell - Working with Netcat!

Here you can discuss ReactOS related topics.

Moderator: Moderator Team

Post Reply
Aeneas
Posts: 468
Joined: Sat Oct 10, 2009 10:09 pm

Remote Shell - Working with Netcat!

Post by Aeneas »

Hi everybody,

Congratulations to the team for the new release. (I recommend to re-check whether everything in the "Application Manager" works, as for me on VirtualBox at least, Python 3 and both Operas definitely did NOT work, and I really had a TOUGH time getting ANYTHING from an FTP-server - in the end, I simply got a version of wget for Windows, as Firefox, Seamonkey, K-Meleon and whatever their names are, ALL failed on FTP, at least on the VBOX-image.)

As in the past, my main interest has been in "am I able to access the shell remotely?" - and the answer was "NO" with Telnet or SSH, I tried several servers. BUT... I remembered the old friend netcat, which CAN actually execute a remote shell... which worked.

I used this one:

http://nmap.org/dist/ncat-portable-5.59BETA1.zip

Setting up the network to "bridged adapter" in VirtualBox, the following worked from within ReactOS as a "server":

ncat -l 3333 -e C:\ReactOS\system32\cmd.exe

I could then from outside of VirtualBox connect to that server from Linux with:

nc whatever-ReactOS-IP 3333

Now, having a shell is kind of lovely, but CAN I DO ANYTHING in that shell? - Well, "dir" worked, but Python 2 did not, and neither did "midnight commander for windows". Soooo... Finally I had luck with GNU Common Lisp, specifically this version:

ftp://ftp.cs.utexas.edu/pub/novak/gcl/gcl.exe

(Note the "ftp", which cost me a bit of nerves. To get it , I resorted to first installing wget from here:

https://sourceforge.net/projects/gnuwin ... ror=freefr

- and then finally getting the file from FTP).

That really worked, and I could really test a function like (defun plusone (x) (+ 1 x)) [and then (plusone 2) giving 3].

I hope this is helpful for anyone else's experiments.

User avatar
Swyter
Posts: 114
Joined: Sun Apr 10, 2011 11:21 am
Location: Spain ← Europe ← Planet Earth ← Milky Way ← Universe

Re: Remote Shell - Working with Netcat!

Post by Swyter »

You should be able to use dwnl for that very same purpose. It's a simple command-line program that runs over WinInet, that means that theoretically supports FTP, HTTP, HTTPS and whatnot.
As it is a custom ReactOS tool, included by default in every install, you can just open the command line and type something like dwnl https://ninite.com/opera/ninite.exe c:\savemehere.exe and you are golden!


Protip: If you install the VirtualBox Guest Additions (and enable bidirectional clipboard support between guest and host) pasting long-winded URLs becomes easy as pie.
External patch contributor for ux/user-mode/l10n/winapi. Sometimes I fix a bit of everything everywhere.

Aeneas
Posts: 468
Joined: Sat Oct 10, 2009 10:09 pm

Re: Remote Shell - Working with Netcat!

Post by Aeneas »

Thank you kindly for your tips, dwnl will indeed make my life easier...

Post Reply

Who is online

Users browsing this forum: Google [Bot] and 2 guests