Unter Ubuntu ist eine Version von Netcat vorinstalliert welche nicht zu diversen Anletungen im Internet passt.


Ubuntu Version

#RechnerA (Sender)
dd if=/dev/zero bs=1024k count=1024 | nc <RechnerB> 1234
#RechnerB (Empfänger)
nc -l 1234


#RechnerA (Sender)
echo "bar" | nc <RechnerB> 1234
#RechnerB (Empfänger)
nc -L -p 1234
[v1.11 NT]
connect to somewhere:   nc [-options] hostname port[s] [ports] ...
listen for inbound:     nc -l -p port [options] [hostname] [port]
        -d              detach from console, background mode

        -e prog         inbound program to exec [dangerous!!]
        -g gateway      source-routing hop point[s], up to 8
        -G num          source-routing pointer: 4, 8, 12, ...
        -h              this cruft
        -i secs         delay interval for lines sent, ports scanned
        -l              listen mode, for inbound connects
        -L              listen harder, re-listen on socket close
        -n              numeric-only IP addresses, no DNS
        -o file         hex dump of traffic
        -p port         local port number
        -r              randomize local and remote ports
        -s addr         local source address
        -t              answer TELNET negotiation
        -u              UDP mode
        -v              verbose [use twice to be more verbose]
        -w secs         timeout for connects and final net reads
        -z              zero-I/O mode [used for scanning]
port numbers can be individual or ranges: m-n [inclusive]
pub/netcat.txt · Zuletzt geändert: 2013/12/06 19:12 (Externe Bearbeitung)