Herramientas de usuario

Herramientas del sitio


enlaces:utilidades_de_red

Diferencias

Muestra las diferencias entre dos versiones de la página.

Enlace a la vista de comparación

Ambos lados, revisión anteriorRevisión previa
Próxima revisión
Revisión previa
Próxima revisiónAmbos lados, revisión siguiente
enlaces:utilidades_de_red [2011/07/08 13:28] – [Netcat] cayuenlaces:utilidades_de_red [2018/11/01 16:35] – [Netcat] cayu
Línea 2: Línea 2:
  
 ===== Conectividad ===== ===== Conectividad =====
 +
 +==== Agregar ruta estatica ====
 +
 +<code>
 +ip route add 192.168.55.0/24 via 192.168.1.254 dev eth1
 +</code>
 +
 +<code>
 +route add -net 192.168.55.0 netmask 255.255.255.0 gw 192.168.1.254 dev eth1
 +</code>
  
 ==== Forzar el modo ethernet ==== ==== Forzar el modo ethernet ====
Línea 10: Línea 20:
 ethtool -s eth0 speed 100 duplex full autoneg off ethtool -s eth0 speed 100 duplex full autoneg off
 </code> </code>
- 
 ==== Conectarse a redes Wi Fi ==== ==== Conectarse a redes Wi Fi ====
 Primero bajamos el servicio de Network Manager si es que lo tenemos instalado Primero bajamos el servicio de Network Manager si es que lo tenemos instalado
Línea 343: Línea 352:
  
 Muestra y busca paquetes. Ngrep se esfuerza por proveer de la mayoría de características comunes del "grep" de GNU, aplicándolas a la capa de network ({"network layer"} del modelo de referencia OSI). ngrep es consciente de la presencia de pcap y permite usar expresiones regulares que concuerden con el "payload" ( o sea la carga, el cuerpo, y _no_ los encabezados) de los paquetes. Actualmente reconoce TCP, UDP, e ICMP sobre Ethernet, PPP, SLIP e interfaces nulas {"null interfaces"}, y comprende la lógica de un filtro "bpf" de la misma manera que herramientas más comunes de sniffing como tcpdump y snoop. Muestra y busca paquetes. Ngrep se esfuerza por proveer de la mayoría de características comunes del "grep" de GNU, aplicándolas a la capa de network ({"network layer"} del modelo de referencia OSI). ngrep es consciente de la presencia de pcap y permite usar expresiones regulares que concuerden con el "payload" ( o sea la carga, el cuerpo, y _no_ los encabezados) de los paquetes. Actualmente reconoce TCP, UDP, e ICMP sobre Ethernet, PPP, SLIP e interfaces nulas {"null interfaces"}, y comprende la lógica de un filtro "bpf" de la misma manera que herramientas más comunes de sniffing como tcpdump y snoop.
 +
 +
 +Usage examples:
 +
 +<code>
 +ngrep '' udp (print all UDP packets)
 +
 +ngrep '' icmp (print all ICMP packets)
 +
 +ngrep '' port 53 (print TCP or UDP port 53 packets)
 +
 +ngrep '' tcp port 23 (print TCP port 23 packets)
 +
 +ngrep 'LILWORD' port 138 (print Microsoft browsing traffic for NT domain LILWORLD)
 +
 +ngrep -iq 'rcpt to|mail from' tcp port 25 (monitor current delivery and print sender and recipients)
 +
 +ngrep 'user' port 110 (monitor POP3)
 +
 +ngrep -q 'abcd' icmp (Microsoft operating systems fill the ICMP payload with the alphabet; is the "pinging" host running a 
 +Microsoft operating system?)
 +
 +ngrep -iq 'user-agent' tcp port 80 (determine client application that client host is running)
 +
 +ngrep '220' port 21 (determine version of FTP server)
 +
 +ngrep 'SSH' port 22 (investigate Secure Shell)
 +
 +ngrep -v '' port 23 (see all traffic but telnet)
 +
 +ngrep -d le0 '' (listen to le0)
 +</code>
 +
 +
 +Useful flags:
 +
 +<code>
 +-A n (prints out "n" packets after the match)
 +
 +-l (pipe the output of ngrep to another program for more processing)
 +
 +-v (print all lines not matching the expression)
 +
 +-d (specify the device you want to monitor)
 +</code>
  
  
Línea 415: Línea 469:
  
  
-==== Netcat ==== 
- 
- Netcat is a featured networking utility which reads and writes data across network connections, using the TCP/IP protocol. 
-It is designed to be a reliable "back-end" tool that can be used directly or easily driven by other programs and scripts. At the same time, it is a feature-rich network debugging and exploration tool, since it can create almost any kind of connection you would need and has several interesting built-in capabilities. 
- 
-It provides access to the following main features: 
- 
-    * Outbound and inbound connections, TCP or UDP, to or from any ports. 
-    * Featured tunneling mode which allows also special tunneling such as UDP to TCP, with the possibility of specifying all network parameters (source port/interface, listening port/interface, and the remote host allowed to connect to the tunnel. 
-    * Built-in port-scanning capabilities, with randomizer. 
-    * Advanced usage options, such as buffered send-mode (one line every N seconds), and hexdump (to stderr or to a specified file) of trasmitted and received data. 
-    * Optional RFC854 telnet codes parser and responder.  
- 
- 
-The GNU Netcat is distributed freely under the GNU General Public License (GPL).  
- 
-<code bash> 
-echo  -e "GET / HTTP/1.0\r\n" | nc 192.168.1.1 80 
-</code> 
- 
-Para pasar un archivo de un equipo a otros podemos ejecutar 
- 
-Desde el servidor 
-<code> 
-cat backup.iso | nc -l 3333 
-<code> 
-Desde el cliente 
-<code> 
-nc 192.168.0.1 3333 > backup.iso 
-</code> 
-Si queremos poner un contador 
-<code> 
-nc 192.168.0.1 3333 | pv -b > backup.iso 
-</code> 
- 
-Otro ejemplo 
- 
-Desde el servidor 
-<code> 
-dd if=/dev/hdb5 | gzip -9 | nc -l 3333 
-</code> 
-Desde el cliente 
-<code> 
-nc 192.168.0.1 3333 | pv -b > myhdb5partition.img.gz 
-</code> 
- 
-Referencias : 
- 
-http://netcat.sourceforge.net/ 
- 
- 
-Tutorial con ejemplos prácticos : http://crysol.org/node/28 
  
 ==== MSN Dump ==== ==== MSN Dump ====
enlaces/utilidades_de_red.txt · Última modificación: 2019/01/22 15:34 por cayu