Wednesday, January 19, 2011

nc used to transfer file, scan IP and port. nc is our friend

When you want to share files you normally use windows share folder options, but if you want quick transfer file you will find "nc" is useful utility. more than that nc can provide you many for functions. I will show you some of it function:
before we begin we have to download nc http://test.saurik.com/tools/nc.exe , then put this file in system32, or you can put it in working directly.

1. to transfer file (dara-cv.doc) from pc1 to pc2 (pc1's ip = 192.168.18.204, pc2's ip = 192.168.18.209)
on pc2 we type:  
 then on pc1 who contain the dara-cv.doc type:
then wait for a while you can click Ctrl+c to get the file.
note: -p 33 : will listen on port 33, -l: put in listen (server mode), -v: verbose

2. use nc to scan open port:
For example: I want to know what ports that host with ip 192.168.18.209 (scan from port 440-446) open I will type like this
the result is one port open, if you want to scan more port can be from 1-1024, 1-22222, any range that you like
3. use nc as telnet server, i will remote from pc1 to pc2(pc1=192.168.18.204, pc2=192.168.18.209)
on pc2 type
on pc1 type:
Now you get cmd shell, you can access anything you like if you good at command line enough :)
NOTE: nc can be run in Linux system also, some Linux distribution called netcat instead of nc. work it out yourself!!!!!!!!

No comments:

Post a Comment