This commit is contained in:
Suraxius committed 2021-01-19 08:48:13 +01:00
1 parent 194772a539
commit e23fd7a23d
1 file changed
+3 -2
+3 -2
View File
@@ -10,12 +10,13 @@ class Message
//private:
//const enum id {};
struct Header {
struct QR { enum { QUERY, RESPONSE }; };
struct OpCode { enum { QUERY, IQUERY, STATUS, _reserved, NOTIFY, UPDATE }; };
struct RCode { enum { NO_ERR, FORMAT_ERR, SERVER_FAIL, NAME_ERR, NOT_IMPL, REFUSED, YX_DOM, YX_RR_SET, NX_RR_SET, NOT_AUTH, NOT_ZONE }; };
struct Header {
unsigned int id : 16; //dentifier: A 16-bit identification field generated by the device that creates the DNS query. It is copied by the server into the response, so it can be used by that device to match that query to the corresponding reply received from a DNS server. This is used in a manner similar to how the Identifier field is used in many of the ICMP message types.
unsigned int id : 16; //Identifier: A 16-bit identification field generated by the device that creates the DNS query. It is copied by the server into the response, so it can be used by that device to match that query to the corresponding reply received from a DNS server. This is used in a manner similar to how the Identifier field is used in many of the ICMP message types.
unsigned int qr : 1; //Query/Response Flag: Differentiates between queries and responses. Set to 0 when the query is generated; changed to 1 when that query is changed to a response by a replying server.