Netcat

De Linuxmemo.

(Différences entre les versions)
(Netcat en scanner de ports)
(Netcat en scanner de ports)
Ligne 42 : Ligne 42 :
  netcat -z -vv 127.0.0.1 1-100 443
  netcat -z -vv 127.0.0.1 1-100 443
-
  netcat -zvn -w2 143.196.215.1 22
+
  netcat -zvn -w2 xxx.xxx.xxx.xxx 22
  -z scan for listening daemons, without sending any data
  -z scan for listening daemons, without sending any data
  -v verbose
  -v verbose

Version du 7 juin 2018 à 07:19

Voir: Cryptcat

Sommaire

NETCAT CLIENT

Ouvrir un socket:

NETCAT <adresse_ip_d'un_serveur> 6667
NETCAT -t <adresse_ip_d'un_serveur_telnet> 23


NETCAT SERVEUR

NETCAT -l -p 23
-l pour dire qu'on est en mode listen (on attend une connection sur un port)
-p 23 pour dire que le port sur lequel on attend la connection est le port 23.
NETCAT -L -p 23
-L majuscule annonce à NetCat qu'il doit attendre des connections en permanence (Windows).
pour Linux
while true; do ./netcat -l -p 55555 -e "/bin/bash"; done
NETCAT -l -p 80

REDIRECTIONS ENTREES/SORTIES

NETCAT -L -p 23 < wingate.txt
NETCAT -L -p 23 > wingate.log
NETCAT -L -p 23 -e c:\command.com
NETCAT -L -p 23 -d -e c:\command.com

Netcat en scanner de ports

netcat -vv 127.0.0.1 1-100 443
netcat -z -vv 127.0.0.1 1-100 443
netcat -zvn -w2 xxx.xxx.xxx.xxx 22
-z scan for listening daemons, without sending any data
-v verbose
-n Do not do any DNS or service lookups
-w timeout

Netcat en mode UDP

netcat -u 127.0.0.1 53
Outils personnels