Date: Wed, 27 May 2020 10:20:11 +0800 From: Hongyi Zhao <hongyi.zhao@gmail.com> To: freebsd-net@freebsd.org Subject: Check a no-auth socks5 proxy running on localhost's 18887 port with netcat. Message-ID: <CAGP6POJm7Ts8r_0tzvJrRv036Xtaact%2BxBH%2BGJd7uWZSrMPhgg@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Hi, I try to check a no-auth socks5 proxy running on localhost's 18887 port with netcat. Based on the notes here: https://stackoverflow.com/questions/52530515/how-use-netcat-to-test-socks5-server I obtained the following two usages: $ printf "\x05\x01\x00\r\n" | nc 127.0.0.1 18887 | hd 00000000 05 00 05 07 00 01 |......| 00000006 Does the first field represent serial number? And I also do the following test: werner@ubuntu-01:~$ printf "\x05\x01\x00\r\n" | /usr/bin/nc.traditional 127.0.0.1 18887 -o out.txt werner@ubuntu-01:~$ cat out.txt > 00000000 05 01 00 0d 0a # ..... < 00000000 05 00 # .. < 00000002 05 07 00 01 # .... Why the first two lines in the output have the same value for the first field? Regards -- Hongyi Zhao <hongyi.zhao@gmail.com>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAGP6POJm7Ts8r_0tzvJrRv036Xtaact%2BxBH%2BGJd7uWZSrMPhgg>