From bc2ad7e69b58959a5441b66957af71f55c1b7d69 Mon Sep 17 00:00:00 2001 From: itojun Date: Wed, 17 Jul 2002 22:34:45 +0000 Subject: parse T_AAAA responses. patch sent to wietse. --- mail/postfix/distinfo | 3 ++- mail/postfix/patches/patch-ah | 31 +++++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 mail/postfix/patches/patch-ah diff --git a/mail/postfix/distinfo b/mail/postfix/distinfo index 30c463c6028..d80abf08488 100644 --- a/mail/postfix/distinfo +++ b/mail/postfix/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.22 2002/06/27 04:47:54 itojun Exp $ +$NetBSD: distinfo,v 1.23 2002/07/17 22:34:45 itojun Exp $ SHA1 (postfix/postfix-1.1.11.tar.gz) = 3a28c32800f94df0c504df68c4c6191f48217c5c Size (postfix/postfix-1.1.11.tar.gz) = 1190741 bytes @@ -9,3 +9,4 @@ SHA1 (patch-ad) = 78f24bf3f7e6829c2a5c9a402e33dea25f1a55d2 SHA1 (patch-ae) = 66908f37243ce4da24129ccb53120b4e068ffa1d SHA1 (patch-af) = fbee5a8854857e2a99c59bcfaee4775df735f086 SHA1 (patch-ag) = 57fcf1c89ec7d9d4f454d6d9d6860a64127b9cac +SHA1 (patch-ah) = d6a403915f52c3c09ac4dd6ea1d21208394a170f diff --git a/mail/postfix/patches/patch-ah b/mail/postfix/patches/patch-ah new file mode 100644 index 00000000000..132cec76ded --- /dev/null +++ b/mail/postfix/patches/patch-ah @@ -0,0 +1,31 @@ +$NetBSD: patch-ah,v 1.3 2002/07/17 22:34:46 itojun Exp $ + +diff -u -r1.3 src/dns/dns_lookup.c +--- src/dns/dns_lookup.c 2001/11/11 05:26:51 1.3 ++++ src/dns/dns_lookup.c 2002/07/17 21:20:30 +@@ -132,6 +132,7 @@ + } DNS_REPLY; + + #define INET_ADDR_LEN 4 /* XXX */ ++#define INET6_ADDR_LEN 16 /* XXX */ + + /* dns_query - query name server and pre-parse the reply */ + +@@ -328,6 +329,17 @@ + break; + case T_A: + if (fixed->length != INET_ADDR_LEN) { ++ msg_warn("extract_answer: bad address length: %d", fixed->length); ++ return (0); ++ } ++ if (fixed->length > sizeof(temp)) ++ msg_panic("dns_get_rr: length %d > DNS_NAME_LEN", ++ fixed->length); ++ memcpy(temp, pos, fixed->length); ++ data_len = fixed->length; ++ break; ++ case T_AAAA: ++ if (fixed->length != INET6_ADDR_LEN) { + msg_warn("extract_answer: bad address length: %d", fixed->length); + return (0); + } -- cgit v1.2.3