i cannot seem to encode the query string properly, i have read somewhere that the string must begin with a new line, end in a null byte and use 0x3 for dots and found this
in a scapy paper online, and this seems to work in my code when i check it with wireshark, howver something like
will not work and often comes up as an invalid query in wireshark
so what im asking is, can anyone tell me the correct way to encode a dns query like this?
So i found out how it works, mostly thanks to this article here:
basicly when encoding the domain before each term you must put in hex the length of the word so
\x06google\x03com\x00\x00\x01\x00\x01where x06 is the length of google
x03 is the length of com