Netcat, also called "the Swiss boxcutter networks", is one of the most popular tool for information security. The potential of this small program are almost endless, so to name a few:file transfer, scanning ports, reverse shell, remote administration, banner grabbing and capable even of capture the network traffic. In a few words can make us to netcat everything and more. The only drawback? Creativity!
File transfer
If you can entice even more, every day I use Netcat now. Want to know how I did it with Netcat? It's easier to do that say it! The first procedure is to put in the computer that is listening would like a free port on a given file (not occupied by any service). After just take as input, as well as the port number, the name and the file extension you want to send.
Let me give an example, so you understand the process in the best ways:
We simulate a possible transfer, which will be the Computer_recv recipient computer and Computer_send will be sending computer. As always, we open our beloved console and Computer_recv type:
nc-LVP (port_number)-w (seconds)> (file_name.extension) example: nc LVP-6775-w 3> / root / Desktop / document.txt
Now that Computer_recv is listening on port 6775, let's Computer_send and send in files, typing on his console:
nc-VVN (ip) (port_number) (file_name.extension)
example: nc -vvn 192.168.1.8 6775 < /root/Desktop/document.txt
The file will be sent within a few seconds, then it is obvious that the higher is its weight, the greater the time required. Here I report the table of options for transferring file;
•-l: Puts a system listens for a possible connection
•-n: Do not use any DNS system to convert the IP address
•-p: port where it listens Netcat (care should be a free port)
•-v: The verbose-mode already seen, that will send some information on the process
•-w: Limit the maximum time, in seconds.
Port scanning
I had mentioned before that feature of Netcat, you is the port scanning, port scanning properly called. This we learned that it is already known to Nmap that this is the top, however it may be pointed out useful to be able to use this technique with Netcat. Passing the input, via the console, a single line Netcat will be able to tell us what ports are open or closed: nc-VVN-z (ip) (range_di_porte)
Example: VVN-nc-z 192.168.1.8 10-20
The above example, will tell Netcat not to translate the ip with the -n, back a lot of information with-vv and make the Input and Output on ports using the TCP protocol. All this ip address
192.168.1.8
on the doors 10,11,12,13,14,15,16,17,18,19 and 20.
If we want to check this via the UDP protocol and non-TCP, we must add the-u option to the previous string. I remember that this process is quite slow and will certainly require a couple of minutes, however it is really worth having the amazing results.
Netcat, also called "the Swiss boxcutter networks", is one of the most popular tool for information security. The potential of this small program are almost endless, so to name a few:file transfer, scanning ports, reverse shell, remote administration, banner grabbing and capable even of capture the network traffic. In a few words can make us to netcat everything and more. The only drawback? Creativity!
File transfer
If you can entice even more, every day I use Netcat now. Want to know how I did it with Netcat? It's easier to do that say it! The first procedure is to put in the computer that is listening would like a free port on a given file (not occupied by any service). After just take as input, as well as the port number, the name and the file extension you want to send.
Let me give an example, so you understand the process in the best ways:
We simulate a possible transfer, which will be the Computer_recv recipient computer and Computer_send will be sending computer. As always, we open our beloved console and Computer_recv type:
nc-LVP (port_number)-w (seconds)> (file_name.extension) example: nc LVP-6775-w 3> / root / Desktop / document.txt
Now that Computer_recv is listening on port 6775, let's Computer_send and send in files, typing on his console:
nc-VVN (ip) (port_number) (file_name.extension)
example: nc -vvn 192.168.1.8 6775 < /root/Desktop/document.txt
The file will be sent within a few seconds, then it is obvious that the higher is its weight, the greater the time required. Here I report the table of options for transferring file;
•-l: Puts a system listens for a possible connection
•-n: Do not use any DNS system to convert the IP address
•-p: port where it listens Netcat (care should be a free port)
•-v: The verbose-mode already seen, that will send some information on the process
•-w: Limit the maximum time, in seconds.
Port scanning
I had mentioned before that feature of Netcat, you is the port scanning, port scanning properly called. This we learned that it is already known to Nmap that this is the top, however it may be pointed out useful to be able to use this technique with Netcat. Passing the input, via the console, a single line Netcat will be able to tell us what ports are open or closed: nc-VVN-z (ip) (range_di_porte)
Example: VVN-nc-z 192.168.1.8 10-20
The above example, will tell Netcat not to translate the ip with the -n, back a lot of information with-vv and make the Input and Output on ports using the TCP protocol. All this ip address
192.168.1.8
on the doors 10,11,12,13,14,15,16,17,18,19 and 20.
If we want to check this via the UDP protocol and non-TCP, we must add the-u option to the previous string. I remember that this process is quite slow and will certainly require a couple of minutes, however it is really worth having the amazing results.
Inscription à :
Publier les commentaires (Atom)
Aucun commentaire: