Shared publicly  - 
Broadcast your shell

Imagine you are using PC1 and you want your partner on PC2 to see what you are doing. You can broadcast your shell at port 5000 with:

$ script -f >(nc -l 5000)

Now, your partner from PC2 can see the shell you are broadcasting:

$ nc IP_FROM_PC1 5000

Now, PC2 can see everything you are doing in your shell at PC1.

This is handy when you want to show someone else some amazing stuff in your shell without giving them control over it.

#Linux   #CommandOfTheDay  
Jacek Wysocki's profile photoJordan Schroeder's profile photoSascha Dewald's profile photoChris Scarff's profile photo
Wow, this was awesome.. but how secure is it? Am not familiar with nc.
I think that you might want to tell how to find out what his or her own IP address is... :) 
You may find son info here: . According to the site there's a variant of the original netcat (nc), called Cryptcat, that's been modified to add encryption.
I'm used it for chatting in office ;-) but never think it is useful like this before
I was thinking this can be useful for showing someone how to configure something without moving my lazy ass
Great! I'm using sometimes nc for sending a file from my machine to browser
e,g, cat .vimrc|nc -l 5000 and then ( IP of my linux machine)
Add a comment...