我想通过 netcat 发送以下内容:
99||0x00
(4 个 ASCII 字符和一个零)
这是怎么做到的?我正在使用 Windows XP。
谢谢你。
# echo -ne "99||\x00" | nc <host> <port>
Put the bytes into a file with binary editor and pipe it to netcat. Windows shell too supports input from file redirection via
netcat (options) < (file)
Alternatively, you may be able to input it with keyboard directly via Alt-000, but I doubt it.
根据您的 Unix 风格,您可以尝试其中一种
echo '99||#' | tr '#' '\000' | netcat <host> <port>
echo -e '99||\000' | netcat <host> <port>