Netcat是个计算机网络公用程序,用来对网络连线TCP或者UDP进行读写。

    1. connect to somewhere: nc [-options] hostname port[s] [ports] ...
    2. listen for inbound: nc -l -p port [-options] [hostname] [port]
    3. options:
    4. -c shell commands as `-e'; use /bin/sh to exec [dangerous!!]
    5. -e filename program to exec after connect [dangerous!!]
    6. -b allow broadcasts
    7. -g gateway source-routing hop point[s], up to 8
    8. -G num source-routing pointer: 4, 8, 12, ...
    9. -h this cruft
    10. -i secs delay interval for lines sent, ports scanned
    11. -k set keepalive option on socket
    12. -l listen mode, for inbound connects
    13. -n numeric-only IP addresses, no DNS
    14. -o file hex dump of traffic
    15. -p port local port number
    16. -r randomize local and remote ports
    17. -q secs quit after EOF on stdin and delay of secs
    18. -s addr local source address
    19. -T tos set Type Of Service
    20. -t answer TELNET negotiation
    21. -u UDP mode
    22. -v verbose [use twice to be more verbose]
    23. -w secs timeout for connects and final net reads
    24. -C Send CRLF as line-ending
    25. -z zero-I/O mode [used for scanning]
    26. port numbers can be individual or ranges: lo-hi [inclusive];
    27. hyphens in port names must be backslash escaped (e.g. 'ftp\-data').

    相关链接:
    https://zh.wikipedia.org/wiki/Netcat
    https://www.jianshu.com/p/cb26a0f6c622
    https://www.fujieace.com/linux/nc-2.html