Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to escape hex values in netcat

Tags:

netcat

I want to send the following via netcat:

99||0x00

(4 ASCII characters and a zero)

How is this done? I'm using Windows XP.

Thank you.

like image 482
Carl Avatar asked Oct 12 '09 09:10

Carl


2 Answers

# echo -ne "99||\x00" | nc <host> <port>
like image 137
Jake Snake Avatar answered Sep 19 '22 16:09

Jake Snake


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.

like image 29
Juraj Avatar answered Sep 19 '22 16:09

Juraj