1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
$NetBSD: patch-aw,v 1.5 2019/07/15 04:32:49 jnemeth Exp $
--- sendmail/readcf.c.orig 2015-06-17 16:51:58.000000000 +0000
+++ sendmail/readcf.c
@@ -20,6 +20,10 @@ SM_RCSID("@(#)$Id: readcf.c,v 8.692 2013
# include <arpa/inet.h>
#endif /* NETINET || NETINET6 */
+#if NAMED_BIND
+extern struct __res_state sm_res;
+#endif
+
#define SECONDS
#define MINUTES * 60
@@ -2910,6 +2914,10 @@ static struct optioninfo
#endif
#define O_USECOMPRESSEDIPV6ADDRESSES 0xec
{ "UseCompressedIPv6Addresses", O_USECOMPRESSEDIPV6ADDRESSES, OI_NONE },
+#ifdef USE_BLACKLIST
+# define O_BLACKLIST 0xf2
+ { "UseBlacklist", O_BLACKLIST, OI_NONE },
+#endif
{ NULL, '\0', OI_NONE }
};
@@ -3318,13 +3326,13 @@ setoption(opt, val, safe, sticky, e)
if (rfp->rf_name == NULL)
syserr("readcf: I option value %s unrecognized", q);
else if (clearmode)
- _res.options &= ~rfp->rf_bits;
+ sm_res.options &= ~rfp->rf_bits;
else
- _res.options |= rfp->rf_bits;
+ sm_res.options |= rfp->rf_bits;
}
if (tTd(8, 2))
sm_dprintf("_res.options = %x, HasWildcardMX = %d\n",
- (unsigned int) _res.options, HasWildcardMX);
+ (unsigned int) sm_res.options, HasWildcardMX);
#else /* NAMED_BIND */
usrerr("name server (I option) specified but BIND not compiled in");
#endif /* NAMED_BIND */
@@ -4540,6 +4548,12 @@ setoption(opt, val, safe, sticky, e)
UseCompressedIPv6Addresses = atobool(val);
break;
+#ifdef USE_BLACKLIST
+ case O_BLACKLIST:
+ UseBlacklist = atobool(val);
+ break;
+#endif
+
default:
if (tTd(37, 1))
{
|