chiark / gitweb /
resolved: properly handle MTU logic
[elogind.git] / src / resolve / resolved-dns-packet.h
index 99f60a15569526c2c9024279170c2e516e2b1647..de3a789a783eb8abd483232f7b00e0d209afaebf 100644 (file)
@@ -44,8 +44,12 @@ struct DnsPacketHeader {
 
 /* The various DNS protocols deviate in how large a packet can grow,
    but the TCP transport has a 16bit size field, hence that appears to
-   be the maximum. */
+   be the absolute maximum. */
 #define DNS_PACKET_SIZE_MAX 0xFFFF
+
+/* RFC 1035 say 512 is the maximum, for classic unicast DNS */
+#define DNS_PACKET_UNICAST_SIZE_MAX 512
+
 #define DNS_PACKET_SIZE_START 512
 
 struct DnsPacket {