I recently ran into a situation where I needed to copy some CSV data residing on a Windows machine to a Linux machine. The remote desktop client software I was using (on my Linux machine) wasn't set up to nativiely allow copy and paste to and from the server. It just so happened that I was recently working with
netcat and thought this would be a great way to send the data to my destination machine. Sadly, Windows does not include
netcat, so I dug around a bit and found that
telnet would be able to take its place. So with a tool to use on both the sending and receiving side of things, I set out to implement what I'm calling "'universal' copy and paste".
So on my Linux machine (destination), I set up the
netcat to listen on port 1234:
netcat -l 1234
On the Windows machine (source), I used telnet to connect to my Linux machine on port 1234, like so:
telnet 188.8.131.52 1234
I could then paste the CSV data on my Windows machine and it would immediately start outputting on my Linux machine. Ta-da, simple and "universal" copy and paste.
Finally, I would be remis if I did not mention that--while this is a working approach--it is not a secure one. The connection is not encrypted so everything is transmitted in clear-text.