Compare commits

...

438 Commits

Author SHA1 Message Date
cvs2git
3ed9f39f74 This commit was manufactured by cvs2git to create tag 'v9_2_1'. 2002-04-23 06:28:36 +00:00
Mark Andrews
8bae85ee9b 9.2.1 2002-04-23 06:28:35 +00:00
Mark Andrews
2d18f59f88 pullup:
CHANGES, FAQ and COPYRIGHT are part of a binary release
2002-04-23 06:09:23 +00:00
Mark Andrews
b45ba90e7f update for 9.2.1 2002-04-23 05:15:01 +00:00
Mark Andrews
c1e52e6097 update for 9.2.1 2002-04-23 03:38:55 +00:00
Mark Andrews
eeb2e36c5a update_copyrights 2002-04-23 02:28:55 +00:00
Mark Andrews
7b51a5ed05 regen 2002-04-23 02:13:48 +00:00
Mark Andrews
dee7d91a52 reviewed by: bwelling@nominum.com
1269.   [bug]           Missing masters clause was not handled gracefully.
                        [RT #2703]
2002-04-23 02:00:03 +00:00
Mark Andrews
09fb82a40d Reviewed by: gson@nominum.com
1244.   [bug]           Receiving a TCP message from a blackhole address would
                        prevent further messages being received over that
                        interface.
2002-04-23 01:53:53 +00:00
Mark Andrews
3855970d74 min-refresh-time et al are not per server but reather globally and not for
master zones.
2002-04-22 04:14:25 +00:00
Mark Andrews
03d58c6ef9 pullup:
allow transfers from all hosts -> allow transfers to all hosts [RT #2723]
2002-04-22 03:43:25 +00:00
Mark Andrews
a233df373c 1271. [port] win32: a make file contained absolute version specific
references.
2002-04-19 01:14:26 +00:00
Mark Andrews
ced2a93ebc 1178. [bug] Follow and cache (if appropriate) A6 and other
data chains to completion in the additional section.
2002-04-19 01:11:19 +00:00
Mark Andrews
410b02f399 use relative paths 2002-04-10 03:53:06 +00:00
Mark Andrews
4e67211f74 9.2.1 2002-03-29 03:01:13 +00:00
Mark Andrews
5849e544f6 move 9.2.1rc2 release marker 2002-03-29 01:47:05 +00:00
Mark Andrews
42823e32ea pullup:
INSIST that there are no outstanding tasks when the task manager is
about to be destroyed (non-threaded).  This will also produce more
useful core dumps if triggered.
2002-03-29 01:41:01 +00:00
Mark Andrews
253c278b39 pullup:
1240.   [bug]           It was possible to leak zone references by
                        specifying an incorrect zone to rndc.
2002-03-29 01:35:24 +00:00
Mark Andrews
769c637e95 pullup:
1238.   [bug]           It is possible to lockup the server when shutting down
                        if notifies are being processed. [RT #2591]
2002-03-29 00:20:07 +00:00
Mark Andrews
af54b372dc pullup:
1239.   [bug]           Under certain circumstances named could continue to
                        use a name after it had been freed triggering
                        INSIST() failures.  [RT #2614]
2002-03-28 05:10:09 +00:00
Mark Andrews
ee95e5b2d3 pullup:
Change 1236 was incorrect.  [RT #2611]
2002-03-27 23:52:33 +00:00
Mark Andrews
c1e109166b 9.2.1rc2 release marker 2002-03-26 06:11:36 +00:00
Mark Andrews
e88346ed0f regen for 9.2.1_rc2 2002-03-26 04:54:08 +00:00
Mark Andrews
57a877555a update for 9.2.1rc2 2002-03-26 03:39:30 +00:00
Mark Andrews
b2f3e5c308 update_copyrights 2002-03-26 00:55:15 +00:00
Mark Andrews
cd27f76d7b merge_copyrights 2002-03-26 00:50:25 +00:00
Mark Andrews
8c7d74701d pullup:
lock mctx for DELETE_TRACE call in isc__mempool_put()
2002-03-20 22:51:43 +00:00
Mark Andrews
d1a95dea1f pullup:
1237.   [bug]           nslookup: "set q=type" failed.
2002-03-20 22:45:11 +00:00
Mark Andrews
1cf32ab2b3 pullup:
1236.   [bug]           dns_rdata{class,type}_fromtext() didn't handle non
                        NULL terminated text regions. [RT #2588]
2002-03-20 22:41:58 +00:00
Mark Andrews
7f855bbeee update 2002-03-20 22:40:54 +00:00
Mark Andrews
f8656a8bd6 missed this 2002-03-20 22:20:59 +00:00
Mark Andrews
93304856f9 add missing result codes 2002-03-20 21:29:47 +00:00
Mark Andrews
e5a402d95e pullup:
1232.   [bug]           unix/errno2result() didn't handle EADDRNOTAVAIL.
2002-03-20 20:59:39 +00:00
Mark Andrews
034804a048 pullup:
1231.   [port]          HPUX 11.11 recvmsg() can return spurious EADDRNOTAVAIL.
2002-03-20 20:56:44 +00:00
Mark Andrews
9789fdd98b pullup:
1230.   [bug]           isccc_cc_isreply() and isccc_cc_isack() were broken.
2002-03-20 20:53:06 +00:00
Mark Andrews
1466c8252a pullup:
1228.   [bug]           'make install' did not depend on 'make all'. [RT #2559]
2002-03-20 20:48:16 +00:00
Mark Andrews
e4166c0e05 pullup:
1227.   [bug]           dns_lex_getmastertoken() now returns ISC_R_BADNUMBER
                        if a number was expected and some other token was
                        found. [RT#2532]
2002-03-20 20:44:18 +00:00
Mark Andrews
356880d58e pullup:
1222.   [bug]           Specifying 'port *' did not always result in a system
                        selected (non-reserved) port being used. [RT #2537]
2002-03-20 20:39:51 +00:00
Mark Andrews
27cd2ff244 pullup:
1221.   [bug]           Zone types 'master', 'slave' and 'stub' were not being
                        compared case insensitively. [RT #2542]
2002-03-20 20:32:41 +00:00
Mark Andrews
4da8460d04 pullup:
1218.   [bug]           Named incorrectly returned SERVFAIL rather than
                        NOTAUTH when there was a TSIG BADTIME error. [RT #2519]
2002-03-20 20:27:21 +00:00
Mark Andrews
ba8a105802 pullup:
1216.   [bug]           Multiple server clauses for the same server were not
                        reported.  [RT #2514]
2002-03-20 20:21:15 +00:00
Mark Andrews
4dedf7a82e pullup:
1215.   [port]          solaris: add support to ifconfig.sh for x86 2.5.1
2002-03-20 19:59:50 +00:00
Mark Andrews
a295792f8d pullup:
1214.   [bug]           Win32: isc_file_renameunique() could leave zero length
                        files behind.
2002-03-20 19:50:54 +00:00
Mark Andrews
ede71ed60b pullup:
1212.   [port]          libbind: 64k answer buffers were causing stack space
                        to be exceeded for certian OS.  Use heap space instead.
2002-03-20 19:44:40 +00:00
Mark Andrews
9e7dfa38b4 pullup:
1211.   [bug]           dns_name_fromtext() incorrectly handled certain
                        valid octal bitlabels. [RT #2483]
2002-03-20 19:38:49 +00:00
Mark Andrews
18a3d3ea3d pullup:
1210.   [bug]           libbind: getnameinfo() failed to lookup IPv4 mapped /
                        compatible addresses. [RT #2461]
2002-03-20 19:31:14 +00:00
Mark Andrews
fdae17c884 pullup:
1229.   [bug]           named would crash if it received a TSIG signed
                        query as part of an AXFR response. [RT #2570]
2002-03-20 19:24:37 +00:00
Mark Andrews
d5d160a7bd silence compiler 2002-03-20 19:20:29 +00:00
Mark Andrews
433695cce3 pullup:
1208.   [bug]           dns_master_load*() failed to log a error message if
                        an error was detected when parsing the ownername of
                        a record.  [RT #2448]
2002-03-20 19:15:13 +00:00
Mark Andrews
24bc7544b2 update 2002-03-20 18:57:07 +00:00
Mark Andrews
59f871bf92 9.2.1rc2 2002-03-15 05:14:11 +00:00
Mark Andrews
0924f3b522 silence compiler 2002-03-12 03:55:57 +00:00
Brian Wellington
cbfefc37a3 improve #1206 2002-03-11 23:53:07 +00:00
Mark Andrews
dc57e5e0ca pullup:
<isc/print.h> for snprintf
2002-02-28 05:17:49 +00:00
Mark Andrews
1962186055 pullup 2002-02-27 07:20:25 +00:00
Mark Andrews
450ffb2f77 #1206 is part of 9.2.1rc1 2002-02-27 00:44:58 +00:00
Bob Halley
e7164f3fcd pull up 1206 for Mark 2002-02-26 23:24:18 +00:00
Bob Halley
991343d9a3 #1204 failed to set sin_len (pull up for Mark) 2002-02-26 23:13:33 +00:00
Mark Andrews
4daf63c4b0 copyright dates 2002-02-20 02:17:28 +00:00
Mark Andrews
538bc08bee update for latest set of pullups 2002-02-20 01:49:55 +00:00
Andreas Gustafsson
258eca377d pullup:
1207.   [bug]           libbind: getaddrinfo() could call freeaddrinfo() with
                        an invalid pointer.
2002-02-20 01:06:19 +00:00
Andreas Gustafsson
6bc9a03601 pullup:
1205.   [bug]           OPT, TSIG and TKEY cannot be used to set the "class"
                        of the message. [RT #2449]
2002-02-20 00:47:40 +00:00
Andreas Gustafsson
ba9a670151 pullup:
1204.   [bug]           libbind: res_nupdate() failed to update the name
                        servers addresses before sending the update.
2002-02-20 00:47:03 +00:00
Andreas Gustafsson
9cdcf06d3b pullup:
1204.   [bug]           libbind: res_nupdate() failed to update the name
                        servers addresses before sending the update.
CHANGES
2002-02-20 00:43:46 +00:00
Andreas Gustafsson
fd7505872d pullup:
1201.   [bug]           Require that if 'callbacks' is passed to
                        dns_rdata_fromtext(), callbacks->error and
                        callbacks->warn are initalised.
2002-02-20 00:39:27 +00:00
Andreas Gustafsson
44b8e407b5 pullup:
1200.   [bug]           Log 'errno' that we are unable to convert to
                        isc_result_t. [RT #2404]
2002-02-19 22:44:51 +00:00
Andreas Gustafsson
191fdb73be pullup:
1198.   [bug]           OPT printing style was not consistant with the way the
                        header fields are printed.  The DO bit was not reported
                        if set.  Report if any of the MBZ bits are set.
2002-02-19 22:39:25 +00:00
Andreas Gustafsson
1f40299d87 pullup:
1197.   [bug]           Attempts to define the same acl multiple times were not
                        detected.
2002-02-19 22:30:05 +00:00
Andreas Gustafsson
a07532875f pullup:
1193.   [bug]           Best effort parsing didn't handle packet truncation.
2002-02-19 22:13:00 +00:00
Mark Andrews
7fbafdc2d7 update 2002-02-19 05:27:39 +00:00
Mark Andrews
c3103a0b2d update 2002-02-19 04:45:34 +00:00
Mark Andrews
b700c2c3d2 libisccfg now requires libdns 2002-02-19 04:43:32 +00:00
Mark Andrews
e6012d7b37 pullup:
Fixes for error handling that were missing in previous commit.
2002-02-19 00:40:09 +00:00
Mark Andrews
751109bdd5 pullup:
memory leak
2002-02-13 04:02:36 +00:00
Mark Andrews
5d1e521490 pullup:
Allocate and free key used to check for duplicate zones.
2002-02-12 13:30:33 +00:00
Mark Andrews
e1748302ad cfg_test needs to link against libdns (shared lib) 2002-02-12 12:02:06 +00:00
Mark Andrews
13db7f40a5 libdns required for shared library build. 2002-02-12 06:49:36 +00:00
Mark Andrews
eb176d660e update 2002-02-12 06:38:36 +00:00
Mark Andrews
f2048c5dff update_copyrights 2002-02-12 06:05:52 +00:00
Mark Andrews
1d4285b6a3 merge_copyrights 2002-02-12 06:05:31 +00:00
Mark Andrews
74fd9ace3f merge_copyrights 2002-02-12 05:56:10 +00:00
Mark Andrews
e52fde1b98 pullup:
distclean should remove HTML.index HTML.manifest
2002-02-12 05:51:27 +00:00
Mark Andrews
63102c64ae pullup:
distclean should remove r1.htm
2002-02-12 05:49:37 +00:00
Mark Andrews
0d2fb0ac27 add libdns to named-checkconf. 2002-02-12 04:31:19 +00:00
Mark Andrews
184f677780 Order subdirectory processing 2002-02-12 04:07:36 +00:00
Mark Andrews
b5d00f6ea2 mark 9.2.1rc1 release point 2002-02-12 03:47:25 +00:00
Mark Andrews
7b373263b7 leftover from previous version 2002-02-12 00:20:07 +00:00
Andreas Gustafsson
773f604c52 1194. [bug] Not all duplicate zone definitions were being detected
at the named.conf checking stage. [RT #2431]
2002-02-11 21:50:17 +00:00
Andreas Gustafsson
65ae185312 pullup:
1195.   [bug]           Attempts to redefine builtin acls should be caught.
                        [RT #2403]
2002-02-11 21:42:10 +00:00
Andreas Gustafsson
60c0e2944d English 2002-02-11 20:16:20 +00:00
Mark Andrews
6f9dfd7330 pullup:
reference FAQ
2002-02-11 05:17:22 +00:00
Mark Andrews
1f179c6edd update for 9.2.1rc1 2002-02-08 13:25:16 +00:00
Mark Andrews
ee9dbfb7cd pullup:
1196.   [contrib]       update mdnkit to 2.2.3.
2002-02-08 12:16:32 +00:00
cvs2git
a51c70decc This commit was manufactured by cvs2git to create branch 'v9_2'. 2002-02-08 05:42:25 +00:00
Mark Andrews
73d7583d98 update copyrights 2002-02-08 03:57:47 +00:00
Mark Andrews
50b0a27f48 remove dead wood 2002-02-08 03:39:43 +00:00
Mark Andrews
97cee754a9 merge_copyrights 2002-02-08 03:32:42 +00:00
Mark Andrews
8db1db6295 pullup: Secure Zone Transfers note 2002-02-07 03:50:14 +00:00
Mark Andrews
323de351b3 update for 9.2.1rc1 2002-01-25 04:21:19 +00:00
Mark Andrews
6b345bc209 update for 9.2.1rc1 2002-01-25 04:12:35 +00:00
Mark Andrews
d3fafb3213 update for 9.2.1 2002-01-25 04:06:02 +00:00
Mark Andrews
c363d0fed8 9.2.1rc1 2002-01-25 03:04:22 +00:00
Mark Andrews
f5e4a39e62 pullup: (by tagging)
1167.   [contrib]       nslint-2.1a3 (from author).O
2002-01-25 01:31:33 +00:00
Mark Andrews
e227c896a2 #1025, #1034, #1035, #1037, #1079 and #1080 2002-01-25 01:12:36 +00:00
Mark Andrews
0f0e3ffdc1 1007. [port] config.guess, config.sub from autoconf-2.52.
1008.   [port]          libtool.m4, ltmain.sh from libtool-1.4.2.

1009.   [port]          OpenUNIX 8 support. [RT #1728]
2002-01-25 01:02:12 +00:00
Mark Andrews
b8c4c3aade 1105. [port] OpenUNIX 8 enable threads by default. [RT #1970]
[Functional change]
2002-01-25 00:57:56 +00:00
Mark Andrews
c2f1d683c9 1073. [bug] The ADB cache cleaning should also be space driven.
[RT #1915, #1938]
                        [ New function dns_adb_setadbsize() ]
2002-01-25 00:49:31 +00:00
Mark Andrews
fa85f47357 pullup:
1108.   [bug]           On Win32, rndc was hanging when named was not running
                        due to failure to select for exceptional conditions
                        in select(). [RT #1870]

win32 fixes for:
1081.   [bug]           Multicast queries were incorrectly identified
                        based on the source address, not the destination
                        address.

1066.   [bug]           Provide a thread safe wrapper for strerror().
                        [RT #1689]  (socket.c only)

General cleanup from mainline.
2002-01-25 00:24:58 +00:00
Mark Andrews
8a044e464b pullup:
1081.   [bug]           Multicast queries were incorrectly identified
                        based on the source address, not the destination
                        address.
(from JINMEI Tatuya)
2002-01-24 23:22:25 +00:00
Mark Andrews
5295debde0 1110. [bug] dig should only accept valid abbreviations of +options.
[RT #2003]
                        [Potentially breaks scripts.  Leave to 9.3.0.]
2002-01-24 23:15:51 +00:00
Mark Andrews
3e69f0cd72 pullup:
1072.   [bug]           The TCP client quota could be exceeded when
                        recursion occurred. [RT #1937]
2002-01-24 23:09:15 +00:00
Mark Andrews
c592760e76 pullup:
1071.   [bug]           Sockets listening for TCP DNS connections
                        specified an excessive listen backlog. [RT #1937]
2002-01-24 22:59:07 +00:00
Mark Andrews
f64f89606f pullup:
nsupdate should not take octal and hex TTLs
2002-01-24 21:59:51 +00:00
Andreas Gustafsson
3f25cb17e3 pullup:
1070.  [bug]           Copy DNSSEC OK (DO) to response as specified by
                       draft-ietf-dnsext-dnssec-okbit-03.txt.
2002-01-24 19:00:27 +00:00
Andreas Gustafsson
e2352fb8cd pullup:
995.   [bug]           dig, host, nslookup: using a raw IPv6 address as a
                        target address should be fatal on a IPv4 only system.
2002-01-24 18:42:29 +00:00
Andreas Gustafsson
21b4f15c60 pullup:
1109.   [bug]           nsupdate accepted illegal ttl values.
2002-01-24 18:32:25 +00:00
Mark Andrews
417cddb8c1 1024. [port] Compilation failed on HP-UX 11.11 due to
incompatible use of the SIOCGLIFCONF macro
                        name. [RT #1831]
                        [needs more work]
2002-01-24 06:32:30 +00:00
Mark Andrews
f27e47b5ff pullup:
1014.   [bug]           Some queries would cause statistics counters to
                        increment more than once or not at all. [RT #1321]
2002-01-24 04:22:58 +00:00
Mark Andrews
2a091ec932 pullup:
988.   [bug]           'additional-from-auth no;' did not work reliably
                        in the case of queries answered from the cache.
                        [RT #1436]
2002-01-24 03:49:04 +00:00
Mark Andrews
9445e10377 1012. [bug] The -p option to named did not behave as documented. 2002-01-24 03:06:25 +00:00
Andreas Gustafsson
f6bd49ffd0 consistent spacing 2002-01-23 18:02:49 +00:00
Andreas Gustafsson
fff1dbdf55 pullup:
1166.   [bug]           "Not Implemented" should be reported as NOTIMP,
                        not NOTIMPL. [RT #2281]
2002-01-23 17:57:51 +00:00
Andreas Gustafsson
69e7554caa pullup:
1170.   [bug]           Don't attempt to print the token when a I/O error
                        occurs when parsing named.conf.  [RT #2275]
2002-01-23 17:54:06 +00:00
Brian Wellington
99df95697c pullup:
1191.   [bug]           A dynamic update removing the last non-apex name in
                        a secure zone would fail. [RT #2399]
2002-01-23 08:17:55 +00:00
Mark Andrews
d778d61208 1168. [bug] Empty also-notify clauses were not handled. [RT #2309] 2002-01-23 05:14:35 +00:00
Mark Andrews
d0bb045c79 1150. [bug] named incorrectly accepted TTL values
containing plus or minus signs, such as
                        1d+1h-1s.
                        [ Uses new function isc_parse_uint32() ]

1151.   [bug]           nslookup failed to check that the arguments to
                        the port, timeout, and retry options were
                        valid integers and in range. [RT #2099]
                        [ Uses new function isc_parse_uint32() ]
2002-01-23 04:23:45 +00:00
Mark Andrews
3fa36cb79d not NOTIMPL -> NOTIMP change 2002-01-23 04:04:22 +00:00
Mark Andrews
ab92fa0aca pullup: style 2002-01-23 03:49:20 +00:00
Mark Andrews
3a7c194000 1187. [bug] named was incorrectly returning DNSSEC records
in negative responses when the DO bit was not set.
                        [ Requires API change (new arguement) to
                        dns_rdataset_towire(), dns_rdataset_towirepartial()
                        and dns_rdataset_towirepartial() ]
2002-01-23 03:33:48 +00:00
Mark Andrews
8a4f85e204 pullup:
1188.   [bug]           Dynamic updates of a signed zone would fail if
                        some of the zone private keys were unavailable.
2002-01-23 03:19:03 +00:00
Mark Andrews
622a5774e6 pullup:
1189.   [bug]           On some systems, malloc(0) returns NULL, which
                        could cause the caller to report an out of memory
                        error. [RT #2398]
2002-01-23 03:09:31 +00:00
Mark Andrews
feed58ca64 pullup:
add format checking
2002-01-23 03:02:28 +00:00
Mark Andrews
eab966fdb3 pullu: typo in comment 2002-01-23 02:55:10 +00:00
Mark Andrews
5eeb5ddc67 1159. [bug] MD and MF are not permitted to be loaded by RFC1123
[ Could cause zones that loaded in 9.2.0 to fail
                        to load.  Leave such breakages to 9.3.0. ]
2002-01-23 02:47:08 +00:00
Andreas Gustafsson
4c7c397275 1183. [bug] Handle ENOSR error when writing to the internal
control pipe. [RT #2395]
2002-01-23 02:35:56 +00:00
Andreas Gustafsson
05b8c412f8 pullup:
pullup from BIND 8:
1185.   [bug]           libbind: don't assume statp->_u._ext.ext is valid
                        unless RES_INIT is set when calling res_*init().

1184.   [bug]           libbind: call res_ndestroy() if RES_INIT is set
                        when res_*init() is called.
2002-01-23 02:34:14 +00:00
Andreas Gustafsson
413463f215 pullup:
wrong test to see if snprintf had a too small buffer.
2002-01-23 02:11:32 +00:00
Andreas Gustafsson
bc1268ea83 pullup:
leave isc_lex_destroy() to close any open streams.
2002-01-23 02:08:57 +00:00
Andreas Gustafsson
d8f67a1d88 pullup:
Fix RT #2309 differently, allowing rather than rejecting empty
 also-notify clauses
2002-01-23 02:05:42 +00:00
Andreas Gustafsson
b7f8bca629 regenerated 2002-01-23 01:55:38 +00:00
Andreas Gustafsson
8bb8f9c6c8 pullup:
initalise warning
initalise token
only print known token types.
2002-01-23 01:53:28 +00:00
Andreas Gustafsson
e6450a5811 regenerated 2002-01-23 01:50:23 +00:00
Andreas Gustafsson
d8b140ce00 pullup:
1172.   [doc]           Add CERT, GPOS, KX, NAPTR, NSAP, PX and TXT to
                        table of RR types in ARM.
2002-01-23 01:41:17 +00:00
Andreas Gustafsson
e47a6956a1 pullup:
1173.   [bug]           Potential memory leaks in isc_log_create() and
                        isc_log_settag(). [RT #2336]
2002-01-23 01:31:15 +00:00
Andreas Gustafsson
7366e9c47d pullup:
1174.   [bug]           Win32: add WSAECONNRESET to the expected errors
                        from connect(). [RT #2308]
2002-01-23 01:07:54 +00:00
Mark Andrews
a818127616 pullup: cut-and-paste-o:s 2002-01-23 00:11:14 +00:00
Mark Andrews
6e574a8b30 prepare for 9.2.1 2002-01-22 23:39:20 +00:00
Andreas Gustafsson
a7859ded82 1175. [bug] named-checkzone failed to call dns_result_register()
at startup which could result in runtime
                        exceptions when printing "out of memory" errors.
                        [RT #2335]
(The named-checkconf.c change was not pulled up; it is not applicable
to the 9.2 branch because the 9.2 named-checkconf.c does not link
with libdns)
2002-01-22 23:34:56 +00:00
Andreas Gustafsson
d7224e6672 pullup:
reference after free in error path.
2002-01-22 23:17:44 +00:00
Mark Andrews
2adafac25f Not applicable to 9.2 2002-01-22 23:15:59 +00:00
Andreas Gustafsson
057fc2ec3f pullup:
1165.   [bug]           We were rejecting notify-source{-v6} in zone clauses.
2002-01-22 23:14:45 +00:00
Andreas Gustafsson
80670d2633 pullup:
1164.   [bug]           Empty masters clauses in slave / stub zones were not
                        handled gracefully.  [RT #2262]
2002-01-22 22:51:05 +00:00
Mark Andrews
16a160ea8a pullup:
http://www.isc.org/ml-archives/
2002-01-22 06:50:48 +00:00
Mark Andrews
f132d4023a pullup:
Q: I have Freebsd 4.4 and "rndc-confgen -a" just sits there.
2002-01-22 06:43:58 +00:00
Mark Andrews
a50304c317 pullup:
1176.   [doc]           Document that allow-v6-synthesis is only performed
                        for clients that are supplied recursive service.
                        [RT #2260]
2002-01-22 06:16:25 +00:00
Mark Andrews
8ac220d5cc pullup:
1186.   [bug]           isc_hex_tobuffer(,,length = 0) failed to unget the
                        EOL token when reading to end of line.
2002-01-22 06:08:47 +00:00
Mark Andrews
3bc24a3a90 pullup:
Q: I get error messages like "multiple RRs of singleton type" and
"CNAME and other data" when transfering a zone.  What does this mean?
2002-01-22 05:21:51 +00:00
Mark Andrews
5ef63950cf pullup:
Q: Why is named listening on UDP port other than 53?
2002-01-22 05:16:11 +00:00
Mark Andrews
4f0ddc4fc1 pullup:
Mac OS X 10.1
2002-01-22 05:14:31 +00:00
Mark Andrews
f5ea135066 pullup:
Mention the need to run "make distclean" prior to re-configuring.
2002-01-22 05:11:17 +00:00
Mark Andrews
bedd38297c note that the command channel can be disabled using controls { }; 2002-01-22 05:09:40 +00:00
Mark Andrews
2bffec87ac pullup:
Out of date comment.
2002-01-22 05:00:30 +00:00
Mark Andrews
f9409b10fd pullup:
1152.   [bug]           libbind: read buffer overflows.
2002-01-22 04:15:45 +00:00
Mark Andrews
f10e90ebb4 1182. [bug] The server could throw an assertion failure when
constructing a negative response packet.
2002-01-21 22:27:03 +00:00
Mark Andrews
73442acbe7 rndc-keygen -> rndc-confgen [RT #2362] 2002-01-16 03:47:23 +00:00
Mark Andrews
4099c201ff whitespace cleanup 2001-12-19 01:29:35 +00:00
Mark Andrews
6cb12c44a3 pullup:
fix large DH key generation, hopefully for the last time.
2001-12-19 01:09:58 +00:00
Andreas Gustafsson
b31471255d pullup: correct Latin plural 2001-12-14 18:30:09 +00:00
Mark Andrews
7caf656a15 pullup:
1162.   [bug]           The allow-notify option was not accepted in slave
                        zone statements.
2001-12-13 06:50:59 +00:00
Mark Andrews
5fc932977a pullup:
check that allow-notify is only specified for slave zones
2001-12-13 06:47:48 +00:00
Brian Wellington
fefd6c28ab 1161. [bug] named-checkzone looped on unbalanced brackets.
[RT #2248]
2001-12-13 06:17:34 +00:00
Mark Andrews
6124a262fa pullup:
1160.   [bug]           Generating Diffie-Hellman keys longer than 1024
                        bits could fail. [RT #2241]
2001-12-12 17:05:20 +00:00
Mark Andrews
21b1491aa2 pullup:
1154.  [bug]           Don't attempt to obtain the netmask of a interface
                       if there is no address configured.  [RT #2176]
2001-12-12 00:16:47 +00:00
Mark Andrews
f3cee71ee5 regen 2001-12-05 02:30:08 +00:00
Mark Andrews
d25f6fac98 pullup:
1156.   [port]          The configure test for strsep() incorrectly
                        succeeded on certain patched versions of
                        AIX 4.3.3. [RT #2190]
2001-12-05 02:28:37 +00:00
Andreas Gustafsson
700847b76c spelling 2001-11-30 01:10:09 +00:00
Andreas Gustafsson
b90dc3fc6a regenerated 2001-11-29 22:56:39 +00:00
Andreas Gustafsson
6b53351ce2 pullup: clarified the meaning of * in an inet controls clause [RT #2073] 2001-11-29 22:55:52 +00:00
Andreas Gustafsson
4463c6f19e reference RT #2164 2001-11-29 18:34:23 +00:00
Andreas Gustafsson
fa85eab969 belated pullup:
125.   [bug]           rndc: -k option was missing from usage message.
                        [RT #2057]
2001-11-28 23:37:50 +00:00
Andreas Gustafsson
3a8943b2d2 regenerated 2001-11-28 23:35:49 +00:00
Andreas Gustafsson
790f33c772 belated pullup:
1124.   [doc]           dig: +[no]dnssec, +[no]besteffort and +[no]fail
                        now documented. [RT #2052]
2001-11-28 23:35:02 +00:00
Andreas Gustafsson
c9114f35c0 belated pullup:
1123.   [bug]           dig +[no]fail did not match description. [RT #2052]
2001-11-28 23:29:13 +00:00
Andreas Gustafsson
6c8ae8b9ef pullup:
1144.   [bug]           rndc-confgen would crash if both the -a and -t
                        options were specified. [RT #2159]
2001-11-28 21:51:51 +00:00
Mark Andrews
9dfa8979a7 The dig help message did not documents the -b, -k, and +noqr options,
and some options were less than logically grouped [RT #2151]
2001-11-28 04:35:14 +00:00
Mark Andrews
d486854a4a order 2001-11-28 02:52:25 +00:00
Mark Andrews
c14c7e14cd pullup:
1140.   [bug]           rndc-confgen did not accept IPv6 addresses as arguments
                        to the -s option. [RT #2138]
2001-11-28 01:58:18 +00:00
Andreas Gustafsson
ed37e8811a end sentence in period 2001-11-28 01:37:44 +00:00
Andreas Gustafsson
eacbf2cc01 pullup:
shutup bogus ambiguous else compiler warning.
2001-11-27 23:21:56 +00:00
Andreas Gustafsson
e8c4b14cde pullup:
1142.   [bug]           dnssec-signzone would fail to delete temporary files
                        in some failure cases. [RT #2144]
2001-11-27 22:41:49 +00:00
Andreas Gustafsson
72ad976640 pullup:
1141.   [bug]           When named rejected a control message, it would
                        leak a file descriptor and memory.  It would also
                        fail to respond, causing rndc to hang. [RT #2139]
2001-11-27 22:38:14 +00:00
Andreas Gustafsson
189dcca2c9 success on Debian GNU/Linux 2.2 and 3.0 reported by Bdale Garbee <bdale@gag.com> 2001-11-27 20:23:33 +00:00
Andreas Gustafsson
e15532f8c6 regenerated 2001-11-27 18:58:03 +00:00
Andreas Gustafsson
462b062d7f pullup: command example was missing TTL (reported in private email by Bdale Garbee <bdale@gag.com>) 2001-11-27 18:57:40 +00:00
Mark Andrews
0797eebc66 pullup:
1136.   [bug]           CNAME records synthesized from DNAMEs did not
                        have a TTL of zero as required by RFC2672
                        [RT #2129]
2001-11-27 00:43:06 +00:00
Andreas Gustafsson
8f4ecd4a9e updated for 9.2.0 (final) 2001-11-25 01:38:13 +00:00
Mark Andrews
402313b3db pullup:
1134.   [bug]           Multithreaded servers could deadlock in ferror()
                        when reloading zone files. [RT #1951, #1998]
2001-11-22 01:23:19 +00:00
Andreas Gustafsson
887c9d05c2 pullup:
1133.   [bug]           IN6_IS_ADDR_LOOPBACK was not portably defined on
                        platforms without IN6_IS_ADDR_LOOPBACK. [RT #2106]
2001-11-22 00:22:02 +00:00
Andreas Gustafsson
8733f0d86c include 1121. - 1131. in 9.2.0rc10; retag 2001-11-16 21:52:55 +00:00
Brian Wellington
25fd0feeea 1121. [bug] The server could attempt to access a NULL zone
table if shut down while resolving.
			[RT #1587, #2054]
2001-11-16 21:47:27 +00:00
Brian Wellington
04999a9c03 pullup:
1131.   [bug]           The match-destinations view option did not work with
                        IPv6 destinations. [RT #2073, #2074]
2001-11-16 21:21:42 +00:00
Andreas Gustafsson
1e1f1edb7d pullup:
130.   [bug]           Log messages reporting an out-of-range serial number
                        did not include the out-of-range number but the
                        following token. [RT #2076]
2001-11-16 19:00:37 +00:00
Mark Andrews
fefab489c7 pullup:
1129.   [bug]           Multithreaded servers could crash under heavy
                        resolution load due to a race condition. [RT #2018]
2001-11-16 11:04:38 +00:00
Mark Andrews
913e3def6d pullup:
extra text after #else
2001-11-15 06:21:38 +00:00
Mark Andrews
5b477dd3b9 1126. [bug] The server could access a freed event if shut
down while a client start event was pending
                        delivery. [RT #2061]
2001-11-15 02:51:46 +00:00
Mark Andrews
309979a136 pullup:
Removed all code within #ifdef DNS_OPT_NEWCODES*.
It was the last thing being sanitized out of releases; removing
it makes it possible to eliminate the sanitation process.
2001-11-15 01:24:21 +00:00
Mark Andrews
fc67f3e0e3 pullup:
Partial fix for RT #2053.  The potential for deadlock still exists,
but it is much less likely to occur because we now only take the ADB lock when
the
external reference count reaches zero, not every time it is decremented.
Althought this does not actually fix the bug, it at least lets us make
progress on testing fixes for other bugs affecting shutdown of multithreaded
servers.
2001-11-15 00:35:17 +00:00
Andreas Gustafsson
abbc8ed09b added FAQ about rndc attempting to use IPv6 2001-11-14 17:59:10 +00:00
Andreas Gustafsson
0258aea36c added --- 9.2.0rc10 released --- marker 2001-11-13 19:51:11 +00:00
Andreas Gustafsson
2ce3018081 consistent spacing; tabify 2001-11-13 19:07:03 +00:00
Andreas Gustafsson
b8b17a7732 regenerated 2001-11-13 19:04:20 +00:00
Andreas Gustafsson
ac81ee4d14 updated for 9.2.0rc10 2001-11-13 19:00:51 +00:00
Andreas Gustafsson
63d380e078 pullup:
1116.   [bug]           Setting transfers in a server clause, transfers-in,
                        or transfers-per-ns to a value greater than
                        2147483647 disabled transfers.  [RT #2002]
(Technically, this is an API change, but since it only changes the signedness of some
function parameters, it is still binary compatible in practice and I'll let it slip
by without bumping the major library version number)
2001-11-13 18:57:14 +00:00
Andreas Gustafsson
46879265d7 pullup:
1120.   [bug]           Errors in options were not fatal. [RT #2002]
2001-11-13 18:36:04 +00:00
Mark Andrews
29d7ef1bca cleanup allow-update-forwarding. 2001-11-13 02:52:10 +00:00
Andreas Gustafsson
80c7cf7e5d pullup:
1113.   [bug]           The allow-update-forwarding option was ignored
                        when specified in a view. [RT #2014]
2001-11-13 01:15:33 +00:00
Mark Andrews
be7d7a6638 pullup:
1118.   [bug]           On multithreaded servers, a race condition
                        could cause an assertion failure in resolver.c
                        during resolver shutdown. [RT #2029]
2001-11-12 22:37:05 +00:00
Mark Andrews
d0b2beb93d pullup:
1111.   [bug]           Multithreaded servers could deadlock processing
                        recursive queries due to a locking hieararchy
                        violation in adb.c. [RT #2017]
2001-11-12 22:28:30 +00:00
Mark Andrews
6358746e6f regen 2001-11-10 15:15:33 +00:00
Mark Andrews
4a2df0557c pullup:
1117.   [port]          The configure check for in6addr_loopback incorrectly
                        succeeded on AIX 4.3 when compiling with -O2
                        because the test code was optimized away.
                        [RT #2016]
2001-11-10 15:14:01 +00:00
Mark Andrews
014f9142bc pullup:
1114.   [port]          Ignore more accept() errors. [RT #2021]
2001-11-10 03:03:44 +00:00
Andreas Gustafsson
d76ac5ddfd pullup:
install soa.h
2001-11-09 23:17:17 +00:00
Andreas Gustafsson
b5c8773673 pullup:
theoretically potential file descriptor leak.
2001-11-09 20:21:41 +00:00
Andreas Gustafsson
3700c88538 regenerated 2001-11-08 00:15:41 +00:00
Andreas Gustafsson
8b672d6342 pullup:
note that the +[no]cmd option cannot be overridden on a per-query
> basis [RT #2004]
2001-11-08 00:15:23 +00:00
Andreas Gustafsson
15491d8b1f regenerated 2001-11-07 19:08:32 +00:00
Andreas Gustafsson
c529637d60 typo 2001-11-07 19:07:29 +00:00
Andreas Gustafsson
d35b058b31 include 1106. and 1107. in rc9 2001-11-07 01:02:14 +00:00
Andreas Gustafsson
364da4eb0f note that HP-UX 11.11 is not yet supported due to its incompatible SIOCGLIFCONF ioctl 2001-11-06 22:30:24 +00:00
Brian Wellington
26c8b645f8 pullup:
1107.   [bug]           nsupdate could catch an assertion failure if an
			invalid domain name was given as the argument to
			the "zone" command.
2001-11-06 21:50:35 +00:00
Andreas Gustafsson
d8c1b06854 pullup:
memory leaks on errors
2001-11-06 20:44:26 +00:00
Andreas Gustafsson
98c08f4dbe pullup:
1106.   [bug]           After seeing an out of range TTL, nsupdate would
                        treat all TTLs as out of range. [RT #2001]
2001-11-06 20:42:01 +00:00
Andreas Gustafsson
fb17fdbd0e pullup:
cvs rdiff -r1.89 -r1.90 bind9/lib/dns/sec/dst/dst_api.c
2001-11-06 19:24:08 +00:00
Andreas Gustafsson
19c189b7a3 miscellaneous corrections 2001-11-06 01:57:19 +00:00
Andreas Gustafsson
2cd386a02f typo 2001-11-06 01:40:06 +00:00
Andreas Gustafsson
d8389bdac5 "a number of bugs", not "a couple of bugs" 2001-11-05 23:48:46 +00:00
Andreas Gustafsson
abe885e016 regenerated 2001-11-05 23:47:05 +00:00
Andreas Gustafsson
d3d785705a split dns example comments confused master and slave;
text about 'mandatory to implement' algorithms made no sense
2001-11-05 23:46:21 +00:00
Andreas Gustafsson
ad923a3d6f regenerated 2001-11-05 23:25:11 +00:00
Mark Andrews
035ef37ffa pullup:
grammar summary output for named maps was missing the name field
2001-11-05 23:22:21 +00:00
Andreas Gustafsson
f38324fe6c typos 2001-11-05 22:56:49 +00:00
Andreas Gustafsson
67308c2197 regenerated 2001-11-05 22:54:41 +00:00
Andreas Gustafsson
93ca4b367d spelling 2001-11-05 22:50:03 +00:00
Andreas Gustafsson
bcf3845c01 include 1103-1104 in rc9 2001-11-05 22:00:48 +00:00
Brian Wellington
a0e8772150 pullup:
don't try to insert the nonexistent file lib/bind/COPYRIGHT into configure
2001-11-05 21:42:51 +00:00
Andreas Gustafsson
e81b4c677b regenerated 2001-11-05 21:28:35 +00:00
Brian Wellington
9476a30889 pullup:
1104.   [bug]           Invalid arguments to the transfer-format option
                        could cause an assertion failure. [RT #1995]
(+ don't say "'foo' unexpected near 'foo'" - once is enough)
2001-11-05 20:21:54 +00:00
Andreas Gustafsson
639fef047e pulled up latest FAQ list from mainline 2001-11-05 18:01:16 +00:00
Mark Andrews
ec5ff01338 1103. [port] OpenUNIX 8 support (ifconfig.sh). [RT #1970] 2001-11-05 04:29:35 +00:00
Andreas Gustafsson
c5f432d9c2 pullup:
typo in debug message [RT #1989]
2001-11-04 19:21:50 +00:00
Andreas Gustafsson
8dda8ff186 pullup:
1087.   [bug]           libbind: struct __res_state to large on 64 bit arch.
(including later fix known as change 1284 in BIND 8)
2001-11-03 00:21:34 +00:00
Andreas Gustafsson
adcfb59d04 regenerated 2001-11-02 22:54:18 +00:00
Andreas Gustafsson
75c43836c1 removed empty line as an excuse for making
another commit so that I can note that the commit message
of the previous commit should have been:
pullup:
silence compiler the same way
2001-11-02 22:31:14 +00:00
Andreas Gustafsson
7752f1112e pullup:
CHANGES lib/bind/dst/dst_api.c lib/bind/dst/support.c
trebuchet ~/9.2 $ cvs commit -mpullup:
2001-11-02 22:26:21 +00:00
Andreas Gustafsson
148fd45777 pullup:
1100.   [bug]           libbind: DNSSEC key ids were computed incorrectly.
2001-11-02 22:25:29 +00:00
Andreas Gustafsson
c7443ec439 pullup:
1099.   [cleanup]       libbind: defining REPORT_ERRORS in lib/bind/dst caused
                        compile time errors.
2001-11-02 21:38:18 +00:00
Andreas Gustafsson
2f65d19e93 pullup:
1098.   [bug]           libbind: HMAC-MD5 key files are now mode 0600.
2001-11-02 21:35:30 +00:00
Andreas Gustafsson
6cb735c864 pullup:
spelling and order
2001-11-02 21:32:52 +00:00
Andreas Gustafsson
ad7a535899 pullup:
1093.   [doc]           libbind: miscellaneous nroff fixes.
2001-11-02 21:06:16 +00:00
Andreas Gustafsson
84189fe5ad pullup:
1092.   [bug]           libbind: get*by*() failed to check if res_init() had
                        been called.
2001-11-02 20:55:24 +00:00
Andreas Gustafsson
b15ba3f20d pullup:
1091.   [bug]           libbind: misplaced va_end().
2001-11-02 20:45:32 +00:00
Andreas Gustafsson
a3a89d7c36 pullup:
1090.   [bug]           libbind: dns_ho.c:add_hostent() was not returning
                        the amount of memory consumed resulting in garbage
                        address being returned.  Alignment calculations were
                        wasting space.  We wern't suppressing duplicate
                        addresses.
2001-11-02 20:35:28 +00:00
Andreas Gustafsson
6c87ddb75d pullup:
1088.   [port]          libbind: MPE/iX C.70 (incomplete)
2001-11-02 20:12:58 +00:00
Andreas Gustafsson
aa224791dd pullup:
1086.   [port]          libbind: sunos: old sprintf.
2001-11-02 17:56:07 +00:00
Andreas Gustafsson
73865279b1 regenerated 2001-11-02 17:46:16 +00:00
Andreas Gustafsson
cad0e68589 pullup:
1085.   [port]          libbind: solaris: sys_nerr and sys_errlist do not
                        exist when compiling in 64 bit mode.
2001-11-02 17:45:31 +00:00
Andreas Gustafsson
513fe0ca30 regenerated 2001-11-02 02:20:35 +00:00
Andreas Gustafsson
a7757e30aa pullup:
1102.   [doc]           Note that query logging is enabled by directing the
                        queries category to a channel.
2001-11-02 02:16:48 +00:00
Andreas Gustafsson
540f27d8bc pullup:
1101.   [bug]           Array bounds read error in lwres_gai_strerror.
2001-11-02 01:32:53 +00:00
Mark Andrews
4e07f65d62 regen 2001-11-02 00:21:34 +00:00
Mark Andrews
c78ef9f491 pullup:
Deal with AIX defining in6addr_any but not in6addr_loopback
in libc, even though both are declared in <netinet/in.h>.  This caused
named to fail to link on AIX after change 1083, which introduced
the first actual use of in6addr_loopback.
2001-11-02 00:20:12 +00:00
Andreas Gustafsson
50d93bb5f8 pullup:
1084.   [cleanup]       libbind: gai_strerror() rewritten.
2001-11-01 19:00:47 +00:00
Mark Andrews
e301648774 pullup:
In several places, dighost.c called cancel_lookup() and then called
requeue_lookup() on the canceled lookup.  Because cancel_lookup()
resets the retry count of the lookup to zero, the requeued lookups
would not be retried at all (for example, in the case of UDP NS
queries executed when doing "dig +search") or, in the case of TCP
queries, retried indefinitely since the unsigned retry count of zero
was subsequently decremented, causing it to wrap around to the largest
unsigned integer value.
2001-10-31 23:04:26 +00:00
Mark Andrews
1260bf0573 pullup:
1083.   [bug]           The default control channel listened on the
                        wildcard adress, not the loopback as documented.
                        [RT #1975]
2001-10-31 23:00:44 +00:00
Mark Andrews
bdbaee5cfc pullup:
1082.  [bug]           The -g option to named incorrectly caused logging
                       to be sent to syslog in addition to stderr.
                       [RT #1974]
2001-10-31 22:44:15 +00:00
Andreas Gustafsson
8ced0871d2 regenerated 2001-10-30 20:30:56 +00:00
Andreas Gustafsson
6032e43f38 mark the memstatistics-file option as unimplemented (on 9.2
branch only, since it is implemented on the mainline) [RT #1972]
2001-10-30 20:30:33 +00:00
Andreas Gustafsson
219a694aca success reported for OpenUNIX 8 2001-10-30 18:22:21 +00:00
Andreas Gustafsson
3c76e82a76 pullup:
1078.  [bug]           We failed to correct bad tv_usec values in one case.
                       [RT #1966]
2001-10-30 17:57:52 +00:00
Andreas Gustafsson
6a1e7c8565 updated for 9.2.0rc9 2001-10-30 02:14:10 +00:00
Mark Andrews
5e8d4ff0bf pullup:
1074.   [bug]           Running out of memory in dump_rdataset() could
                        cause an assertion failure. [RT #1946]
2001-10-30 01:57:16 +00:00
Mark Andrews
e169fd331c pullup:
AXFRs were misidentified as AXFR-style IXFRs in log messages
2001-10-30 01:28:29 +00:00
Mark Andrews
58fbc62a4a pullup:
running out of memory during ns_client_t construction could crash server
[RT #409]
2001-10-30 01:12:34 +00:00
Andreas Gustafsson
a504607ef1 pullup:
1076.   [bug]           A badly defined global key could trigger an assertion
                        on load/reload if views were used. [RT #1947]
2001-10-29 20:18:48 +00:00
Mark Andrews
74ceb7b203 1075. [bug] Out-of-range network prefix lengths were not
reported. [RT #1954]
2001-10-28 22:48:33 +00:00
Andreas Gustafsson
449733f214 note that the localhost and localnets ACLs do not currently support IPv6 2001-10-24 23:00:51 +00:00
Andreas Gustafsson
94f960b541 added --- 9.2.0rc8 released --- marker 2001-10-23 17:21:27 +00:00
Andreas Gustafsson
381f821556 updated for 9.2.0rc8 2001-10-23 17:06:33 +00:00
Mark Andrews
3a0f5543c9 pullup:
some variables that should have been static weren't
2001-10-23 02:42:00 +00:00
Mark Andrews
8153dde6c8 pullup:
eliminated race condition in water() [RT #1932]
2001-10-23 01:31:08 +00:00
Andreas Gustafsson
fa52840ac8 pullup: silence compiler warning 2001-10-22 23:52:19 +00:00
Andreas Gustafsson
85939fa773 regenerated 2001-10-22 23:36:00 +00:00
Andreas Gustafsson
5a78ccdf1f pullup:
1068.   [bug]           errno could be overwritten by catgets(). [RT #1921]
1066.   [bug]           Provide a thread safe wrapper for strerror().
                        [RT #1689]
(Also some changes to configure.in, config.h.in, and acconfig.h that were
necessary to allow config.h.in to be correctly regenerated with the
HAVE_STRERROR definition needed by 1066.)
2001-10-22 23:28:26 +00:00
Andreas Gustafsson
7209c50da4 pullup:
1064.   [bug]           Do not shut down active network interfaces if we
                        are unable to scan the interface list. [RT #1921]
2001-10-22 17:42:05 +00:00
Andreas Gustafsson
0ae6a5f852 pullup:
1063.   [bug]           libbind: "make install" was failing on IRIX.
(lib/bind/port/irix/include/paths.h was pulled up by tagging)
2001-10-22 17:00:49 +00:00
Brian Wellington
e94a2fdd30 pullup:
1062.	[bug]		If the control channel listener socket was shut
			down before server exit, the listener object could
			be freed twice. [RT #1916]
2001-10-19 22:29:08 +00:00
Mark Andrews
2ef5add037 remove EXCLUDED when kitting. 2001-10-19 01:23:23 +00:00
Mark Andrews
bada421314 Initial file (empty). 2001-10-19 01:22:27 +00:00
Mark Andrews
c65bd9be83 pullup:
1061.   [bug]           If periodic cache cleaning happened to start
                        while cleaning due to reaching the configured
                        maximum cache size was in progress, the server
                        could catch an assertion failure. [RT #1912]
2001-10-19 00:22:26 +00:00
Mark Andrews
7a89c23c2d 1057. [bug] Reloading the server after adding a "file" clause
to a zone statement could cause the server to
                        crash due to a typo in change 1016.
2001-10-18 00:35:20 +00:00
Andreas Gustafsson
6ca3f52bee pullup:
1056.   [bug]           Rndc could catch an assertion failure on SIGINT due
                        to an uninitialized variable. [RT #1908]
2001-10-17 18:26:01 +00:00
Andreas Gustafsson
c535e67633 include 1054. in 9.2.0rc7 2001-10-16 18:54:41 +00:00
Andreas Gustafsson
05cd9da1d8 consistently refer to Windows NT / 2000 systems as Win32 2001-10-16 18:54:07 +00:00
Mark Andrews
ec95dac291 pullup:
1054.   [bug]           winnt: cfg_categories and cfg_modules need to be
                        visible outside of the libisccfg DLL.
2001-10-16 05:58:29 +00:00
Andreas Gustafsson
3b3d01b318 added --- 9.2.0rc7 released --- marker 2001-10-15 23:09:16 +00:00
Brian Wellington
0e71bf20df pullup:
1053.   [bug]           Dig did not increase its timeout when receiving
                        AXFRs unless the +time option was used. [RT #1904]
2001-10-15 23:06:07 +00:00
Andreas Gustafsson
106423c056 regenerated 2001-10-15 21:58:57 +00:00
Andreas Gustafsson
6812f56fa2 pullup:
mention [filename] in the help.
2001-10-15 20:25:57 +00:00
Andreas Gustafsson
f3c187e0c7 pullup: check-zone -> named-checkzone (from Jinmei) 2001-10-15 18:21:25 +00:00
Andreas Gustafsson
fe6a60a7c3 consistent spacing 2001-10-15 17:10:14 +00:00
Mark Andrews
a1a06d7854 pullup:
1052.  [bug]           Journals were not being created in binary mode
                       resulting in "journal format not recognized" error
                       under Windows NT/2000.  [RT #1889]
2001-10-15 04:57:51 +00:00
Mark Andrews
7ce9f2dbe8 pullup:
1051.   [bug]           Do not ignore a network interface completely just
                        because it has a noncontiguous netmask.  Instead,
                        omit it from the localnets ACL and issue a warning.
                        [RT #1891]
2001-10-13 03:56:44 +00:00
Mark Andrews
267d8eb613 pullup:
1050.  [bug]           Log messages reporting malformed IP addresses in
                       address lists such as that of the forwarders option
                       failed to include the correct error code, file
                       name, and line number. [RT #1890]
2001-10-13 03:52:13 +00:00
Andreas Gustafsson
e31320a1d0 updated for 9.2.0rc7 2001-10-12 23:34:24 +00:00
Andreas Gustafsson
5cb1e19b03 pullup:
don't assume perl is in the path
2001-10-12 20:12:07 +00:00
Andreas Gustafsson
23b81eeddd pullup:
the tkey test would randomly fail due to key IDs with a leading
zero being interpreted as octal numbers
2001-10-12 20:11:43 +00:00
Andreas Gustafsson
31da643c6a pullup:
1033.   [bug]           Always respond to requests with an unsupported opcode
                        with NOTIMP, even if we don't have a matching view
                        or cannot determine the class.
2001-10-12 19:14:47 +00:00
Andreas Gustafsson
dd0319d149 1047. [bug] named was incorrectly refusing all requests signed
with a TSIG key derived from an unsigned TKEY
                        negotiation with a NOERROR response. [RT #1886]
2001-10-12 18:20:14 +00:00
Andreas Gustafsson
315eafec07 pullup:
1039.   [bug]           Negative responses with CNAMEs in the answer section
                        were cached incorrectly. [RT #1862]
2001-10-12 17:49:41 +00:00
Mark Andrews
a4fbe403e4 pullup:
1048.   [bug]           Servers built with -DISC_MEM_USE_INTERNAL_MALLOC=1
                        didn't work.
2001-10-12 01:17:37 +00:00
Mark Andrews
a3ed377607 pullup:
1047.   [bug]           When a request was refused due to being signed with
                        a TSIG key derived from an unsigned TKEY negotiation,
                        the response could have an rcode of SUCCESS rather
                        than REFUSED. [RT #1886]
2001-10-12 01:05:51 +00:00
Andreas Gustafsson
29ca9003a5 use "oldconfig", not "_placeholder" as the name of the
obsolete DNS_LOGCATEGORY_CONFIG logging category, to lessen confusion in
case someone links a 9.2.0-pre-rc7 binary against an rc7 or newer shared
library
2001-10-11 23:07:00 +00:00
Andreas Gustafsson
85532057dc regenerated 2001-10-11 17:45:49 +00:00
Andreas Gustafsson
86457878fd pullup:
1046.   [bug]           The help message for the --with-openssl configure
                        option was inaccurate. [RT #1880]
2001-10-11 17:45:35 +00:00
Andreas Gustafsson
7779b6cbf6 pullup:
1045.   [bug]           It was possible to skip saving glue for a nameserver
                        for a stub zone.
2001-10-11 17:20:40 +00:00
Andreas Gustafsson
ac5c31df78 1044. [bug] Specifying allow-transfer, notify-source, or
notify-source-v6 in a stub zone was not treated
                        as an error.
2001-10-11 17:19:40 +00:00
Andreas Gustafsson
e370391b5e pullup:
1044.   [bug]           Specifying allow-transfer, notify-source, or
                        notify-source-v6 in a stub zone was not treated
                        as an error.
2001-10-11 17:12:42 +00:00
Mark Andrews
329fd2fe75 pullup:
1043.   [bug]           Specifying a transfer-source or transfer-source-v6
                        option in the zone statement for a master zone was
                        not treated as an error. [RT #1876]
2001-10-11 03:31:04 +00:00
Mark Andrews
8002894e6e pullup:
1042.   [bug]           The "config" logging category did not work properly.
                        [RT #1873]
2001-10-11 02:03:23 +00:00
Mark Andrews
890db7ab7d 1041. [bug] Dig/host/nslookup could catch an assertion failure
on SIGINT due to an uninitialized variable. [RT #1867]
2001-10-11 01:35:37 +00:00
Mark Andrews
9e3fe84689 pullup:
1040.   [bug]           Multiple listen-on-v6 options with different ports
                        were not accepted. [RT #1875]
2001-10-11 01:20:31 +00:00
Andreas Gustafsson
f6bcdffe6d Q: Why don't my zones reload when I do an "rndc reload" or SIGHUP? 2001-10-10 23:25:55 +00:00
Andreas Gustafsson
55ab8cebff qualify 1038. 2001-10-09 23:08:30 +00:00
Andreas Gustafsson
ae62248c8a pullup:
1038.   [bug]           TKEY queries with an owner name other than the root
                        could cause an assertion failure. [RT #1866, #1869]
2001-10-09 23:06:57 +00:00
Andreas Gustafsson
96bc10707a pullup:
on plaforms with no gettimeofday(), use struct _TIMEZONE instead of
struct timezone
2001-10-09 00:51:07 +00:00
Andreas Gustafsson
c7302ffd98 pullup:
1031.   [bug]           libbind.a: isc__gettimeofday() infinite recursion.
                        [RT #1858]
2001-10-08 18:10:57 +00:00
Andreas Gustafsson
1d19dc5411 added --- 9.2.0rc6 released --- marker 2001-10-05 23:04:04 +00:00
Brian Wellington
818d9fec02 pullup:
Improve error messages printed by dnssec tools when compiled
without crypto support (patch from Olafur)
2001-10-05 00:21:48 +00:00
Brian Wellington
41ea62ace5 pullup:
1030.   [bug]           On systems with no resolv.conf file, nsupdate
			exited with an error rather than defaulting
			to using the loopback address. [RT #1836]
2001-10-05 00:17:08 +00:00
Andreas Gustafsson
a325a8cbed pullup:
make prototype of get_reverse() match the code
2001-10-04 22:21:45 +00:00
Andreas Gustafsson
e17d517a93 pullup:
1028.   [bug]           On Win32, dig/host/nslookup looked for resolv.conf
                        in the wrong directory. [RT #1833]
2001-10-04 22:05:30 +00:00
Andreas Gustafsson
f5b3693207 pullup:
1029.   [bug]           Some named.conf errors did not cause the loading
                        of the configuration file to return a failure
                        status even though they were logged. [RT #1847]
2001-10-04 21:32:29 +00:00
Andreas Gustafsson
2616068121 1026. [port] Recognize OpenUNIX 8 in config.guess. [RT #1830]
(9.2 branch only, fixed by upgrading config.guess on mainline)
(commit on the right branch this time)
2001-10-04 20:59:03 +00:00
Andreas Gustafsson
4e9291c48b pullup:
the wrong result code was checked [RT #1847]
2001-10-04 19:43:06 +00:00
Andreas Gustafsson
07aa5a2c61 updated for 9.2.0rc6 2001-10-03 23:24:01 +00:00
Andreas Gustafsson
1550dcfff2 1027. [bug] RRs having the reserved type 0 should be rejected.
[RT #1471]
2001-10-03 22:49:00 +00:00
Andreas Gustafsson
b8e65dbc1e 1026. [port] Recognize OpenUNIX 8 in config.guess. [RT #1830]
(9.2 branch only, fixed by upgrading config.guess on mainline)
2001-10-03 22:48:38 +00:00
Andreas Gustafsson
a1d2958b24 pullup:
1022.   [bug]           Don't report empty root hints as "extra data".
                        [RT #1802]
2001-10-03 22:31:19 +00:00
Andreas Gustafsson
de32eba8a8 unverified report of success on OpenBSD 2.9 2001-10-03 17:27:01 +00:00
Mark Andrews
8f534756ca Disallow creation of TYPE0 records from wire data 2001-10-03 02:07:34 +00:00
Mark Andrews
2d4f039432 Disallow creation of TYPE0 records from master files, since the server
reserves type 0 for internal purposes related to negative caching
2001-10-03 02:05:25 +00:00
Andreas Gustafsson
23438327a1 added BSD/OS 4.2 to list of unverified reports of success (from Jim) 2001-10-01 23:21:47 +00:00
Andreas Gustafsson
064fadaa40 pullup:
added bind9->win2k zone transfer failure FAQ
2001-10-01 22:00:50 +00:00
Andreas Gustafsson
1ebadd777b pullup:
1021.   [bug]           On Win32, log message timestamps were one month
                        later than they should have been, and the server
                        would exhibit unspecified behavior in December.
2001-10-01 01:42:38 +00:00
Andreas Gustafsson
febc2e8db5 added --- 9.2.0rc5 released --- marker 2001-09-29 18:26:41 +00:00
Andreas Gustafsson
90787e192c and and 2001-09-29 17:43:42 +00:00
Andreas Gustafsson
4f3d12c632 clarified 1002. 2001-09-29 17:36:23 +00:00
Andreas Gustafsson
4748473739 the word "argument" was misspelled in several places 2001-09-29 00:15:05 +00:00
Brian Wellington
d65168b7a7 pullup:
1020.	[bug]		IXFR log messages did not distinguish between
			true IXFRs, AXFR-style IXFRs, and and mere
			version polls. [RT #1811]
2001-09-28 22:07:12 +00:00
Andreas Gustafsson
7c91a38c54 updated for 9.2.0rc5 2001-09-28 21:42:15 +00:00
Brian Wellington
4b09cca4b9 pullup:
1018.   [bug]           The default log channel was not always initialized
                        correctly. [RT #1813]
2001-09-28 18:35:02 +00:00
Mark Andrews
a4e8b19b83 1019. [bug] The value of the lame-ttl option was limited to 18000
seconds, not 1800 seconds as documented. [RT #1803]
2001-09-28 05:35:47 +00:00
Andreas Gustafsson
041153229d pullup:
1017.   [bug]           When specifying TSIG keys to dig and nsupdate using
                        the -k option, they must be HMAC-MD5 keys.  [RT #1810]
2001-09-27 23:30:49 +00:00
Andreas Gustafsson
c3312fd9d0 pullup:
dns_tsigkey_createfromkey wasn't checking that the key algorithm matched the
key name.
2001-09-27 23:17:10 +00:00
Andreas Gustafsson
538bbefb23 pullup:
clarified the connection between DNSSEC, crypto support,
and OpenSSL [RT #1805]
2001-09-27 01:13:35 +00:00
Mark Andrews
3f4c95eb98 SunOS 5.6 portability 2001-09-27 00:44:26 +00:00
Mark Andrews
d30fcb907b 1016. [bug] Slave zones with no backup file were re-transferred
on every server reload.
2001-09-26 03:43:00 +00:00
Mark Andrews
d924384f72 1015. [bug] Log channels that had a "versions" option but no
"size" option failed to create numbered log
                       files. [RT #1783]
2001-09-26 02:52:09 +00:00
Andreas Gustafsson
4632c084a6 missing comma in last pullup [RT #1780] 2001-09-21 23:18:45 +00:00
Andreas Gustafsson
43022c8c8f added --- 9.2.0rc4 released --- marker 2001-09-21 22:17:50 +00:00
Andreas Gustafsson
1d89523b69 pullup:
1000.   [bug]           BIND 8 compatibility: accept "HESIOD" as a alias
                        for class "HS".  [RT #1759]
2001-09-21 20:46:35 +00:00
Andreas Gustafsson
4fdcaf0cc7 redo pullup:
1013.   [bug]           It was possible to cancel a query twice when marking
                        a server as bogus or by having a blackhole acl.
                        [RT #1776]
2001-09-21 20:40:06 +00:00
Andreas Gustafsson
7e470ba93b oops, previous commit included other stuff in addition to the
intended pullup; reverting it
2001-09-21 20:37:09 +00:00
Andreas Gustafsson
a9617effd0 pullup:
1002.   [bug]           Log unknown class including file and line.  [RT #1759]
2001-09-21 20:30:32 +00:00
Andreas Gustafsson
1716d085b1 updated for 9.2.0rc4 2001-09-21 20:27:46 +00:00
Andreas Gustafsson
f0f9aa979b pullup:
1013.   [bug]           It was possible to cancel a query twice when marking
                        a server as bogus or by having a blackhole acl.
                        [RT #1776]
2001-09-21 18:50:46 +00:00
Andreas Gustafsson
0617eaff38 pulled up 2001-09-21 17:49:58 +00:00
Mark Andrews
9cdfffc7ce pullup:
controls->shuttingdown should not be set on server reload.
2001-09-21 03:31:17 +00:00
Mark Andrews
b21236d838 redo #1010 2001-09-21 00:28:58 +00:00
Mark Andrews
7a74126eb8 undo 2001-09-21 00:28:05 +00:00
Mark Andrews
9f89b34f4d pullup:
1010.   [bug]           The server could attempt to execute a command channel
                        command after initiating server shutdown, causing
                        an assertion failure. [RT #1766]
2001-09-20 23:01:44 +00:00
Andreas Gustafsson
66ed65d1b7 regenerated 2001-09-19 22:18:24 +00:00
Andreas Gustafsson
dea6647faa pullup: document the global provide-ixfr and request-ixfr options [RT #1772] 2001-09-19 22:16:57 +00:00
Brian Wellington
a25169ea43 pullup:
1006.   [bug]           If a KEY RR was found missing during DNSSEC validation,
			an assertion failure could subsequently be triggered
			in the resolver. [RT #1763]
2001-09-19 21:51:42 +00:00
Mark Andrews
99a0822e3c pullup:
1005.   [bug]           Don't copy nonzero RCODEs from request to response.
                        [RT #1765]
2001-09-19 02:44:00 +00:00
Mark Andrews
5e8c385e64 pullup:
1004.  [port]          Deal with recvfrom() returning EHOSTDOWN. [RT #1770]
2001-09-19 02:37:21 +00:00
Andreas Gustafsson
0375d5da0c pullup:
'dig +short' should explicitly enable printing the answer section.
Otherwise, 'dig +noall +short' prints nothing.
2001-09-18 01:04:05 +00:00
Andreas Gustafsson
94c8b1aa0f pullup:
doio_recv was not catching a ECONNRESET error. Fixed this and added code to catch other possible errors. Miscellaneous errno handling cleanup [RT #1745]
2001-09-17 22:28:57 +00:00
Andreas Gustafsson
2fddd0b746 use ifconfig.sh up, not ifconfig.sh start, to be
consistent with the ifconfig.sh usage message [RT #1758]
2001-09-17 21:43:09 +00:00
Andreas Gustafsson
b40cb80704 pulled up Brian's latest FAQ fixes 2001-09-17 20:41:34 +00:00
Andreas Gustafsson
62f58f434c note that ifconfig.sh must be run as root 2001-09-17 20:34:28 +00:00
Andreas Gustafsson
b2eeaf6500 pull up part of 997.:
ISC_R_SUCCESS could be returned on failure
2001-09-15 00:37:18 +00:00
Andreas Gustafsson
8be3f42f6b it's contrib/linux/coredump-patch, not bind9/linux/coredump-patch 2001-09-14 21:23:29 +00:00
Andreas Gustafsson
63fe5ccb87 regenerated 2001-09-14 20:29:50 +00:00
Andreas Gustafsson
be2d2c1599 pullup:
replaced 'List the keys included in the keyset file' by
'The list of keys to be included in the keyset file', as
suggested by <Jason.Fountain@compaq.com>
2001-09-14 20:29:32 +00:00
Andreas Gustafsson
f8baa72034 updated for 9.2.0rc3 2001-09-12 21:11:27 +00:00
Andreas Gustafsson
5de2109e1c pullup:
A message could be leaked when a segment of an incoming zone transfer
failed to verify.
2001-09-12 20:44:04 +00:00
Andreas Gustafsson
67adc92106 pullup:
fix a memory leak on a tsig error condition.
2001-09-12 00:15:11 +00:00
Andreas Gustafsson
625aae0fba this should have a CHANGES entry since several people reported it:
990.   [bug]           The rndc-confgen man page was not installed.
2001-09-11 23:40:32 +00:00
Andreas Gustafsson
1015c4cdea pullup:
989.   [bug]           Report filename if $INCLUDE fails for file related
                        errors. [RT #1736]
2001-09-11 23:32:55 +00:00
Andreas Gustafsson
c54833a8e9 pullup:
987.   [bug]           "dig -help" didn't show "+[no]stats".

 986.   [bug]           "dig +noall" failed to clear stats and command
                        printing.
2001-09-11 01:37:48 +00:00
Andreas Gustafsson
976dd45973 pullup:
compare: a REQUIRE() was comparing a variable against itself not agaist the
other arguement as it should have been.
2001-09-11 01:09:07 +00:00
Andreas Gustafsson
783cf0d73d 984. [bug] Multithreading should be enabled by default on
Solaris 2.7 and newer, but it wasn't.
2001-09-10 19:44:50 +00:00
Andreas Gustafsson
928d42e559 regenerated 2001-09-10 18:59:41 +00:00
Andreas Gustafsson
deb2c2ffab pullup:
It's *solaris2.x* not *solaris-2.x*
2001-09-10 18:59:31 +00:00
Andreas Gustafsson
0363b921c9 pullup:
install rndc-confgen.8
2001-09-07 16:46:11 +00:00
Mark Andrews
ae35d154ce pullup:
host-statistics is not implemented,
maintain-ixfr-base is obsolete [RT #1717]
2001-09-06 23:06:43 +00:00
Andreas Gustafsson
d5dbfd6f17 tabified 2001-09-06 17:04:04 +00:00
Andreas Gustafsson
ad8c0c65aa 980. will be in 9.2.0rc2 2001-09-06 17:03:46 +00:00
Mark Andrews
42b48b7156 pullup:
Added Warning Note regarding resolv.conf file
2001-09-06 05:31:02 +00:00
Mark Andrews
c9c55707eb pullup:
Added macro to suppress warning dependencies message
2001-09-06 05:29:01 +00:00
Mark Andrews
2958e100b5 check return value of strftime() 2001-09-06 00:34:06 +00:00
Mark Andrews
aa6e560fbd 980. [bug] Incoming zone transfers restarting after an error
could trigger an assertion failure. [RT #1692]
2001-09-06 00:23:19 +00:00
Andreas Gustafsson
3f538ef15c pullup:
[RT #1709]
Change isc_entropy_usebestsource() to have saner semantics:
 - If an invalid file is specified, an error will be returned instead of the
   keyboard being used.
 - If no file is specified but a random device is present, the keyboard will
   be used if there is an error opening the random device.
 - ISC_ENTROPY_KEYBOARDYES indicates that the keyboard should be the
   only device used.  Otherwise, passing '-r keyboard' is meaningless
   on a machine with a random device, since the keyboard will not be used.

Change the callers in the dnssec tools and rndc-confgen to check for the
special file "keyboard" and call isc_entropy_usebestsource() with the right set
of parameters.
2001-09-06 00:14:18 +00:00
Andreas Gustafsson
f58f6043ce pullup:
Assertion failure when ISC_MEM_DEBUGRECORD set.
2001-09-05 17:51:13 +00:00
Andreas Gustafsson
f17bffa68d pullup:
isc_time_formattimestamp() created static const for bad time string
2001-09-05 17:32:05 +00:00
Andreas Gustafsson
b1436346a0 pullup:
isc_file_getmodtime() does not need write access to file
2001-09-05 17:29:25 +00:00
Andreas Gustafsson
fdd3a3e7fa pullup:
needs #include <isc/print.h>
2001-09-05 17:04:43 +00:00
Andreas Gustafsson
d73ed70241 capitalize 2001-09-05 01:00:32 +00:00
Andreas Gustafsson
aa8953a586 added --- 9.2.0rc2 released --- marker 2001-09-05 00:59:45 +00:00
Andreas Gustafsson
caaa091d76 regenerated 2001-09-05 00:57:37 +00:00
Andreas Gustafsson
f5c726cbef typo 2001-09-05 00:56:38 +00:00
Andreas Gustafsson
b7d04c63c0 updated for 9.2.0rc2 2001-09-05 00:39:28 +00:00
Andreas Gustafsson
7ee450d5f6 pullup:
972.   [bug]           The file modification time code in zone.c was using the
                        wrong epoch.  [RT #1667]
(This pullup includes not only the changes to zone.c, but all the
recent epoch-related fixes)
2001-09-05 00:38:13 +00:00
Andreas Gustafsson
641e33bdd4 pullup:
978.   [bug]           dns_db_attachversion() had an invalid REQUIRE()
                        condition.
2001-09-04 23:09:33 +00:00
Andreas Gustafsson
faedfb6dce pullup:
Previous update was missing the release version of telling how to build the
resource file [RT #1668]
2001-09-04 22:54:59 +00:00
Andreas Gustafsson
89227c76be pullup:
977.   [bug]           Improve "not at top of zone" error message.
2001-09-04 22:51:41 +00:00
Andreas Gustafsson
f6fc4b1391 pullup:
updated to properly support shutdowns.  See RT #1672 as it relates to NT
2001-09-04 19:40:20 +00:00
Andreas Gustafsson
44caf20759 <named/types.h> needed for interfacemgr type declaration 2001-09-04 19:38:46 +00:00
Andreas Gustafsson
e5094285ce pullup:
Update to change path to resolv.conf and define RESOLV_CONF
2001-09-04 19:36:33 +00:00
Andreas Gustafsson
15fd491c85 pullup:
Changed RESOLV_CONF to be conditionally defined allowing win32 to override this definition
2001-09-04 19:35:49 +00:00
Andreas Gustafsson
2c141ce0fb pullup:
975.   [bug]           "max-cache-size default;" as a view option
                        caused an assertion failure.

 974.   [bug]           "max-cahe-size unlimited;" as a global option
                        was not accepted.
2001-09-04 19:15:36 +00:00
Andreas Gustafsson
9113f8b75c pullup: string formats 2001-08-31 18:01:22 +00:00
Mark Andrews
ac9d955cdd pullup:
The request object would fail to send its completion event when
the control event was delivered if a response was received between
sending and delivery of the completion event [RT #1676]
Fix locking hierarchy violation [RT #1672]
2001-08-31 02:07:11 +00:00
Andreas Gustafsson
54706e9e57 pullup:
973.   [bug]           Failed to log the question name when logging:
                        "bad zone transfer request: non-authoritative zone
                        (NOTAUTH)".
2001-08-31 00:37:12 +00:00
Andreas Gustafsson
6aa1a89bf1 pullup:
RT #1675 resolv.conf was specified to be in an invalid directory.
Location was changed to be in the same etc directory as all of the other
configuration files
2001-08-30 20:29:53 +00:00
Andreas Gustafsson
31d635e582 pullup:
Remove shutdown privilege-enabling code. Installer should not be shutting down the system.
2001-08-30 20:27:55 +00:00
cvs2git
02da396800 This commit was manufactured by cvs2git to create branch 'v9_2'. 2001-08-30 04:33:21 +00:00
756 changed files with 39794 additions and 45924 deletions

487
CHANGES
View File

@@ -1,3 +1,109 @@
--- 9.2.1 released ---
1271. [port] win32: a make file contained absolute version specific
references.
1269. [bug] Missing masters clause was not handled gracefully.
[RT #2703]
1244. [bug] Receiving a TCP message from a blackhole address would
prevent further messages being received over that
interface.
1178. [bug] Follow and cache (if appropriate) A6 and other
data chains to completion in the additional section.
--- 9.2.1rc2 released ---
1240. [bug] It was possible to leak zone references by
specifying an incorrect zone to rndc.
1239. [bug] Under certain circumstances named could continue to
use a name after it had been freed triggering
INSIST() failures. [RT #2614]
1238. [bug] It is possible to lockup the server when shutting down
if notifies are being processed. [RT #2591]
1237. [bug] nslookup: "set q=type" failed.
1236. [bug] dns_rdata{class,type}_fromtext() didn't handle non
NULL terminated text regions. [RT #2588]
1232. [bug] unix/errno2result() didn't handle EADDRNOTAVAIL.
1231. [port] HPUX 11.11 recvmsg() can return spurious EADDRNOTAVAIL.
1230. [bug] isccc_cc_isreply() and isccc_cc_isack() were broken.
1229. [bug] named would crash if it received a TSIG signed
query as part of an AXFR response. [RT #2570]
1228. [bug] 'make install' did not depend on 'make all'. [RT #2559]
1227. [bug] dns_lex_getmastertoken() now returns ISC_R_BADNUMBER
if a number was expected and some other token was
found. [RT#2532]
1222. [bug] Specifying 'port *' did not always result in a system
selected (non-reserved) port being used. [RT #2537]
1221. [bug] Zone types 'master', 'slave' and 'stub' were not being
compared case insensitively. [RT #2542]
1218. [bug] Named incorrectly returned SERVFAIL rather than
NOTAUTH when there was a TSIG BADTIME error. [RT #2519]
1216. [bug] Multiple server clauses for the same server were not
reported. [RT #2514]
1215. [port] solaris: add support to ifconfig.sh for x86 2.5.1
1214. [bug] Win32: isc_file_renameunique() could leave zero length
files behind.
1212. [port] libbind: 64k answer buffers were causing stack space
to be exceeded for certian OS. Use heap space instead.
1211. [bug] dns_name_fromtext() incorrectly handled certain
valid octal bitlabels. [RT #2483]
1210. [bug] libbind: getnameinfo() failed to lookup IPv4 mapped /
compatible addresses. [RT #2461]
1208. [bug] dns_master_load*() failed to log a error message if
an error was detected when parsing the ownername of
a record. [RT #2448]
--- 9.2.1rc1 released ---
1207. [bug] libbind: getaddrinfo() could call freeaddrinfo() with
an invalid pointer.
1206. [bug] SERVFAIL and NOTIMP responses to an EDNS query should
trigger a non-EDNS retry.
1205. [bug] OPT, TSIG and TKEY cannot be used to set the "class"
of the message. [RT #2449]
1204. [bug] libbind: res_nupdate() failed to update the name
server addresses before sending the update.
1201. [bug] Require that if 'callbacks' is passed to
dns_rdata_fromtext(), callbacks->error and
callbacks->warn are initialized.
1200. [bug] Log 'errno' that we are unable to convert to
isc_result_t. [RT #2404]
1198. [bug] OPT printing style was not consistant with the way the
header fields are printed. The DO bit was not reported
if set. Report if any of the MBZ bits are set.
1197. [bug] Attempts to define the same acl multiple times were not
detected.
1196. [contrib] update mdnkit to 2.2.3.
1195. [bug] Attempts to redefine builtin acls should be caught.
@@ -8,16 +114,9 @@
1193. [bug] Best effort parsing didn't handle packet truncation.
1192. [bug] The seconds fields in LOC records were restricted
to three decimal places. More decimal places should
be allowed and silently truncated.
1191. [bug] A dynamic update removing the last non-apex name in
1191. [bug] A dynamic update removing the last non-apex name in
a secure zone would fail. [RT #2399]
1190. [func] Add the "rndc freeze" and "rndc unfreeze" commands.
[RT #2394]
1189. [bug] On some systems, malloc(0) returns NULL, which
could cause the caller to report an out of memory
error. [RT #2398]
@@ -25,11 +124,8 @@
1188. [bug] Dynamic updates of a signed zone would fail if
some of the zone private keys were unavailable.
1187. [bug] named was incorrectly returning DNSSEC records
in negative responses when the DO bit was not set.
1186. [bug] isc_hex_tobuffer(,,length = 0) failed to unget the
EOL token when reading to end of line.
1186. [bug] isc_hex_tobuffer(,,length = 0) failed to unget the
EOL token when reading to end of line.
1185. [bug] libbind: don't assume statp->_u._ext.ext is valid
unless RES_INIT is set when calling res_*init().
@@ -43,30 +139,14 @@
1182. [bug] The server could throw an assertion failure when
constructing a negative response packet.
1181. [func] Add the "key-directory" configuration statement,
which allows the server to look for online signing
keys in alternate directories.
1180. [func] dnssec-keygen should always generate keys with
protocol 3 (DNSSEC), since it's less confusing
that way.
1179. [func] Add SIG(0) support to nsupdate.
1178. [func] Follow and cache (if appropriate) A6 and other
data chains to completion in the additional section.
1177. [func] Report view when loading zones if it is not a
standard view (_default or _bind). [RT #2270]
1176. [doc] Document that allow-v6-synthesis is only performed
for clients that are supplied recursive service.
[RT #2260]
1175. [bug] named-checkzone and named-checkconf failed to call
dns_result_register() at startup which could
result in runtime exceptions when printing
"out of memory" errors. [RT #2335]
1175. [bug] named-checkzone failed to call dns_result_register()
at startup which could result in runtime
exceptions when printing "out of memory" errors.
[RT #2335]
1174. [bug] Win32: add WSAECONNRESET to the expected errors
from connect(). [RT #2308]
@@ -77,14 +157,9 @@
1172. [doc] Add CERT, GPOS, KX, NAPTR, NSAP, PX and TXT to
table of RR types in ARM.
1171. [func] Added function isc_region_compare(), updated files in
lib/dns to use this function instead of local one.
1170. [bug] Don't attempt to print the token when a I/O error
occurs when parsing named.conf. [RT #2275]
1169. [func] Identify recursive queries in the query log.
1168. [bug] Empty also-notify clauses were not handled. [RT #2309]
1167. [contrib] nslint-2.1a3 (from author).
@@ -97,8 +172,6 @@
1164. [bug] Empty masters clauses in slave / stub zones were not
handled gracefully. [RT #2262]
1163. [func] isc_time_formattimestamp() now includes the year.
1162. [bug] The allow-notify option was not accepted in slave
zone statements.
@@ -108,62 +181,18 @@
1160. [bug] Generating Diffie-Hellman keys longer than 1024
bits could fail. [RT #2241]
1159. [bug] MD and MF are not permitted to be loaded by RFC1123.
1158. [func] Report the client's address when logging notify
messages.
1157. [func] match-clients and match-destinations now accept
keys. [RT #2045]
1156. [port] The configure test for strsep() incorrectly
succeeded on certain patched versions of
AIX 4.3.3. [RT #2190]
1155. [func] Recover from master files being removed from under
us.
1154. [bug] Don't attempt to obtain the netmask of a interface
if there is no address configured. [RT #2176]
1153. [func] 'rndc {stop|halt} -p' now reports the process id
of the instance of named being shutdown.
1152. [bug] libbind: read buffer overflows.
1151. [bug] nslookup failed to check that the arguments to
the port, timeout, and retry options were
valid integers and in range. [RT #2099]
1150. [bug] named incorrectly accepted TTL values
containing plus or minus signs, such as
1d+1h-1s.
1149. [func] New function isc_parse_uint32().
1148. [func] 'rndc-confgen -a' now provides positive feedback.
1147. [func] Set IPV6_V6ONLY on IPv6 sockets if supported by
the OS. listen-on-v6 { any; }; should no longer
result in IPv4 queries be accepted. Similarly
control { inet :: ... }; should no longer result
in IPv4 connections being accepted. This can be
overridden at compile time by defining
ISC_ALLOW_MAPPED=1.
1146. [func] Allow IPV6_IPV6ONLY to be set/cleared on a socket if
supported by the OS by a new function
isc_socket_ipv6only().
1145. [func] "host" no longer reports a NOERROR/NODATA response
by printing nothing. [RT #2065]
1144. [bug] rndc-confgen would crash if both the -a and -t
options were specified. [RT #2159]
1143. [bug] When a trusted-keys statement was present and named
was built without crypto support, it would leak memory.
1142. [bug] dnssec-signzone would fail to delete temporary files
in some failure cases. [RT #2144]
@@ -175,22 +204,50 @@
1140. [bug] rndc-confgen did not accept IPv6 addresses as arguments
to the -s option. [RT #2138]
1139. [func] It is now possible to flush a given name from the
cache(s) via 'rndc flushname name [view]'. [RT #2051]
1138. [func] It is now possible to flush a given name from the
cache by calling the new function
dns_cache_flushname().
1137. [func] It is now possible to flush a given name from the
ADB by calling the new function dns_adb_flushname().
1136. [bug] CNAME records synthesized from DNAMEs did not
have a TTL of zero as required by RFC2672.
[RT #2129]
1135. [func] You can now override the default syslog() facility for
named/lwresd at compile time. [RT #1982]
1125. [bug] rndc: -k option was missing from usage message.
[RT #2057]
1124. [doc] dig: +[no]dnssec, +[no]besteffort and +[no]fail
are now documented. [RT #2052]
1123. [bug] dig +[no]fail did not match description. [RT #2052]
1109. [bug] nsupdate accepted illegal ttl values.
1108. [bug] On Win32, rndc was hanging when named was not running
due to failure to select for exceptional conditions
in select(). [RT #1870]
1081. [bug] Multicast queries were incorrectly identified
based on the source address, not the destination
address.
1072. [bug] The TCP client quota could be exceeded when
recursion occurred. [RT #1937]
1071. [bug] Sockets listening for TCP DNS connections
specified an excessive listen backlog. [RT #1937]
1070. [bug] Copy DNSSEC OK (DO) to response as specified by
draft-ietf-dnsext-dnssec-okbit-03.txt.
1014. [bug] Some queries would cause statistics counters to
increment more than once or not at all. [RT #1321]
1012. [bug] The -p option to named did not behave as documented.
988. [bug] 'additional-from-auth no;' did not work reliably
in the case of queries answered from the cache.
[RT #1436]
995. [bug] dig, host, nslookup: using a raw IPv6 address as a
target address should be fatal on a IPv4 only system.
--- 9.2.0 released ---
1134. [bug] Multithreaded servers could deadlock in ferror()
when reloading zone files. [RT #1951, #1998]
@@ -198,7 +255,7 @@
1133. [bug] IN6_IS_ADDR_LOOPBACK was not portably defined on
platforms without IN6_IS_ADDR_LOOPBACK. [RT #2106]
1132. [func] Improve UPDATE prerequisite failure diagnotic messages.
--- 9.2.0rc10 released ---
1131. [bug] The match-destinations view option did not work with
IPv6 destinations. [RT #2073, #2074]
@@ -210,37 +267,16 @@
1129. [bug] Multithreaded servers could crash under heavy
resolution load due to a race condition. [RT #2018]
1128. [func] sdb drivers can now provide RR data in either text
or wire format, the latter using the new functions
dns_sdb_putrdata() and dns_sdb_putnamedrdata().
1127. [func] rndc: If the server to contact has multiple addresses,
try all of them.
1126. [bug] The server could access a freed event if shut
down while a client start event was pending
delivery. [RT #2061]
1125. [bug] rndc: -k option was missing from usage message.
[RT #2057]
1124. [doc] dig: +[no]dnssec, +[no]besteffort and +[no]fail
are now documented. [RT #2052]
1123. [bug] dig +[no]fail did not match description. [RT #2052]
1122. [tuning] Resolution timeout reduced from 90 to 30 seconds.
[RT #2046]
1121. [bug] The server could attempt to access a NULL zone
table if shut down while resolving.
[RT #1587, #2054]
1120. [bug] Errors in options were not fatal. [RT #2002]
1119. [func] Added support in Win32 for NTFS file/directory ACL's
for access control.
1118. [bug] On multithreaded servers, a race condition
could cause an assertion failure in resolver.c
during resolver shutdown. [RT #2029]
@@ -254,32 +290,16 @@
or transfers-per-ns to a value greater than
2147483647 disabled transfers. [RT #2002]
1115. [func] Set maximum values for cleaning-interval,
heartbeat-interval, interface-interval,
max-transfer-idle-in, max-transfer-idle-out,
max-transfer-time-in, max-transfer-time-out,
statistics-interval of 28 days and
sig-validity-interval of 3660 days. [RT #2002]
1114. [port] Ignore more accept() errors. [RT #2021]
1113. [bug] The allow-update-forwarding option was ignored
when specified in a view. [RT #2014]
1112. [placeholder]
1111. [bug] Multithreaded servers could deadlock processing
recursive queries due to a locking hieararchy
violation in adb.c. [RT #2017]
1110. [bug] dig should only accept valid abbreviations of +options.
[RT #2003]
1109. [bug] nsupdate accepted illegal ttl values.
1108. [bug] On Win32, rndc was hanging when named was not running
due to failure to select for exceptional conditions
in select(). [RT #1870]
--- 9.2.0rc9 released ---
1107. [bug] nsupdate could catch an assertion failure if an
invalid domain name was given as the argument to
@@ -288,8 +308,6 @@
1106. [bug] After seeing an out of range TTL, nsupdate would
treat all TTLs as out of range. [RT #2001]
1105. [port] OpenUNIX 8 enable threads by default. [RT #1970]
1104. [bug] Invalid arguments to the transfer-format option
could cause an assertion failure. [RT #1995]
@@ -307,16 +325,6 @@
1098. [bug] libbind: HMAC-MD5 key files are now mode 0600.
1097. [func] libbind: RES_PRF_TRUNC for dig.
1096. [func] libbind: "DNSSEC OK" (DO) support.
1095. [func] libbind: resolver option: no-tld-query. disables
trying unqualified as a tld. no_tld_query is also
supported for FreeBSD compatability.
1094. [func] libbind: add support gcc's format string checking.
1093. [doc] libbind: miscellaneous nroff fixes.
1092. [bug] libbind: get*by*() failed to check if res_init() had
@@ -326,13 +334,10 @@
1090. [bug] libbind: dns_ho.c:add_hostent() was not returning
the amount of memory consumed resulting in garbage
address being returned. Alignment calculations were
wasting space. We weren't suppressing duplicate
address being returned. Alignment calculations were
wasting space. We weren't suppressing duplicate
addresses.
1089. [func] libbind: inet_{cidr,net}_{pton,ntop}() now have IPv6
support.
1088. [port] libbind: MPE/iX C.70 (incomplete)
1087. [bug] libbind: struct __res_state too large on 64 bit arch.
@@ -342,7 +347,7 @@
1085. [port] libbind: solaris: sys_nerr and sys_errlist do not
exist when compiling in 64 bit mode.
1084. [cleanup] libbind: gai_strerror() re-written.
1084. [cleanup] libbind: gai_strerror() rewritten.
1083. [bug] The default control channel listened on the
wildcard adress, not the loopback as documented.
@@ -352,27 +357,9 @@
to be sent to syslog in addition to stderr.
[RT #1974]
1081. [bug] Multicast queries were incorrectly identified
based on the source address, not the destination
address.
1080. [bug] BIND 8 compatibility: accept bare IP prefixes
as the second element of a two-element top level
sort list statement. [RT #1964]
1079. [bug] BIND 8 compatibility: accept bare elements at top
level of sort list treating them as if they were
a single element list. [RT #1963]
1078. [bug] We failed to correct bad tv_usec values in one case.
[RT #1966]
1077. [func] Do not accept further recursive clients when
the total number of of recursive lookups being
processed exceeds max-recursive-clients, even
if some of the lookups are internally generated.
[RT #1915, #1938]
1076. [bug] A badly defined global key could trigger an assertion
on load/reload if views were used. [RT #1947]
@@ -382,35 +369,17 @@
1074. [bug] Running out of memory in dump_rdataset() could
cause an assertion failure. [RT #1946]
1073. [bug] The ADB cache cleaning should also be space driven.
[RT #1915, #1938]
1072. [bug] The TCP client quota could be exceeded when
recursion occurred. [RT #1937]
1071. [bug] Sockets listening for TCP DNS connections
specified an excessive listen backlog. [RT #1937]
1070. [bug] Copy DNSSEC OK (DO) to response as specified by
draft-ietf-dnsext-dnssec-okbit-03.txt.
1069. [placeholder]
--- 9.2.0rc8 released ---
1068. [bug] errno could be overwritten by catgets(). [RT #1921]
1067. [func] Allow quotas to be soft, isc_quota_soft().
1066. [bug] Provide a thread safe wrapper for strerror().
[RT #1689]
1065. [func] Runtime support to select new / old style interface
scanning using ioctls.
1064. [bug] Do not shut down active network interfaces if we
are unable to scan the interface list. [RT #1921]
1063. [bug] libbind: "make install" was failing on IRIX.
[RT #1919]
1062. [bug] If the control channel listener socket was shut
down before server exit, the listener object could
@@ -421,15 +390,6 @@
maximum cache size was in progress, the server
could catch an assertion failure. [RT #1912]
1060. [func] Move refresh, stub and notify UDP retry processing
into dns_request.
1059. [func] dns_request now support will now retry UDP queries,
dns_request_createvia2() and dns_request_createraw2().
1058. [func] Limited lifetime ticker timers are now available,
isc_timertype_limited.
1057. [bug] Reloading the server after adding a "file" clause
to a zone statement could cause the server to
crash due to a typo in change 1016.
@@ -437,15 +397,13 @@
1056. [bug] Rndc could catch an assertion failure on SIGINT due
to an uninitialized variable. [RT #1908]
1055. [func] Version and hostname queries can now be disabled
using "version none;" and "hostname none;",
respectively.
--- 9.2.0rc7 released ---
1054. [bug] On Win32, cfg_categories and cfg_modules need to be
exported from the libisccfg DLL.
1053. [bug] Dig did not increase its timeout when receiving
AXFRs unless the +time option was used. [RT #1904]
AXFRs unless the +time option was used. [RT #1904]
1052. [bug] Journals were not being created in binary mode
resulting in "journal format not recognized" error
@@ -461,9 +419,6 @@
failed to include the correct error code, file
name, and line number. [RT #1890]
1049. [func] "pid-file none;" will disable writing a pid file.
[RT #1848]
1048. [bug] Servers built with -DISC_MEM_USE_INTERNAL_MALLOC=1
didn't work.
@@ -501,28 +456,11 @@
TKEY queries with an owner name other than the root
could cause an assertion failure. [RT #1866, #1869]
1037. [bug] Negative responses whose authority section contain
SOA or NS records whose owner names are not equal
equal to or parents of the query name should be
rejected. [RT #1862]
1036. [func] Silently drop requests received via multicast as
long as there is no final multicast DNS standard.
1035. [bug] If we respond to multicast queries (which we
currently do not), respond from a unicast address
as specified in RFC 1123. [RT #137]
1034. [bug] Ignore the RD bit on multicast queries as specified
in RFC 1123. [RT #137]
1033. [bug] Always respond to requests with an unsupported opcode
with NOTIMP, even if we don't have a matching view
or cannot determine the class.
1032. [func] hostname.bind/txt/chaos now returns the name of
the machine hosting the nameserver. This is useful
in diagnosing problems with anycast servers.
--- 9.2.0rc6 released ---
1031. [bug] libbind.a: isc__gettimeofday() infinite recursion.
[RT #1858]
@@ -541,20 +479,13 @@
1027. [bug] RRs having the reserved type 0 should be rejected.
[RT #1471]
1026. [placeholder]
1025. [bug] Don't use multicast addresses to resolve iterative
queries. [RT #101]
1024. [port] Compilation failed on HP-UX 11.11 due to
incompatible use of the SIOCGLIFCONF macro
name. [RT #1831]
1023. [func] Accept hints without TTLs.
1026. [port] Recognize OpenUNIX 8 in config.guess. [RT #1830]
1022. [bug] Don't report empty root hints as "extra data".
[RT #1802]
--- 9.2.0rc5 released ---
1021. [bug] On Win32, log message timestamps were one month
later than they should have been, and the server
would exhibit unspecified behavior in December.
@@ -578,28 +509,18 @@
1015. [bug] Log channels that had a "versions" option but no
"size" option failed to create numbered log
files. [RT #1783]
--- 9.2.0rc4 released ---
1014. [bug] Some queries would cause statistics counters to
increment more than once or not at all. [RT #1321]
1013. [bug] It was possible to cancel a query twice when marking
a server as bogus or by having a blackhole acl.
[RT #1776]
1012. [bug] The -p option to named did not behave as documented.
1011. [cleanup] Removed isc_dir_current().
1010. [bug] The server could attempt to execute a command channel
command after initiating server shutdown, causing
an assertion failure. [RT #1766]
1009. [port] OpenUNIX 8 support. [RT #1728]
1008. [port] libtool.m4, ltmain.sh from libtool-1.4.2.
1007. [port] config.guess, config.sub from autoconf-2.52.
1006. [bug] If a KEY RR was found missing during DNSSEC validation,
an assertion failure could subsequently be triggered
in the resolver. [RT #1763]
@@ -609,8 +530,6 @@
1004. [port] Deal with recvfrom() returning EHOSTDOWN. [RT #1770]
1003. [func] Add the +retry option to dig.
1002. [bug] When reporting an unknown class name in named.conf,
including the file name and line number. [RT #1759]
@@ -621,83 +540,31 @@
1000. [bug] BIND 8 compatibility: accept "HESIOD" as an alias
for class "HS". [RT #1759]
999. [func] "rndc retransfer zone [class [view]]" added.
[RT #1752]
998. [func] named-checkzone now has arguments to specify the
chroot directory (-t) and working directory (-w).
[RT #1755]
997. [func] Add support for RSA-SHA1 keys (RFC3110).
996. [func] Issue warning if the configuration filename contains
the chroot path.
995. [bug] dig, host, nslookup: using a raw IPv6 address as a
target address should be fatal on a IPv4 only system.
994. [func] Treat non-authoritative responses to queries for type
NS as referrals even if the NS records are in the
answer section, because BIND 8 servers incorrectly
send them that way. This is necessary for DNSSEC
validation of the NS records of a secure zone to
succeed when the parent is a BIND 8 server. [RT #1706]
993. [func] dig: -v now reports the version.
992. [doc] dig: ~/.digrc is now documented.
991. [func] Lower UDP refresh timeout messages to level
debug 1.
--- 9.2.0rc3 released ---
990. [bug] The rndc-confgen man page was not installed.
989. [bug] Report filename if $INCLUDE fails for file related
errors. [RT #1736]
988. [bug] 'additional-from-auth no;' did not work reliably
in the case of queries answered from the cache.
[RT #1436]
987. [bug] "dig -help" didn't show "+[no]stats".
986. [bug] "dig +noall" failed to clear stats and command
printing.
985. [func] Consider network interfaces to be up iff they have
a nonzero IP address rather than based on the
IFF_UP flag. [RT #1160]
984. [bug] Multithreading should be enabled by default on
Solaris 2.7 and newer, but it wasn't.
983. [func] The server now supports generating IXFR difference
sequences for non-dynamic zones by comparing zone
versions, when enabled using the new config
option "ixfr-from-differences". [RT #1727]
982. [func] If "memstatistics-file" is set in options the memory
statistics will be written to it.
981. [func] The dnssec tools can now take multiple '-r randomfile'
arguments.
--- 9.2.0rc2 released ---
980. [bug] Incoming zone transfers restarting after an error
could trigger an assertion failure. [RT #1692]
979. [func] Incremental master file dumping. dns_master_dumpinc(),
dns_master_dumptostreaminc(), dns_dumpctx_attach(),
dns_dumpctx_detach(), dns_dumpctx_cancel(),
dns_dumpctx_db() and dns_dumpctx_version().
978. [bug] dns_db_attachversion() had an invalid REQUIRE()
condition.
977. [bug] Improve "not at top of zone" error message.
976. [func] named-checkconf can now test load master zones
(named-checkconf -z). [RT #1468]
975. [bug] "max-cache-size default;" as a view option
caused an assertion failure.
@@ -711,17 +578,6 @@
972. [bug] The file modification time code in zone.c was using the
wrong epoch. [RT #1667]
971. [placeholder]
970. [func] 'max-journal-size' can now be used to set a target
size for a journal.
969. [func] dig now supports the undocumented dig 8 feature
of allowing arbitrary labels, not just dotted
decimal quads, with the -x option. This can be
used to conveniently look up RFC2317 names as in
"dig -x 10.0.0.0-127". [RT #827, #1576, #1598]
968. [bug] On win32, the isc_time_now() function was unnecessarily
calling strtime(). [RT #1671]
@@ -2701,7 +2557,8 @@
347. [bug] Don't crash if an argument is left off options in dig.
346. [placeholder]
346. [func] Add support for .digrc config file, in the
user's current directory
345. [bug] Large-scale changes/cleanups to dig:
* Significantly improve structure handling
@@ -3063,7 +2920,7 @@
257. [bug] The server detached the last zone manager reference
too early, while it could still be in use by queries.
This manifested itself as assertion failures during the
shutdown process for busy name servers. [RT #133]
shutdown process for busy name servers [RT #133].
256. [func] isc_ratelimiter_t now has attach/detach semantics, and
isc_ratelimiter_shutdown guarantees that the rate

View File

@@ -1,4 +1,4 @@
Copyright (C) 1996-2001 Internet Software Consortium.
Copyright (C) 1996-2002 Internet Software Consortium.
Permission to use, copy, modify, and distribute this software for any
purpose with or without fee is hereby granted, provided that the above
@@ -13,6 +13,7 @@ FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
$Id: COPYRIGHT,v 1.6.2.2 2002/02/12 06:05:48 marka Exp $
Portions Copyright (C) 1996-2001 Nominum, Inc.

83
EXCLUDED Normal file
View File

@@ -0,0 +1,83 @@
1007. [port] config.guess, config.sub from autoconf-2.52.
1008. [port] libtool.m4, ltmain.sh from libtool-1.4.2.
1009. [port] OpenUNIX 8 support. [RT #1728]
1024. [port] Compilation failed on HP-UX 11.11 due to
incompatible use of the SIOCGLIFCONF macro
name. [RT #1831]
[needs more work]
1025. [bug] Don't use multicast addresses to resolve iterative
queries. [RT #101]
1034. [bug] Ignore the RD bit on multicast queries as specified
in RFC 1123. [RT #137]
1035. [bug] If we respond to multicast queries (which we
currently do not), respond from a unicast address
as specified in RFC 1123. [RT #137]
1037. [bug] Negative responses whose authority section contain
SOA or NS records whose owner names are not equal
equal to or parents of the query name should be
rejected. [RT #1862]
1073. [bug] The ADB cache cleaning should also be space driven.
[RT #1915, #1938]
[ New function dns_adb_setadbsize() ]
1079. [bug] BIND 8 compatibility: accept bare elements at top
level of sort list treating them as if they were
a single element list. [RT #1963]
1080. [bug] BIND 8 compatibility: accept bare IP prefixes
as the second element of a two-element top level
sort list statement. [RT #1964]
1105. [port] OpenUNIX 8 enable threads by default. [RT #1970]
[Functional change]
1110. [bug] dig should only accept valid abbreviations of +options.
[RT #2003]
[Potentially breaks scripts. Leave to 9.3.0.]
1143. [bug] When a trusted-keys statement was present and named
was built without crypto support, it would leak memory.
[ Not applicable to 9.2 ]
1150. [bug] named incorrectly accepted TTL values
containing plus or minus signs, such as
1d+1h-1s.
[ Uses new function isc_parse_uint32() ]
1151. [bug] nslookup failed to check that the arguments to
the port, timeout, and retry options were
valid integers and in range. [RT #2099]
[ Uses new function isc_parse_uint32() ]
1159. [bug] MD and MF are not permitted to be loaded by RFC1123
[ Could cause zones that loaded in 9.2.0 to fail
to load. Leave such breakages to 9.3.0. ]
1187. [bug] named was incorrectly returning DNSSEC records
in negative responses when the DO bit was not set.
[ Requires API change (new arguement) to
dns_rdataset_towire(), dns_rdataset_towirepartial()
and dns_rdataset_towirepartial() ]
1192. [bug] The seconds fields in LOC records were restricted
to three decimal places. More decimal places should
be allowed but warned about.
1209. [bug] Dig, host, nslookup were not checking the message ids
on the responses. [RT #2454]
1233. [bug] The flags field of a KEY record can be expressed in
hex as well as decimal.
[ Not applicable to 9.2.x ]
1234. [bug] 'rrset-order' and 'sortlist' should be additive
not exclusive.

51
FAQ
View File

@@ -141,18 +141,6 @@ be fixed in 8.2.4. It can be safely ignored - the notify has been
acted on by the slave despite the error message.
Q: I keep getting log messages like the following. Why?
Dec 4 23:47:59 client 10.0.0.1#1355: updating zone 'example.com/IN':
update failed: 'RRset exists (value dependent)' prerequisite not
satisfied (NXRRSET)
A: DNS updates allow the update request to test to see if certain
conditions are met prior to proceeding with the update. The message
above is saying that conditions were not met and the update is not
proceeding. See doc/rfc/rfc2136.txt for more details on prerequisites.
Q: I keep getting log messages like the following. Why?
Jun 21 12:00:00.000 client 10.0.0.1#1234: update denied
@@ -266,38 +254,17 @@ use those to make sure you reach the correct view on the other machine.
You put the external address on the alias so that all the other
dns clients on these boxes see the internal view by default.
A: (BIND 9.3 and later) Use TSIG to select the appropriate view.
Master 10.0.1.1:
key "external" {
algorithm hmac-md5;
secret "xxxxxxxx";
};
view "internal" {
match-clients { !key external; 10.0.1/24; };
...
};
view "external" {
match-clients { key external; any; };
server 10.0.0.2 { keys external; };
recursion no;
...
};
Q: When I try to use rndc, I get the error message "network
unreachable" or "connection refused", even though I know named is
running.
Slave 10.0.1.2:
key "external" {
algorithm hmac-md5;
secret "xxxxxxxx";
};
view "internal" {
match-clients { !key external; 10.0.1/24; };
};
view "external" {
match-clients { key external; any; };
server 10.0.0.1 { keys external; };
recursion no;
...
};
A: You probably have "default-server localhost" in /etc/rndc.conf,
your /etc/hosts or DNS maps "localhost" to both the IPv4 loopback
address 127.0.0.1 and the IPv6 loopback address ::1, and you do not
have IPv6 fully operational. Change the "default-server localhost" to
"default-server 127.0.0.1" to make sure rdnc does not try to contact
the name server using IPv6.
Q: I have Freebsd 4.4 and "rndc-confgen -a" just sits there.

32
README
View File

@@ -44,21 +44,18 @@ BIND 9
Nominum, Inc.
BIND 9.3.0
BIND 9.2.1
BIND 9.3.0 has a number of new features over 9.2,
including:
NOTE:
* Zones containing MD and MF will now be rejected.
* dig, nslookup name. now report "Not Implemented" as
NOTIMP rather than NOTIMPL. This will have impact on scripts
that are looking for NOTIMPL.
BIND 9.2.1 is a maintenance release, containing fixes for
a number of bugs in 9.2.0 but no new features.
NOTE: dig, nslookup name. now report "Not Implemented" as
NOTIMP rather than NOTIMPL. This will have impact on scripts
that are looking for NOTIMPL.
BIND 9.2.0
BIND 9.2.0 has a number of new features over 9.1,
BIND 9.2.0 introduces a number of new features over 9.1,
including:
- The size of the cache can now be limited using the
@@ -158,13 +155,16 @@ Building
COMPAQ Tru64 UNIX 4.0D
COMPAQ Tru64 UNIX 5 (with IPv6 EAK)
FreeBSD 3.4-STABLE, 3.5, 4.0, 4.1
HP-UX 11
HP-UX 11.x, x < 11
IRIX64 6.5
NetBSD 1.5
Red Hat Linux 6.0, 6.1, 6.2, 7.0
Solaris 2.6, 7, 8
Windows NT/W2K
HP-UX 11.11 is not yet supported due to its incompatible
SIOCGLIFCONF ioctl.
Additionally, we have unverified reports of success building
previous versions of BIND 9 from users of the following systems:
@@ -177,6 +177,7 @@ Building
UnixWare 7.1.1
HP-UX 10.20
BSD/OS 4.2
OpenUNIX 8
Mac OS X 10.1
To build, just
@@ -206,10 +207,6 @@ Building
Any additional preprocessor symbols you want defined.
Defaults to empty string.
Possible settings:
Change the default syslog facility of named/lwresd.
e.g. -DISC_FACILITY=LOG_LOCAL0
To build shared libraries, specify "--with-libtool" on the
configure command line.
@@ -282,6 +279,9 @@ Documentation
notes in doc/misc/migration. If you are upgrading from
BIND 4, read doc/misc/migration-4to9.
Frequently asked questions and their answers can be found in
FAQ.
Bug Reports and Mailing Lists
@@ -292,7 +292,7 @@ Bug Reports and Mailing Lists
To join the BIND 9 Users mailing list, send mail to
bind9-users-request@isc.org
archives of which can be found via
http://www.isc.org/ml-archives/

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: acconfig.h,v 1.36 2001/10/22 22:52:16 gson Exp $ */
/* $Id: acconfig.h,v 1.35.2.1 2001/10/22 23:28:07 gson Exp $ */
/***
*** This file is not to be included by any public header files, because

View File

@@ -1,4 +1,4 @@
# Copyright (C) 2000, 2001 Internet Software Consortium.
# Copyright (C) 2000-2002 Internet Software Consortium.
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
@@ -13,7 +13,7 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.18 2001/11/06 20:04:57 bwelling Exp $
# $Id: Makefile.in,v 1.15.2.3 2002/02/12 06:05:50 marka Exp $
srcdir = @srcdir@
VPATH = @srcdir@
@@ -21,23 +21,20 @@ top_srcdir = @top_srcdir@
@BIND9_VERSION@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = ${BIND9_INCLUDES} ${DNS_INCLUDES} ${ISCCFG_INCLUDES} \
${ISC_INCLUDES}
CINCLUDES = ${DNS_INCLUDES} ${ISCCFG_INCLUDES} ${ISC_INCLUDES}
CDEFINES = -DNAMED_CONFFILE=\"${sysconfdir}/named.conf\"
CWARNINGS =
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCCFGLIBS = ../../lib/isccfg/libisccfg.@A@
ISCLIBS = ../../lib/isc/libisc.@A@
BIND9LIBS = ../../lib/bind9/libbind9.@A@
DNSDEPLIBS = ../../lib/dns/libdns.@A@
ISCCFGDEPLIBS = ../../lib/isccfg/libisccfg.@A@
ISCDEPLIBS = ../../lib/isc/libisc.@A@
BIND9DEPLIBS = ../../lib/bind9/libbind9.@A@
LIBS = @LIBS@
@@ -65,9 +62,10 @@ named-checkzone.@O@: named-checkzone.c
${LIBTOOL} ${CC} ${ALL_CFLAGS} -DVERSION=\"${VERSION}\" \
-c ${srcdir}/named-checkzone.c
named-checkconf: named-checkconf.@O@ check-tool.@O@ ${ISCDEPLIBS} ${ISCCFGDEPLIBS} ${BIND9DEPLIBS}
named-checkconf: named-checkconf.@O@ check-tool.@O@ ${ISCDEPLIBS} \
${ISCCFGDEPLIBS} ${DNSDEPLIBS}
${LIBTOOL} ${PURIFY} ${CC} ${CFLAGS} -o $@ named-checkconf.@O@ \
check-tool.@O@ ${BIND9LIBS} ${DNSLIBS} ${ISCCFGLIBS} ${ISCLIBS} ${LIBS}
check-tool.@O@ ${ISCCFGLIBS} ${DNSLIBS} ${ISCLIBS} ${LIBS}
named-checkzone: named-checkzone.@O@ check-tool.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS}
${LIBTOOL} ${PURIFY} ${CC} ${CFLAGS} -o $@ named-checkzone.@O@ \
@@ -88,4 +86,4 @@ install:: named-checkconf named-checkzone installdirs
for m in ${MANPAGES}; do ${INSTALL_DATA} ${srcdir}/$$m ${DESTDIR}${mandir}/man8; done
clean distclean::
rm -f ${TARGETS}
rm -f ${TARGETS} r1.htm

View File

@@ -15,38 +15,18 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: check-tool.c,v 1.6 2001/09/05 21:09:31 bwelling Exp $ */
/* $Id: check-tool.c,v 1.4 2001/03/03 23:11:33 bwelling Exp $ */
#include <config.h>
#include <stdio.h>
#include <string.h>
#include "check-tool.h"
#include <isc/util.h>
#include <isc/buffer.h>
#include <isc/log.h>
#include <isc/region.h>
#include <isc/types.h>
#include <dns/fixedname.h>
#include <dns/name.h>
#include <dns/rdataclass.h>
#include <dns/types.h>
#include <dns/zone.h>
#define CHECK(r) \
do { \
result = (r); \
if (result != ISC_R_SUCCESS) \
goto cleanup; \
} while (0)
static const char *dbtype[] = { "rbt" };
int debug = 0;
isc_result_t
setup_logging(isc_mem_t *mctx, isc_log_t **logp) {
isc_logdestination_t destination;
@@ -70,54 +50,3 @@ setup_logging(isc_mem_t *mctx, isc_log_t **logp) {
*logp = log;
return (ISC_R_SUCCESS);
}
isc_result_t
load_zone(isc_mem_t *mctx, const char *zonename, const char *filename,
const char *classname, dns_zone_t **zonep)
{
isc_result_t result;
dns_rdataclass_t rdclass;
isc_textregion_t region;
isc_buffer_t buffer;
dns_fixedname_t fixorigin;
dns_name_t *origin;
dns_zone_t *zone = NULL;
REQUIRE(zonep == NULL || *zonep == NULL);
if (debug)
fprintf(stderr, "loading \"%s\" from \"%s\" class \"%s\"\n",
zonename, filename, classname);
CHECK(dns_zone_create(&zone, mctx));
dns_zone_settype(zone, dns_zone_master);
isc_buffer_init(&buffer, zonename, strlen(zonename));
isc_buffer_add(&buffer, strlen(zonename));
dns_fixedname_init(&fixorigin);
origin = dns_fixedname_name(&fixorigin);
CHECK(dns_name_fromtext(origin, &buffer, dns_rootname,
ISC_FALSE, NULL));
CHECK(dns_zone_setorigin(zone, origin));
CHECK(dns_zone_setdbtype(zone, 1, (const char * const *) dbtype));
CHECK(dns_zone_setfile(zone, filename));
DE_CONST(classname, region.base);
region.length = strlen(classname);
CHECK(dns_rdataclass_fromtext(&rdclass, &region));
dns_zone_setclass(zone, rdclass);
dns_zone_setoption(zone, DNS_ZONEOPT_MANYERRORS, ISC_TRUE);
CHECK(dns_zone_load(zone));
if (zonep != NULL){
*zonep = zone;
zone = NULL;
}
cleanup:
if (zone != NULL)
dns_zone_detach(&zone);
return (result);
}

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: check-tool.h,v 1.3 2001/09/03 08:21:46 marka Exp $ */
/* $Id: check-tool.h,v 1.2 2001/01/09 21:39:09 bwelling Exp $ */
#ifndef CHECK_TOOL_H
#define CHECK_TOOL_H
@@ -23,19 +23,12 @@
#include <isc/lang.h>
#include <isc/types.h>
#include <dns/types.h>
ISC_LANG_BEGINDECLS
isc_result_t
setup_logging(isc_mem_t *mctx, isc_log_t **logp);
isc_result_t
load_zone(isc_mem_t *mctx, const char *zonename, const char *filename,
const char *classname, dns_zone_t **zonep);
extern int debug;
ISC_LANG_ENDDECLS
#endif

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: named-checkconf.c,v 1.21 2002/01/14 01:42:03 marka Exp $ */
/* $Id: named-checkconf.c,v 1.12 2001/07/27 17:45:26 gson Exp $ */
#include <config.h>
@@ -31,28 +31,16 @@
#include <isc/string.h>
#include <isc/util.h>
#include <isccfg/namedconf.h>
#include <bind9/check.h>
#include <dns/log.h>
#include <dns/result.h>
#include <isccfg/cfg.h>
#include <isccfg/check.h>
#include "check-tool.h"
isc_log_t *logc = NULL;
#define CHECK(r)\
do { \
result = (r); \
if (result != ISC_R_SUCCESS) \
goto cleanup; \
} while (0)
static void
usage(void) {
fprintf(stderr, "usage: named-checkconf [-v] [-z] [-t directory] "
"[named.conf]\n");
fprintf(stderr, "usage: named-checkconf [-v] [-t directory] [named.conf]\n");
exit(1);
}
@@ -73,7 +61,7 @@ directory_callback(const char *clausename, cfg_obj_t *obj, void *arg) {
result = isc_dir_chdir(directory);
if (result != ISC_R_SUCCESS) {
cfg_obj_log(obj, logc, ISC_LOG_ERROR,
"change directory to '%s' failed: %s\n",
"change directory to '%s' failed: %s",
directory, isc_result_totext(result));
return (result);
}
@@ -81,112 +69,6 @@ directory_callback(const char *clausename, cfg_obj_t *obj, void *arg) {
return (ISC_R_SUCCESS);
}
static isc_result_t
configure_zone(const char *vclass, const char *view, cfg_obj_t *zconfig,
isc_mem_t *mctx)
{
isc_result_t result;
const char *zclass;
const char *zname;
const char *zfile;
cfg_obj_t *zoptions = NULL;
cfg_obj_t *classobj = NULL;
cfg_obj_t *typeobj = NULL;
cfg_obj_t *fileobj = NULL;
cfg_obj_t *dbobj = NULL;
zname = cfg_obj_asstring(cfg_tuple_get(zconfig, "name"));
classobj = cfg_tuple_get(zconfig, "class");
if (!cfg_obj_isstring(classobj))
zclass = vclass;
else
zclass = cfg_obj_asstring(classobj);
zoptions = cfg_tuple_get(zconfig, "options");
cfg_map_get(zoptions, "type", &typeobj);
if (typeobj == NULL)
return (ISC_R_FAILURE);
if (strcasecmp(cfg_obj_asstring(typeobj), "master") != 0)
return (ISC_R_SUCCESS);
cfg_map_get(zoptions, "database", &dbobj);
if (dbobj != NULL)
return (ISC_R_SUCCESS);
cfg_map_get(zoptions, "file", &fileobj);
if (fileobj == NULL)
return (ISC_R_FAILURE);
zfile = cfg_obj_asstring(fileobj);
result = load_zone(mctx, zname, zfile, zclass, NULL);
if (result != ISC_R_SUCCESS)
fprintf(stderr, "%s/%s/%s: %s\n", view, zname, zclass,
dns_result_totext(result));
return(result);
}
static isc_result_t
configure_view(const char *vclass, const char *view, cfg_obj_t *config,
cfg_obj_t *vconfig, isc_mem_t *mctx)
{
cfg_listelt_t *element;
cfg_obj_t *voptions;
cfg_obj_t *zonelist;
isc_result_t result = ISC_R_SUCCESS;
voptions = NULL;
if (vconfig != NULL)
voptions = cfg_tuple_get(vconfig, "options");
zonelist = NULL;
if (voptions != NULL)
(void)cfg_map_get(voptions, "zone", &zonelist);
else
(void)cfg_map_get(config, "zone", &zonelist);
for (element = cfg_list_first(zonelist);
element != NULL;
element = cfg_list_next(element))
{
cfg_obj_t *zconfig = cfg_listelt_value(element);
CHECK(configure_zone(vclass, view, zconfig, mctx));
}
cleanup:
return (result);
}
static isc_result_t
load_zones_fromconfig(cfg_obj_t *config, isc_mem_t *mctx) {
cfg_listelt_t *element;
cfg_obj_t *classobj;
cfg_obj_t *views;
cfg_obj_t *vconfig;
const char *vclass;
isc_result_t result = ISC_R_SUCCESS;
views = NULL;
(void)cfg_map_get(config, "view", &views);
for (element = cfg_list_first(views);
element != NULL;
element = cfg_list_next(element))
{
const char *vname;
vclass = "IN";
vconfig = cfg_listelt_value(element);
if (vconfig != NULL) {
classobj = cfg_tuple_get(vconfig, "class");
if (cfg_obj_isstring(classobj))
vclass = cfg_obj_asstring(classobj);
}
vname = cfg_obj_asstring(cfg_tuple_get(vconfig, "name"));
CHECK(configure_view(vclass, vname, config, vconfig, mctx));
}
if (views == NULL)
CHECK(configure_view("IN", "_default", config, NULL, mctx));
cleanup:
return (result);
}
int
main(int argc, char **argv) {
int c;
@@ -196,14 +78,9 @@ main(int argc, char **argv) {
isc_mem_t *mctx = NULL;
isc_result_t result;
int exit_status = 0;
isc_boolean_t load_zones = ISC_FALSE;
while ((c = isc_commandline_parse(argc, argv, "dt:vz")) != EOF) {
while ((c = isc_commandline_parse(argc, argv, "t:v")) != EOF) {
switch (c) {
case 'd':
debug++;
break;
case 't':
result = isc_dir_chroot(isc_commandline_argument);
if (result != ISC_R_SUCCESS) {
@@ -223,10 +100,6 @@ main(int argc, char **argv) {
printf(VERSION "\n");
exit(0);
case 'z':
load_zones = ISC_TRUE;
break;
default:
usage();
}
@@ -241,8 +114,6 @@ main(int argc, char **argv) {
RUNTIME_CHECK(setup_logging(mctx, &logc) == ISC_R_SUCCESS);
dns_result_register();
RUNTIME_CHECK(cfg_parser_create(mctx, logc, &parser) == ISC_R_SUCCESS);
cfg_parser_setcallback(parser, directory_callback, NULL);
@@ -251,18 +122,10 @@ main(int argc, char **argv) {
ISC_R_SUCCESS)
exit(1);
result = bind9_check_namedconf(config, logc, mctx);
result = cfg_check_namedconf(config, logc, mctx);
if (result != ISC_R_SUCCESS)
exit_status = 1;
if (result == ISC_R_SUCCESS && load_zones) {
dns_log_init(logc);
dns_log_setcontext(logc);
result = load_zones_fromconfig(config, mctx);
if (result != ISC_R_SUCCESS)
exit_status = 1;
}
cfg_obj_destroy(parser, &config);
cfg_parser_destroy(&parser);

View File

@@ -1,6 +1,6 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!--
- Copyright (C) 2001 Internet Software Consortium.
- Copyright (C) 2001, 2002 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
@@ -16,7 +16,7 @@
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: named-checkconf.docbook,v 1.4 2001/09/04 00:32:32 marka Exp $ -->
<!-- $Id: named-checkconf.docbook,v 1.3.2.1 2002/02/08 03:56:57 marka Exp $ -->
<refentry>
<refentryinfo>
@@ -40,7 +40,6 @@
<arg><option>-v</option></arg>
<arg><option>-t <replaceable class="parameter">directory</replaceable></option></arg>
<arg choice="req">filename</arg>
<arg><option>-z</option></arg>
</cmdsynopsis>
</refsynopsisdiv>
@@ -77,16 +76,6 @@
</listitem>
</varlistentry>
<varlistentry>
<term>-z</term>
<listitem>
<para>
Perform a check load the master zonefiles found in
<filename>named.conf</filename>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>filename</term>
<listitem>

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 1999-2001 Internet Software Consortium.
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: named-checkzone.c,v 1.19 2002/01/14 01:42:04 marka Exp $ */
/* $Id: named-checkzone.c,v 1.13.2.2 2002/02/08 03:56:58 marka Exp $ */
#include <config.h>
@@ -23,7 +23,6 @@
#include <isc/app.h>
#include <isc/commandline.h>
#include <isc/dir.h>
#include <isc/log.h>
#include <isc/mem.h>
#include <isc/socket.h>
@@ -42,10 +41,12 @@
#include "check-tool.h"
static int debug = 0;
static int quiet = 0;
static isc_mem_t *mctx = NULL;
dns_zone_t *zone = NULL;
dns_zonetype_t zonetype = dns_zone_master;
static const char *dbtype[] = { "rbt" };
#define ERRRET(result, function) \
do { \
@@ -60,10 +61,57 @@ dns_zonetype_t zonetype = dns_zone_master;
static void
usage(void) {
fprintf(stderr,
"usage: named-checkzone [-dqv] [-c class] zonename filename\n");
"usage: named-checkzone [-dqv] [-c class] zonename filename \n");
exit(1);
}
static isc_result_t
setup(char *zonename, char *filename, char *classname) {
isc_result_t result;
dns_rdataclass_t rdclass;
isc_textregion_t region;
isc_buffer_t buffer;
dns_fixedname_t fixorigin;
dns_name_t *origin;
if (debug)
fprintf(stderr, "loading \"%s\" from \"%s\" class \"%s\"\n",
zonename, filename, classname);
result = dns_zone_create(&zone, mctx);
ERRRET(result, "dns_zone_new");
dns_zone_settype(zone, zonetype);
isc_buffer_init(&buffer, zonename, strlen(zonename));
isc_buffer_add(&buffer, strlen(zonename));
dns_fixedname_init(&fixorigin);
result = dns_name_fromtext(dns_fixedname_name(&fixorigin),
&buffer, dns_rootname, ISC_FALSE, NULL);
ERRRET(result, "dns_name_fromtext");
origin = dns_fixedname_name(&fixorigin);
result = dns_zone_setorigin(zone, origin);
ERRRET(result, "dns_zone_setorigin");
result = dns_zone_setdbtype(zone, 1, (const char * const *) dbtype);
ERRRET(result, "dns_zone_setdatabase");
result = dns_zone_setfile(zone, filename);
ERRRET(result, "dns_zone_setdatabase");
region.base = classname;
region.length = strlen(classname);
result = dns_rdataclass_fromtext(&rdclass, &region);
ERRRET(result, "dns_rdataclass_fromtext");
dns_zone_setclass(zone, rdclass);
dns_zone_setoption(zone, DNS_ZONEOPT_MANYERRORS, ISC_TRUE);
result = dns_zone_load(zone);
return (result);
}
static void
destroy(void) {
if (zone != NULL)
@@ -79,60 +127,26 @@ main(int argc, char **argv) {
isc_result_t result;
char classname_in[] = "IN";
char *classname = classname_in;
const char *workdir = NULL;
while ((c = isc_commandline_parse(argc, argv, "c:dqist:vw:")) != EOF) {
while ((c = isc_commandline_parse(argc, argv, "c:dqsv")) != EOF) {
switch (c) {
case 'c':
classname = isc_commandline_argument;
break;
case 'd':
debug++;
break;
case 'q':
quiet++;
break;
case 't':
result = isc_dir_chroot(isc_commandline_argument);
if (result != ISC_R_SUCCESS) {
fprintf(stderr, "isc_dir_chroot: %s: %s\n",
isc_commandline_argument,
isc_result_totext(result));
exit(1);
}
result = isc_dir_chdir("/");
if (result != ISC_R_SUCCESS) {
fprintf(stderr, "isc_dir_chdir: %s\n",
isc_result_totext(result));
exit(1);
}
break;
case 'v':
printf(VERSION "\n");
exit(0);
case 'w':
workdir = isc_commandline_argument;
break;
default:
usage();
}
}
if (workdir != NULL) {
result = isc_dir_chdir(workdir);
if (result != ISC_R_SUCCESS) {
fprintf(stderr, "isc_dir_chdir: %s: %s\n",
workdir, isc_result_totext(result));
exit(1);
}
}
if (isc_commandline_index + 2 > argc)
usage();
@@ -147,7 +161,7 @@ main(int argc, char **argv) {
origin = argv[isc_commandline_index++];
filename = argv[isc_commandline_index++];
result = load_zone(mctx, origin, filename, classname, &zone);
result = setup(origin, filename, classname);
if (!quiet && result == ISC_R_SUCCESS)
fprintf(stdout, "OK\n");
destroy();

View File

@@ -16,7 +16,7 @@
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: named-checkzone.docbook,v 1.4 2001/09/15 02:05:35 marka Exp $ -->
<!-- $Id: named-checkzone.docbook,v 1.3 2001/06/29 01:05:00 gson Exp $ -->
<refentry>
<refentryinfo>
@@ -41,8 +41,6 @@
<arg><option>-q</option></arg>
<arg><option>-v</option></arg>
<arg><option>-c <replaceable class="parameter">class</replaceable></option></arg>
<arg><option>-t <replaceable class="parameter">directory</replaceable></option></arg>
<arg><option>-w <replaceable class="parameter">directory</replaceable></option></arg>
<arg choice="req">zonename</arg>
<arg choice="req">filename</arg>
</cmdsynopsis>
@@ -100,29 +98,6 @@
</listitem>
</varlistentry>
<varlistentry>
<term>-t <replaceable class="parameter">directory</replaceable></term>
<listitem>
<para>
chroot to <filename>directory</filename> so that include
directives in the configuration file are processed as if
run by a similarly chrooted named.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-w <replaceable class="parameter">directory</replaceable></term>
<listitem>
<para>
chdir to <filename>directory</filename> so that relative
filenames in master file $INCLUDE directives work. This
is similar to the directory clause in
<filename>named.conf</filename>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>zonename</term>
<listitem>

View File

@@ -42,7 +42,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "__STDC__" /FR /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccfg/include" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "__STDC__" /FR /YX /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
@@ -50,7 +50,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccfg/win32/Release/libisccfg.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/named-checkconf.exe"
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/isccfg/win32/Release/libisccfg.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/named-checkconf.exe"
!ELSEIF "$(CFG)" == "namedcheckconf - Win32 Debug"
@@ -66,7 +66,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "_DEBUG" /D "__STDC__" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccfg/include" /D "_DEBUG" /D "__STDC__" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# SUBTRACT CPP /X /YX
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
@@ -75,7 +75,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib ../../../lib/bind9/win32/Debug/libbind9.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/named-checkconf.exe" /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/named-checkconf.exe" /pdbtype:sept
!ENDIF

View File

@@ -25,9 +25,6 @@ NULL=
NULL=nul
!ENDIF
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "namedcheckconf - Win32 Release"
OUTDIR=.\Release
@@ -36,21 +33,10 @@ INTDIR=.\Release
OutDir=.\Release
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Release\named-checkconf.exe" "$(OUTDIR)\namedcheckconf.bsc"
!ELSE
ALL : "libdns - Win32 Release" "libisccfg - Win32 Release" "libisc - Win32 Release" "..\..\..\Build\Release\named-checkconf.exe" "$(OUTDIR)\namedcheckconf.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libisc - Win32 ReleaseCLEAN" "libisccfg - Win32 ReleaseCLEAN" "libdns - Win32 ReleaseCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\check-tool.obj"
-@erase "$(INTDIR)\check-tool.sbr"
-@erase "$(INTDIR)\named-checkconf.obj"
@@ -62,96 +48,8 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "__STDC__" /FR"$(INTDIR)\\" /Fp"$(INTDIR)\namedcheckconf.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\namedcheckconf.bsc"
BSC32_SBRS= \
"$(INTDIR)\check-tool.sbr" \
"$(INTDIR)\named-checkconf.sbr"
"$(OUTDIR)\namedcheckconf.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccfg/win32/Release/libisccfg.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\named-checkconf.pdb" /machine:I386 /out:"../../../Build/Release/named-checkconf.exe"
LINK32_OBJS= \
"$(INTDIR)\check-tool.obj" \
"$(INTDIR)\named-checkconf.obj" \
"..\..\..\lib\isc\win32\Release\libisc.lib" \
"..\..\..\lib\isccfg\win32\Release\libisccfg.lib" \
"..\..\..\lib\dns\win32\Release\libdns.lib"
"..\..\..\Build\Release\named-checkconf.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "namedcheckconf - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Debug\named-checkconf.exe" "$(OUTDIR)\namedcheckconf.bsc"
!ELSE
ALL : "libdns - Win32 Debug" "libisccfg - Win32 Debug" "libisc - Win32 Debug" "..\..\..\Build\Debug\named-checkconf.exe" "$(OUTDIR)\namedcheckconf.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libisc - Win32 DebugCLEAN" "libisccfg - Win32 DebugCLEAN" "libdns - Win32 DebugCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\check-tool.obj"
-@erase "$(INTDIR)\check-tool.sbr"
-@erase "$(INTDIR)\named-checkconf.obj"
-@erase "$(INTDIR)\named-checkconf.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\named-checkconf.pdb"
-@erase "$(OUTDIR)\namedcheckconf.bsc"
-@erase "..\..\..\Build\Debug\named-checkconf.exe"
-@erase "..\..\..\Build\Debug\named-checkconf.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "_DEBUG" /D "__STDC__" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\namedcheckconf.bsc"
BSC32_SBRS= \
"$(INTDIR)\check-tool.sbr" \
"$(INTDIR)\named-checkconf.sbr"
"$(OUTDIR)\namedcheckconf.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib ../../../lib/bind9/win32/Debug/libbind9.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\named-checkconf.pdb" /debug /machine:I386 /out:"../../../Build/Debug/named-checkconf.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\check-tool.obj" \
"$(INTDIR)\named-checkconf.obj" \
"..\..\..\lib\isc\win32\Debug\libisc.lib" \
"..\..\..\lib\isccfg\win32\Debug\libisccfg.lib" \
"..\..\..\lib\dns\win32\Debug\libdns.lib"
"..\..\..\Build\Debug\named-checkconf.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
CPP=cl.exe
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccfg/include" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "__STDC__" /FR"$(INTDIR)\\" /Fp"$(INTDIR)\namedcheckconf.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
@@ -183,6 +81,113 @@ LINK32_OBJS= \
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\namedcheckconf.bsc"
BSC32_SBRS= \
"$(INTDIR)\check-tool.sbr" \
"$(INTDIR)\named-checkconf.sbr"
"$(OUTDIR)\namedcheckconf.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/isccfg/win32/Release/libisccfg.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\named-checkconf.pdb" /machine:I386 /out:"../../../Build/Release/named-checkconf.exe"
LINK32_OBJS= \
"$(INTDIR)\check-tool.obj" \
"$(INTDIR)\named-checkconf.obj"
"..\..\..\Build\Release\named-checkconf.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "namedcheckconf - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
ALL : "..\..\..\Build\Debug\named-checkconf.exe" "$(OUTDIR)\namedcheckconf.bsc"
CLEAN :
-@erase "$(INTDIR)\check-tool.obj"
-@erase "$(INTDIR)\check-tool.sbr"
-@erase "$(INTDIR)\named-checkconf.obj"
-@erase "$(INTDIR)\named-checkconf.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\named-checkconf.pdb"
-@erase "$(OUTDIR)\namedcheckconf.bsc"
-@erase "..\..\..\Build\Debug\named-checkconf.exe"
-@erase "..\..\..\Build\Debug\named-checkconf.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccfg/include" /D "_DEBUG" /D "__STDC__" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\namedcheckconf.bsc"
BSC32_SBRS= \
"$(INTDIR)\check-tool.sbr" \
"$(INTDIR)\named-checkconf.sbr"
"$(OUTDIR)\namedcheckconf.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\named-checkconf.pdb" /debug /machine:I386 /out:"../../../Build/Debug/named-checkconf.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\check-tool.obj" \
"$(INTDIR)\named-checkconf.obj"
"..\..\..\Build\Debug\named-checkconf.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("namedcheckconf.dep")
@@ -206,84 +211,6 @@ SOURCE="..\named-checkconf.c"
$(CPP) $(CPP_PROJ) $(SOURCE)
!IF "$(CFG)" == "namedcheckconf - Win32 Release"
"libisc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release"
cd "..\..\..\bin\check\win32"
"libisc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ELSEIF "$(CFG)" == "namedcheckconf - Win32 Debug"
"libisc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug"
cd "..\..\..\bin\check\win32"
"libisc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ENDIF
!IF "$(CFG)" == "namedcheckconf - Win32 Release"
"libisccfg - Win32 Release" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Release"
cd "..\..\..\bin\check\win32"
"libisccfg - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ELSEIF "$(CFG)" == "namedcheckconf - Win32 Debug"
"libisccfg - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Debug"
cd "..\..\..\bin\check\win32"
"libisccfg - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ENDIF
!IF "$(CFG)" == "namedcheckconf - Win32 Release"
"libdns - Win32 Release" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release"
cd "..\..\..\bin\check\win32"
"libdns - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ELSEIF "$(CFG)" == "namedcheckconf - Win32 Debug"
"libdns - Win32 Debug" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug"
cd "..\..\..\bin\check\win32"
"libdns - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ENDIF
!ENDIF

View File

@@ -25,9 +25,6 @@ NULL=
NULL=nul
!ENDIF
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "namedcheckzone - Win32 Release"
OUTDIR=.\Release
@@ -36,21 +33,10 @@ INTDIR=.\Release
OutDir=.\Release
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Release\named-checkzone.exe" "$(OUTDIR)\namedcheckzone.bsc"
!ELSE
ALL : "libisc - Win32 Release" "libdns - Win32 Release" "..\..\..\Build\Release\named-checkzone.exe" "$(OUTDIR)\namedcheckzone.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 ReleaseCLEAN" "libisc - Win32 ReleaseCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\check-tool.obj"
-@erase "$(INTDIR)\check-tool.sbr"
-@erase "$(INTDIR)\named-checkzone.obj"
@@ -62,94 +48,8 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /D "NDEBUG" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D "__STDC__" /FR"$(INTDIR)\\" /Fp"$(INTDIR)\namedcheckzone.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\namedcheckzone.bsc"
BSC32_SBRS= \
"$(INTDIR)\check-tool.sbr" \
"$(INTDIR)\named-checkzone.sbr"
"$(OUTDIR)\namedcheckzone.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\named-checkzone.pdb" /machine:I386 /out:"../../../Build/Release/named-checkzone.exe"
LINK32_OBJS= \
"$(INTDIR)\check-tool.obj" \
"$(INTDIR)\named-checkzone.obj" \
"..\..\..\lib\dns\win32\Release\libdns.lib" \
"..\..\..\lib\isc\win32\Release\libisc.lib"
"..\..\..\Build\Release\named-checkzone.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "namedcheckzone - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Debug\named-checkzone.exe" "$(OUTDIR)\namedcheckzone.bsc"
!ELSE
ALL : "libisc - Win32 Debug" "libdns - Win32 Debug" "..\..\..\Build\Debug\named-checkzone.exe" "$(OUTDIR)\namedcheckzone.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 DebugCLEAN" "libisc - Win32 DebugCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\check-tool.obj"
-@erase "$(INTDIR)\check-tool.sbr"
-@erase "$(INTDIR)\named-checkzone.obj"
-@erase "$(INTDIR)\named-checkzone.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\named-checkzone.pdb"
-@erase "$(OUTDIR)\namedcheckzone.bsc"
-@erase "..\..\..\Build\Debug\named-checkzone.exe"
-@erase "..\..\..\Build\Debug\named-checkzone.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /D "_DEBUG" /D "__STDC__" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\namedcheckzone.bsc"
BSC32_SBRS= \
"$(INTDIR)\check-tool.sbr" \
"$(INTDIR)\named-checkzone.sbr"
"$(OUTDIR)\namedcheckzone.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\named-checkzone.pdb" /debug /machine:I386 /out:"../../../Build/Debug/named-checkzone.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\check-tool.obj" \
"$(INTDIR)\named-checkzone.obj" \
"..\..\..\lib\dns\win32\Debug\libdns.lib" \
"..\..\..\lib\isc\win32\Debug\libisc.lib"
"..\..\..\Build\Debug\named-checkzone.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
.c{$(INTDIR)}.obj::
$(CPP) @<<
@@ -181,6 +81,113 @@ LINK32_OBJS= \
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\namedcheckzone.bsc"
BSC32_SBRS= \
"$(INTDIR)\check-tool.sbr" \
"$(INTDIR)\named-checkzone.sbr"
"$(OUTDIR)\namedcheckzone.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\named-checkzone.pdb" /machine:I386 /out:"../../../Build/Release/named-checkzone.exe"
LINK32_OBJS= \
"$(INTDIR)\check-tool.obj" \
"$(INTDIR)\named-checkzone.obj"
"..\..\..\Build\Release\named-checkzone.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "namedcheckzone - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
ALL : "..\..\..\Build\Debug\named-checkzone.exe" "$(OUTDIR)\namedcheckzone.bsc"
CLEAN :
-@erase "$(INTDIR)\check-tool.obj"
-@erase "$(INTDIR)\check-tool.sbr"
-@erase "$(INTDIR)\named-checkzone.obj"
-@erase "$(INTDIR)\named-checkzone.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\named-checkzone.pdb"
-@erase "$(OUTDIR)\namedcheckzone.bsc"
-@erase "..\..\..\Build\Debug\named-checkzone.exe"
-@erase "..\..\..\Build\Debug\named-checkzone.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /D "_DEBUG" /D "__STDC__" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\namedcheckzone.bsc"
BSC32_SBRS= \
"$(INTDIR)\check-tool.sbr" \
"$(INTDIR)\named-checkzone.sbr"
"$(OUTDIR)\namedcheckzone.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\named-checkzone.pdb" /debug /machine:I386 /out:"../../../Build/Debug/named-checkzone.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\check-tool.obj" \
"$(INTDIR)\named-checkzone.obj"
"..\..\..\Build\Debug\named-checkzone.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("namedcheckzone.dep")
@@ -204,58 +211,6 @@ SOURCE="..\named-checkzone.c"
$(CPP) $(CPP_PROJ) $(SOURCE)
!IF "$(CFG)" == "namedcheckzone - Win32 Release"
"libdns - Win32 Release" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release"
cd "..\..\..\bin\check\win32"
"libdns - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ELSEIF "$(CFG)" == "namedcheckzone - Win32 Debug"
"libdns - Win32 Debug" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug"
cd "..\..\..\bin\check\win32"
"libdns - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ENDIF
!IF "$(CFG)" == "namedcheckzone - Win32 Release"
"libisc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release"
cd "..\..\..\bin\check\win32"
"libisc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ELSEIF "$(CFG)" == "namedcheckzone - Win32 Debug"
"libisc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug"
cd "..\..\..\bin\check\win32"
"libisc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\check\win32"
!ENDIF
!ENDIF

View File

@@ -13,7 +13,7 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.29 2001/11/21 02:19:00 gson Exp $
# $Id: Makefile.in,v 1.25 2001/06/08 17:18:06 gson Exp $
srcdir = @srcdir@
VPATH = @srcdir@
@@ -21,27 +21,22 @@ top_srcdir = @top_srcdir@
@BIND9_VERSION@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = -I${srcdir}/include ${DNS_INCLUDES} ${BIND9_INCLUDES} \
${ISC_INCLUDES}
CINCLUDES = -I${srcdir}/include ${DNS_INCLUDES} ${ISC_INCLUDES}
CDEFINES = -DVERSION=\"${VERSION}\"
CWARNINGS =
ISCCFGLIBS = ../../lib/isccfg/libisccfg.@A@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
BIND9LIBS = ../../lib/bind9/libbind9.@A@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCLIBS = ../../lib/isc/libisc.@A@
ISCCFGDEPLIBS = ../../lib/isccfg/libisccfg.@A@
DNSDEPLIBS = ../../lib/dns/libdns.@A@
BIND9DEPLIBS = ../../lib/bind9/libbind9.@A@
ISCDEPLIBS = ../../lib/isc/libisc.@A@
DEPLIBS = ${DNSDEPLIBS} ${BIND9DEPLIBS} ${ISCDEPLIBS} ${ISCCFGDEPLIBS}
DEPLIBS = ${DNSDEPLIBS} ${ISCDEPLIBS}
LIBS = ${DNSLIBS} ${BIND9LIBS} ${ISCLIBS} ${ISCCFGLIBS} @LIBS@
LIBS = ${DNSLIBS} ${ISCLIBS} @LIBS@
SUBDIRS =

View File

@@ -48,10 +48,6 @@ Unless it is told to query a specific name server,
.PP
When no command line arguments or options are given, will perform an
NS query for "." (the root).
.PP
It is possible to set per-user defaults for \fBdig\fR via
\fI${HOME}/.digrc\fR. This file is read and any options in it
are applied before the command line arguments.
.SH "SIMPLE USAGE"
.PP
A typical invocation of \fBdig\fR looks like:
@@ -279,16 +275,10 @@ An attempt to set \fIT\fR to less than 1 will result
in a query timeout of 1 second being applied.
.TP
\fB+tries=T\fR
Sets the number of times to try UDP queries to server to
Sets the number of times to retry UDP queries to server to
\fIT\fR instead of the default, 3. If
\fIT\fR is less than or equal to zero, the number of
tries is silently rounded up to 1.
.TP
\fB+retry=T\fR
Sets the number of times to retry UDP queries to server to
\fIT\fR instead of the default, 2. Unlike
\fI+tries\fR, this does not include the initial
query.
retries is silently rounded up to 1.
.TP
\fB+ndots=D\fR
Set the number of dots that have to appear in
@@ -362,8 +352,6 @@ isc.org.
.SH "FILES"
.PP
\fI/etc/resolv.conf\fR
.PP
\fI${HOME}/.digrc\fR
.SH "SEE ALSO"
.PP
\fBhost\fR(1),

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2000, 2001 Internet Software Consortium.
* Copyright (C) 2000-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dig.c,v 1.176 2001/12/19 12:16:38 marka Exp $ */
/* $Id: dig.c,v 1.157.2.7 2002/03/12 03:55:57 marka Exp $ */
#include <config.h>
#include <stdlib.h>
@@ -24,7 +24,6 @@
#include <isc/app.h>
#include <isc/netaddr.h>
#include <isc/parseint.h>
#include <isc/print.h>
#include <isc/string.h>
#include <isc/util.h>
@@ -63,6 +62,7 @@ extern isc_mem_t *mctx;
extern dns_messageid_t id;
extern int sendcount;
extern int ndots;
extern int tries;
extern int lookup_counter;
extern int exitcode;
extern isc_sockaddr_t bind_address;
@@ -144,11 +144,6 @@ usage(void) {
exit(1);
}
static void
version(void) {
fputs("DiG " VERSION "\n", stderr);
}
static void
help(void) {
print_usage(stdout);
@@ -172,7 +167,6 @@ help(void) {
" +[no]tcp (TCP mode, alternate syntax)\n"
" +time=### (Set query timeout) [5]\n"
" +tries=### (Set number of UDP attempts) [3]\n"
" +retry=### (Set number of UDP retries) [2]\n"
" +domain=### (Set default domainname)\n"
" +bufsize=### (Set EDNS0 Max UDP packet size)\n"
" +ndots=### (Set NDOTS value)\n"
@@ -203,9 +197,7 @@ help(void) {
" +[no]dnssec (Request DNSSEC records)\n"
" +[no]multiline (Print records in an expanded format)\n"
" global d-opts and servers (before host name) affect all queries.\n"
" local d-opts and servers (after host name) affect only that lookup.\n"
" -h (print help and exit)\n"
" -v (print version and exit)\n",
" local d-opts and servers (after host name) affect only that lookup.\n",
stdout);
}
@@ -216,12 +208,14 @@ void
received(int bytes, isc_sockaddr_t *from, dig_query_t *query) {
isc_uint64_t diff;
isc_time_t now;
isc_result_t result;
time_t tnow;
char fromtext[ISC_SOCKADDR_FORMATSIZE];
isc_sockaddr_format(from, fromtext, sizeof(fromtext));
TIME_NOW(&now);
result = isc_time_now(&now);
check_result(result, "isc_time_now");
if (query->lookup->stats && !short_form) {
diff = isc_time_microdiff(&now, &query->time_sent);
@@ -283,7 +277,9 @@ say_message(dns_rdata_t *rdata, dig_query_t *query, isc_buffer_t *buf) {
result = dns_rdata_totext(rdata, NULL, buf);
check_result(result, "dns_rdata_totext");
if (query->lookup->identify) {
TIME_NOW(&now);
result = isc_time_now(&now);
if (result != ISC_R_SUCCESS)
return (result);
diff = isc_time_microdiff(&now, &query->time_sent);
ADD_STRING(buf, " from server ");
ADD_STRING(buf, query->servname);
@@ -545,7 +541,7 @@ printgreeting(int argc, char **argv, dig_lookup_t *lookup) {
strlen(lookup->cmdline) - 1;
strncat(lookup->cmdline, "\n", remaining);
if (first) {
snprintf(append, sizeof(append),
snprintf(append, sizeof (append),
";; global options: %s %s\n",
short_form ? "short_form" : "",
printcmd ? "printcmd" : "");
@@ -595,14 +591,14 @@ reorder_args(int argc, char *argv[]) {
static isc_uint32_t
parse_uint(char *arg, const char *desc, isc_uint32_t max) {
isc_result_t result;
char *endp;
isc_uint32_t tmp;
result = isc_parse_uint32(&tmp, arg, 10);
if (result == ISC_R_SUCCESS && tmp > max)
result = ISC_R_RANGE;
if (result != ISC_R_SUCCESS)
fatal("%s '%s': %s", desc, arg, isc_result_totext(result));
tmp = strtoul(arg, &endp, 10);
if (*endp != '\0')
fatal("%s '%s' must be numeric", desc, arg);
if (tmp > max)
fatal("%s '%s' out of range", desc, arg);
return (tmp);
}
@@ -624,46 +620,28 @@ plus_option(char *option, isc_boolean_t is_batchfile,
strncpy(option_store, option, sizeof(option_store));
option_store[sizeof(option_store)-1]=0;
ptr = option_store;
cmd = next_token(&ptr,"=");
cmd=next_token(&ptr,"=");
if (cmd == NULL) {
printf(";; Invalid option %s\n",option_store);
return;
}
value = ptr;
value=ptr;
if (strncasecmp(cmd,"no",2)==0) {
cmd += 2;
state = ISC_FALSE;
}
#define FULLCHECK(A) \
do { \
size_t _l = strlen(cmd); \
if (_l >= sizeof(A) || strncasecmp(cmd, A, _l) != 0) \
goto invalid_option; \
} while (0)
#define FULLCHECK2(A, B) \
do { \
size_t _l = strlen(cmd); \
if ((_l >= sizeof(A) || strncasecmp(cmd, A, _l) != 0) && \
(_l >= sizeof(B) || strncasecmp(cmd, B, _l) != 0)) \
goto invalid_option; \
} while (0)
switch (cmd[0]) {
case 'a':
switch (cmd[1]) {
case 'a': /* aaflag */
FULLCHECK("aaflag");
lookup->aaonly = state;
break;
case 'd':
switch (cmd[2]) {
case 'd': /* additional */
FULLCHECK("additional");
lookup->section_additional = state;
break;
case 'f': /* adflag */
FULLCHECK("adflag");
lookup->adflag = state;
break;
default:
@@ -671,7 +649,6 @@ plus_option(char *option, isc_boolean_t is_batchfile,
}
break;
case 'l': /* all */
FULLCHECK("all");
lookup->section_question = state;
lookup->section_authority = state;
lookup->section_answer = state;
@@ -681,11 +658,9 @@ plus_option(char *option, isc_boolean_t is_batchfile,
printcmd = state;
break;
case 'n': /* answer */
FULLCHECK("answer");
lookup->section_answer = state;
break;
case 'u': /* authority */
FULLCHECK("authority");
lookup->section_authority = state;
break;
default:
@@ -695,11 +670,9 @@ plus_option(char *option, isc_boolean_t is_batchfile,
case 'b':
switch (cmd[1]) {
case 'e':/* besteffort */
FULLCHECK("besteffort");
lookup->besteffort = state;
break;
case 'u':/* bufsize */
FULLCHECK("bufsize");
if (value == NULL)
goto need_value;
if (!state)
@@ -716,15 +689,12 @@ plus_option(char *option, isc_boolean_t is_batchfile,
case 'c':
switch (cmd[1]) {
case 'd':/* cdflag */
FULLCHECK("cdflag");
lookup->cdflag = state;
break;
case 'm': /* cmd */
FULLCHECK("cmd");
printcmd = state;
break;
case 'o': /* comments */
FULLCHECK("comments");
lookup->comments = state;
if (lookup == default_lookup)
pluscomm = state;
@@ -736,15 +706,12 @@ plus_option(char *option, isc_boolean_t is_batchfile,
case 'd':
switch (cmd[1]) {
case 'e': /* defname */
FULLCHECK("defname");
usesearch = state;
break;
case 'n': /* dnssec */
FULLCHECK("dnssec");
lookup->dnssec = state;
break;
case 'o': /* domain */
FULLCHECK("domain");
if (value == NULL)
goto need_value;
if (!state)
@@ -757,29 +724,24 @@ plus_option(char *option, isc_boolean_t is_batchfile,
}
break;
case 'f': /* fail */
FULLCHECK("fail");
lookup->servfail_stops = state;
break;
case 'i':
switch (cmd[1]) {
case 'd': /* identify */
FULLCHECK("identify");
lookup->identify = state;
break;
case 'g': /* ignore */
default: /* Inherets default for compatibility */
FULLCHECK("ignore");
lookup->ignore = ISC_TRUE;
}
break;
case 'm': /* multiline */
FULLCHECK("multiline");
multiline = state;
break;
case 'n':
switch (cmd[1]) {
case 'd': /* ndots */
FULLCHECK("ndots");
if (value == NULL)
goto need_value;
if (!state)
@@ -787,7 +749,6 @@ plus_option(char *option, isc_boolean_t is_batchfile,
ndots = parse_uint(value, "ndots", MAXNDOTS);
break;
case 's': /* nssearch */
FULLCHECK("nssearch");
lookup->ns_search_only = state;
if (state) {
lookup->trace_root = ISC_TRUE;
@@ -810,11 +771,9 @@ plus_option(char *option, isc_boolean_t is_batchfile,
case 'q':
switch (cmd[1]) {
case 'r': /* qr */
FULLCHECK("qr");
qr = state;
break;
case 'u': /* question */
FULLCHECK("question");
lookup->section_question = state;
if (lookup == default_lookup)
plusquest = state;
@@ -823,40 +782,15 @@ plus_option(char *option, isc_boolean_t is_batchfile,
goto invalid_option;
}
break;
case 'r':
switch (cmd[1]) {
case 'e':
switch (cmd[2]) {
case 'c': /* recurse */
FULLCHECK("recurse");
lookup->recurse = state;
break;
case 't': /* retry / retries */
FULLCHECK2("retry", "retries");
if (value == NULL)
goto need_value;
if (!state)
goto invalid_option;
lookup->retries = parse_uint(value, "retries",
MAXTRIES - 1);
lookup->retries++;
break;
default:
goto invalid_option;
}
break;
default:
goto invalid_option;
}
case 'r': /* recurse */
lookup->recurse = state;
break;
case 's':
switch (cmd[1]) {
case 'e': /* search */
FULLCHECK("search");
usesearch = state;
break;
case 'h': /* short */
FULLCHECK("short");
short_form = state;
if (state) {
printcmd = ISC_FALSE;
@@ -869,7 +803,6 @@ plus_option(char *option, isc_boolean_t is_batchfile,
}
break;
case 't': /* stats */
FULLCHECK("stats");
lookup->stats = state;
break;
default:
@@ -879,12 +812,10 @@ plus_option(char *option, isc_boolean_t is_batchfile,
case 't':
switch (cmd[1]) {
case 'c': /* tcp */
FULLCHECK("tcp");
if (!is_batchfile)
lookup->tcp_mode = state;
break;
case 'i': /* timeout */
FULLCHECK("timeout");
if (value == NULL)
goto need_value;
if (!state)
@@ -896,7 +827,6 @@ plus_option(char *option, isc_boolean_t is_batchfile,
case 'r':
switch (cmd[2]) {
case 'a': /* trace */
FULLCHECK("trace");
lookup->trace = state;
lookup->trace_root = state;
if (state) {
@@ -910,12 +840,11 @@ plus_option(char *option, isc_boolean_t is_batchfile,
}
break;
case 'i': /* tries */
FULLCHECK("tries");
if (value == NULL)
goto need_value;
if (!state)
goto invalid_option;
lookup->retries = parse_uint(value, "tries",
lookup->retries = parse_uint(value, "retries",
MAXTRIES);
if (lookup->retries == 0)
lookup->retries = 1;
@@ -929,7 +858,6 @@ plus_option(char *option, isc_boolean_t is_batchfile,
}
break;
case 'v':
FULLCHECK("vc");
if (!is_batchfile)
lookup->tcp_mode = state;
break;
@@ -984,10 +912,6 @@ dash_option(char *option, char *next, dig_lookup_t **lookup,
case 'n':
nibble = ISC_TRUE;
return (ISC_FALSE);
case 'v':
version();
exit(0);
break;
}
if (value == NULL)
goto invalid_option;
@@ -1086,9 +1010,7 @@ dash_option(char *option, char *next, dig_lookup_t **lookup,
return (value_from_next);
case 'x':
*lookup = clone_lookup(default_lookup, ISC_TRUE);
if (get_reverse(textname, value, nibble, ISC_FALSE)
== ISC_R_SUCCESS)
{
if (get_reverse(textname, value, nibble) == ISC_R_SUCCESS) {
strncpy((*lookup)->textname, textname,
sizeof((*lookup)->textname));
debug("looking up %s", (*lookup)->textname);
@@ -1185,17 +1107,14 @@ parse_args(isc_boolean_t is_batchfile, isc_boolean_t config_only,
#ifndef NOPOSIX
/*
* Treat ${HOME}/.digrc as a special batchfile
* Treat .digrc as a special batchfile
*/
INSIST(batchfp == NULL);
homedir = getenv("HOME");
if (homedir != NULL) {
unsigned int n;
n = snprintf(rcfile, sizeof(rcfile), "%s/.digrc",
homedir);
if (n < sizeof(rcfile))
batchfp = fopen(rcfile, "r");
}
if (homedir != NULL)
snprintf(rcfile, sizeof(rcfile), "%s/.digrc", homedir);
else
strcpy(rcfile, ".digrc");
batchfp = fopen(rcfile, "r");
if (batchfp != NULL) {
while (fgets(batchline, sizeof(batchline),
batchfp) != 0) {
@@ -1206,8 +1125,7 @@ parse_args(isc_boolean_t is_batchfile, isc_boolean_t config_only,
while ((bargv[bargc] != NULL) &&
(bargc < 62)) {
bargc++;
bargv[bargc] =
next_token(&input, " \t\r\n");
bargv[bargc] = next_token(&input, " \t\r\n");
}
bargv[0] = argv[0];
@@ -1265,7 +1183,7 @@ parse_args(isc_boolean_t is_batchfile, isc_boolean_t config_only,
tr.base = rv[0];
tr.length = strlen(rv[0]);
result = dns_rdatatype_fromtext(&rdtype,
(isc_textregion_t *)&tr);
(isc_textregion_t *)&tr);
if (result == ISC_R_SUCCESS &&
rdtype == dns_rdatatype_ixfr)
{
@@ -1276,30 +1194,28 @@ parse_args(isc_boolean_t is_batchfile, isc_boolean_t config_only,
continue;
}
}
if (result == ISC_R_SUCCESS) {
if (result == ISC_R_SUCCESS)
{
if (lookup->rdtypeset) {
fprintf(stderr, ";; Warning, "
"extra type option\n");
}
if (rdtype == dns_rdatatype_ixfr) {
lookup->rdtype =
dns_rdatatype_ixfr;
lookup->rdtype = dns_rdatatype_ixfr;
lookup->rdtypeset = ISC_TRUE;
lookup->ixfr_serial =
parse_uint(&rv[0][5],
"serial number",
MAXSERIAL);
lookup->section_question =
plusquest;
lookup->section_question = plusquest;
lookup->comments = pluscomm;
} else {
lookup->rdtype = rdtype;
lookup->rdtypeset = ISC_TRUE;
if (rdtype ==
dns_rdatatype_axfr) {
lookup->section_question =
if (rdtype == dns_rdatatype_axfr) {
lookup->section_question =
plusquest;
lookup->comments = pluscomm;
lookup->comments = pluscomm;
}
lookup->ixfr_serial = ISC_FALSE;
}
@@ -1350,7 +1266,7 @@ parse_args(isc_boolean_t is_batchfile, isc_boolean_t config_only,
perror(batchname);
if (exitcode < 8)
exitcode = 8;
fatal("couldn't open specified batch file");
fatal("Couldn't open specified batch file");
}
/* XXX Remove code dup from shutdown code */
next_line:

View File

@@ -16,7 +16,7 @@
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dig.docbook,v 1.10 2001/11/14 06:34:24 marka Exp $ -->
<!-- $Id: dig.docbook,v 1.4.2.2 2001/11/28 23:35:02 gson Exp $ -->
<refentry>
@@ -98,12 +98,6 @@ When no command line arguments or options are given, will perform an
NS query for "." (the root).
</para>
<para>
It is possible to set per-user defaults for <command>dig</command> via
<filename>${HOME}/.digrc</filename>. This file is read and any options in it
are applied before the command line arguments.
</para>
</refsect1>
<refsect1>
@@ -422,18 +416,10 @@ in a query timeout of 1 second being applied.
<varlistentry><term><option>+tries=T</option></term>
<listitem><para>
Sets the number of times to try UDP queries to server to
Sets the number of times to retry UDP queries to server to
<parameter>T</parameter> instead of the default, 3. If
<parameter>T</parameter> is less than or equal to zero, the number of
tries is silently rounded up to 1.
</para></listitem></varlistentry>
<varlistentry><term><option>+retry=T</option></term>
<listitem><para>
Sets the number of times to retry UDP queries to server to
<parameter>T</parameter> instead of the default, 2. Unlike
<parameter>+tries</parameter>, this does not include the initial
query.
retries is silently rounded up to 1.
</para></listitem></varlistentry>
<varlistentry><term><option>+ndots=D</option></term>
@@ -541,9 +527,6 @@ will not print the initial query when it looks up the NS records for
<para>
<filename>/etc/resolv.conf</filename>
</para>
<para>
<filename>${HOME}/.digrc</filename>
</para>
</refsect1>
<refsect1>

View File

@@ -186,21 +186,11 @@ CLASS="FILENAME"
><P
>When no command line arguments or options are given, will perform an
NS query for "." (the root).</P
><P
>It is possible to set per-user defaults for <B
CLASS="COMMAND"
>dig</B
> via
<TT
CLASS="FILENAME"
>${HOME}/.digrc</TT
>. This file is read and any options in it
are applied before the command line arguments.</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN68"
NAME="AEN65"
></A
><H2
>SIMPLE USAGE</H2
@@ -297,7 +287,7 @@ CLASS="COMMAND"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN97"
NAME="AEN94"
></A
><H2
>OPTIONS</H2
@@ -511,7 +501,7 @@ CLASS="FILENAME"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN147"
NAME="AEN144"
></A
><H2
>QUERY OPTIONS</H2
@@ -884,7 +874,7 @@ CLASS="OPTION"
></DT
><DD
><P
>Sets the number of times to try UDP queries to server to
>Sets the number of times to retry UDP queries to server to
<TT
CLASS="PARAMETER"
><I
@@ -897,29 +887,7 @@ CLASS="PARAMETER"
>T</I
></TT
> is less than or equal to zero, the number of
tries is silently rounded up to 1.</P
></DD
><DT
><TT
CLASS="OPTION"
>+retry=T</TT
></DT
><DD
><P
>Sets the number of times to retry UDP queries to server to
<TT
CLASS="PARAMETER"
><I
>T</I
></TT
> instead of the default, 2. Unlike
<TT
CLASS="PARAMETER"
><I
>+tries</I
></TT
>, this does not include the initial
query.</P
retries is silently rounded up to 1.</P
></DD
><DT
><TT
@@ -1029,7 +997,7 @@ in the the OPT record in the additional section of the query.</P
><DIV
CLASS="REFSECT1"
><A
NAME="AEN345"
NAME="AEN335"
></A
><H2
>MULTIPLE QUERIES</H2
@@ -1113,7 +1081,7 @@ CLASS="LITERAL"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN363"
NAME="AEN353"
></A
><H2
>FILES</H2
@@ -1122,16 +1090,11 @@ NAME="AEN363"
CLASS="FILENAME"
>/etc/resolv.conf</TT
></P
><P
><TT
CLASS="FILENAME"
>${HOME}/.digrc</TT
></P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN369"
NAME="AEN357"
></A
><H2
>SEE ALSO</H2
@@ -1165,7 +1128,7 @@ CLASS="CITETITLE"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN382"
NAME="AEN370"
></A
><H2
>BUGS </H2

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2000, 2001 Internet Software Consortium.
* Copyright (C) 2000-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dighost.c,v 1.238 2001/11/30 01:58:39 gson Exp $ */
/* $Id: dighost.c,v 1.221.2.11 2002/02/19 22:12:57 gson Exp $ */
/*
* Notice to programmers: Do not use this code as an example of how to
@@ -52,6 +52,7 @@
#include <isc/entropy.h>
#include <isc/lang.h>
#include <isc/netaddr.h>
#include <isc/netdb.h>
#include <isc/print.h>
#include <isc/result.h>
#include <isc/string.h>
@@ -60,10 +61,22 @@
#include <isc/types.h>
#include <isc/util.h>
#include <bind9/getaddresses.h>
#include <dig/dig.h>
#ifdef HAVE_ADDRINFO
#ifdef HAVE_GETADDRINFO
#ifdef HAVE_GAISTRERROR
#define USE_GETADDRINFO
#endif
#endif
#endif
#ifndef USE_GETADDRINFO
#ifndef ISC_PLATFORM_NONSTDHERRNO
extern int h_errno;
#endif
#endif
ISC_LIST(dig_lookup_t) lookup_list;
dig_serverlist_t server_list;
ISC_LIST(dig_searchlist_t) search_list;
@@ -90,7 +103,7 @@ int sendcount = 0;
int recvcount = 0;
int sockcount = 0;
int ndots = -1;
int tries = 3;
int tries = 2;
int lookup_counter = 0;
/*
@@ -187,90 +200,54 @@ hex_dump(isc_buffer_t *b) {
printf("\n");
}
/*
* Append 'len' bytes of 'text' at '*p', failing with
* ISC_R_NOSPACE if that would advance p past 'end'.
*/
static isc_result_t
append(const char *text, int len, char **p, char *end) {
if (len > end - *p)
return (ISC_R_NOSPACE);
memcpy(*p, text, len);
*p += len;
return (ISC_R_SUCCESS);
}
static isc_result_t
reverse_octets(const char *in, char **p, char *end) {
char *dot = strchr(in, '.');
int len;
if (dot != NULL) {
isc_result_t result;
result = reverse_octets(dot + 1, p, end);
if (result != ISC_R_SUCCESS)
return (result);
result = append(".", 1, p, end);
if (result != ISC_R_SUCCESS)
return (result);
len = dot - in;
} else {
len = strlen(in);
}
return (append(in, len, p, end));
}
isc_result_t
get_reverse(char *reverse, char *value, isc_boolean_t nibble,
isc_boolean_t strict)
{
int r;
get_reverse(char *reverse, char *value, isc_boolean_t nibble) {
int adrs[4];
char working[MXNAME];
int remaining;
int i, n;
isc_result_t result;
isc_netaddr_t addr;
addr.family = AF_INET6;
r = inet_pton(AF_INET6, value, &addr.type.in6);
if (r > 0) {
/* This is a valid IPv6 address. */
result = DNS_R_BADDOTTEDQUAD;
reverse[0] = 0;
debug("get_reverse(%s)", value);
if (strspn(value, "0123456789.") == strlen(value)) {
n = sscanf(value, "%d.%d.%d.%d",
&adrs[0], &adrs[1],
&adrs[2], &adrs[3]);
if (n == 0) {
return (DNS_R_BADDOTTEDQUAD);
}
reverse[MXNAME - 1] = 0;
for (i = n - 1; i >= 0; i--) {
snprintf(working, sizeof(working), "%d.",
adrs[i]);
remaining = MXNAME - strlen(reverse) - 1;
strncat(reverse, working, remaining);
}
remaining = MXNAME - strlen(reverse) - 1;
strncat(reverse, "in-addr.arpa.", remaining);
result = ISC_R_SUCCESS;
} else if (strspn(value, "0123456789abcdefABCDEF:")
== strlen(value)) {
isc_netaddr_t addr;
dns_fixedname_t fname;
dns_name_t *name;
addr.family = AF_INET6;
n = inet_pton(AF_INET6, value, &addr.type.in6);
if (n <= 0)
return (DNS_R_BADDOTTEDQUAD);
dns_fixedname_init(&fname);
name = dns_fixedname_name(&fname);
result = dns_byaddr_createptrname(&addr, nibble, name);
if (result != ISC_R_SUCCESS)
return (result);
dns_name_format(name, reverse, MXNAME);
return (ISC_R_SUCCESS);
} else {
/*
* Not a valid IPv6 address. Assume IPv4.
* If 'strict' is not set, construct the
* in-addr.arpa name by blindly reversing
* octets whether or not they look like integers,
* so that this can be used for RFC2317 names
* and such.
*/
char *p = reverse;
char *end = reverse + MXNAME;
if (strict) {
int adrs[4];
int n;
if (strspn(value, "0123456789.") != strlen(value))
return (DNS_R_BADDOTTEDQUAD);
n = sscanf(value, "%d.%d.%d.%d",
&adrs[0], &adrs[1],
&adrs[2], &adrs[3]);
if (n == 0)
return (DNS_R_BADDOTTEDQUAD);
}
result = reverse_octets(value, &p, end);
if (result != ISC_R_SUCCESS)
return (result);
/* Append .in-addr.arpa. and a terminating NUL. */
result = append(".in-addr.arpa.", 15, &p, end);
if (result != ISC_R_SUCCESS)
return (result);
return (ISC_R_SUCCESS);
}
return (result);
}
void
@@ -320,7 +297,7 @@ make_server(const char *servname) {
debug("make_server(%s)", servname);
srv = isc_mem_allocate(mctx, sizeof(struct dig_server));
if (srv == NULL)
fatal("memory allocation failure in %s:%d",
fatal("Memory allocation failure in %s:%d",
__FILE__, __LINE__);
strncpy(srv->servername, servname, MXNAME);
srv->servername[MXNAME-1] = 0;
@@ -362,7 +339,7 @@ make_empty_lookup(void) {
looknew = isc_mem_allocate(mctx, sizeof(struct dig_lookup));
if (looknew == NULL)
fatal("memory allocation failure in %s:%d",
fatal("Memory allocation failure in %s:%d",
__FILE__, __LINE__);
looknew->pending = ISC_TRUE;
looknew->textname[0] = 0;
@@ -488,7 +465,7 @@ requeue_lookup(dig_lookup_t *lookold, isc_boolean_t servers) {
lookup_counter++;
if (lookup_counter > LOOKUP_LIMIT)
fatal("too many lookups");
fatal("Too many lookups");
looknew = clone_lookup(lookold, servers);
INSIST(looknew != NULL);
@@ -519,7 +496,7 @@ setup_text_key(void) {
secretsize = strlen(keysecret) * 3 / 4;
secretstore = isc_mem_allocate(mctx, secretsize);
if (secretstore == NULL)
fatal("memory allocation failure in %s:%d",
fatal("Memory allocation failure in %s:%d",
__FILE__, __LINE__);
isc_buffer_init(&secretbuf, secretstore, secretsize);
result = isc_base64_decodestring(keysecret, &secretbuf);
@@ -582,7 +559,7 @@ make_searchlist_entry(char *domain) {
dig_searchlist_t *search;
search = isc_mem_allocate(mctx, sizeof(*search));
if (search == NULL)
fatal("memory allocation failure in %s:%d",
fatal("Memory allocation failure in %s:%d",
__FILE__, __LINE__);
strncpy(search->origin, domain, MXNAME);
search->origin[MXNAME-1] = 0;
@@ -898,7 +875,7 @@ try_clear_lookup(dig_lookup_t *lookup) {
q->servname);
q = ISC_LIST_NEXT(q, link);
}
return (ISC_FALSE);
return (ISC_FALSE);
}
}
/*
@@ -1408,7 +1385,7 @@ setup_lookup(dig_lookup_t *lookup) {
serv = ISC_LIST_NEXT(serv, link)) {
query = isc_mem_allocate(mctx, sizeof(dig_query_t));
if (query == NULL)
fatal("memory allocation failure in %s:%d",
fatal("Memory allocation failure in %s:%d",
__FILE__, __LINE__);
debug("create query %p linked to lookup %p",
query, lookup);
@@ -1571,7 +1548,7 @@ send_tcp_connect(dig_query_t *query) {
INSIST(query->sock == NULL);
result = isc_socket_create(socketmgr,
isc_sockaddr_pf(&query->sockaddr),
isc_sockettype_tcp, &query->sock);
isc_sockettype_tcp, &query->sock) ;
check_result(result, "isc_socket_create");
sockcount++;
debug("sockcount=%d", sockcount);
@@ -1660,7 +1637,8 @@ send_udp(dig_query_t *query) {
ISC_LIST_ENQUEUE(query->sendlist, &l->sendbuf,
link);
debug("sending a request");
TIME_NOW(&query->time_sent);
result = isc_time_now(&query->time_sent);
check_result(result, "isc_time_now");
INSIST(query->sock != NULL);
result = isc_socket_sendtov(query->sock, &query->sendlist,
global_task, send_done, query,
@@ -1686,8 +1664,8 @@ send_udp(dig_query_t *query) {
*/
static void
connect_timeout(isc_task_t *task, isc_event_t *event) {
dig_lookup_t *l = NULL;
dig_query_t *query = NULL, *cq;
dig_lookup_t *l=NULL;
dig_query_t *query=NULL, *cq;
UNUSED(task);
REQUIRE(event->ev_type == ISC_TIMEREVENT_IDLE);
@@ -1866,7 +1844,8 @@ launch_next_query(dig_query_t *query, isc_boolean_t include_question) {
debug("recvcount=%d",recvcount);
if (!query->first_soa_rcvd) {
debug("sending a request in launch_next_query");
TIME_NOW(&query->time_sent);
result = isc_time_now(&query->time_sent);
check_result(result, "isc_time_now");
result = isc_socket_sendv(query->sock, &query->sendlist,
global_task, send_done, query);
check_result(result, "isc_socket_sendv");
@@ -2195,8 +2174,10 @@ recv_done(isc_task_t *task, isc_event_t *event) {
debug("before parse starts");
parseflags = DNS_MESSAGEPARSE_PRESERVEORDER;
if (l->besteffort)
if (l->besteffort) {
parseflags |= DNS_MESSAGEPARSE_BESTEFFORT;
parseflags |= DNS_MESSAGEPARSE_IGNORETRUNCATION;
}
result = dns_message_parse(msg, b, parseflags);
if (result == DNS_R_RECOVERABLE) {
printf(";; Warning: Message parser reports malformed "
@@ -2403,16 +2384,61 @@ recv_done(isc_task_t *task, isc_event_t *event) {
*/
void
get_address(char *host, in_port_t port, isc_sockaddr_t *sockaddr) {
int count;
isc_result_t result;
struct in_addr in4;
struct in6_addr in6;
#ifdef USE_GETADDRINFO
struct addrinfo *res = NULL, hints;
int result;
#else
struct hostent *he;
#endif
isc_app_block();
result = bind9_getaddresses(host, port, sockaddr, 1, &count);
isc_app_unblock();
if (result != ISC_R_SUCCESS)
fatal("couldn't get address for '%s': %s",
host, isc_result_totext(result));
INSIST(count == 1);
debug("get_address()");
if (inet_pton(AF_INET6, host, &in6) == 1) {
if (!have_ipv6)
fatal("Protocol family INET6 not supported '%s'", host);
isc_sockaddr_fromin6(sockaddr, &in6, port);
} else if (inet_pton(AF_INET, host, &in4) == 1) {
if (have_ipv4)
isc_sockaddr_fromin(sockaddr, &in4, port);
else
isc_sockaddr_v6fromin(sockaddr, &in4, port);
} else {
#ifdef USE_GETADDRINFO
memset(&hints, 0, sizeof(hints));
if (!have_ipv6)
hints.ai_family = PF_INET;
else if (!have_ipv4)
hints.ai_family = PF_INET6;
else
hints.ai_family = PF_UNSPEC;
debug ("before getaddrinfo()");
isc_app_block();
result = getaddrinfo(host, NULL, &hints, &res);
isc_app_unblock();
if (result != 0) {
fatal("Couldn't find server '%s': %s",
host, gai_strerror(result));
}
memcpy(&sockaddr->type.sa, res->ai_addr, res->ai_addrlen);
sockaddr->length = res->ai_addrlen;
isc_sockaddr_setport(sockaddr, port);
freeaddrinfo(res);
#else
debug ("before gethostbyname()");
isc_app_block();
he = gethostbyname(host);
isc_app_unblock();
if (he == NULL)
fatal("Couldn't find server '%s' (h_errno=%d)",
host, h_errno);
INSIST(he->h_addrtype == AF_INET);
isc_sockaddr_fromin(sockaddr,
(struct in_addr *)(he->h_addr_list[0]),
port);
#endif
}
}
/*

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2000, 2001 Internet Software Consortium.
* Copyright (C) 2000-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: host.c,v 1.83 2001/12/19 12:16:40 marka Exp $ */
/* $Id: host.c,v 1.76.2.2 2002/02/08 03:57:04 marka Exp $ */
#include <config.h>
#include <stdlib.h>
@@ -24,7 +24,6 @@
#include <isc/app.h>
#include <isc/commandline.h>
#include <isc/netaddr.h>
#include <isc/print.h>
#include <isc/string.h>
#include <isc/util.h>
#include <isc/task.h>
@@ -94,28 +93,111 @@ static const char *rcodetext[] = {
"BADVERS"
};
struct rtype {
unsigned int type;
const char *text;
};
static const char *rtypetext[] = {
"zero", /* 0 */
"has address", /* 1 */
"name server", /* 2 */
"MD", /* 3 */
"MF", /* 4 */
"is an alias for", /* 5 */
"SOA", /* 6 */
"MB", /* 7 */
"MG", /* 8 */
"MR", /* 9 */
"NULL", /* 10 */
"has well known services", /* 11 */
"domain name pointer", /* 12 */
"host information", /* 13 */
"MINFO", /* 14 */
"mail is handled by", /* 15 */
"text", /* 16 */
"RP", /* 17 */
"AFSDB", /* 18 */
"x25 address", /* 19 */
"isdn address", /* 20 */
"RT", /* 21 */
"NSAP", /* 22 */
"NSAP_PTR", /* 23 */
"has signature", /* 24 */
"has key", /* 25 */
"PX", /* 26 */
"GPOS", /* 27 */
"has AAAA address", /* 28 */
"LOC", /* 29 */
"has next record", /* 30 */
"EID", /* 31 */
"NIMLOC", /* 32 */
"SRV", /* 33 */
"ATMA", /* 34 */
"NAPTR", /* 35 */
"KX", /* 36 */
"CERT", /* 37 */
"has v6 address", /* 38 */
"DNAME", /* 39 */
"has optional information", /* 41 */
"has 42 record", /* 42 */
"has 43 record", /* 43 */
"has 44 record", /* 44 */
"has 45 record", /* 45 */
"has 46 record", /* 46 */
"has 47 record", /* 47 */
"has 48 record", /* 48 */
"has 49 record", /* 49 */
"has 50 record", /* 50 */
"has 51 record", /* 51 */
"has 52 record", /* 52 */
"has 53 record", /* 53 */
"has 54 record", /* 54 */
"has 55 record", /* 55 */
"has 56 record", /* 56 */
"has 57 record", /* 57 */
"has 58 record", /* 58 */
"has 59 record", /* 59 */
"has 60 record", /* 60 */
"has 61 record", /* 61 */
"has 62 record", /* 62 */
"has 63 record", /* 63 */
"has 64 record", /* 64 */
"has 65 record", /* 65 */
"has 66 record", /* 66 */
"has 67 record", /* 67 */
"has 68 record", /* 68 */
"has 69 record", /* 69 */
"has 70 record", /* 70 */
"has 71 record", /* 71 */
"has 72 record", /* 72 */
"has 73 record", /* 73 */
"has 74 record", /* 74 */
"has 75 record", /* 75 */
"has 76 record", /* 76 */
"has 77 record", /* 77 */
"has 78 record", /* 78 */
"has 79 record", /* 79 */
"has 80 record", /* 80 */
"has 81 record", /* 81 */
"has 82 record", /* 82 */
"has 83 record", /* 83 */
"has 84 record", /* 84 */
"has 85 record", /* 85 */
"has 86 record", /* 86 */
"has 87 record", /* 87 */
"has 88 record", /* 88 */
"has 89 record", /* 89 */
"has 90 record", /* 90 */
"has 91 record", /* 91 */
"has 92 record", /* 92 */
"has 93 record", /* 93 */
"has 94 record", /* 94 */
"has 95 record", /* 95 */
"has 96 record", /* 96 */
"has 97 record", /* 97 */
"has 98 record", /* 98 */
"has 99 record", /* 99 */
"UINFO", /* 100 */
"UID", /* 101 */
"GID", /* 102 */
"UNSPEC"}; /* 103 */
struct rtype rtypes[] = {
{ 1, "has address" },
{ 2, "name server" },
{ 5, "is an alias for" },
{ 11, "has well known services" },
{ 12, "domain name pointer" },
{ 13, "host information" },
{ 15, "mail is handled by" },
{ 16, "descriptive text" },
{ 19, "x25 address" },
{ 20, "ISDN address" },
{ 24, "has signature" },
{ 25, "has key" },
{ 28, "has IPv6 address" },
{ 29, "location" },
{ 0, NULL }
};
static void
show_usage(void) {
@@ -145,14 +227,17 @@ dighost_shutdown(void) {
}
void
received(int bytes, isc_sockaddr_t *from, dig_query_t *query) {
received(int bytes, isc_sockaddr_t *from, dig_query_t *query)
{
isc_time_t now;
isc_result_t result;
int diff;
if (!short_form) {
char fromtext[ISC_SOCKADDR_FORMATSIZE];
isc_sockaddr_format(from, fromtext, sizeof(fromtext));
TIME_NOW(&now);
result = isc_time_now(&now);
check_result(result, "isc_time_now");
diff = (int) isc_time_microdiff(&now, &query->time_sent);
printf("Received %u bytes from %s in %d ms\n",
bytes, fromtext, diff/1000);
@@ -218,6 +303,7 @@ printsection(dns_message_t *msg, dns_section_t sectionid,
char t[4096];
isc_boolean_t first;
isc_boolean_t no_rdata;
const char *rtt;
if (sectionid == DNS_SECTION_QUESTION)
no_rdata = ISC_TRUE;
@@ -265,27 +351,15 @@ printsection(dns_message_t *msg, dns_section_t sectionid,
} else {
loopresult = dns_rdataset_first(rdataset);
while (loopresult == ISC_R_SUCCESS) {
struct rtype *t;
const char *rtt;
char typebuf[DNS_RDATATYPE_FORMATSIZE];
char typebuf2[DNS_RDATATYPE_FORMATSIZE
+ 20];
dns_rdataset_current(rdataset, &rdata);
for (t = rtypes; t->text != NULL; t++) {
if (t->type == rdata.type) {
rtt = t->text;
goto found;
}
}
dns_rdatatype_format(rdata.type,
typebuf,
sizeof(typebuf));
snprintf(typebuf2, sizeof(typebuf2),
"has %s record", typebuf);
rtt = typebuf2;
found:
if (rdata.type <= 103)
rtt = rtypetext[rdata.type];
else if (rdata.type == 249)
rtt = "key";
else if (rdata.type == 250)
rtt = "signature";
else
rtt = "unknown";
say_message(print_name, rtt,
&rdata, query);
dns_rdata_reset(&rdata);
@@ -457,15 +531,6 @@ printmessage(dig_query_t *query, dns_message_t *msg, isc_boolean_t headers) {
if (!short_form)
printf("\n");
if (short_form && ISC_LIST_EMPTY(msg->sections[DNS_SECTION_ANSWER])) {
char namestr[DNS_NAME_FORMATSIZE];
char typestr[DNS_RDATATYPE_FORMATSIZE];
dns_name_format(query->lookup->name, namestr, sizeof(namestr));
dns_rdatatype_format(query->lookup->rdtype, typestr,
sizeof(typestr));
printf("%s has no %s record\n", namestr, typestr);
}
return (result);
}
@@ -507,7 +572,7 @@ parse_args(isc_boolean_t is_batchfile, int argc, char **argv) {
(isc_textregion_t *)&tr);
if (result != ISC_R_SUCCESS)
fprintf(stderr, "warning: invalid type: %s\n",
fprintf(stderr,"Warning: invalid type: %s\n",
isc_commandline_argument);
else {
lookup->rdtype = rdtype;
@@ -521,7 +586,7 @@ parse_args(isc_boolean_t is_batchfile, int argc, char **argv) {
(isc_textregion_t *)&tr);
if (result != ISC_R_SUCCESS)
fprintf(stderr, "warning: invalid class: %s\n",
fprintf(stderr,"Warning: invalid class: %s\n",
isc_commandline_argument);
else {
lookup->rdclass = rdclass;
@@ -576,10 +641,9 @@ parse_args(isc_boolean_t is_batchfile, int argc, char **argv) {
break;
}
}
if (isc_commandline_index >= argc)
if (isc_commandline_index >= argc) {
show_usage();
}
strncpy(hostname, argv[isc_commandline_index], sizeof(hostname));
hostname[sizeof(hostname)-1]=0;
if (argc > isc_commandline_index + 1) {
@@ -590,9 +654,7 @@ parse_args(isc_boolean_t is_batchfile, int argc, char **argv) {
}
lookup->pending = ISC_FALSE;
if (get_reverse(store, hostname, lookup->nibble, ISC_TRUE)
== ISC_R_SUCCESS)
{
if (get_reverse(store, hostname, lookup->nibble) == ISC_R_SUCCESS) {
strncpy(lookup->textname, store, sizeof(lookup->textname));
lookup->textname[sizeof(lookup->textname)-1] = 0;
lookup->rdtype = dns_rdatatype_ptr;

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dig.h,v 1.76 2001/10/04 07:02:28 halley Exp $ */
/* $Id: dig.h,v 1.71.2.3 2001/11/15 01:24:13 marka Exp $ */
#ifndef DIG_H
#define DIG_H
@@ -189,8 +189,7 @@ void
get_address(char *host, in_port_t port, isc_sockaddr_t *sockaddr);
isc_result_t
get_reverse(char *reverse, char *value, isc_boolean_t nibble,
isc_boolean_t strict);
get_reverse(char *reverse, char *value, isc_boolean_t nibble);
void
fatal(const char *format, ...) ISC_FORMAT_PRINTF(1, 2);

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2000, 2001 Internet Software Consortium.
* Copyright (C) 2000-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: nslookup.c,v 1.95 2001/12/19 12:16:42 marka Exp $ */
/* $Id: nslookup.c,v 1.90.2.3 2002/03/20 22:45:11 marka Exp $ */
#include <config.h>
@@ -25,7 +25,6 @@
#include <isc/buffer.h>
#include <isc/commandline.h>
#include <isc/event.h>
#include <isc/parseint.h>
#include <isc/string.h>
#include <isc/timer.h>
#include <isc/util.h>
@@ -48,12 +47,17 @@ extern ISC_LIST(dig_lookup_t) lookup_list;
extern ISC_LIST(dig_server_t) server_list;
extern ISC_LIST(dig_searchlist_t) search_list;
extern isc_boolean_t usesearch, debugging;
extern isc_boolean_t have_ipv6, usesearch, qr, debugging;
extern in_port_t port;
extern unsigned int timeout;
extern isc_mem_t *mctx;
extern dns_messageid_t id;
extern int sendcount;
extern int ndots;
extern int tries;
extern int lookup_counter;
extern int exitcode;
extern isc_taskmgr_t *taskmgr;
extern isc_task_t *global_task;
extern char *progname;
@@ -133,8 +137,7 @@ static const char *rtypetext[] = {
"v6 address = ", /* 38 */
"dname = ", /* 39 */
"rtype_40 = ", /* 40 */
"optional = " /* 41 */
};
"optional = "}; /* 41 */
#define N_KNOWN_RRTYPES (sizeof(rtypetext) / sizeof(rtypetext[0]))
@@ -518,45 +521,7 @@ safecpy(char *dest, char *src, int size) {
strncpy(dest, src, size);
dest[size-1] = 0;
}
static isc_result_t
parse_uint(isc_uint32_t *uip, const char *value, isc_uint32_t max, const char *desc) {
isc_uint32_t n;
isc_result_t result = isc_parse_uint32(&n, value, 10);
if (result == ISC_R_SUCCESS && n > max)
result = ISC_R_RANGE;
if (result != ISC_R_SUCCESS) {
printf("invalid %s '%s': %s\n", desc,
value, isc_result_totext(result));
return result;
}
*uip = n;
return (ISC_R_SUCCESS);
}
static void
set_port(const char *value) {
isc_uint32_t n;
isc_result_t result = parse_uint(&n, value, 65535, "port");
if (result == ISC_R_SUCCESS)
port = n;
}
static void
set_timeout(const char *value) {
isc_uint32_t n;
isc_result_t result = parse_uint(&n, value, UINT_MAX, "timeout");
if (result == ISC_R_SUCCESS)
timeout = n;
}
static void
set_tries(const char *value) {
isc_uint32_t n;
isc_result_t result = parse_uint(&n, value, INT_MAX, "tries");
if (result == ISC_R_SUCCESS)
tries = n;
}
static void
setoption(char *opt) {
@@ -583,6 +548,9 @@ setoption(char *opt) {
} else if (strncasecmp(opt, "qu=", 3) == 0) {
if (testtype(&opt[3]))
safecpy(deftype, &opt[3], sizeof(deftype));
} else if (strncasecmp(opt, "q=", 2) == 0) {
if (testtype(&opt[2]))
safecpy(deftype, &opt[2], sizeof(deftype));
} else if (strncasecmp(opt, "domain=", 7) == 0) {
safecpy(domainopt, &opt[7], sizeof(domainopt));
set_search_domain(domainopt);
@@ -592,21 +560,21 @@ setoption(char *opt) {
set_search_domain(domainopt);
usesearch = ISC_TRUE;
} else if (strncasecmp(opt, "port=", 5) == 0) {
set_port(&opt[5]);
port = atoi(&opt[5]);
} else if (strncasecmp(opt, "po=", 3) == 0) {
set_port(&opt[3]);
port = atoi(&opt[3]);
} else if (strncasecmp(opt, "timeout=", 8) == 0) {
set_timeout(&opt[8]);
timeout = atoi(&opt[8]);
} else if (strncasecmp(opt, "t=", 2) == 0) {
set_timeout(&opt[2]);
timeout = atoi(&opt[2]);
} else if (strncasecmp(opt, "rec", 3) == 0) {
recurse = ISC_TRUE;
} else if (strncasecmp(opt, "norec", 5) == 0) {
recurse = ISC_FALSE;
} else if (strncasecmp(opt, "retry=", 6) == 0) {
set_tries(&opt[6]);
tries = atoi(&opt[6]);
} else if (strncasecmp(opt, "ret=", 4) == 0) {
set_tries(&opt[4]);
tries = atoi(&opt[4]);
} else if (strncasecmp(opt, "def", 3) == 0) {
usesearch = ISC_TRUE;
} else if (strncasecmp(opt, "nodef", 5) == 0) {
@@ -623,11 +591,11 @@ setoption(char *opt) {
debugging = ISC_TRUE;
} else if (strncasecmp(opt, "nod2", 4) == 0) {
debugging = ISC_FALSE;
} else if (strncasecmp(opt, "search", 3) == 0) {
} else if (strncasecmp(opt, "search",3) == 0) {
usesearch = ISC_TRUE;
} else if (strncasecmp(opt, "nosearch", 5) == 0) {
} else if (strncasecmp(opt, "nosearch",5) == 0) {
usesearch = ISC_FALSE;
} else if (strncasecmp(opt, "sil", 3) == 0) {
} else if (strncasecmp(opt, "sil",3) == 0) {
deprecation_msg = ISC_FALSE;
} else {
printf("*** Invalid option: %s\n", opt);
@@ -659,9 +627,7 @@ addlookup(char *opt) {
rdclass = dns_rdataclass_in;
}
lookup = make_empty_lookup();
if (get_reverse(store, opt, lookup->nibble, ISC_TRUE)
== ISC_R_SUCCESS)
{
if (get_reverse(store, opt, lookup->nibble) == ISC_R_SUCCESS) {
safecpy(lookup->textname, store, sizeof(lookup->textname));
lookup->rdtype = dns_rdatatype_ptr;
lookup->rdtypeset = ISC_TRUE;

View File

@@ -42,7 +42,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
@@ -50,7 +50,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/dig.exe"
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/dig.exe"
!ELSEIF "$(CFG)" == "dig - Win32 Debug"
@@ -66,7 +66,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# SUBTRACT CPP /X /u /YX
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
@@ -75,7 +75,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/dig.exe" /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/dig.exe" /pdbtype:sept
!ENDIF

View File

@@ -25,29 +25,15 @@ NULL=
NULL=nul
!ENDIF
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "dig - Win32 Release"
OUTDIR=.\Release
INTDIR=.\Release
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Release\dig.exe"
!ELSE
ALL : "libbind9 - Win32 Release" "libisc - Win32 Release" "libdns - Win32 Release" "..\..\..\Build\Release\dig.exe"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 ReleaseCLEAN" "libisc - Win32 ReleaseCLEAN" "libbind9 - Win32 ReleaseCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\dig.obj"
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\vc60.idb"
@@ -56,89 +42,8 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\dig.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\dig.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\dig.pdb" /machine:I386 /out:"../../../Build/Release/dig.exe"
LINK32_OBJS= \
"$(INTDIR)\dig.obj" \
"$(INTDIR)\dighost.obj" \
"..\..\..\lib\dns\win32\Release\libdns.lib" \
"..\..\..\lib\isc\win32\Release\libisc.lib" \
"..\..\..\lib\bind9\win32\Release\libbind9.lib"
"..\..\..\Build\Release\dig.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "dig - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Debug\dig.exe" "$(OUTDIR)\dig.bsc"
!ELSE
ALL : "libbind9 - Win32 Debug" "libisc - Win32 Debug" "libdns - Win32 Debug" "..\..\..\Build\Debug\dig.exe" "$(OUTDIR)\dig.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 DebugCLEAN" "libisc - Win32 DebugCLEAN" "libbind9 - Win32 DebugCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\dig.obj"
-@erase "$(INTDIR)\dig.sbr"
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\dighost.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\dig.bsc"
-@erase "$(OUTDIR)\dig.pdb"
-@erase "..\..\..\Build\Debug\dig.exe"
-@erase "..\..\..\Build\Debug\dig.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\dig.bsc"
BSC32_SBRS= \
"$(INTDIR)\dig.sbr" \
"$(INTDIR)\dighost.sbr"
"$(OUTDIR)\dig.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\dig.pdb" /debug /machine:I386 /out:"../../../Build/Debug/dig.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\dig.obj" \
"$(INTDIR)\dighost.obj" \
"..\..\..\lib\dns\win32\Debug\libdns.lib" \
"..\..\..\lib\isc\win32\Debug\libisc.lib" \
"..\..\..\lib\bind9\win32\Debug\libbind9.lib"
"..\..\..\Build\Debug\dig.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
CPP=cl.exe
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\dig.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
@@ -170,6 +75,106 @@ LINK32_OBJS= \
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\dig.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\dig.pdb" /machine:I386 /out:"../../../Build/Release/dig.exe"
LINK32_OBJS= \
"$(INTDIR)\dig.obj" \
"$(INTDIR)\dighost.obj"
"..\..\..\Build\Release\dig.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "dig - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
ALL : "..\..\..\Build\Debug\dig.exe" "$(OUTDIR)\dig.bsc"
CLEAN :
-@erase "$(INTDIR)\dig.obj"
-@erase "$(INTDIR)\dig.sbr"
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\dighost.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\dig.bsc"
-@erase "$(OUTDIR)\dig.pdb"
-@erase "..\..\..\Build\Debug\dig.exe"
-@erase "..\..\..\Build\Debug\dig.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\dig.bsc"
BSC32_SBRS= \
"$(INTDIR)\dig.sbr" \
"$(INTDIR)\dighost.sbr"
"$(OUTDIR)\dig.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\dig.pdb" /debug /machine:I386 /out:"../../../Build/Debug/dig.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\dig.obj" \
"$(INTDIR)\dighost.obj"
"..\..\..\Build\Debug\dig.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("dig.dep")
@@ -217,84 +222,6 @@ SOURCE=..\dighost.c
!ENDIF
!IF "$(CFG)" == "dig - Win32 Release"
"libdns - Win32 Release" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libdns - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "dig - Win32 Debug"
"libdns - Win32 Debug" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libdns - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!IF "$(CFG)" == "dig - Win32 Release"
"libisc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libisc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "dig - Win32 Debug"
"libisc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libisc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!IF "$(CFG)" == "dig - Win32 Release"
"libbind9 - Win32 Release" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libbind9 - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "dig - Win32 Debug"
"libbind9 - Win32 Debug" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libbind9 - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!ENDIF

View File

@@ -42,7 +42,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
@@ -50,7 +50,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/host.exe"
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/host.exe"
!ELSEIF "$(CFG)" == "host - Win32 Debug"
@@ -66,7 +66,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# SUBTRACT CPP /X /u /YX
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
@@ -75,7 +75,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/host.exe" /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/host.exe" /pdbtype:sept
!ENDIF

View File

@@ -25,29 +25,15 @@ NULL=
NULL=nul
!ENDIF
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "host - Win32 Release"
OUTDIR=.\Release
INTDIR=.\Release
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Release\host.exe"
!ELSE
ALL : "libbind9 - Win32 Release" "libisc - Win32 Release" "libdns - Win32 Release" "..\..\..\Build\Release\host.exe"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 ReleaseCLEAN" "libisc - Win32 ReleaseCLEAN" "libbind9 - Win32 ReleaseCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\host.obj"
-@erase "$(INTDIR)\vc60.idb"
@@ -56,89 +42,8 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\host.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\host.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\host.pdb" /machine:I386 /out:"../../../Build/Release/host.exe"
LINK32_OBJS= \
"$(INTDIR)\dighost.obj" \
"$(INTDIR)\host.obj" \
"..\..\..\lib\dns\win32\Release\libdns.lib" \
"..\..\..\lib\isc\win32\Release\libisc.lib" \
"..\..\..\lib\bind9\win32\Release\libbind9.lib"
"..\..\..\Build\Release\host.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "host - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Debug\host.exe" "$(OUTDIR)\host.bsc"
!ELSE
ALL : "libbind9 - Win32 Debug" "libisc - Win32 Debug" "libdns - Win32 Debug" "..\..\..\Build\Debug\host.exe" "$(OUTDIR)\host.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 DebugCLEAN" "libisc - Win32 DebugCLEAN" "libbind9 - Win32 DebugCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\dighost.sbr"
-@erase "$(INTDIR)\host.obj"
-@erase "$(INTDIR)\host.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\host.bsc"
-@erase "$(OUTDIR)\host.pdb"
-@erase "..\..\..\Build\Debug\host.exe"
-@erase "..\..\..\Build\Debug\host.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\host.bsc"
BSC32_SBRS= \
"$(INTDIR)\dighost.sbr" \
"$(INTDIR)\host.sbr"
"$(OUTDIR)\host.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\host.pdb" /debug /machine:I386 /out:"../../../Build/Debug/host.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\dighost.obj" \
"$(INTDIR)\host.obj" \
"..\..\..\lib\dns\win32\Debug\libdns.lib" \
"..\..\..\lib\isc\win32\Debug\libisc.lib" \
"..\..\..\lib\bind9\win32\Debug\libbind9.lib"
"..\..\..\Build\Debug\host.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
CPP=cl.exe
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\host.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
@@ -170,6 +75,106 @@ LINK32_OBJS= \
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\host.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\host.pdb" /machine:I386 /out:"../../../Build/Release/host.exe"
LINK32_OBJS= \
"$(INTDIR)\dighost.obj" \
"$(INTDIR)\host.obj"
"..\..\..\Build\Release\host.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "host - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
ALL : "..\..\..\Build\Debug\host.exe" "$(OUTDIR)\host.bsc"
CLEAN :
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\dighost.sbr"
-@erase "$(INTDIR)\host.obj"
-@erase "$(INTDIR)\host.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\host.bsc"
-@erase "$(OUTDIR)\host.pdb"
-@erase "..\..\..\Build\Debug\host.exe"
-@erase "..\..\..\Build\Debug\host.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\host.bsc"
BSC32_SBRS= \
"$(INTDIR)\dighost.sbr" \
"$(INTDIR)\host.sbr"
"$(OUTDIR)\host.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\host.pdb" /debug /machine:I386 /out:"../../../Build/Debug/host.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\dighost.obj" \
"$(INTDIR)\host.obj"
"..\..\..\Build\Debug\host.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("host.dep")
@@ -217,84 +222,6 @@ SOURCE=..\host.c
!ENDIF
!IF "$(CFG)" == "host - Win32 Release"
"libdns - Win32 Release" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libdns - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "host - Win32 Debug"
"libdns - Win32 Debug" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libdns - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!IF "$(CFG)" == "host - Win32 Release"
"libisc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libisc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "host - Win32 Debug"
"libisc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libisc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!IF "$(CFG)" == "host - Win32 Release"
"libbind9 - Win32 Release" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libbind9 - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "host - Win32 Debug"
"libbind9 - Win32 Debug" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libbind9 - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!ENDIF

View File

@@ -42,7 +42,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
@@ -50,7 +50,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/nslookup.exe"
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/nslookup.exe"
!ELSEIF "$(CFG)" == "nslookup - Win32 Debug"
@@ -66,7 +66,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# SUBTRACT CPP /X /u /YX
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
@@ -75,7 +75,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/nslookup.exe" /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/nslookup.exe" /pdbtype:sept
!ENDIF

View File

@@ -25,29 +25,15 @@ NULL=
NULL=nul
!ENDIF
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "nslookup - Win32 Release"
OUTDIR=.\Release
INTDIR=.\Release
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Release\nslookup.exe"
!ELSE
ALL : "libbind9 - Win32 Release" "libisc - Win32 Release" "libdns - Win32 Release" "..\..\..\Build\Release\nslookup.exe"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 ReleaseCLEAN" "libisc - Win32 ReleaseCLEAN" "libbind9 - Win32 ReleaseCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\nslookup.obj"
-@erase "$(INTDIR)\vc60.idb"
@@ -56,89 +42,8 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\nslookup.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\nslookup.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\nslookup.pdb" /machine:I386 /out:"../../../Build/Release/nslookup.exe"
LINK32_OBJS= \
"$(INTDIR)\dighost.obj" \
"$(INTDIR)\nslookup.obj" \
"..\..\..\lib\dns\win32\Release\libdns.lib" \
"..\..\..\lib\isc\win32\Release\libisc.lib" \
"..\..\..\lib\bind9\win32\Release\libbind9.lib"
"..\..\..\Build\Release\nslookup.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "nslookup - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Debug\nslookup.exe" "$(OUTDIR)\nslookup.bsc"
!ELSE
ALL : "libbind9 - Win32 Debug" "libisc - Win32 Debug" "libdns - Win32 Debug" "..\..\..\Build\Debug\nslookup.exe" "$(OUTDIR)\nslookup.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 DebugCLEAN" "libisc - Win32 DebugCLEAN" "libbind9 - Win32 DebugCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\dighost.sbr"
-@erase "$(INTDIR)\nslookup.obj"
-@erase "$(INTDIR)\nslookup.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\nslookup.bsc"
-@erase "$(OUTDIR)\nslookup.pdb"
-@erase "..\..\..\Build\Debug\nslookup.exe"
-@erase "..\..\..\Build\Debug\nslookup.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\nslookup.bsc"
BSC32_SBRS= \
"$(INTDIR)\dighost.sbr" \
"$(INTDIR)\nslookup.sbr"
"$(OUTDIR)\nslookup.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\nslookup.pdb" /debug /machine:I386 /out:"../../../Build/Debug/nslookup.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\dighost.obj" \
"$(INTDIR)\nslookup.obj" \
"..\..\..\lib\dns\win32\Debug\libdns.lib" \
"..\..\..\lib\isc\win32\Debug\libisc.lib" \
"..\..\..\lib\bind9\win32\Debug\libbind9.lib"
"..\..\..\Build\Debug\nslookup.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
CPP=cl.exe
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\nslookup.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
@@ -170,6 +75,106 @@ LINK32_OBJS= \
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\nslookup.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\nslookup.pdb" /machine:I386 /out:"../../../Build/Release/nslookup.exe"
LINK32_OBJS= \
"$(INTDIR)\dighost.obj" \
"$(INTDIR)\nslookup.obj"
"..\..\..\Build\Release\nslookup.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "nslookup - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
ALL : "..\..\..\Build\Debug\nslookup.exe" "$(OUTDIR)\nslookup.bsc"
CLEAN :
-@erase "$(INTDIR)\dighost.obj"
-@erase "$(INTDIR)\dighost.sbr"
-@erase "$(INTDIR)\nslookup.obj"
-@erase "$(INTDIR)\nslookup.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\nslookup.bsc"
-@erase "$(OUTDIR)\nslookup.pdb"
-@erase "..\..\..\Build\Debug\nslookup.exe"
-@erase "..\..\..\Build\Debug\nslookup.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\nslookup.bsc"
BSC32_SBRS= \
"$(INTDIR)\dighost.sbr" \
"$(INTDIR)\nslookup.sbr"
"$(OUTDIR)\nslookup.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\nslookup.pdb" /debug /machine:I386 /out:"../../../Build/Debug/nslookup.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\dighost.obj" \
"$(INTDIR)\nslookup.obj"
"..\..\..\Build\Debug\nslookup.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("nslookup.dep")
@@ -217,84 +222,6 @@ SOURCE=..\nslookup.c
!ENDIF
!IF "$(CFG)" == "nslookup - Win32 Release"
"libdns - Win32 Release" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libdns - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "nslookup - Win32 Debug"
"libdns - Win32 Debug" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libdns - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!IF "$(CFG)" == "nslookup - Win32 Release"
"libisc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libisc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "nslookup - Win32 Debug"
"libisc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libisc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!IF "$(CFG)" == "nslookup - Win32 Release"
"libbind9 - Win32 Release" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release"
cd "..\..\..\bin\dig\win32"
"libbind9 - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ELSEIF "$(CFG)" == "nslookup - Win32 Debug"
"libbind9 - Win32 Debug" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug"
cd "..\..\..\bin\dig\win32"
"libbind9 - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\dig\win32"
!ENDIF
!ENDIF

View File

@@ -13,7 +13,7 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.21 2001/11/06 20:05:00 bwelling Exp $
# $Id: Makefile.in,v 1.19 2001/06/01 00:44:58 bwelling Exp $
srcdir = @srcdir@
VPATH = @srcdir@
@@ -21,14 +21,14 @@ top_srcdir = @top_srcdir@
@BIND9_VERSION@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = ${DNS_INCLUDES} ${ISC_INCLUDES}
CDEFINES =
CWARNINGS =
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCLIBS = ../../lib/isc/libisc.@A@
DNSDEPLIBS = ../../lib/dns/libdns.@A@

View File

@@ -17,7 +17,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssec-keygen.c,v 1.60 2002/01/21 10:13:19 bwelling Exp $ */
/* $Id: dnssec-keygen.c,v 1.48.2.1 2001/10/05 00:21:44 bwelling Exp $ */
#include <config.h>
@@ -48,8 +48,6 @@
const char *program = "dnssec-keygen";
int verbose;
static const char *algs = "RSA | RSAMD5 | DH | DSA | RSASHA1 | HMAC-MD5";
static isc_boolean_t
dsa_size_ok(int size) {
return (ISC_TF(size >= 512 && size <= 1024 && size % 64 == 0));
@@ -61,29 +59,27 @@ usage(void) {
fprintf(stderr, " %s -a alg -b bits -n type [options] name\n\n",
program);
fprintf(stderr, "Required options:\n");
fprintf(stderr, " -a algorithm: %s\n", algs);
fprintf(stderr, " -a algorithm: RSA | RSAMD5 | DH | DSA | HMAC-MD5"
"\n");
fprintf(stderr, " -b key size, in bits:\n");
fprintf(stderr, " RSAMD5:\t\t[512..%d]\n", MAX_RSA);
fprintf(stderr, " RSASHA1:\t\t[512..%d]\n", MAX_RSA);
fprintf(stderr, " RSA:\t\t[512..%d]\n", MAX_RSA);
fprintf(stderr, " DH:\t\t[128..4096]\n");
fprintf(stderr, " DSA:\t\t[512..1024] and divisible by 64\n");
fprintf(stderr, " HMAC-MD5:\t[1..512]\n");
fprintf(stderr, " -n nametype: ZONE | HOST | ENTITY | USER\n");
fprintf(stderr, " name: owner of the key\n");
fprintf(stderr, "Other options:\n");
fprintf(stderr, " -c <class> (default: IN)\n");
fprintf(stderr, " -e use large exponent (RSAMD5/RSASHA1 only)\n");
fprintf(stderr, " -g <generator> use specified generator "
"(DH only)\n");
fprintf(stderr, " -t <type>: "
"AUTHCONF | NOAUTHCONF | NOAUTH | NOCONF "
"(default: AUTHCONF)\n");
fprintf(stderr, " -p <protocol>: "
"default: 3 [dnssec]\n");
fprintf(stderr, " -s <strength> strength value this key signs DNS "
"records with (default: 0)\n");
fprintf(stderr, " -r <randomdev>: a file containing random data\n");
fprintf(stderr, " -v <verbose level>\n");
fprintf(stderr, " -c class (default: IN)\n");
fprintf(stderr, " -e use large exponent (RSA only)\n");
fprintf(stderr, " -g use specified generator (DH only)\n");
fprintf(stderr, " -t type: AUTHCONF | NOAUTHCONF | NOAUTH | NOCONF "
"(default: AUTHCONF)\n");
fprintf(stderr, " -p protocol value "
"(default: 2 [email] for USER, 3 [dnssec] otherwise)\n");
fprintf(stderr, " -s strength value this key signs DNS records "
"with (default: 0)\n");
fprintf(stderr, " -r randomdev (a file containing random data)\n");
fprintf(stderr, " -v verbose level\n");
fprintf(stderr, "Output:\n");
fprintf(stderr, " K<name>+<alg>+<id>.key, "
"K<name>+<alg>+<id>.private\n");
@@ -95,7 +91,8 @@ int
main(int argc, char **argv) {
char *algname = NULL, *nametype = NULL, *type = NULL;
char *classname = NULL;
char *endp;
char *randomfile = NULL;
char *prog, *endp;
dst_key_t *key = NULL, *oldkey;
dns_fixedname_t fname;
dns_name_t *name;
@@ -113,15 +110,22 @@ main(int argc, char **argv) {
isc_entropy_t *ectx = NULL;
dns_rdataclass_t rdclass;
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
if ((prog = strrchr(argv[0],'/')) == NULL)
prog = isc_mem_strdup(mctx, argv[0]);
else
prog = isc_mem_strdup(mctx, ++prog);
if (prog == NULL)
fatal("out of memory");
if (argc == 1)
usage();
RUNTIME_CHECK(isc_mem_create(0, 0, &mctx) == ISC_R_SUCCESS);
dns_result_register();
while ((ch = isc_commandline_parse(argc, argv,
"a:b:c:eg:n:t:p:s:r:v:h")) != -1)
"a:b:c:eg:n:t:p:s:hr:v:")) != -1)
{
switch (ch) {
case 'a':
@@ -146,9 +150,13 @@ main(int argc, char **argv) {
break;
case 'n':
nametype = isc_commandline_argument;
if (nametype == NULL)
fatal("out of memory");
break;
case 't':
type = isc_commandline_argument;
if (type == NULL)
fatal("out of memory");
break;
case 'p':
protocol = strtol(isc_commandline_argument, &endp, 10);
@@ -164,7 +172,7 @@ main(int argc, char **argv) {
"[0..15]");
break;
case 'r':
setup_entropy(mctx, isc_commandline_argument, &ectx);
randomfile = isc_commandline_argument;
break;
case 'v':
endp = NULL;
@@ -182,8 +190,7 @@ main(int argc, char **argv) {
}
}
if (ectx == NULL)
setup_entropy(mctx, NULL, &ectx);
setup_entropy(mctx, randomfile, &ectx);
ret = dst_lib_init(mctx, ectx,
ISC_ENTROPY_BLOCKING | ISC_ENTROPY_GOODONLY);
if (ret != ISC_R_SUCCESS)
@@ -198,7 +205,9 @@ main(int argc, char **argv) {
if (algname == NULL)
fatal("no algorithm was specified");
if (strcasecmp(algname, "HMAC-MD5") == 0)
if (strcasecmp(algname, "RSA") == 0)
alg = DNS_KEYALG_RSA;
else if (strcasecmp(algname, "HMAC-MD5") == 0)
alg = DST_ALG_HMACMD5;
else {
r.base = algname;
@@ -228,8 +237,7 @@ main(int argc, char **argv) {
fatal("key size not specified (-b option)");
switch (alg) {
case DNS_KEYALG_RSAMD5:
case DNS_KEYALG_RSASHA1:
case DNS_KEYALG_RSA:
if (size != 0 && (size < 512 || size > MAX_RSA))
fatal("RSA key size %d out of range", size);
break;
@@ -239,7 +247,7 @@ main(int argc, char **argv) {
break;
case DNS_KEYALG_DSA:
if (size != 0 && !dsa_size_ok(size))
fatal("invalid DSS key size: %d", size);
fatal("Invalid DSS key size: %d", size);
break;
case DST_ALG_HMACMD5:
if (size < 1 || size > 512)
@@ -247,12 +255,11 @@ main(int argc, char **argv) {
break;
}
if (!(alg == DNS_KEYALG_RSAMD5 || alg == DNS_KEYALG_RSASHA1) &&
rsa_exp != 0)
fatal("specified RSA exponent for a non-RSA key");
if (alg != DNS_KEYALG_RSA && rsa_exp != 0)
fatal("specified RSA exponent without RSA");
if (alg != DNS_KEYALG_DH && generator != 0)
fatal("specified DH generator for a non-DH key");
fatal("specified DH generator without DH");
if (nametype == NULL)
fatal("no nametype specified");
@@ -266,25 +273,31 @@ main(int argc, char **argv) {
else
fatal("invalid nametype %s", nametype);
rdclass = strtoclass(classname);
if (classname != NULL) {
r.base = classname;
r.length = strlen(classname);
ret = dns_rdataclass_fromtext(&rdclass, &r);
if (ret != ISC_R_SUCCESS)
fatal("unknown class %s",classname);
} else
rdclass = dns_rdataclass_in;
flags |= signatory;
if (protocol == -1)
protocol = DNS_KEYPROTO_DNSSEC;
if (protocol == -1) {
if ((flags & DNS_KEYFLAG_OWNERMASK) == DNS_KEYOWNER_USER)
protocol = DNS_KEYPROTO_EMAIL;
else
protocol = DNS_KEYPROTO_DNSSEC;
}
if ((flags & DNS_KEYFLAG_TYPEMASK) == DNS_KEYTYPE_NOKEY) {
if (size > 0)
fatal("specified null key with non-zero size");
fatal("Specified null key with non-zero size");
if ((flags & DNS_KEYFLAG_SIGNATORYMASK) != 0)
fatal("specified null key with signing authority");
fatal("Specified null key with signing authority");
}
if ((flags & DNS_KEYFLAG_OWNERMASK) == DNS_KEYOWNER_ZONE &&
(alg == DNS_KEYALG_DH || alg == DST_ALG_HMACMD5))
fatal("a key with algorithm '%s' cannot be a zone key",
algname);
dns_fixedname_init(&fname);
name = dns_fixedname_name(&fname);
isc_buffer_init(&buf, argv[isc_commandline_index],
@@ -292,12 +305,11 @@ main(int argc, char **argv) {
isc_buffer_add(&buf, strlen(argv[isc_commandline_index]));
ret = dns_name_fromtext(name, &buf, dns_rootname, ISC_FALSE, NULL);
if (ret != ISC_R_SUCCESS)
fatal("invalid key name %s: %s", argv[isc_commandline_index],
fatal("Invalid key name %s: %s", argv[isc_commandline_index],
isc_result_totext(ret));
switch(alg) {
case DNS_KEYALG_RSAMD5:
case DNS_KEYALG_RSASHA1:
case DNS_KEYALG_RSA:
param = rsa_exp;
break;
case DNS_KEYALG_DH:
@@ -326,8 +338,8 @@ main(int argc, char **argv) {
if (ret != ISC_R_SUCCESS) {
char namestr[DNS_NAME_FORMATSIZE];
char algstr[ALG_FORMATSIZE];
dns_name_format(name, namestr, sizeof(namestr));
alg_format(alg, algstr, sizeof(algstr));
dns_name_format(name, namestr, sizeof namestr);
alg_format(alg, algstr, sizeof algstr);
fatal("failed to generate key %s/%s: %s\n",
namestr, algstr, isc_result_totext(ret));
exit(-1);
@@ -369,7 +381,7 @@ main(int argc, char **argv) {
ret = dst_key_tofile(key, DST_TYPE_PUBLIC | DST_TYPE_PRIVATE, NULL);
if (ret != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(key, keystr, sizeof(keystr));
key_format(key, keystr, sizeof keystr);
fatal("failed to write key %s: %s\n", keystr,
isc_result_totext(ret));
}
@@ -377,6 +389,7 @@ main(int argc, char **argv) {
isc_buffer_clear(&buf);
ret = dst_key_buildfilename(key, 0, NULL, &buf);
printf("%s\n", filename);
isc_mem_free(mctx, prog);
dst_key_free(&key);
cleanup_logging(&log);

View File

@@ -16,7 +16,7 @@
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-keygen.docbook,v 1.4 2002/01/21 10:13:20 bwelling Exp $ -->
<!-- $Id: dnssec-keygen.docbook,v 1.3 2001/04/10 21:50:26 bwelling Exp $ -->
<refentry>
<refentryinfo>
@@ -156,7 +156,8 @@
<listitem>
<para>
Sets the protocol value for the generated key. The protocol
is a number between 0 and 255. The default is 3 (DNSSEC).
is a number between 0 and 255. The default is 2 (email) for
keys of type USER and 3 (DNSSEC) for all other key types.
Other possible values for this argument are listed in
RFC 2535 and its successors.
</para>

View File

@@ -17,7 +17,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssec-makekeyset.c,v 1.58 2001/10/04 23:48:14 gson Exp $ */
/* $Id: dnssec-makekeyset.c,v 1.52.2.1 2001/10/05 00:21:45 bwelling Exp $ */
#include <config.h>
@@ -30,11 +30,11 @@
#include <isc/util.h>
#include <dns/db.h>
#include <dns/diff.h>
#include <dns/dnssec.h>
#include <dns/fixedname.h>
#include <dns/log.h>
#include <dns/rdata.h>
#include <dns/rdatalist.h>
#include <dns/rdataset.h>
#include <dns/result.h>
#include <dns/secalg.h>
@@ -44,6 +44,8 @@
#include "dnssectool.h"
#define BUFSIZE 2048
const char *program = "dnssec-makekeyset";
int verbose;
@@ -110,29 +112,42 @@ zonekey_on_list(dst_key_t *key) {
return (ISC_FALSE);
}
static isc_boolean_t
rdata_on_list(dns_rdata_t *rdata, dns_rdatalist_t *list) {
dns_rdata_t *trdata;
for (trdata = ISC_LIST_HEAD(list->rdata);
trdata != NULL;
trdata = ISC_LIST_NEXT(trdata, link))
{
if (dns_rdata_compare(trdata, rdata) == 0)
return (ISC_TRUE);
}
return (ISC_FALSE);
}
int
main(int argc, char *argv[]) {
int i, ch;
char *startstr = NULL, *endstr = NULL;
char *randomfile = NULL;
dns_fixedname_t fdomain;
dns_name_t *domain = NULL;
char *output = NULL;
char *endp;
unsigned char data[65536];
unsigned char *data;
dns_db_t *db;
dns_dbnode_t *node;
dns_dbversion_t *version;
dns_diff_t diff;
dns_difftuple_t *tuple;
dns_fixedname_t tname;
dst_key_t *key = NULL;
dns_rdata_t rdata = DNS_RDATA_INIT;
dns_rdataset_t rdataset;
dns_rdataclass_t rdclass;
dns_rdata_t *rdata;
dns_rdatalist_t rdatalist, sigrdatalist;
dns_rdataset_t rdataset, sigrdataset;
isc_result_t result;
isc_buffer_t b;
isc_region_t r;
isc_log_t *log = NULL;
keynode_t *keynode;
dns_name_t *savedname = NULL;
unsigned int eflags;
isc_boolean_t pseudorandom = ISC_FALSE;
isc_boolean_t tryverify = ISC_FALSE;
@@ -166,7 +181,7 @@ main(int argc, char *argv[]) {
break;
case 'r':
setup_entropy(mctx, isc_commandline_argument, &ectx);
randomfile = isc_commandline_argument;
break;
case 'v':
@@ -193,14 +208,13 @@ main(int argc, char *argv[]) {
if (argc < 1)
usage();
if (ectx == NULL)
setup_entropy(mctx, NULL, &ectx);
setup_entropy(mctx, randomfile, &ectx);
eflags = ISC_ENTROPY_BLOCKING;
if (!pseudorandom)
eflags |= ISC_ENTROPY_GOODONLY;
result = dst_lib_init(mctx, ectx, eflags);
if (result != ISC_R_SUCCESS)
fatal("could not initialize dst: %s",
fatal("could not initialize dst: %s",
isc_result_totext(result));
isc_stdtime_get(&now);
@@ -223,8 +237,11 @@ main(int argc, char *argv[]) {
setup_logging(verbose, mctx, &log);
dns_diff_init(mctx, &diff);
rdclass = 0;
dns_rdatalist_init(&rdatalist);
rdatalist.rdclass = 0;
rdatalist.type = dns_rdatatype_key;
rdatalist.covers = 0;
rdatalist.ttl = ttl;
ISC_LIST_INIT(keylist);
@@ -238,36 +255,48 @@ main(int argc, char *argv[]) {
if (result != ISC_R_SUCCESS)
fatal("error loading key from %s: %s", argv[i],
isc_result_totext(result));
if (rdclass == 0)
rdclass = dst_key_class(key);
if (rdatalist.rdclass == 0)
rdatalist.rdclass = dst_key_class(key);
isc_buffer_init(&namebuf, namestr, sizeof(namestr));
isc_buffer_init(&namebuf, namestr, sizeof namestr);
result = dns_name_tofilenametext(dst_key_name(key),
ISC_FALSE,
&namebuf);
check_result(result, "dns_name_tofilenametext");
isc_buffer_putuint8(&namebuf, 0);
if (domain == NULL) {
dns_fixedname_init(&fdomain);
domain = dns_fixedname_name(&fdomain);
dns_name_copy(dst_key_name(key), domain, NULL);
} else if (!dns_name_equal(domain, dst_key_name(key))) {
char str[DNS_NAME_FORMATSIZE];
dns_name_format(domain, str, sizeof(str));
fatal("all keys must have the same owner - %s "
"and %s do not match", str, namestr);
if (savedname == NULL) {
savedname = isc_mem_get(mctx, sizeof(dns_name_t));
if (savedname == NULL)
fatal("out of memory");
dns_name_init(savedname, NULL);
result = dns_name_dup(dst_key_name(key), mctx,
savedname);
if (result != ISC_R_SUCCESS)
fatal("out of memory");
} else {
char savednamestr[DNS_NAME_FORMATSIZE];
dns_name_format(savedname, savednamestr,
sizeof savednamestr);
if (!dns_name_equal(savedname, dst_key_name(key)) != 0)
fatal("all keys must have the same owner - %s "
"and %s do not match",
savednamestr, namestr);
}
if (output == NULL) {
output = isc_mem_allocate(mctx,
strlen("keyset-") +
strlen(namestr) + 1);
if (output == NULL)
fatal("out of memory");
sprintf(output, "keyset-%s", namestr);
strcpy(output, "keyset-");
strcat(output, namestr);
}
if (domain == NULL) {
dns_fixedname_init(&fdomain);
domain = dns_fixedname_name(&fdomain);
dns_name_copy(dst_key_name(key), domain, NULL);
}
if (dst_key_iszonekey(key)) {
dst_key_t *zonekey = NULL;
result = dst_key_fromnamedfile(argv[i],
@@ -278,7 +307,8 @@ main(int argc, char *argv[]) {
fatal("failed to read private key %s: %s",
argv[i], isc_result_totext(result));
if (!zonekey_on_list(zonekey)) {
keynode = isc_mem_get(mctx, sizeof(keynode_t));
keynode = isc_mem_get(mctx,
sizeof (keynode_t));
if (keynode == NULL)
fatal("out of memory");
keynode->key = zonekey;
@@ -286,41 +316,39 @@ main(int argc, char *argv[]) {
} else
dst_key_free(&zonekey);
}
dns_rdata_reset(&rdata);
isc_buffer_init(&b, data, sizeof(data));
rdata = isc_mem_get(mctx, sizeof(dns_rdata_t));
if (rdata == NULL)
fatal("out of memory");
dns_rdata_init(rdata);
data = isc_mem_get(mctx, BUFSIZE);
if (data == NULL)
fatal("out of memory");
isc_buffer_init(&b, data, BUFSIZE);
result = dst_key_todns(key, &b);
dst_key_free(&key);
if (result != ISC_R_SUCCESS)
fatal("failed to convert key %s to a DNS KEY: %s",
argv[i], isc_result_totext(result));
isc_buffer_usedregion(&b, &r);
dns_rdata_fromregion(&rdata, rdclass, dns_rdatatype_key, &r);
tuple = NULL;
result = dns_difftuple_create(mctx, DNS_DIFFOP_ADD,
domain, ttl, &rdata, &tuple);
check_result(result, "dns_difftuple_create");
dns_diff_append(&diff, &tuple);
dns_rdata_fromregion(rdata, rdatalist.rdclass,
dns_rdatatype_key, &r);
if (!rdata_on_list(rdata, &rdatalist))
ISC_LIST_APPEND(rdatalist.rdata, rdata, link);
else {
isc_mem_put(mctx, data, BUFSIZE);
isc_mem_put(mctx, rdata, sizeof *rdata);
}
dst_key_free(&key);
}
db = NULL;
result = dns_db_create(mctx, "rbt", dns_rootname, dns_dbtype_zone,
rdclass, 0, NULL, &db);
if (result != ISC_R_SUCCESS)
fatal("failed to create a database");
version = NULL;
dns_db_newversion(db, &version);
result = dns_diff_apply(&diff, db, version);
check_result(result, "dns_diff_apply");
dns_diff_clear(&diff);
dns_fixedname_init(&tname);
dns_rdataset_init(&rdataset);
result = dns_db_find(db, domain, version, dns_rdatatype_key, 0, 0,
NULL, dns_fixedname_name(&tname), &rdataset,
NULL);
check_result(result, "dns_db_find");
result = dns_rdatalist_tordataset(&rdatalist, &rdataset);
check_result(result, "dns_rdatalist_tordataset()");
dns_rdatalist_init(&sigrdatalist);
sigrdatalist.rdclass = rdatalist.rdclass;
sigrdatalist.type = dns_rdatatype_sig;
sigrdatalist.covers = dns_rdatatype_key;
sigrdatalist.ttl = ttl;
if (ISC_LIST_EMPTY(keylist))
fprintf(stderr,
@@ -330,48 +358,69 @@ main(int argc, char *argv[]) {
keynode != NULL;
keynode = ISC_LIST_NEXT(keynode, link))
{
dns_rdata_reset(&rdata);
isc_buffer_init(&b, data, sizeof(data));
rdata = isc_mem_get(mctx, sizeof(dns_rdata_t));
if (rdata == NULL)
fatal("out of memory");
dns_rdata_init(rdata);
data = isc_mem_get(mctx, BUFSIZE);
if (data == NULL)
fatal("out of memory");
isc_buffer_init(&b, data, BUFSIZE);
result = dns_dnssec_sign(domain, &rdataset, keynode->key,
&starttime, &endtime, mctx, &b,
&rdata);
rdata);
isc_entropy_stopcallbacksources(ectx);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(keynode->key, keystr, sizeof(keystr));
key_format(keynode->key, keystr, sizeof keystr);
fatal("failed to sign keyset with key %s: %s",
keystr, isc_result_totext(result));
}
if (tryverify) {
result = dns_dnssec_verify(domain, &rdataset,
keynode->key, ISC_TRUE,
mctx, &rdata);
mctx, rdata);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(keynode->key, keystr, sizeof(keystr));
key_format(keynode->key, keystr, sizeof keystr);
fatal("signature from key '%s' failed to "
"verify: %s",
keystr, isc_result_totext(result));
}
}
tuple = NULL;
result = dns_difftuple_create(mctx, DNS_DIFFOP_ADD,
domain, ttl, &rdata, &tuple);
check_result(result, "dns_difftuple_create");
dns_diff_append(&diff, &tuple);
ISC_LIST_APPEND(sigrdatalist.rdata, rdata, link);
dns_rdataset_init(&sigrdataset);
result = dns_rdatalist_tordataset(&sigrdatalist, &sigrdataset);
check_result(result, "dns_rdatalist_tordataset()");
}
result = dns_diff_apply(&diff, db, version);
check_result(result, "dns_diff_apply");
dns_diff_clear(&diff);
db = NULL;
result = dns_db_create(mctx, "rbt", dns_rootname, dns_dbtype_zone,
rdataset.rdclass, 0, NULL, &db);
if (result != ISC_R_SUCCESS) {
char domainstr[DNS_NAME_FORMATSIZE];
dns_name_format(domain, domainstr, sizeof domainstr);
fatal("failed to create a database for %s", domainstr);
}
dns_rdataset_disassociate(&rdataset);
version = NULL;
dns_db_newversion(db, &version);
node = NULL;
result = dns_db_findnode(db, domain, ISC_TRUE, &node);
check_result(result, "dns_db_findnode()");
dns_db_addrdataset(db, node, version, 0, &rdataset, 0, NULL);
if (!ISC_LIST_EMPTY(keylist))
dns_db_addrdataset(db, node, version, 0, &sigrdataset, 0,
NULL);
dns_db_detachnode(db, &node);
dns_db_closeversion(db, &version, ISC_TRUE);
result = dns_db_dump(db, version, output);
if (result != ISC_R_SUCCESS) {
char domainstr[DNS_NAME_FORMATSIZE];
dns_name_format(domain, domainstr, sizeof(domainstr));
dns_name_format(domain, domainstr, sizeof domainstr);
fatal("failed to write database for %s to %s",
domainstr, output);
}
@@ -380,6 +429,20 @@ main(int argc, char *argv[]) {
dns_db_detach(&db);
dns_rdataset_disassociate(&rdataset);
while (!ISC_LIST_EMPTY(rdatalist.rdata)) {
rdata = ISC_LIST_HEAD(rdatalist.rdata);
ISC_LIST_UNLINK(rdatalist.rdata, rdata, link);
isc_mem_put(mctx, rdata->data, BUFSIZE);
isc_mem_put(mctx, rdata, sizeof *rdata);
}
while (!ISC_LIST_EMPTY(sigrdatalist.rdata)) {
rdata = ISC_LIST_HEAD(sigrdatalist.rdata);
ISC_LIST_UNLINK(sigrdatalist.rdata, rdata, link);
isc_mem_put(mctx, rdata->data, BUFSIZE);
isc_mem_put(mctx, rdata, sizeof *rdata);
}
while (!ISC_LIST_EMPTY(keylist)) {
keynode = ISC_LIST_HEAD(keylist);
ISC_LIST_UNLINK(keylist, keynode, link);
@@ -387,6 +450,11 @@ main(int argc, char *argv[]) {
isc_mem_put(mctx, keynode, sizeof(keynode_t));
}
if (savedname != NULL) {
dns_name_free(savedname, mctx);
isc_mem_put(mctx, savedname, sizeof(dns_name_t));
}
cleanup_logging(&log);
cleanup_entropy(&ectx);

View File

@@ -16,7 +16,7 @@
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-makekeyset.docbook,v 1.3 2001/09/14 20:20:54 gson Exp $ -->
<!-- $Id: dnssec-makekeyset.docbook,v 1.2.2.1 2001/09/14 20:29:32 gson Exp $ -->
<refentry>
<refentryinfo>

View File

@@ -17,7 +17,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssec-signkey.c,v 1.57 2001/10/11 22:53:46 gson Exp $ */
/* $Id: dnssec-signkey.c,v 1.50.2.1 2001/10/05 00:21:46 bwelling Exp $ */
#include <config.h>
@@ -31,12 +31,12 @@
#include <dns/db.h>
#include <dns/dbiterator.h>
#include <dns/diff.h>
#include <dns/dnssec.h>
#include <dns/fixedname.h>
#include <dns/log.h>
#include <dns/rdata.h>
#include <dns/rdataclass.h>
#include <dns/rdatalist.h>
#include <dns/rdataset.h>
#include <dns/rdatasetiter.h>
#include <dns/rdatastruct.h>
@@ -50,6 +50,8 @@
const char *program = "dnssec-signkey";
int verbose;
#define BUFSIZE 2048
typedef struct keynode keynode_t;
struct keynode {
dst_key_t *key;
@@ -117,11 +119,9 @@ loadkeys(dns_name_t *name, dns_rdataset_t *rdataset) {
result = dns_dnssec_keyfromrdata(name, &rdata, mctx, &key);
if (result != ISC_R_SUCCESS)
continue;
if (!dst_key_iszonekey(key)) {
dst_key_free(&key);
if (!dst_key_iszonekey(key))
continue;
}
keynode = isc_mem_get(mctx, sizeof(keynode_t));
keynode = isc_mem_get(mctx, sizeof (keynode_t));
if (keynode == NULL)
fatal("out of memory");
keynode->key = key;
@@ -158,28 +158,28 @@ main(int argc, char *argv[]) {
dns_name_t *domain;
char *output = NULL;
char *endp;
unsigned char data[65536];
unsigned char *data;
char *randomfile = NULL;
dns_db_t *db;
dns_dbnode_t *node;
dns_dbversion_t *version;
dns_diff_t diff;
dns_difftuple_t *tuple;
dns_dbiterator_t *dbiter;
dns_rdatasetiter_t *rdsiter;
dst_key_t *key = NULL;
dns_rdata_t rdata = DNS_RDATA_INIT;
dns_rdata_t *rdata;
dns_rdata_t sigrdata = DNS_RDATA_INIT;
dns_rdataset_t rdataset, sigrdataset;
dns_rdatalist_t sigrdatalist;
dns_rdataset_t rdataset, sigrdataset, newsigrdataset;
dns_rdata_sig_t sig;
isc_result_t result;
isc_buffer_t b;
isc_textregion_t tr;
isc_log_t *log = NULL;
keynode_t *keynode;
isc_boolean_t pseudorandom = ISC_FALSE;
unsigned int eflags;
dns_rdataclass_t rdclass;
isc_boolean_t tryverify = ISC_FALSE;
isc_boolean_t settime = ISC_FALSE;
static isc_boolean_t tryverify = ISC_FALSE;
result = isc_mem_create(0, 0, &mctx);
check_result(result, "isc_mem_create()");
@@ -209,7 +209,7 @@ main(int argc, char *argv[]) {
break;
case 'r':
setup_entropy(mctx, isc_commandline_argument, &ectx);
randomfile = isc_commandline_argument;
break;
case 'v':
@@ -232,10 +232,16 @@ main(int argc, char *argv[]) {
if (argc < 2)
usage();
rdclass = strtoclass(classname);
if (classname != NULL) {
tr.base = classname;
tr.length = strlen(classname);
result = dns_rdataclass_fromtext(&rdclass, &tr);
if (result != ISC_R_SUCCESS)
fatal("unknown class %s",classname);
} else
rdclass = dns_rdataclass_in;
if (ectx == NULL)
setup_entropy(mctx, NULL, &ectx);
setup_entropy(mctx, randomfile, &ectx);
eflags = ISC_ENTROPY_BLOCKING;
if (!pseudorandom)
eflags |= ISC_ENTROPY_GOODONLY;
@@ -250,12 +256,6 @@ main(int argc, char *argv[]) {
!(startstr == NULL && endstr == NULL))
fatal("if -s or -e is specified, both must be");
if (startstr != NULL) {
starttime = strtotime(startstr, now, now);
endtime = strtotime(endstr, now, starttime);
settime = ISC_TRUE;
}
setup_logging(verbose, mctx, &log);
if (strlen(argv[0]) < 8 || strncmp(argv[0], "keyset-", 7) != 0)
@@ -306,7 +306,8 @@ main(int argc, char *argv[]) {
strlen("signedkey-") + strlen(tdomain) + 1);
if (output == NULL)
fatal("out of memory");
sprintf(output, "signedkey-%s", tdomain);
strcpy(output, "signedkey-");
strcat(output, tdomain);
version = NULL;
dns_db_newversion(db, &version);
@@ -317,15 +318,13 @@ main(int argc, char *argv[]) {
0, &rdataset, &sigrdataset);
if (result != ISC_R_SUCCESS) {
char domainstr[DNS_NAME_FORMATSIZE];
dns_name_format(domain, domainstr, sizeof(domainstr));
dns_name_format(domain, domainstr, sizeof domainstr);
fatal("failed to find rdataset '%s KEY': %s",
domainstr, isc_result_totext(result));
}
loadkeys(domain, &rdataset);
dns_diff_init(mctx, &diff);
if (!dns_rdataset_isassociated(&sigrdataset))
fatal("no SIG KEY set present");
@@ -340,29 +339,47 @@ main(int argc, char *argv[]) {
ISC_TRUE, mctx, &sigrdata);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(key, keystr, sizeof(keystr));
key_format(key, keystr, sizeof keystr);
fatal("signature by key '%s' did not verify: %s",
keystr, isc_result_totext(result));
}
if (!settime) {
starttime = sig.timesigned;
endtime = sig.timeexpire;
settime = ISC_TRUE;
}
dns_rdata_freestruct(&sig);
dns_rdata_reset(&sigrdata);
dns_rdata_freestruct(&sig);
result = dns_rdataset_next(&sigrdataset);
} while (result == ISC_R_SUCCESS);
if (startstr != NULL) {
starttime = strtotime(startstr, now, now);
endtime = strtotime(endstr, now, starttime);
} else {
starttime = sig.timesigned;
endtime = sig.timeexpire;
}
for (keynode = ISC_LIST_HEAD(keylist);
keynode != NULL;
keynode = ISC_LIST_NEXT(keynode, link))
if (!keynode->verified)
fatal("not all zone keys self signed the key set");
fatal("Not all zone keys self signed the key set");
result = dns_rdataset_first(&sigrdataset);
check_result(result, "dns_rdataset_first()");
dns_rdataset_current(&sigrdataset, &sigrdata);
result = dns_rdata_tostruct(&sigrdata, &sig, mctx);
check_result(result, "dns_rdata_tostruct()");
dns_rdataset_disassociate(&sigrdataset);
argc -= 1;
argv += 1;
dns_rdatalist_init(&sigrdatalist);
sigrdatalist.rdclass = rdataset.rdclass;
sigrdatalist.type = dns_rdatatype_sig;
sigrdatalist.covers = dns_rdatatype_key;
sigrdatalist.ttl = rdataset.ttl;
for (i = 0; i < argc; i++) {
key = NULL;
result = dst_key_fromnamedfile(argv[i],
@@ -373,45 +390,45 @@ main(int argc, char *argv[]) {
fatal("failed to read key %s from disk: %s",
argv[i], isc_result_totext(result));
dns_rdata_reset(&rdata);
isc_buffer_init(&b, data, sizeof(data));
rdata = isc_mem_get(mctx, sizeof(dns_rdata_t));
if (rdata == NULL)
fatal("out of memory");
dns_rdata_init(rdata);
data = isc_mem_get(mctx, BUFSIZE);
if (data == NULL)
fatal("out of memory");
isc_buffer_init(&b, data, BUFSIZE);
result = dns_dnssec_sign(domain, &rdataset, key,
&starttime, &endtime,
mctx, &b, &rdata);
mctx, &b, rdata);
isc_entropy_stopcallbacksources(ectx);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(key, keystr, sizeof(keystr));
key_format(key, keystr, sizeof keystr);
fatal("key '%s' failed to sign data: %s",
keystr, isc_result_totext(result));
}
if (tryverify) {
result = dns_dnssec_verify(domain, &rdataset, key,
ISC_TRUE, mctx, &rdata);
ISC_TRUE, mctx, rdata);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(key, keystr, sizeof(keystr));
key_format(key, keystr, sizeof keystr);
fatal("signature from key '%s' failed to "
"verify: %s",
keystr, isc_result_totext(result));
}
}
tuple = NULL;
result = dns_difftuple_create(mctx, DNS_DIFFOP_ADD,
domain, rdataset.ttl,
&rdata, &tuple);
check_result(result, "dns_difftuple_create");
dns_diff_append(&diff, &tuple);
ISC_LIST_APPEND(sigrdatalist.rdata, rdata, link);
dst_key_free(&key);
}
result = dns_db_deleterdataset(db, node, version, dns_rdatatype_sig,
dns_rdatatype_key);
check_result(result, "dns_db_deleterdataset");
dns_rdataset_init(&newsigrdataset);
result = dns_rdatalist_tordataset(&sigrdatalist, &newsigrdataset);
check_result (result, "dns_rdatalist_tordataset()");
result = dns_diff_apply(&diff, db, version);
check_result(result, "dns_diff_apply");
dns_diff_clear(&diff);
dns_db_addrdataset(db, node, version, 0, &newsigrdataset, 0, NULL);
check_result (result, "dns_db_addrdataset()");
dns_db_detachnode(db, &node);
dns_db_closeversion(db, &version, ISC_TRUE);
@@ -423,7 +440,16 @@ main(int argc, char *argv[]) {
printf("%s\n", output);
dns_rdataset_disassociate(&rdataset);
dns_rdataset_disassociate(&sigrdataset);
dns_rdataset_disassociate(&newsigrdataset);
dns_rdata_freestruct(&sig);
while (!ISC_LIST_EMPTY(sigrdatalist.rdata)) {
rdata = ISC_LIST_HEAD(sigrdatalist.rdata);
ISC_LIST_UNLINK(sigrdatalist.rdata, rdata, link);
isc_mem_put(mctx, rdata->data, BUFSIZE);
isc_mem_put(mctx, rdata, sizeof *rdata);
}
dns_db_detach(&db);

View File

@@ -17,7 +17,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssec-signzone.c,v 1.158 2002/02/05 05:16:11 bwelling Exp $ */
/* $Id: dnssec-signzone.c,v 1.139.2.1 2001/10/05 00:21:48 bwelling Exp $ */
#include <config.h>
@@ -55,9 +55,11 @@
#include <dns/rdatastruct.h>
#include <dns/rdatatype.h>
#include <dns/result.h>
#include <dns/secalg.h>
#include <dns/time.h>
#include <dst/dst.h>
#include <dst/result.h>
#include "dnssectool.h"
@@ -83,6 +85,7 @@ typedef struct signer_event sevent_t;
struct signer_event {
ISC_EVENT_COMMON(sevent_t);
dns_fixedname_t *fname;
dns_fixedname_t *fnextname;
dns_dbnode_t *node;
};
@@ -107,6 +110,8 @@ static dns_db_t *gdb; /* The database */
static dns_dbversion_t *gversion; /* The database version */
static dns_dbiterator_t *gdbiter; /* The database iterator */
static dns_name_t *gorigin; /* The database origin */
static dns_dbnode_t *gnode = NULL; /* The "current" database node */
static dns_name_t *lastzonecut;
static isc_task_t *master = NULL;
static unsigned int ntasks = 0;
static isc_boolean_t shuttingdown = ISC_FALSE, finished = ISC_FALSE;
@@ -138,15 +143,6 @@ set_bit(unsigned char *array, unsigned int index, unsigned int bit) {
array[index / 8] &= (~mask & 0xFF);
}
static void
dumpnode(dns_name_t *name, dns_dbnode_t *node) {
isc_result_t result;
result = dns_master_dumpnodetostream(mctx, gdb, gversion, node, name,
masterstyle, fp);
check_result(result, "dns_master_dumpnodetostream");
}
static signer_key_t *
newkeystruct(dst_key_t *dstkey, isc_boolean_t isdefault) {
signer_key_t *key;
@@ -172,7 +168,7 @@ signwithkey(dns_name_t *name, dns_rdataset_t *rdataset, dns_rdata_t *rdata,
isc_entropy_stopcallbacksources(ectx);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(key, keystr, sizeof(keystr));
key_format(key, keystr, sizeof keystr);
fatal("key '%s' failed to sign data: %s",
keystr, isc_result_totext(result));
}
@@ -263,7 +259,7 @@ expecttofindkey(dns_name_t *name) {
case DNS_R_DNAME:
return (ISC_FALSE);
}
dns_name_format(name, namestr, sizeof(namestr));
dns_name_format(name, namestr, sizeof namestr);
fatal("failure looking for '%s KEY' in database: %s",
namestr, isc_result_totext(result));
return (ISC_FALSE); /* removes a warning */
@@ -308,8 +304,8 @@ signset(dns_diff_t *diff, dns_dbnode_t *node, dns_name_t *name,
char typestr[TYPE_FORMATSIZE];
char sigstr[SIG_FORMATSIZE];
dns_name_format(name, namestr, sizeof(namestr));
type_format(set->type, typestr, sizeof(typestr));
dns_name_format(name, namestr, sizeof namestr);
type_format(set->type, typestr, sizeof typestr);
ttl = ISC_MIN(set->ttl, endtime - starttime);
@@ -355,7 +351,7 @@ signset(dns_diff_t *diff, dns_dbnode_t *node, dns_name_t *name,
future = ISC_TF(now < sig.timesigned);
key = keythatsigned(&sig);
sig_format(&sig, sigstr, sizeof(sigstr));
sig_format(&sig, sigstr, sizeof sigstr);
if (sig.timesigned > sig.timeexpire) {
/* sig is dropped and not replaced */
@@ -429,7 +425,7 @@ signset(dns_diff_t *diff, dns_dbnode_t *node, dns_name_t *name,
unsigned char array[BUFSIZE];
char keystr[KEY_FORMATSIZE];
key_format(key->key, keystr, sizeof(keystr));
key_format(key->key, keystr, sizeof keystr);
vbprintf(1, "\tresigning with key %s\n", keystr);
isc_buffer_init(&b, array, sizeof(array));
signwithkey(name, set, &trdata, key->key, &b);
@@ -453,28 +449,26 @@ signset(dns_diff_t *diff, dns_dbnode_t *node, dns_name_t *name,
if (dns_rdataset_isassociated(&sigset))
dns_rdataset_disassociate(&sigset);
for (key = ISC_LIST_HEAD(keylist);
key != NULL;
key = ISC_LIST_NEXT(key, link))
{
isc_buffer_t b;
dns_rdata_t trdata;
unsigned char array[BUFSIZE];
char keystr[KEY_FORMATSIZE];
key = ISC_LIST_HEAD(keylist);
while (key != NULL) {
if (key->isdefault && !nowsignedby[key->position]) {
isc_buffer_t b;
dns_rdata_t trdata = DNS_RDATA_INIT;
unsigned char array[BUFSIZE];
char keystr[KEY_FORMATSIZE];
if (!key->isdefault || nowsignedby[key->position])
continue;
key_format(key->key, keystr, sizeof(keystr));
vbprintf(1, "\tsigning with key %s\n", keystr);
dns_rdata_init(&trdata);
isc_buffer_init(&b, array, sizeof(array));
signwithkey(name, set, &trdata, key->key, &b);
tuple = NULL;
result = dns_difftuple_create(mctx, DNS_DIFFOP_ADD, name,
ttl, &trdata, &tuple);
check_result(result, "dns_difftuple_create");
dns_diff_append(diff, &tuple);
key_format(key->key, keystr, sizeof keystr);
vbprintf(1, "\tsigning with key %s\n", keystr);
isc_buffer_init(&b, array, sizeof(array));
signwithkey(name, set, &trdata, key->key, &b);
tuple = NULL;
result = dns_difftuple_create(mctx, DNS_DIFFOP_ADD,
name, ttl, &trdata,
&tuple);
check_result(result, "dns_difftuple_create");
dns_diff_append(diff, &tuple);
}
key = ISC_LIST_NEXT(key, link);
}
isc_mem_put(mctx, wassignedby, arraysize * sizeof(isc_boolean_t));
@@ -486,11 +480,10 @@ static isc_boolean_t
hasnullkey(dns_rdataset_t *rdataset) {
isc_result_t result;
dns_rdata_t rdata = DNS_RDATA_INIT;
isc_boolean_t found = ISC_FALSE;
for (result = dns_rdataset_first(rdataset);
result == ISC_R_SUCCESS;
result = dns_rdataset_next(rdataset))
{
result = dns_rdataset_first(rdataset);
while (result == ISC_R_SUCCESS) {
dst_key_t *key = NULL;
dns_rdata_reset(&rdata);
@@ -498,13 +491,14 @@ hasnullkey(dns_rdataset_t *rdataset) {
result = dns_dnssec_keyfromrdata(dns_rootname,
&rdata, mctx, &key);
if (result != ISC_R_SUCCESS)
fatal("could not convert KEY into internal "
"format: %s", isc_result_totext(result));
if (dst_key_isnullkey(key)) {
dst_key_free(&key);
return (ISC_TRUE);
}
fatal("could not convert KEY into internal format: %s",
isc_result_totext(result));
if (dst_key_isnullkey(key))
found = ISC_TRUE;
dst_key_free(&key);
if (found == ISC_TRUE)
return (ISC_TRUE);
result = dns_rdataset_next(rdataset);
}
if (result != ISC_R_NOMORE)
fatal("failure looking for null keys");
@@ -530,7 +524,7 @@ opendb(const char *prefix, dns_name_t *name, dns_rdataclass_t rdclass,
check_result(result, "dns_name_tofilenametext()");
if (isc_buffer_availablelength(&b) == 0) {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof(namestr));
dns_name_format(name, namestr, sizeof namestr);
fatal("name '%s' is too long", namestr);
}
isc_buffer_putuint8(&b, 0);
@@ -678,9 +672,11 @@ haschildkey(dns_name_t *name) {
dns_rdata_freestruct(&sig);
if (key == NULL) {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof(namestr));
vbprintf(1, "unknown KEY in %s signedkey file\n",
namestr);
dns_name_format(name, namestr, sizeof namestr);
fprintf(stderr,
"creating KEY from signedkey file for %s: "
"%s\n",
namestr, isc_result_totext(result));
goto failure;
}
result = dns_dnssec_verify(name, &set, key->key,
@@ -690,9 +686,10 @@ haschildkey(dns_name_t *name) {
break;
} else {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof(namestr));
vbprintf(1, "verifying SIG in %s signedkey file: %s\n",
namestr, isc_result_totext(result));
dns_name_format(name, namestr, sizeof namestr);
fprintf(stderr,
"verifying SIG in signedkey file for %s: %s\n",
namestr, isc_result_totext(result));
}
dns_rdata_reset(&sigrdata);
}
@@ -721,8 +718,6 @@ nxt_setbit(dns_rdataset_t *rdataset, dns_rdatatype_t type) {
dns_rdata_t rdata = DNS_RDATA_INIT;
dns_rdata_nxt_t nxt;
REQUIRE(type <= dns_rdatatype_nxt);
result = dns_rdataset_first(rdataset);
check_result(result, "dns_rdataset_first()");
dns_rdataset_current(rdataset, &rdata);
@@ -745,7 +740,7 @@ createnullkey(dns_db_t *db, dns_dbversion_t *version, dns_name_t *name,
isc_result_t result;
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof(namestr));
dns_name_format(name, namestr, sizeof namestr);
vbprintf(2, "adding null key at %s\n", namestr);
key.common.rdclass = dns_db_class(db);
@@ -757,7 +752,7 @@ createnullkey(dns_db_t *db, dns_dbversion_t *version, dns_name_t *name,
key.algorithm = DNS_KEYALG_DSA;
key.datalen = 0;
key.data = NULL;
isc_buffer_init(&b, keydata, sizeof(keydata));
isc_buffer_init(&b, keydata, sizeof keydata);
result = dns_rdata_fromstruct(&keyrdata, dns_db_class(db),
dns_rdatatype_key, &key, &b);
if (result != ISC_R_SUCCESS)
@@ -777,40 +772,6 @@ createnullkey(dns_db_t *db, dns_dbversion_t *version, dns_name_t *name,
dns_diff_clear(&diff);
}
static void
warnwild(const char *name) {
static int warned = 0;
fprintf(stderr, "%s: warning: wildcard name seen: %s\n",
program, name);
if (warned++ != 0)
return;
fprintf(stderr, "%s: warning: BIND 9 doesn't properly "
"handle wildcards in secure zones:\n",
program);
fprintf(stderr, "\t- wildcard nonexistence proof is "
"not generated by the server\n");
fprintf(stderr, "\t- wildcard nonexistence proof is "
"not required by the resolver\n");
}
static isc_boolean_t
delegation(dns_name_t *name, dns_dbnode_t *node) {
dns_rdataset_t nsset;
isc_result_t result;
if (dns_name_equal(name, gorigin))
return (ISC_FALSE);
dns_rdataset_init(&nsset);
result = dns_db_findrdataset(gdb, node, gversion, dns_rdatatype_ns,
0, 0, &nsset, NULL);
if (dns_rdataset_isassociated(&nsset))
dns_rdataset_disassociate(&nsset);
return (ISC_TF(result == ISC_R_SUCCESS));
}
/*
* Signs all records at a name. This mostly just signs each set individually,
* but also adds the SIG bit to any NXTs generated earlier, deals with
@@ -823,23 +784,45 @@ signname(dns_dbnode_t *node, dns_name_t *name) {
dns_rdatasetiter_t *rdsiter;
isc_boolean_t isdelegation = ISC_FALSE;
isc_boolean_t childkey = ISC_FALSE;
static int warnwild = 0;
isc_boolean_t atorigin;
isc_boolean_t neednullkey = ISC_FALSE;
dns_diff_t diff;
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof(namestr));
if (dns_name_iswildcard(name))
warnwild(namestr);
if (dns_name_iswildcard(name)) {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof namestr);
if (warnwild++ == 0) {
fprintf(stderr, "%s: warning: BIND 9 doesn't properly "
"handle wildcards in secure zones:\n",
program);
fprintf(stderr, "\t- wildcard nonexistence proof is "
"not generated by the server\n");
fprintf(stderr, "\t- wildcard nonexistence proof is "
"not required by the resolver\n");
}
fprintf(stderr, "%s: warning: wildcard name seen: %s\n",
program, namestr);
}
atorigin = dns_name_equal(name, gorigin);
/*
* Determine if this is a delegation point.
* If this is not the origin, determine if it's a delegation point.
*/
if (delegation(name, node))
isdelegation = ISC_TRUE;
if (!atorigin) {
dns_rdataset_t nsset;
dns_rdataset_init(&nsset);
result = dns_db_findrdataset(gdb, node, gversion,
dns_rdatatype_ns, 0, 0, &nsset,
NULL);
/* Is this a delegation point? */
if (result == ISC_R_SUCCESS) {
isdelegation = ISC_TRUE;
dns_rdataset_disassociate(&nsset);
}
}
/*
* If this is a delegation point, determine if we need to generate
@@ -858,6 +841,8 @@ signname(dns_dbnode_t *node, dns_name_t *name) {
dns_rdatatype_key, 0, 0, &keyset,
NULL);
if (result == ISC_R_SUCCESS && childkey) {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof namestr);
if (hasnullkey(&keyset)) {
fatal("%s has both a signedkey file and "
"null keys in the zone. Aborting.",
@@ -873,6 +858,8 @@ signname(dns_dbnode_t *node, dns_name_t *name) {
nullkeyttl = keyset.ttl;
dns_rdataset_disassociate(&keyset);
} else if (childkey) {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof namestr);
vbprintf(2, "child key for %s found\n", namestr);
neednullkey = ISC_FALSE;
}
@@ -907,7 +894,7 @@ signname(dns_dbnode_t *node, dns_name_t *name) {
/*
* If this name is a delegation point, skip all records
* except an NXT set and a KEY set containing a null key.
* except an NXT set a KEY set containing a null key.
*/
if (isdelegation) {
if (!(rdataset.type == dns_rdatatype_nxt ||
@@ -929,17 +916,21 @@ signname(dns_dbnode_t *node, dns_name_t *name) {
dns_rdataset_disassociate(&rdataset);
result = dns_rdatasetiter_next(rdsiter);
}
if (result != ISC_R_NOMORE)
if (result != ISC_R_NOMORE) {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof namestr);
fatal("rdataset iteration for name '%s' failed: %s",
namestr, isc_result_totext(result));
}
dns_rdatasetiter_destroy(&rdsiter);
result = dns_diff_applysilently(&diff, gdb, gversion);
if (result != ISC_R_SUCCESS)
result = dns_diff_apply(&diff, gdb, gversion);
if (result != ISC_R_SUCCESS) {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof namestr);
fatal("failed to add SIGs at node '%s': %s",
namestr, isc_result_totext(result));
}
dns_diff_clear(&diff);
}
@@ -984,6 +975,51 @@ active_node(dns_dbnode_t *node) {
return (active);
}
static inline isc_result_t
next_active(dns_name_t *name, dns_dbnode_t **nodep) {
isc_result_t result;
isc_boolean_t active;
do {
active = ISC_FALSE;
result = dns_dbiterator_current(gdbiter, nodep, name);
if (result == ISC_R_SUCCESS) {
active = active_node(*nodep);
if (!active) {
dns_db_detachnode(gdb, nodep);
result = dns_dbiterator_next(gdbiter);
}
}
} while (result == ISC_R_SUCCESS && !active);
return (result);
}
static inline isc_result_t
next_nonglue(dns_name_t *name, dns_dbnode_t **nodep, dns_name_t *origin,
dns_name_t *lastcut)
{
isc_result_t result;
do {
result = next_active(name, nodep);
if (result == ISC_R_SUCCESS) {
if (dns_name_issubdomain(name, origin) &&
(lastcut == NULL ||
!dns_name_issubdomain(name, lastcut)))
return (ISC_R_SUCCESS);
result = dns_master_dumpnodetostream(mctx, gdb,
gversion,
*nodep, name,
masterstyle, fp);
check_result(result, "dns_master_dumpnodetostream");
dns_db_detachnode(gdb, nodep);
result = dns_dbiterator_next(gdbiter);
}
} while (result == ISC_R_SUCCESS);
return (result);
}
/*
* Extracts the TTL from the SOA.
*/
@@ -1000,10 +1036,12 @@ soattl(void) {
dns_rdataset_init(&soaset);
result = dns_db_find(gdb, gorigin, gversion, dns_rdatatype_soa,
0, 0, NULL, name, &soaset, NULL);
if (result != ISC_R_SUCCESS)
fatal("failed to find an SOA at the zone apex: %s",
isc_result_totext(result));
if (result != ISC_R_SUCCESS) {
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr, sizeof namestr);
fatal("failed to find '%s SOA' in the zone: %s",
namestr, isc_result_totext(result));
}
ttl = soaset.ttl;
dns_rdataset_disassociate(&soaset);
return (ttl);
@@ -1058,6 +1096,11 @@ presign(void) {
result = dns_dbiterator_first(gdbiter);
check_result(result, "dns_dbiterator_first()");
lastzonecut = NULL;
zonettl = soattl();
}
/*
@@ -1065,69 +1108,131 @@ presign(void) {
*/
static void
postsign(void) {
if (lastzonecut != NULL) {
dns_name_free(lastzonecut, mctx);
isc_mem_put(mctx, lastzonecut, sizeof(dns_name_t));
}
dns_dbiterator_destroy(&gdbiter);
}
/*
* Find the next name to nxtify & sign
*/
static isc_result_t
getnextname(dns_name_t *name, dns_name_t *nextname, dns_dbnode_t **nodep) {
isc_result_t result;
dns_dbnode_t *nextnode, *curnode;
LOCK(&namelock);
if (shuttingdown || finished) {
result = ISC_R_NOMORE;
if (gnode != NULL)
dns_db_detachnode(gdb, &gnode);
goto out;
}
if (gnode == NULL) {
dns_fixedname_t ftname;
dns_name_t *tname;
dns_fixedname_init(&ftname);
tname = dns_fixedname_name(&ftname);
result = next_nonglue(tname, &gnode, gorigin, lastzonecut);
if (result != ISC_R_SUCCESS)
fatal("failed to iterate through the zone");
}
nextnode = NULL;
curnode = NULL;
dns_dbiterator_current(gdbiter, &curnode, name);
if (!dns_name_equal(name, gorigin)) {
dns_rdatasetiter_t *rdsiter = NULL;
dns_rdataset_t set;
dns_rdataset_init(&set);
result = dns_db_allrdatasets(gdb, curnode, gversion, 0,
&rdsiter);
check_result(result, "dns_db_allrdatasets");
result = dns_rdatasetiter_first(rdsiter);
while (result == ISC_R_SUCCESS) {
dns_rdatasetiter_current(rdsiter, &set);
if (set.type == dns_rdatatype_ns) {
dns_rdataset_disassociate(&set);
break;
}
dns_rdataset_disassociate(&set);
result = dns_rdatasetiter_next(rdsiter);
}
if (result != ISC_R_SUCCESS && result != ISC_R_NOMORE)
fatal("rdataset iteration failed: %s",
isc_result_totext(result));
if (result == ISC_R_SUCCESS) {
if (lastzonecut != NULL)
dns_name_free(lastzonecut, mctx);
else {
lastzonecut = isc_mem_get(mctx,
sizeof(dns_name_t));
if (lastzonecut == NULL)
fatal("out of memory");
}
dns_name_init(lastzonecut, NULL);
result = dns_name_dup(name, mctx, lastzonecut);
check_result(result, "dns_name_dup()");
}
dns_rdatasetiter_destroy(&rdsiter);
}
result = dns_dbiterator_next(gdbiter);
if (result == ISC_R_SUCCESS)
result = next_nonglue(nextname, &nextnode, gorigin,
lastzonecut);
if (result == ISC_R_NOMORE) {
dns_name_clone(gorigin, nextname);
finished = ISC_TRUE;
result = ISC_R_SUCCESS;
} else if (result != ISC_R_SUCCESS)
fatal("iterating through the database failed: %s",
isc_result_totext(result));
dns_db_detachnode(gdb, &curnode);
*nodep = gnode;
gnode = nextnode;
out:
UNLOCK(&namelock);
return (result);
}
/*
* Assigns a node to a worker thread. This is protected by the master task's
* lock.
*/
static void
assignwork(isc_task_t *task, isc_task_t *worker) {
dns_fixedname_t *fname;
dns_name_t *name;
dns_fixedname_t *fname, *fnextname;
dns_dbnode_t *node;
sevent_t *sevent;
dns_rdataset_t nxt;
isc_boolean_t found;
isc_result_t result;
if (shuttingdown)
return;
if (finished) {
fname = isc_mem_get(mctx, sizeof(dns_fixedname_t));
fnextname = isc_mem_get(mctx, sizeof(dns_fixedname_t));
if (fname == NULL || fnextname == NULL)
fatal("out of memory");
dns_fixedname_init(fname);
dns_fixedname_init(fnextname);
node = NULL;
result = getnextname(dns_fixedname_name(fname),
dns_fixedname_name(fnextname), &node);
if (result == ISC_R_NOMORE) {
isc_mem_put(mctx, fname, sizeof(dns_fixedname_t));
isc_mem_put(mctx, fnextname, sizeof(dns_fixedname_t));
if (assigned == completed) {
isc_task_detach(&task);
isc_app_shutdown();
}
return;
}
fname = isc_mem_get(mctx, sizeof(dns_fixedname_t));
if (fname == NULL)
fatal("out of memory");
dns_fixedname_init(fname);
name = dns_fixedname_name(fname);
node = NULL;
found = ISC_FALSE;
LOCK(&namelock);
while (!found) {
result = dns_dbiterator_current(gdbiter, &node, name);
if (result != ISC_R_SUCCESS)
fatal("failure iterating database: %s",
isc_result_totext(result));
dns_rdataset_init(&nxt);
result = dns_db_findrdataset(gdb, node, gversion,
dns_rdatatype_nxt, 0, 0,
&nxt, NULL);
if (result == ISC_R_SUCCESS)
found = ISC_TRUE;
else
dumpnode(name, node);
if (dns_rdataset_isassociated(&nxt))
dns_rdataset_disassociate(&nxt);
result = dns_dbiterator_next(gdbiter);
if (result == ISC_R_NOMORE) {
finished = ISC_TRUE;
break;
} else if (result != ISC_R_SUCCESS)
fatal("failure iterating database: %s",
isc_result_totext(result));
if (!found)
dns_db_detachnode(gdb, &node);
}
UNLOCK(&namelock);
sevent = (sevent_t *)
isc_event_allocate(mctx, task, SIGNER_EVENT_WORK,
sign, NULL, sizeof(sevent_t));
@@ -1136,6 +1241,7 @@ assignwork(isc_task_t *task, isc_task_t *worker) {
sevent->node = node;
sevent->fname = fname;
sevent->fnextname = fnextname;
isc_task_send(worker, (isc_event_t **)&sevent);
assigned++;
}
@@ -1157,12 +1263,17 @@ startworker(isc_task_t *task, isc_event_t *event) {
*/
static void
writenode(isc_task_t *task, isc_event_t *event) {
isc_result_t result;
isc_task_t *worker;
sevent_t *sevent = (sevent_t *)event;
completed++;
worker = (isc_task_t *)event->ev_sender;
dumpnode(dns_fixedname_name(sevent->fname), sevent->node);
result = dns_master_dumpnodetostream(mctx, gdb, gversion,
sevent->node,
dns_fixedname_name(sevent->fname),
masterstyle, fp);
check_result(result, "dns_master_dumpnodetostream");
cleannode(gdb, gversion, sevent->node);
dns_db_detachnode(gdb, &sevent->node);
isc_mem_put(mctx, sevent->fname, sizeof(dns_fixedname_t));
@@ -1171,19 +1282,25 @@ writenode(isc_task_t *task, isc_event_t *event) {
}
/*
* Sign a database node.
* Sign and nxtify a database node.
*/
static void
sign(isc_task_t *task, isc_event_t *event) {
dns_fixedname_t *fname;
dns_fixedname_t *fname, *fnextname;
dns_dbnode_t *node;
sevent_t *sevent, *wevent;
isc_result_t result;
sevent = (sevent_t *)event;
node = sevent->node;
fname = sevent->fname;
fnextname = sevent->fnextname;
isc_event_free(&event);
result = dns_nxt_build(gdb, gversion, node,
dns_fixedname_name(fnextname), zonettl);
check_result(result, "dns_nxt_build()");
isc_mem_put(mctx, fnextname, sizeof(dns_fixedname_t));
signname(node, dns_fixedname_name(fname));
wevent = (sevent_t *)
isc_event_allocate(mctx, task, SIGNER_EVENT_WRITE,
@@ -1195,80 +1312,6 @@ sign(isc_task_t *task, isc_event_t *event) {
isc_task_send(master, (isc_event_t **)&wevent);
}
/*
* Generate NXT records for the zone.
*/
static void
nxtify(void) {
dns_dbiterator_t *dbiter = NULL;
dns_dbnode_t *node = NULL, *nextnode = NULL;
dns_fixedname_t fname, fnextname, fzonecut;
dns_name_t *name, *nextname, *zonecut;
isc_boolean_t done = ISC_FALSE;
isc_result_t result;
dns_fixedname_init(&fname);
name = dns_fixedname_name(&fname);
dns_fixedname_init(&fnextname);
nextname = dns_fixedname_name(&fnextname);
dns_fixedname_init(&fzonecut);
zonecut = NULL;
result = dns_db_createiterator(gdb, ISC_FALSE, &dbiter);
check_result(result, "dns_db_createiterator()");
result = dns_dbiterator_first(dbiter);
check_result(result, "dns_dbiterator_first()");
while (!done) {
dns_dbiterator_current(dbiter, &node, name);
if (delegation(name, node)) {
zonecut = dns_fixedname_name(&fzonecut);
dns_name_copy(name, zonecut, NULL);
}
result = dns_dbiterator_next(dbiter);
nextnode = NULL;
while (result == ISC_R_SUCCESS) {
isc_boolean_t active = ISC_FALSE;
result = dns_dbiterator_current(dbiter, &nextnode,
nextname);
if (result != ISC_R_SUCCESS)
break;
active = active_node(nextnode);
if (!active) {
dns_db_detachnode(gdb, &nextnode);
result = dns_dbiterator_next(dbiter);
continue;
}
if (result != ISC_R_SUCCESS) {
dns_db_detachnode(gdb, &nextnode);
break;
}
if (!dns_name_issubdomain(nextname, gorigin) ||
(zonecut != NULL &&
dns_name_issubdomain(nextname, zonecut)))
{
dns_db_detachnode(gdb, &nextnode);
result = dns_dbiterator_next(dbiter);
continue;
}
dns_db_detachnode(gdb, &nextnode);
break;
}
if (result == ISC_R_NOMORE) {
dns_name_clone(gorigin, nextname);
done = ISC_TRUE;
} else if (result != ISC_R_SUCCESS)
fatal("iterating through the database failed: %s",
isc_result_totext(result));
result = dns_nxt_build(gdb, gversion, node, nextname, zonettl);
check_result(result, "dns_nxt_build()");
dns_db_detachnode(gdb, &node);
}
dns_dbiterator_destroy(&dbiter);
}
/*
* Load the zone file from disk
*/
@@ -1453,36 +1496,12 @@ removetempfile(void) {
isc_file_remove(tempfile);
}
static void
print_stats(isc_time_t *timer_start, isc_time_t *timer_finish) {
isc_uint64_t runtime_us; /* Runtime in microseconds */
isc_uint64_t runtime_ms; /* Runtime in milliseconds */
isc_uint64_t sig_ms; /* Signatures per millisecond */
runtime_us = isc_time_microdiff(timer_finish, timer_start);
printf("Signatures generated: %10d\n", nsigned);
printf("Signatures retained: %10d\n", nretained);
printf("Signatures dropped: %10d\n", ndropped);
printf("Signatures successfully verified: %10d\n", nverified);
printf("Signatures unsuccessfully verified: %10d\n", nverifyfailed);
runtime_ms = runtime_us / 1000;
printf("Runtime in seconds: %7u.%03u\n",
(unsigned int) (runtime_ms / 1000),
(unsigned int) (runtime_ms % 1000));
if (runtime_us > 0) {
sig_ms = ((isc_uint64_t)nsigned * 1000000000) / runtime_us;
printf("Signatures per second: %7u.%03u\n",
(unsigned int) sig_ms / 1000,
(unsigned int) sig_ms % 1000);
}
}
int
main(int argc, char *argv[]) {
int i, ch;
char *startstr = NULL, *endstr = NULL, *classname = NULL;
char *origin = NULL, *file = NULL, *output = NULL;
char *randomfile = NULL;
char *endp;
isc_time_t timer_start, timer_finish;
signer_key_t *key;
@@ -1493,6 +1512,7 @@ main(int argc, char *argv[]) {
isc_boolean_t free_output = ISC_FALSE;
int tempfilelen;
dns_rdataclass_t rdclass;
isc_textregion_t r;
isc_task_t **tasks = NULL;
masterstyle = &dns_master_style_explicitttl;
@@ -1505,7 +1525,7 @@ main(int argc, char *argv[]) {
dns_result_register();
while ((ch = isc_commandline_parse(argc, argv,
"c:s:e:i:v:o:f:ahpr:td:n:S"))
"c:s:e:i:v:o:f:ahpr:td:n:"))
!= -1) {
switch (ch) {
case 'c':
@@ -1533,7 +1553,7 @@ main(int argc, char *argv[]) {
break;
case 'r':
setup_entropy(mctx, isc_commandline_argument, &ectx);
randomfile = isc_commandline_argument;
break;
case 'v':
@@ -1570,12 +1590,6 @@ main(int argc, char *argv[]) {
fatal("number of cpus must be numeric");
break;
case 'S':
/* This is intentionally undocumented */
/* -S: simple output style */
masterstyle = &dns_master_style_simple;
break;
case 'h':
default:
usage();
@@ -1583,8 +1597,7 @@ main(int argc, char *argv[]) {
}
}
if (ectx == NULL)
setup_entropy(mctx, NULL, &ectx);
setup_entropy(mctx, randomfile, &ectx);
eflags = ISC_ENTROPY_BLOCKING;
if (!pseudorandom)
eflags |= ISC_ENTROPY_GOODONLY;
@@ -1611,7 +1624,15 @@ main(int argc, char *argv[]) {
ntasks = isc_os_ncpus();
vbprintf(4, "using %d cpus\n", ntasks);
rdclass = strtoclass(classname);
if (classname != NULL) {
r.base = classname;
r.length = strlen(classname);
result = dns_rdataclass_fromtext(&rdclass, &r);
if (result != ISC_R_SUCCESS)
fatal("unknown class %s",classname);
} else
rdclass = dns_rdataclass_in;
setup_logging(verbose, mctx, &log);
@@ -1639,14 +1660,15 @@ main(int argc, char *argv[]) {
origin = file;
gdb = NULL;
TIME_NOW(&timer_start);
isc_time_now(&timer_start);
loadzone(file, origin, rdclass, &gdb);
gorigin = dns_db_origin(gdb);
zonettl = soattl();
ISC_LIST_INIT(keylist);
if (argc == 0) {
signer_key_t *key;
loadzonekeys(gdb);
key = ISC_LIST_HEAD(keylist);
@@ -1663,7 +1685,7 @@ main(int argc, char *argv[]) {
DST_TYPE_PRIVATE,
mctx, &newkey);
if (result != ISC_R_SUCCESS)
fatal("cannot load key %s: %s", argv[i],
fatal("cannot load key %s: %s", argv[i],
isc_result_totext(result));
key = ISC_LIST_HEAD(keylist);
@@ -1703,8 +1725,6 @@ main(int argc, char *argv[]) {
result = dns_db_newversion(gdb, &gversion);
check_result(result, "dns_db_newversion()");
nxtify();
tempfilelen = strlen(output) + 20;
tempfile = isc_mem_get(mctx, tempfilelen);
if (tempfile == NULL)
@@ -1780,6 +1800,7 @@ main(int argc, char *argv[]) {
printf("%s\n", output);
dns_db_closeversion(gdb, &gversion, ISC_FALSE);
dns_db_detach(&gdb);
while (!ISC_LIST_EMPTY(keylist)) {
@@ -1804,8 +1825,35 @@ main(int argc, char *argv[]) {
(void) isc_app_finish();
if (printstats) {
TIME_NOW(&timer_finish);
print_stats(&timer_start, &timer_finish);
isc_uint64_t runtime_us; /* Runtime in microseconds */
isc_uint64_t runtime_ms; /* Runtime in milliseconds */
isc_uint64_t sig_ms; /* Signatures per millisecond */
isc_time_now(&timer_finish);
runtime_us = isc_time_microdiff(&timer_finish, &timer_start);
printf("Signatures generated: %10d\n",
nsigned);
printf("Signatures retained: %10d\n",
nretained);
printf("Signatures dropped: %10d\n",
ndropped);
printf("Signatures successfully verified: %10d\n",
nverified);
printf("Signatures unsuccessfully verified: %10d\n",
nverifyfailed);
runtime_ms = runtime_us / 1000;
printf("Runtime in seconds: %7u.%03u\n",
(unsigned int) (runtime_ms / 1000),
(unsigned int) (runtime_ms % 1000));
if (runtime_us > 0) {
sig_ms = ((isc_uint64_t)nsigned * 1000000000) /
runtime_us;
printf("Signatures per second: %7u.%03u\n",
(unsigned int) sig_ms / 1000,
(unsigned int) sig_ms % 1000);
}
}
return (0);

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssectool.c,v 1.36 2001/11/27 22:08:58 bwelling Exp $ */
/* $Id: dnssectool.c,v 1.31.2.2 2001/11/27 22:41:49 gson Exp $ */
#include <config.h>
@@ -23,8 +23,6 @@
#include <isc/buffer.h>
#include <isc/entropy.h>
#include <isc/list.h>
#include <isc/mem.h>
#include <isc/string.h>
#include <isc/time.h>
#include <isc/util.h>
@@ -33,7 +31,6 @@
#include <dns/log.h>
#include <dns/name.h>
#include <dns/rdatastruct.h>
#include <dns/rdataclass.h>
#include <dns/rdatatype.h>
#include <dns/result.h>
#include <dns/secalg.h>
@@ -44,15 +41,7 @@
extern int verbose;
extern const char *program;
typedef struct entropysource entropysource_t;
struct entropysource {
isc_entropysource_t *source;
isc_mem_t *mctx;
ISC_LINK(entropysource_t) link;
};
static ISC_LIST(entropysource_t) sources;
static isc_entropysource_t *source = NULL;
static fatalcallback_t *fatalcallback = NULL;
void
@@ -122,8 +111,8 @@ sig_format(dns_rdata_sig_t *sig, char *cp, unsigned int size) {
char namestr[DNS_NAME_FORMATSIZE];
char algstr[DNS_NAME_FORMATSIZE];
dns_name_format(&sig->signer, namestr, sizeof(namestr));
alg_format(sig->algorithm, algstr, sizeof(algstr));
dns_name_format(&sig->signer, namestr, sizeof namestr);
alg_format(sig->algorithm, algstr, sizeof algstr);
snprintf(cp, size, "%s/%s/%d", namestr, algstr, sig->keyid);
}
@@ -132,8 +121,8 @@ key_format(const dst_key_t *key, char *cp, unsigned int size) {
char namestr[DNS_NAME_FORMATSIZE];
char algstr[DNS_NAME_FORMATSIZE];
dns_name_format(dst_key_name(key), namestr, sizeof(namestr));
alg_format((dns_secalg_t) dst_key_alg(key), algstr, sizeof(algstr));
dns_name_format(dst_key_name(key), namestr, sizeof namestr);
alg_format((dns_secalg_t) dst_key_alg(key), algstr, sizeof algstr);
snprintf(cp, size, "%s/%s/%d", namestr, algstr, dst_key_id(key));
}
@@ -209,8 +198,6 @@ cleanup_logging(isc_log_t **logp) {
void
setup_entropy(isc_mem_t *mctx, const char *randomfile, isc_entropy_t **ectx) {
isc_result_t result;
isc_entropysource_t *source = NULL;
entropysource_t *elt;
int usekeyboard = ISC_ENTROPY_KEYBOARDMAYBE;
REQUIRE(ectx != NULL);
@@ -219,7 +206,6 @@ setup_entropy(isc_mem_t *mctx, const char *randomfile, isc_entropy_t **ectx) {
result = isc_entropy_create(mctx, ectx);
if (result != ISC_R_SUCCESS)
fatal("could not create entropy object");
ISC_LIST_INIT(sources);
}
if (randomfile != NULL && strcmp(randomfile, "keyboard") == 0) {
@@ -233,32 +219,17 @@ setup_entropy(isc_mem_t *mctx, const char *randomfile, isc_entropy_t **ectx) {
if (result != ISC_R_SUCCESS)
fatal("could not initialize entropy source: %s",
isc_result_totext(result));
if (source != NULL) {
elt = isc_mem_get(mctx, sizeof(*elt));
if (elt == NULL)
fatal("out of memory");
elt->source = source;
elt->mctx = mctx;
ISC_LINK_INIT(elt, link);
ISC_LIST_APPEND(sources, elt, link);
}
}
void
cleanup_entropy(isc_entropy_t **ectx) {
entropysource_t *source;
while (!ISC_LIST_EMPTY(sources)) {
source = ISC_LIST_HEAD(sources);
ISC_LIST_UNLINK(sources, source, link);
isc_entropy_destroysource(&source->source);
isc_mem_put(source->mctx, source, sizeof(*source));
}
if (source != NULL)
isc_entropy_destroysource(&source);
isc_entropy_detach(ectx);
}
isc_stdtime_t
strtotime(const char *str, isc_int64_t now, isc_int64_t base) {
strtotime(char *str, isc_int64_t now, isc_int64_t base) {
isc_int64_t val, offset;
isc_result_t result;
char *endp;
@@ -287,19 +258,3 @@ strtotime(const char *str, isc_int64_t now, isc_int64_t base) {
return ((isc_stdtime_t) val);
}
dns_rdataclass_t
strtoclass(const char *str) {
isc_consttextregion_t r;
dns_rdataclass_t rdclass;
isc_result_t ret;
if (str == NULL)
return dns_rdataclass_in;
r.base = str;
r.length = strlen(str);
ret = dns_rdataclass_fromtext(&rdclass, (isc_textregion_t *)&r);
if (ret != ISC_R_SUCCESS)
fatal("unknown class %s", str);
return (rdclass);
}

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssectool.h,v 1.16 2001/09/21 00:17:01 bwelling Exp $ */
/* $Id: dnssectool.h,v 1.15 2001/08/08 22:54:16 gson Exp $ */
#ifndef DNSSECTOOL_H
#define DNSSECTOOL_H 1
@@ -68,9 +68,6 @@ void
cleanup_entropy(isc_entropy_t **ectx);
isc_stdtime_t
strtotime(const char *str, isc_int64_t now, isc_int64_t base);
dns_rdataclass_t
strtoclass(const char *str);
strtotime(char *str, isc_int64_t now, isc_int64_t base);
#endif /* DNSSEC_DNSSECTOOL_H */

View File

@@ -13,7 +13,7 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.77 2001/11/20 01:14:55 gson Exp $
# $Id: Makefile.in,v 1.74 2001/06/01 00:45:00 bwelling Exp $
srcdir = @srcdir@
VPATH = @srcdir@
@@ -21,7 +21,7 @@ top_srcdir = @top_srcdir@
@BIND9_VERSION@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
#
# Add database drivers here.
@@ -32,39 +32,36 @@ DBDRIVER_INCLUDES =
DBDRIVER_LIBS =
CINCLUDES = -I${srcdir}/include -I${srcdir}/unix/include \
${LWRES_INCLUDES} ${DNS_INCLUDES} ${BIND9_INCLUDES} \
${LWRES_INCLUDES} ${DNS_INCLUDES} \
${ISCCFG_INCLUDES} ${ISCCC_INCLUDES} ${ISC_INCLUDES} \
${DBDRIVER_INCLUDES}
CDEFINES =
CWARNINGS =
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCCFGLIBS = ../../lib/isccfg/libisccfg.@A@
ISCCCLIBS = ../../lib/isccc/libisccc.@A@
ISCLIBS = ../../lib/isc/libisc.@A@
LWRESLIBS = ../../lib/lwres/liblwres.@A@
BIND9LIBS = ../../lib/bind9/libbind9.@A@
DNSDEPLIBS = ../../lib/dns/libdns.@A@
ISCCFGDEPLIBS = ../../lib/isccfg/libisccfg.@A@
ISCCCDEPLIBS = ../../lib/isccc/libisccc.@A@
ISCDEPLIBS = ../../lib/isc/libisc.@A@
LWRESDEPLIBS = ../../lib/lwres/liblwres.@A@
BIND9DEPLIBS = ../../lib/bind9/libbind9.@A@
DEPLIBS = ${LWRESDEPLIBS} ${DNSDEPLIBS} ${BIND9DEPLIBS} \
DEPLIBS = ${LWRESDEPLIBS} ${DNSDEPLIBS} \
${ISCCFGDEPLIBS} ${ISCCCDEPLIBS} ${ISCDEPLIBS}
LIBS = ${LWRESLIBS} ${DNSLIBS} ${BIND9LIBS} \
LIBS = ${LWRESLIBS} ${DNSLIBS} \
${ISCCFGLIBS} ${ISCCCLIBS} ${ISCLIBS} ${DBDRIVER_LIBS} @LIBS@
SUBDIRS = unix
TARGETS = named lwresd
OBJS = aclconf.@O@ builtin.@O@ client.@O@ config.@O@ control.@O@ \
controlconf.@O@ interfacemgr.@O@ \
OBJS = aclconf.@O@ client.@O@ config.@O@ control.@O@ controlconf.@O@ interfacemgr.@O@ \
listenlist.@O@ log.@O@ logconf.@O@ main.@O@ notify.@O@ \
query.@O@ server.@O@ sortlist.@O@ \
tkeyconf.@O@ tsigconf.@O@ update.@O@ xfrout.@O@ \
@@ -75,8 +72,7 @@ OBJS = aclconf.@O@ builtin.@O@ client.@O@ config.@O@ control.@O@ \
UOBJS = unix/os.@O@
SRCS = aclconf.c builtin.c client.c config.c control.c \
controlconf.c interfacemgr.c \
SRCS = aclconf.c client.c config.c control.c controlconf.c interfacemgr.c \
listenlist.c log.c logconf.c main.c notify.c \
query.c server.c sortlist.c \
tkeyconf.c tsigconf.c update.c xfrout.c \
@@ -116,7 +112,7 @@ docclean manclean maintainer-clean::
rm -f ${MANOBJS}
clean distclean maintainer-clean::
rm -f ${TARGETS} ${OBJS}
rm -f ${TARGETS}
installdirs:
$(SHELL) ${top_srcdir}/mkinstalldirs ${DESTDIR}${sbindir}

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: aclconf.c,v 1.28 2002/01/04 02:31:59 gson Exp $ */
/* $Id: aclconf.c,v 1.27 2001/04/12 21:02:46 tale Exp $ */
#include <config.h>
@@ -23,8 +23,6 @@
#include <isc/string.h> /* Required for HP/UX (and others?) */
#include <isc/util.h>
#include <isccfg/namedconf.h>
#include <dns/acl.h>
#include <dns/fixedname.h>
#include <dns/log.h>

View File

@@ -1,207 +0,0 @@
/*
* Copyright (C) 2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM
* DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL
* INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT,
* INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING
* FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: builtin.c,v 1.2 2002/01/25 03:12:07 marka Exp $ */
/*
* The built-in "version", "hostname", and "authors" databases.
*/
#include <config.h>
#include <string.h>
#include <stdio.h>
#include <isc/print.h>
#include <isc/result.h>
#include <isc/util.h>
#include <dns/sdb.h>
#include <dns/result.h>
#include <named/builtin.h>
#include <named/globals.h>
#include <named/server.h>
#include <named/os.h>
typedef struct builtin builtin_t;
static isc_result_t do_version_lookup(dns_sdblookup_t *lookup);
static isc_result_t do_hostname_lookup(dns_sdblookup_t *lookup);
static isc_result_t do_authors_lookup(dns_sdblookup_t *lookup);
/*
* We can't use function pointers as the db_data directly
* because ANSI C does not guarantee that function pointers
* can safely be cast to void pointers and back.
*/
struct builtin {
isc_result_t (*do_lookup)(dns_sdblookup_t *lookup);
};
static builtin_t version_builtin = { do_version_lookup };
static builtin_t hostname_builtin = { do_hostname_lookup };
static builtin_t authors_builtin = { do_authors_lookup };
static dns_sdbimplementation_t *builtin_impl;
static isc_result_t
builtin_lookup(const char *zone, const char *name, void *dbdata,
dns_sdblookup_t *lookup)
{
builtin_t *b = (builtin_t *) dbdata;
UNUSED(zone);
if (strcmp(name, "@") == 0)
return (b->do_lookup(lookup));
else
return (ISC_R_NOTFOUND);
}
static isc_result_t
put_txt(dns_sdblookup_t *lookup, const char *text) {
unsigned char buf[256];
unsigned int len = strlen(text);
if (len > 255)
len = 255; /* Silently truncate */
buf[0] = len;
memcpy(&buf[1], text, len);
return (dns_sdb_putrdata(lookup, dns_rdatatype_txt, 0, buf, len + 1));
}
static isc_result_t
do_version_lookup(dns_sdblookup_t *lookup) {
if (ns_g_server->version_set) {
if (ns_g_server->version == NULL)
return (ISC_R_SUCCESS);
else
return (put_txt(lookup, ns_g_server->version));
} else {
return (put_txt(lookup, ns_g_version));
}
}
static isc_result_t
do_hostname_lookup(dns_sdblookup_t *lookup) {
if (ns_g_server->hostname_set) {
if (ns_g_server->hostname == NULL)
return (ISC_R_SUCCESS);
else
return (put_txt(lookup, ns_g_server->hostname));
} else {
char buf[256];
isc_result_t result = ns_os_gethostname(buf, sizeof(buf));
if (result != ISC_R_SUCCESS)
return (result);
return (put_txt(lookup, buf));
}
}
static isc_result_t
do_authors_lookup(dns_sdblookup_t *lookup) {
isc_result_t result;
const char **p;
static const char *authors[] = {
"Mark Andrews",
"James Brister",
"Ben Cottrell",
"Michael Graff",
"Andreas Gustafsson",
"Bob Halley",
"David Lawrence",
"Danny Mayer",
"Damien Neil",
"Matt Nelson",
"Michael Sawyer",
"Brian Wellington",
NULL
};
/*
* If a version string is specified, disable the authors.bind zone.
*/
if (ns_g_server->version_set)
return (ISC_R_SUCCESS);
for (p = authors; *p != NULL; p++) {
result = put_txt(lookup, *p);
if (result != ISC_R_SUCCESS)
return (result);
}
return (ISC_R_SUCCESS);
}
static isc_result_t
builtin_authority(const char *zone, void *dbdata, dns_sdblookup_t *lookup) {
isc_result_t result;
UNUSED(zone);
UNUSED(dbdata);
result = dns_sdb_putsoa(lookup, "@", "hostmaster", 0);
if (result != ISC_R_SUCCESS)
return (ISC_R_FAILURE);
result = dns_sdb_putrr(lookup, "ns", 0, "@");
if (result != ISC_R_SUCCESS)
return (ISC_R_FAILURE);
return (ISC_R_SUCCESS);
}
static isc_result_t
builtin_create(const char *zone, int argc, char **argv,
void *driverdata, void **dbdata)
{
UNUSED(zone);
UNUSED(driverdata);
if (argc != 1)
return (DNS_R_SYNTAX);
if (strcmp(argv[0], "version") == 0)
*dbdata = &version_builtin;
else if (strcmp(argv[0], "hostname") == 0)
*dbdata = &hostname_builtin;
else if (strcmp(argv[0], "authors") == 0)
*dbdata = &authors_builtin;
else
return (ISC_R_NOTIMPLEMENTED);
return (ISC_R_SUCCESS);
}
static dns_sdbmethods_t builtin_methods = {
builtin_lookup,
builtin_authority,
NULL, /* allnodes */
builtin_create,
NULL /* destroy */
};
isc_result_t
ns_builtin_init(void) {
RUNTIME_CHECK(dns_sdb_register("_builtin", &builtin_methods, NULL,
DNS_SDBFLAG_RELATIVEOWNER |
DNS_SDBFLAG_RELATIVERDATA,
ns_g_mctx, &builtin_impl)
== ISC_R_SUCCESS);
return (ISC_R_SUCCESS);
}
void
ns_builtin_deinit(void) {
dns_sdb_unregister(&builtin_impl);
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 1999-2001 Internet Software Consortium.
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: client.c,v 1.203 2002/01/23 08:46:36 bwelling Exp $ */
/* $Id: client.c,v 1.176.2.11 2002/04/23 01:53:53 marka Exp $ */
#include <config.h>
@@ -95,7 +95,6 @@ struct ns_clientmgr {
/* Locked by lock. */
isc_boolean_t exiting;
client_list_t active; /* Active clients */
client_list_t recursing; /* Recursing clients */
client_list_t inactive; /* To be recycled */
};
@@ -151,7 +150,7 @@ struct ns_clientmgr {
#define NS_CLIENTSTATE_WORKING 4
/*
* The client object has received a request and is working
* on it. It has a view, and it may have any of a non-reset OPT,
* on it. It has a view, and it may have any of a non-reset OPT,
* recursion quota, and an outstanding write request.
*/
@@ -174,27 +173,6 @@ static void client_start(isc_task_t *task, isc_event_t *event);
static void client_request(isc_task_t *task, isc_event_t *event);
static void ns_client_dumpmessage(ns_client_t *client, const char *reason);
void
ns_client_recursing(ns_client_t *client, isc_boolean_t killoldest) {
ns_client_t *oldest;
REQUIRE(NS_CLIENT_VALID(client));
LOCK(&client->manager->lock);
if (killoldest) {
oldest = ISC_LIST_HEAD(client->manager->recursing);
if (oldest != NULL) {
ns_query_cancel(oldest);
ISC_LIST_UNLINK(*oldest->list, oldest, link);
ISC_LIST_APPEND(client->manager->active, oldest, link);
oldest->list = &client->manager->active;
}
}
ISC_LIST_UNLINK(*client->list, client, link);
ISC_LIST_APPEND(client->manager->recursing, client, link);
client->list = &client->manager->recursing;
UNLOCK(&client->manager->lock);
}
void
ns_client_settimeout(ns_client_t *client, unsigned int seconds) {
isc_result_t result;
@@ -310,9 +288,9 @@ exit_check(ns_client_t *client) {
isc_quota_detach(&client->tcpquota);
if (client->timerset) {
(void)isc_timer_reset(client->timer,
isc_timertype_inactive,
NULL, NULL, ISC_TRUE);
(void) isc_timer_reset(client->timer,
isc_timertype_inactive,
NULL, NULL, ISC_TRUE);
client->timerset = ISC_FALSE;
}
@@ -445,8 +423,7 @@ exit_check(ns_client_t *client) {
client->list = NULL;
if (manager->exiting &&
ISC_LIST_EMPTY(manager->active) &&
ISC_LIST_EMPTY(manager->inactive) &&
ISC_LIST_EMPTY(manager->recursing))
ISC_LIST_EMPTY(manager->inactive))
destroy_manager = manager;
}
/*
@@ -535,6 +512,7 @@ client_shutdown(isc_task_t *task, isc_event_t *event) {
(void)exit_check(client);
}
static void
ns_client_endrequest(ns_client_t *client) {
INSIST(client->naccepts == 0);
@@ -632,7 +610,7 @@ ns_client_next(ns_client_t *client, isc_result_t result) {
if (client->newstate > newstate)
client->newstate = newstate;
(void)exit_check(client);
(void) exit_check(client);
}
@@ -762,8 +740,7 @@ client_sendpkg(ns_client_t *client, isc_buffer_t *buffer) {
sockflags |= ISC_SOCKFLAG_NORETRY;
}
if ((client->attributes & NS_CLIENTATTR_PKTINFO) != 0 &&
(client->attributes & NS_CLIENTATTR_MULTICAST) == 0)
if ((client->attributes & NS_CLIENTATTR_PKTINFO) != 0)
pktinfo = &client->pktinfo;
else
pktinfo = NULL;
@@ -841,7 +818,6 @@ ns_client_send(ns_client_t *client) {
dns_compress_t cctx;
isc_boolean_t cleanup_cctx = ISC_FALSE;
unsigned char sendbuf[SEND_BUFFER_SIZE];
unsigned int dnssec_opts;
REQUIRE(NS_CLIENT_VALID(client));
@@ -850,11 +826,6 @@ ns_client_send(ns_client_t *client) {
if ((client->attributes & NS_CLIENTATTR_RA) != 0)
client->message->flags |= DNS_MESSAGEFLAG_RA;
if ((client->attributes & NS_CLIENTATTR_WANTDNSSEC) != 0)
dnssec_opts = 0;
else
dnssec_opts = DNS_MESSAGERENDER_OMITDNSSEC;
/*
* XXXRTH The following doesn't deal with TCP buffer resizing.
*/
@@ -890,8 +861,7 @@ ns_client_send(ns_client_t *client) {
goto done;
result = dns_message_rendersection(client->message,
DNS_SECTION_ANSWER,
DNS_MESSAGERENDER_PARTIAL |
dnssec_opts);
DNS_MESSAGERENDER_PARTIAL);
if (result == ISC_R_NOSPACE) {
client->message->flags |= DNS_MESSAGEFLAG_TC;
goto renderend;
@@ -900,8 +870,7 @@ ns_client_send(ns_client_t *client) {
goto done;
result = dns_message_rendersection(client->message,
DNS_SECTION_AUTHORITY,
DNS_MESSAGERENDER_PARTIAL |
dnssec_opts);
DNS_MESSAGERENDER_PARTIAL);
if (result == ISC_R_NOSPACE) {
client->message->flags |= DNS_MESSAGEFLAG_TC;
goto renderend;
@@ -909,8 +878,7 @@ ns_client_send(ns_client_t *client) {
if (result != ISC_R_SUCCESS)
goto done;
result = dns_message_rendersection(client->message,
DNS_SECTION_ADDITIONAL,
dnssec_opts);
DNS_SECTION_ADDITIONAL, 0);
if (result != ISC_R_SUCCESS && result != ISC_R_NOSPACE)
goto done;
renderend:
@@ -1059,8 +1027,7 @@ client_addopt(ns_client_t *client) {
ISC_LIST_INIT(rdatalist->rdata);
ISC_LIST_APPEND(rdatalist->rdata, rdata, link);
RUNTIME_CHECK(dns_rdatalist_tordataset(rdatalist, rdataset)
== ISC_R_SUCCESS);
dns_rdatalist_tordataset(rdatalist, rdataset);
client->opt = rdataset;
@@ -1068,13 +1035,13 @@ client_addopt(ns_client_t *client) {
}
static inline isc_boolean_t
allowed(isc_netaddr_t *addr, dns_name_t *signer, dns_acl_t *acl) {
allowed(isc_netaddr_t *addr, dns_acl_t *acl) {
int match;
isc_result_t result;
if (acl == NULL)
return (ISC_TRUE);
result = dns_acl_match(addr, signer, acl, &ns_g_server->aclenv,
result = dns_acl_match(addr, NULL, acl, &ns_g_server->aclenv,
&match, NULL);
if (result == ISC_R_SUCCESS && match > 0)
return (ISC_TRUE);
@@ -1090,7 +1057,7 @@ client_request(isc_task_t *task, isc_event_t *event) {
ns_client_t *client;
isc_socketevent_t *sevent;
isc_result_t result;
isc_result_t sigresult = ISC_R_SUCCESS;
isc_result_t sigresult;
isc_buffer_t *buffer;
isc_buffer_t tbuffer;
dns_view_t *view;
@@ -1200,15 +1167,13 @@ client_request(isc_task_t *task, isc_event_t *event) {
}
}
/*
* Silently drop multicast requests for the present.
* XXXMPA look at when/if mDNS spec stabilizes.
*/
if ((client->attributes & NS_CLIENTATTR_MULTICAST) != 0) {
ns_client_log(client, NS_LOGCATEGORY_CLIENT,
NS_LOGMODULE_CLIENT, ISC_LOG_DEBUG(2),
"dropping multicast request");
ns_client_next(client, DNS_R_REFUSED);
"multicast request");
#if 0
ns_client_error(client, DNS_R_REFUSED);
#endif
}
result = dns_message_peekheader(buffer, &id, &flags);
@@ -1265,10 +1230,6 @@ client_request(isc_task_t *task, isc_event_t *event) {
client->message->rcode = dns_rcode_noerror;
/* RFC1123 section 6.1.3.2 */
if ((client->attributes & NS_CLIENTATTR_MULTICAST) != 0)
client->message->flags &= ~DNS_MESSAGEFLAG_RD;
/*
* Deal with EDNS.
*/
@@ -1347,16 +1308,10 @@ client_request(isc_task_t *task, isc_event_t *event) {
if (client->message->rdclass == view->rdclass ||
client->message->rdclass == dns_rdataclass_any)
{
dns_name_t *tsig = NULL;
sigresult = dns_message_rechecksig(client->message,
view);
if (sigresult == ISC_R_SUCCESS)
tsig = client->message->tsigname;
if (allowed(&netaddr, tsig, view->matchclients) &&
allowed(&destaddr, tsig, view->matchdestinations) &&
!((client->message->flags & DNS_MESSAGEFLAG_RD)
== 0 && view->matchrecursiveonly))
if (allowed(&netaddr, view->matchclients) &&
allowed(&destaddr, view->matchdestinations) &&
!((flags & DNS_MESSAGEFLAG_RD) == 0 &&
view->matchrecursiveonly))
{
dns_view_attach(view, &client->view);
break;
@@ -1374,9 +1329,6 @@ client_request(isc_task_t *task, isc_event_t *event) {
*/
isc_buffer_t b;
isc_region_t *r;
dns_message_resetsig(client->message);
r = dns_message_getrawmessage(client->message);
isc_buffer_init(&b, r->base, r->length);
isc_buffer_add(&b, r->length);
@@ -1402,6 +1354,7 @@ client_request(isc_task_t *task, isc_event_t *event) {
* not. We do not log the lack of a signature unless we are
* debugging.
*/
sigresult = dns_message_checksig(client->message, client->view);
client->signer = NULL;
dns_name_init(&client->signername, NULL);
result = dns_message_signer(client->message, &client->signername);
@@ -1511,7 +1464,7 @@ client_timeout(isc_task_t *task, isc_event_t *event) {
if (client->newstate > NS_CLIENTSTATE_READY)
client->newstate = NS_CLIENTSTATE_READY;
(void)exit_check(client);
(void) exit_check(client);
}
static isc_result_t
@@ -1530,7 +1483,7 @@ client_create(ns_clientmgr_t *manager, ns_client_t **clientp)
REQUIRE(clientp != NULL && *clientp == NULL);
client = isc_mem_get(manager->mctx, sizeof(*client));
client = isc_mem_get(manager->mctx, sizeof *client);
if (client == NULL)
return (ISC_R_NOMEMORY);
@@ -1669,7 +1622,7 @@ client_create(ns_clientmgr_t *manager, ns_client_t **clientp)
isc_task_detach(&client->task);
cleanup_client:
isc_mem_put(manager->mctx, client, sizeof(*client));
isc_mem_put(manager->mctx, client, sizeof *client);
return (result);
}
@@ -1732,8 +1685,8 @@ client_newconn(isc_task_t *task, isc_event_t *event) {
client->state = NS_CLIENTSTATE_READING;
INSIST(client->recursionquota == NULL);
(void)isc_socket_getpeername(client->tcpsocket,
&client->peeraddr);
(void) isc_socket_getpeername(client->tcpsocket,
&client->peeraddr);
client->peeraddr_valid = ISC_TRUE;
ns_client_log(client, NS_LOGCATEGORY_CLIENT,
NS_LOGMODULE_CLIENT, ISC_LOG_DEBUG(3),
@@ -1774,6 +1727,8 @@ client_newconn(isc_task_t *task, isc_event_t *event) {
ns_client_log(client, DNS_LOGCATEGORY_SECURITY,
NS_LOGMODULE_CLIENT, ISC_LOG_DEBUG(10),
"blackholed connection attempt");
client->newstate = NS_CLIENTSTATE_READY;
(void)exit_check(client);
goto freeevent;
}
@@ -1851,7 +1806,7 @@ client_udprecv(ns_client_t *client) {
isc_result_totext(result));
/*
* This cannot happen in the current implementation, since
* isc_socket_recv2() cannot fail if flags == 0.
* isc_socket_recv2() cannot fail if flags == 0A
*
* If this does fail, we just go idle.
*/
@@ -1883,7 +1838,7 @@ ns_client_detach(ns_client_t **clientp) {
ns_client_log(client, NS_LOGCATEGORY_CLIENT,
NS_LOGMODULE_CLIENT, ISC_LOG_DEBUG(10),
"ns_client_detach: ref = %d", client->references);
(void)exit_check(client);
(void) exit_check(client);
}
isc_boolean_t
@@ -1922,13 +1877,12 @@ static void
clientmgr_destroy(ns_clientmgr_t *manager) {
REQUIRE(ISC_LIST_EMPTY(manager->active));
REQUIRE(ISC_LIST_EMPTY(manager->inactive));
REQUIRE(ISC_LIST_EMPTY(manager->recursing));
MTRACE("clientmgr_destroy");
DESTROYLOCK(&manager->lock);
manager->magic = 0;
isc_mem_put(manager->mctx, manager, sizeof(*manager));
isc_mem_put(manager->mctx, manager, sizeof *manager);
}
isc_result_t
@@ -1938,7 +1892,7 @@ ns_clientmgr_create(isc_mem_t *mctx, isc_taskmgr_t *taskmgr,
ns_clientmgr_t *manager;
isc_result_t result;
manager = isc_mem_get(mctx, sizeof(*manager));
manager = isc_mem_get(mctx, sizeof *manager);
if (manager == NULL)
return (ISC_R_NOMEMORY);
@@ -1952,7 +1906,6 @@ ns_clientmgr_create(isc_mem_t *mctx, isc_taskmgr_t *taskmgr,
manager->exiting = ISC_FALSE;
ISC_LIST_INIT(manager->active);
ISC_LIST_INIT(manager->inactive);
ISC_LIST_INIT(manager->recursing);
manager->magic = MANAGER_MAGIC;
MTRACE("create");
@@ -1962,7 +1915,7 @@ ns_clientmgr_create(isc_mem_t *mctx, isc_taskmgr_t *taskmgr,
return (ISC_R_SUCCESS);
cleanup_manager:
isc_mem_put(manager->mctx, manager, sizeof(*manager));
isc_mem_put(manager->mctx, manager, sizeof *manager);
return (result);
}
@@ -1983,11 +1936,6 @@ ns_clientmgr_destroy(ns_clientmgr_t **managerp) {
manager->exiting = ISC_TRUE;
for (client = ISC_LIST_HEAD(manager->recursing);
client != NULL;
client = ISC_LIST_NEXT(client, link))
isc_task_shutdown(client->task);
for (client = ISC_LIST_HEAD(manager->active);
client != NULL;
client = ISC_LIST_NEXT(client, link))
@@ -1999,8 +1947,7 @@ ns_clientmgr_destroy(ns_clientmgr_t **managerp) {
isc_task_shutdown(client->task);
if (ISC_LIST_EMPTY(manager->active) &&
ISC_LIST_EMPTY(manager->inactive) &&
ISC_LIST_EMPTY(manager->recursing))
ISC_LIST_EMPTY(manager->inactive))
need_destroy = ISC_TRUE;
UNLOCK(&manager->lock);
@@ -2153,7 +2100,12 @@ ns_client_name(ns_client_t *client, char *peerbuf, size_t len) {
snprintf(peerbuf, len, "@%p", client);
}
void
static void
ns_client_logv(ns_client_t *client, isc_logcategory_t *category,
isc_logmodule_t *module, int level, const char *fmt, va_list ap)
ISC_FORMAT_PRINTF(5, 0);
static void
ns_client_logv(ns_client_t *client, isc_logcategory_t *category,
isc_logmodule_t *module, int level, const char *fmt, va_list ap)
{
@@ -2161,7 +2113,7 @@ ns_client_logv(ns_client_t *client, isc_logcategory_t *category,
char peerbuf[ISC_SOCKADDR_FORMATSIZE];
vsnprintf(msgbuf, sizeof(msgbuf), fmt, ap);
ns_client_name(client, peerbuf, sizeof(peerbuf));
ns_client_name(client, peerbuf, sizeof peerbuf);
isc_log_write(ns_g_lctx, category, module, level,
"client %s: %s", peerbuf, msgbuf);

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2001 Internet Software Consortium.
* Copyright (C) 2001, 2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: config.c,v 1.26 2002/01/23 02:12:22 marka Exp $ */
/* $Id: config.c,v 1.11.2.4 2002/03/20 20:32:41 marka Exp $ */
#include <config.h>
@@ -30,7 +30,7 @@
#include <isc/sockaddr.h>
#include <isc/util.h>
#include <isccfg/namedconf.h>
#include <isccfg/cfg.h>
#include <dns/fixedname.h>
#include <dns/name.h>
@@ -87,6 +87,7 @@ options {\n\
treat-cr-as-space true;\n\
use-id-pool true;\n\
use-ixfr true;\n\
version \""VERSION"\";\n\
\n\
/* view */\n\
allow-notify {none;};\n\
@@ -141,29 +142,7 @@ options {\n\
min-refresh-time 300;\n\
sig-validity-interval 30; /* days */\n\
zone-statistics false;\n\
max-journal-size unlimited;\n\
ixfr-from-differences false;\n\
};\n\
\n\
view \"_bind\" chaos {\n\
recursion no;\n\
\n\
zone \"version.bind\" chaos {\n\
type master;\n\
database \"_builtin version\";\n\
};\n\
\n\
zone \"hostname.bind\" chaos {\n\
type master;\n\
database \"_builtin hostname\";\n\
};\n\
\n\
zone \"authors.bind\" chaos {\n\
type master;\n\
database \"_builtin authors\";\n\
};\n\
};\n\
";
};";
isc_result_t
ns_config_parsedefaults(cfg_parser_t *parser, cfg_obj_t **conf) {
@@ -178,7 +157,7 @@ isc_result_t
ns_config_get(cfg_obj_t **maps, const char* name, cfg_obj_t **obj) {
int i;
for (i = 0;; i++) {
for (i = 0; ; i++) {
if (maps[i] == NULL)
return (ISC_R_NOTFOUND);
if (cfg_map_get(maps[i], name, obj) == ISC_R_SUCCESS)
@@ -224,11 +203,11 @@ ns_config_getzonetype(cfg_obj_t *zonetypeobj) {
char *str;
str = cfg_obj_asstring(zonetypeobj);
if (strcmp(str, "master") == 0)
if (strcasecmp(str, "master") == 0)
ztype = dns_zone_master;
else if (strcmp(str, "slave") == 0)
else if (strcasecmp(str, "slave") == 0)
ztype = dns_zone_slave;
else if (strcmp(str, "stub") == 0)
else if (strcasecmp(str, "stub") == 0)
ztype = dns_zone_stub;
else
INSIST(0);
@@ -249,7 +228,6 @@ ns_config_getiplist(cfg_obj_t *config, cfg_obj_t *list,
isc_result_t result;
INSIST(addrsp != NULL && *addrsp == NULL);
INSIST(countp != NULL);
addrlist = cfg_tuple_get(list, "addresses");
count = ns_config_listcount(addrlist);
@@ -399,7 +377,7 @@ ns_config_getipandkeylist(cfg_obj_t *config, cfg_obj_t *list, isc_mem_t *mctx,
isc_mem_put(mctx, addrs, count * sizeof(isc_sockaddr_t));
if (keys != NULL) {
unsigned int j;
for (j = 0; j <= i; j++) {
for (j = 0 ; j <= i; j++) {
if (keys[j] == NULL)
continue;
if (dns_name_dynamic(keys[j]))
@@ -441,7 +419,7 @@ ns_config_getport(cfg_obj_t *config, in_port_t *portp) {
isc_result_t result;
int i;
(void)cfg_map_get(config, "options", &options);
cfg_map_get(config, "options", &options);
i = 0;
if (options != NULL)
maps[i++] = options;

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: control.c,v 1.11 2002/01/22 22:05:46 bwelling Exp $ */
/* $Id: control.c,v 1.7 2001/05/31 01:21:06 bwelling Exp $ */
#include <config.h>
@@ -32,7 +32,6 @@
#include <named/control.h>
#include <named/log.h>
#include <named/os.h>
#include <named/server.h>
static isc_boolean_t
@@ -86,16 +85,12 @@ ns_control_docommand(isccc_sexpr_t *message, isc_buffer_t *text) {
result = ns_server_reconfigcommand(ns_g_server, command);
} else if (command_compare(command, NS_COMMAND_REFRESH)) {
result = ns_server_refreshcommand(ns_g_server, command);
} else if (command_compare(command, NS_COMMAND_RETRANSFER)) {
result = ns_server_retransfercommand(ns_g_server, command);
} else if (command_compare(command, NS_COMMAND_HALT)) {
ns_server_flushonshutdown(ns_g_server, ISC_FALSE);
ns_os_shutdownmsg(command, text);
isc_app_shutdown();
result = ISC_R_SUCCESS;
} else if (command_compare(command, NS_COMMAND_STOP)) {
ns_server_flushonshutdown(ns_g_server, ISC_TRUE);
ns_os_shutdownmsg(command, text);
isc_app_shutdown();
result = ISC_R_SUCCESS;
} else if (command_compare(command, NS_COMMAND_DUMPSTATS)) {
@@ -113,14 +108,8 @@ ns_control_docommand(isccc_sexpr_t *message, isc_buffer_t *text) {
result = ISC_R_SUCCESS;
} else if (command_compare(command, NS_COMMAND_FLUSH)) {
result = ns_server_flushcache(ns_g_server, command);
} else if (command_compare(command, NS_COMMAND_FLUSHNAME)) {
result = ns_server_flushname(ns_g_server, command);
} else if (command_compare(command, NS_COMMAND_STATUS)) {
result = ns_server_status(ns_g_server, text);
} else if (command_compare(command, NS_COMMAND_FREEZE)) {
result = ns_server_freeze(ns_g_server, ISC_TRUE, command);
} else if (command_compare(command, NS_COMMAND_UNFREEZE)) {
result = ns_server_freeze(ns_g_server, ISC_FALSE, command);
} else {
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_CONTROL, ISC_LOG_WARNING,

View File

@@ -15,25 +15,29 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: controlconf.c,v 1.37 2002/01/04 02:32:01 gson Exp $ */
/* $Id: controlconf.c,v 1.28.2.7 2001/11/27 22:38:14 gson Exp $ */
#include <config.h>
#include <isc/base64.h>
#include <isc/buffer.h>
#include <isc/event.h>
#include <isc/file.h>
#include <isc/fsaccess.h>
#include <isc/mem.h>
#include <isc/net.h>
#include <isc/netaddr.h>
#include <isc/print.h>
#include <isc/random.h>
#include <isc/result.h>
#include <isc/stdio.h>
#include <isc/stdtime.h>
#include <isc/string.h>
#include <isc/timer.h>
#include <isc/util.h>
#include <isccfg/namedconf.h>
#include <bind9/check.h>
#include <isccfg/cfg.h>
#include <isccfg/check.h>
#include <isccc/alist.h>
#include <isccc/cc.h>
@@ -43,8 +47,11 @@
#include <isccc/sexpr.h>
#include <isccc/util.h>
#include <dns/keyvalues.h>
#include <dns/result.h>
#include <dst/dst.h>
#include <named/config.h>
#include <named/control.h>
#include <named/log.h>
@@ -759,7 +766,7 @@ get_rndckey(isc_mem_t *mctx, controlkeylist_t *keyids) {
if (keyid->keyname == NULL)
CHECK(ISC_R_NOMEMORY);
CHECK(bind9_check_key(key, ns_g_lctx));
CHECK(cfg_check_key(key, ns_g_lctx));
(void)cfg_map_get(key, "algorithm", &algobj);
(void)cfg_map_get(key, "secret", &secretobj);

View File

@@ -1,29 +0,0 @@
/*
* Copyright (C) 2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM
* DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL
* INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT,
* INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING
* FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: builtin.h,v 1.1 2001/11/20 01:18:15 gson Exp $ */
#ifndef NAMED_BUILTIN_H
#define NAMED_BUILTIN_H 1
#include <isc/types.h>
isc_result_t ns_builtin_init(void);
void ns_builtin_deinit(void);
#endif /* NAMED_BUILTIN_H */

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: client.h,v 1.65 2002/01/23 08:46:39 bwelling Exp $ */
/* $Id: client.h,v 1.60.2.2 2001/11/15 02:51:46 marka Exp $ */
#ifndef NAMED_CLIENT_H
#define NAMED_CLIENT_H 1
@@ -153,8 +153,6 @@ struct ns_client {
#define NS_CLIENTATTR_RA 0x02 /* Client gets recusive service */
#define NS_CLIENTATTR_PKTINFO 0x04 /* pktinfo is valid */
#define NS_CLIENTATTR_MULTICAST 0x08 /* recv'd from multicast */
#define NS_CLIENTATTR_WANTDNSSEC 0x10 /* include dnssec records */
/***
*** Functions
@@ -305,19 +303,8 @@ ns_client_log(ns_client_t *client, isc_logcategory_t *category,
isc_logmodule_t *module, int level,
const char *fmt, ...) ISC_FORMAT_PRINTF(5, 6);
void
ns_client_logv(ns_client_t *client, isc_logcategory_t *category,
isc_logmodule_t *module, int level, const char *fmt, va_list ap) ISC_FORMAT_PRINTF(5, 0);
void
ns_client_aclmsg(const char *msg, dns_name_t *name, dns_rdataclass_t rdclass,
char *buf, size_t len);
void
ns_client_recursing(ns_client_t *client, isc_boolean_t killoldest);
/*
* Add client to end of recursing list. If 'killoldest' is true
* kill the oldest recursive client (list head).
*/
#endif /* NAMED_CLIENT_H */

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: control.h,v 1.9 2002/01/22 22:05:51 bwelling Exp $ */
/* $Id: control.h,v 1.6 2001/05/08 04:09:40 bwelling Exp $ */
#ifndef NAMED_CONTROL_H
#define NAMED_CONTROL_H 1
@@ -36,17 +36,13 @@
#define NS_COMMAND_RELOAD "reload"
#define NS_COMMAND_RECONFIG "reconfig"
#define NS_COMMAND_REFRESH "refresh"
#define NS_COMMAND_RETRANSFER "retransfer"
#define NS_COMMAND_DUMPSTATS "stats"
#define NS_COMMAND_QUERYLOG "querylog"
#define NS_COMMAND_DUMPDB "dumpdb"
#define NS_COMMAND_TRACE "trace"
#define NS_COMMAND_NOTRACE "notrace"
#define NS_COMMAND_FLUSH "flush"
#define NS_COMMAND_FLUSHNAME "flushname"
#define NS_COMMAND_STATUS "status"
#define NS_COMMAND_FREEZE "freeze"
#define NS_COMMAND_UNFREEZE "unfreeze"
isc_result_t
ns_controls_create(ns_server_t *server, ns_controls_t **ctrlsp);

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: main.h,v 1.9 2001/09/07 00:36:55 marka Exp $ */
/* $Id: main.h,v 1.8 2001/08/08 22:54:26 gson Exp $ */
#ifndef NAMED_MAIN_H
#define NAMED_MAIN_H 1
@@ -23,7 +23,4 @@
void
ns_main_earlyfatal(const char *format, ...) ISC_FORMAT_PRINTF(1, 2);
void
ns_main_setmemstats(const char *);
#endif /* NAMED_MAIN_H */

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 1999-2001 Internet Software Consortium.
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: query.h,v 1.32 2002/01/23 08:46:40 bwelling Exp $ */
/* $Id: query.h,v 1.28.2.3 2002/02/08 03:57:17 marka Exp $ */
#ifndef NAMED_QUERY_H
#define NAMED_QUERY_H 1
@@ -49,7 +49,6 @@ struct ns_query {
dns_zone_t * authzone;
isc_boolean_t authdbset;
isc_boolean_t isreferral;
isc_mutex_t fetchlock;
dns_fetch_t * fetch;
dns_a6context_t a6ctx;
isc_bufferlist_t namebufs;
@@ -72,7 +71,7 @@ struct ns_query {
#define NS_QUERYATTR_QUERYOKVALID 0x0040
#define NS_QUERYATTR_QUERYOK 0x0080
#define NS_QUERYATTR_WANTRECURSION 0x0100
/* unused */
#define NS_QUERYATTR_WANTDNSSEC 0x0200
#define NS_QUERYATTR_NOAUTHORITY 0x0400
#define NS_QUERYATTR_NOADDITIONAL 0x0800
@@ -85,7 +84,4 @@ ns_query_free(ns_client_t *client);
void
ns_query_start(ns_client_t *client);
void
ns_query_cancel(ns_client_t *client);
#endif /* NAMED_QUERY_H */

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: server.h,v 1.64 2002/01/22 22:05:52 bwelling Exp $ */
/* $Id: server.h,v 1.58.2.1 2001/09/04 19:38:46 gson Exp $ */
#ifndef NAMED_SERVER_H
#define NAMED_SERVER_H 1
@@ -49,12 +49,6 @@ struct ns_server {
isc_quota_t tcpquota;
isc_quota_t recursionquota;
dns_acl_t *blackholeacl;
char * statsfile; /* Statistics file name */
char * dumpfile; /* Dump file name */
isc_boolean_t version_set; /* User has set version */
char * version; /* User-specified version */
isc_boolean_t hostname_set; /* User has set hostname */
char * hostname; /* User-specified hostname */
/*
* Current ACL environment. This defines the
@@ -82,8 +76,11 @@ struct ns_server {
isc_boolean_t flushonshutdown;
isc_boolean_t log_queries; /* For BIND 8 compatibility */
char * statsfile; /* Statistics file name */
isc_uint64_t * querystats; /* Query statistics counters */
char * dumpfile; /* Dump file name */
ns_controls_t * controls; /* Control channels */
};
@@ -137,12 +134,6 @@ ns_server_refreshcommand(ns_server_t *server, char *args);
* Act on a "refresh" command from the command channel.
*/
isc_result_t
ns_server_retransfercommand(ns_server_t *server, char *args);
/*
* Act on a "retransfer" command from the command channel.
*/
isc_result_t
ns_server_togglequerylog(ns_server_t *server);
/*
@@ -173,22 +164,10 @@ ns_server_setdebuglevel(ns_server_t *server, char *args);
isc_result_t
ns_server_flushcache(ns_server_t *server, char *args);
/*
* Flush a particular name from the server's cache(s)
*/
isc_result_t
ns_server_flushname(ns_server_t *server, char *args);
/*
* Report the server's status.
*/
isc_result_t
ns_server_status(ns_server_t *server, isc_buffer_t *text);
/*
* Enable or disable updates for a zone.
*/
isc_result_t
ns_server_freeze(ns_server_t *server, isc_boolean_t freeze, char *args);
#endif /* NAMED_SERVER_H */

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 1999-2001 Internet Software Consortium.
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: interfacemgr.c,v 1.66 2001/11/29 13:14:32 marka Exp $ */
/* $Id: interfacemgr.c,v 1.59.2.5 2002/02/08 03:57:10 marka Exp $ */
#include <config.h>
@@ -119,7 +119,7 @@ ns_interfacemgr_destroy(ns_interfacemgr_t *mgr) {
ns_listenlist_detach(&mgr->listenon6);
DESTROYLOCK(&mgr->lock);
mgr->magic = 0;
isc_mem_put(mgr->mctx, mgr, sizeof(*mgr));
isc_mem_put(mgr->mctx, mgr, sizeof *mgr);
}
dns_aclenv_t *
@@ -294,9 +294,6 @@ ns_interface_accepttcp(ns_interface_t *ifp) {
isc_result_totext(result));
goto tcp_socket_failure;
}
#ifndef ISC_ALLOW_MAPPED
isc_socket_ipv6only(ifp->tcpsocket, ISC_TRUE);
#endif
result = isc_socket_bind(ifp->tcpsocket, &ifp->addr);
if (result != ISC_R_SUCCESS) {
isc_log_write(IFMGR_COMMON_LOGARGS, ISC_LOG_ERROR,
@@ -476,9 +473,6 @@ static isc_result_t
do_ipv4(ns_interfacemgr_t *mgr) {
isc_interfaceiter_t *iter = NULL;
isc_result_t result;
isc_netaddr_t zero_address;
isc_netaddr_any(&zero_address);
result = isc_interfaceiter_create(mgr->mctx, &iter);
if (result != ISC_R_SUCCESS)
@@ -508,14 +502,7 @@ do_ipv4(ns_interfacemgr_t *mgr) {
if (interface.address.family != AF_INET)
continue;
/*
* Test for the address being nonzero rather than testing
* INTERFACE_F_UP, because on some systems the latter
* follows the media state and we could end up ignoring
* the interface for an entire rescan interval due to
* a temporary media glitch at rescan time.
*/
if (isc_netaddr_equal(&interface.address, &zero_address))
if ((interface.flags & INTERFACE_F_UP) == 0)
continue;
elt.type = dns_aclelementtype_ipprefix;

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: log.c,v 1.35 2001/11/23 01:15:06 marka Exp $ */
/* $Id: log.c,v 1.33.2.1 2001/10/31 22:44:15 marka Exp $ */
#include <config.h>
@@ -25,10 +25,6 @@
#include <named/log.h>
#ifndef ISC_FACILITY
#define ISC_FACILITY LOG_DAEMON
#endif
/*
* When adding a new category, be sure to add the appropriate
* #define to <named/log.h>.
@@ -130,15 +126,6 @@ ns_log_setdefaultchannels(isc_logconfig_t *lcfg) {
goto cleanup;
}
#if ISC_FACILITY != LOG_DAEMON
destination.facility = ISC_FACILITY;
result = isc_log_createchannel(lcfg, "default_syslog",
ISC_LOG_TOSYSLOG, ISC_LOG_INFO,
&destination, 0);
if (result != ISC_R_SUCCESS)
goto cleanup;
#endif
/*
* Set the initial debug level.
*/

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: logconf.c,v 1.33 2001/10/11 01:16:15 gson Exp $ */
/* $Id: logconf.c,v 1.30.2.3 2001/10/11 02:03:20 marka Exp $ */
#include <config.h>

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: lwdclient.c,v 1.16 2001/11/30 01:58:45 gson Exp $ */
/* $Id: lwdclient.c,v 1.13 2001/01/22 22:29:02 gson Exp $ */
#include <config.h>
@@ -29,7 +29,6 @@
#include <dns/log.h>
#include <named/types.h>
#include <named/log.h>
#include <named/lwresd.h>
#include <named/lwdclient.h>
@@ -82,7 +81,7 @@ ns_lwdclientmgr_create(ns_lwreslistener_t *listener, unsigned int nclients,
!= ISC_R_SUCCESS)
goto errout;
for (i = 0; i < nclients; i++) {
for (i = 0 ; i < nclients ; i++) {
client = isc_mem_get(lwresd->mctx, sizeof(ns_lwdclient_t));
if (client != NULL) {
ns_lwdclient_log(50, "created client %p, manager %p",
@@ -117,7 +116,7 @@ ns_lwdclientmgr_create(ns_lwreslistener_t *listener, unsigned int nclients,
client = ISC_LIST_HEAD(cm->idle);
while (client != NULL) {
ISC_LIST_UNLINK(cm->idle, client, link);
isc_mem_put(lwresd->mctx, client, sizeof(*client));
isc_mem_put(lwresd->mctx, client, sizeof (*client));
client = ISC_LIST_HEAD(cm->idle);
}
@@ -127,7 +126,7 @@ ns_lwdclientmgr_create(ns_lwreslistener_t *listener, unsigned int nclients,
if (cm->lwctx != NULL)
lwres_context_destroy(&cm->lwctx);
isc_mem_put(lwresd->mctx, cm, sizeof(*cm));
isc_mem_put(lwresd->mctx, cm, sizeof (*cm));
return (result);
}
@@ -149,7 +148,7 @@ lwdclientmgr_destroy(ns_lwdclientmgr_t *cm) {
ns_lwdclient_log(50, "destroying client %p, manager %p",
client, cm);
ISC_LIST_UNLINK(cm->idle, client, link);
isc_mem_put(cm->mctx, client, sizeof(*client));
isc_mem_put(cm->mctx, client, sizeof (*client));
client = ISC_LIST_HEAD(cm->idle);
}
@@ -164,7 +163,7 @@ lwdclientmgr_destroy(ns_lwdclientmgr_t *cm) {
listener = cm->listener;
ns_lwreslistener_unlinkcm(listener, cm);
ns_lwdclient_log(50, "destroying manager %p", cm);
isc_mem_put(cm->mctx, cm, sizeof(*cm));
isc_mem_put(cm->mctx, cm, sizeof (*cm));
ns_lwreslistener_detach(&listener);
}
@@ -212,7 +211,6 @@ process_request(ns_lwdclient_t *client) {
void
ns_lwdclient_recv(isc_task_t *task, isc_event_t *ev) {
isc_result_t result;
ns_lwdclient_t *client = ev->ev_arg;
ns_lwdclientmgr_t *cm = client->clientmgr;
isc_socketevent_t *dev = (isc_socketevent_t *)ev;
@@ -252,13 +250,7 @@ ns_lwdclient_recv(isc_task_t *task, isc_event_t *ev) {
isc_event_free(&ev);
dev = NULL;
result = ns_lwdclient_startrecv(cm);
if (result != ISC_R_SUCCESS)
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_LWRESD, ISC_LOG_ERROR,
"could not start lwres "
"client handler: %s",
isc_result_totext(result));
ns_lwdclient_startrecv(cm);
process_request(client);
}
@@ -337,7 +329,7 @@ lwdclientmgr_shutdown_callback(isc_task_t *task, isc_event_t *ev) {
ns_lwdclient_log(50, "destroying client %p, manager %p",
client, cm);
ISC_LIST_UNLINK(cm->idle, client, link);
isc_mem_put(cm->mctx, client, sizeof(*client));
isc_mem_put(cm->mctx, client, sizeof (*client));
client = ISC_LIST_HEAD(cm->idle);
}
@@ -374,7 +366,6 @@ lwdclientmgr_shutdown_callback(isc_task_t *task, isc_event_t *ev) {
void
ns_lwdclient_stateidle(ns_lwdclient_t *client) {
ns_lwdclientmgr_t *cm;
isc_result_t result;
cm = client->clientmgr;
@@ -389,13 +380,7 @@ ns_lwdclient_stateidle(ns_lwdclient_t *client) {
NS_LWDCLIENT_SETIDLE(client);
result = ns_lwdclient_startrecv(cm);
if (result != ISC_R_SUCCESS)
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_LWRESD, ISC_LOG_ERROR,
"could not start lwres "
"client handler: %s",
isc_result_totext(result));
ns_lwdclient_startrecv(cm);
}
void

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: lwdgabn.c,v 1.14 2001/11/27 00:55:34 gson Exp $ */
/* $Id: lwdgabn.c,v 1.13 2001/01/22 22:12:16 bwelling Exp $ */
#include <config.h>
@@ -546,11 +546,11 @@ init_gabn(ns_lwdclient_t *client) {
* Initialize the real name and alias arrays in the reply we're
* going to build up.
*/
for (i = 0; i < LWRES_MAX_ALIASES; i++) {
for (i = 0 ; i < LWRES_MAX_ALIASES ; i++) {
client->aliases[i] = NULL;
client->aliaslen[i] = 0;
}
for (i = 0; i < LWRES_MAX_ADDRS; i++) {
for (i = 0 ; i < LWRES_MAX_ADDRS ; i++) {
client->addrs[i].family = 0;
client->addrs[i].length = 0;
memset(client->addrs[i].address, 0, LWRES_ADDR_MAXLEN);

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: lwdgnba.c,v 1.14 2001/11/27 00:55:35 gson Exp $ */
/* $Id: lwdgnba.c,v 1.13 2001/08/08 22:54:19 gson Exp $ */
#include <config.h>
@@ -179,11 +179,11 @@ init_gnba(ns_lwdclient_t *client) {
* Initialize the real name and alias arrays in the reply we're
* going to build up.
*/
for (i = 0; i < LWRES_MAX_ALIASES; i++) {
for (i = 0 ; i < LWRES_MAX_ALIASES ; i++) {
client->aliases[i] = NULL;
client->aliaslen[i] = 0;
}
for (i = 0; i < LWRES_MAX_ADDRS; i++) {
for (i = 0 ; i < LWRES_MAX_ADDRS ; i++) {
client->addrs[i].family = 0;
client->addrs[i].length = 0;
memset(client->addrs[i].address, 0, LWRES_ADDR_MAXLEN);

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: lwresd.c,v 1.42 2002/01/23 02:12:21 marka Exp $ */
/* $Id: lwresd.c,v 1.37 2001/08/07 01:58:55 marka Exp $ */
/*
* Main program for the Lightweight Resolver Daemon.
@@ -38,7 +38,7 @@
#include <isc/task.h>
#include <isc/util.h>
#include <isccfg/namedconf.h>
#include <isccfg/cfg.h>
#include <dns/log.h>
#include <dns/result.h>
@@ -152,7 +152,7 @@ ns_lwresd_parseeresolvconf(isc_mem_t *mctx, cfg_parser_t *pctx,
if (lwc->nsnext > 0) {
CHECK(buffer_putstr(&b, "\tforwarders {\n"));
for (i = 0; i < lwc->nsnext; i++) {
for (i = 0 ; i < lwc->nsnext ; i++) {
CHECK(lwaddr_sockaddr_fromlwresaddr(
&sa,
&lwc->nameservers[i],
@@ -173,7 +173,7 @@ ns_lwresd_parseeresolvconf(isc_mem_t *mctx, cfg_parser_t *pctx,
CHECK(buffer_putstr(&b, "\t\t{\n"));
CHECK(buffer_putstr(&b, "\t\t\tany;\n"));
CHECK(buffer_putstr(&b, "\t\t\t{\n"));
for (i = 0; i < lwc->sortlistnxt; i++) {
for (i = 0 ; i < lwc->sortlistnxt; i++) {
lwres_addr_t *lwaddr = &lwc->sortlist[i].addr;
lwres_addr_t *lwmask = &lwc->sortlist[i].mask;
unsigned int mask;
@@ -245,7 +245,7 @@ ns_lwresd_parseeresolvconf(isc_mem_t *mctx, cfg_parser_t *pctx,
if (lwc->lwnext > 0) {
CHECK(buffer_putstr(&b, "\tlisten-on {\n"));
for (i = 0; i < lwc->lwnext; i++) {
for (i = 0 ; i < lwc->lwnext ; i++) {
CHECK(lwaddr_sockaddr_fromlwresaddr(&sa,
&lwc->lwservers[i],
0));
@@ -341,7 +341,7 @@ ns_lwdmanager_create(isc_mem_t *mctx, cfg_obj_t *lwres,
}
searchobj = NULL;
(void)cfg_map_get(lwres, "search", &searchobj);
cfg_map_get(lwres, "search", &searchobj);
if (searchobj != NULL) {
lwresd->search = NULL;
result = ns_lwsearchlist_create(lwresd->mctx,
@@ -599,7 +599,7 @@ listener_startclients(ns_lwreslistener_t *listener) {
* Create the client managers.
*/
result = ISC_R_SUCCESS;
for (i = 0; i < NTASKS && result == ISC_R_SUCCESS; i++)
for (i = 0 ; i < NTASKS && result == ISC_R_SUCCESS; i++)
result = ns_lwdclientmgr_create(listener, NRECVS,
ns_g_taskmgr);
@@ -615,13 +615,7 @@ listener_startclients(ns_lwreslistener_t *listener) {
LOCK(&listener->lock);
cm = ISC_LIST_HEAD(listener->cmgrs);
while (cm != NULL) {
result = ns_lwdclient_startrecv(cm);
if (result != ISC_R_SUCCESS)
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_LWRESD, ISC_LOG_ERROR,
"could not start lwres "
"client handler: %s",
isc_result_totext(result));
ns_lwdclient_startrecv(cm);
cm = ISC_LIST_NEXT(cm, link);
}
UNLOCK(&listener->lock);
@@ -789,7 +783,7 @@ ns_lwresd_configure(isc_mem_t *mctx, cfg_obj_t *config) {
port = LWRES_UDP_PORT;
listenerslist = NULL;
(void)cfg_map_get(lwres, "listen-on", &listenerslist);
cfg_map_get(lwres, "listen-on", &listenerslist);
if (listenerslist == NULL) {
struct in_addr localhost;
isc_sockaddr_t address;

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: main.c,v 1.126 2001/11/20 01:14:57 gson Exp $ */
/* $Id: main.c,v 1.119 2001/08/08 22:54:20 gson Exp $ */
#include <config.h>
@@ -31,7 +31,6 @@
#include <isc/os.h>
#include <isc/platform.h>
#include <isc/resource.h>
#include <isc/stdio.h>
#include <isc/task.h>
#include <isc/timer.h>
#include <isc/util.h>
@@ -50,7 +49,6 @@
*/
#define NS_MAIN 1
#include <named/builtin.h>
#include <named/control.h>
#include <named/globals.h> /* Explicit, though named/log.h includes it. */
#include <named/interfacemgr.h>
@@ -70,27 +68,6 @@ static char program_name[ISC_DIR_NAMEMAX] = "named";
static char absolute_conffile[ISC_DIR_PATHMAX];
static char saved_command_line[512];
static void
ns_main_earlywarning(const char *format, ...) ISC_FORMAT_PRINTF(1, 2);
static void
ns_main_earlywarning(const char *format, ...) {
va_list args;
va_start(args, format);
if (ns_g_lctx != NULL) {
isc_log_vwrite(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_MAIN, ISC_LOG_WARNING,
format, args);
} else {
fprintf(stderr, "%s: ", program_name);
vfprintf(stderr, format, args);
fprintf(stderr, "\n");
fflush(stderr);
}
va_end(args);
}
void
ns_main_earlyfatal(const char *format, ...) {
va_list args;
@@ -221,8 +198,7 @@ lwresd_usage(void) {
"[-d debuglevel] [-f|-g]\n"
" [-n number_of_cpus] [-p port]"
"[-P listen-port] [-s]\n"
" [-t chrootdir] [-u username] [-i pidfile]\n"
" [-m {usage|trace|record}]\n");
" [-t chrootdir] [-u username] [-i pidfile]\n");
}
static void
@@ -234,8 +210,7 @@ usage(void) {
fprintf(stderr,
"usage: named [-c conffile] [-d debuglevel] "
"[-f|-g] [-n number_of_cpus]\n"
" [-p port] [-s] [-t chrootdir] [-u username]\n"
" [-m {usage|trace|record}]\n");
" [-p port] [-s] [-t chrootdir] [-u username]\n");
}
static void
@@ -296,38 +271,6 @@ parse_int(char *arg, const char *desc) {
return (tmp);
}
static struct flag_def {
const char *name;
unsigned int value;
} mem_debug_flags[] = {
{ "trace", ISC_MEM_DEBUGTRACE },
{ "record", ISC_MEM_DEBUGRECORD },
{ "usage", ISC_MEM_DEBUGUSAGE },
{ NULL, 0 }
};
static void
set_flags(const char *arg, struct flag_def *defs, unsigned int *ret) {
for (;;) {
const struct flag_def *def;
const char *end = strchr(arg, ',');
if (end == NULL)
end = arg + strlen(arg);
for (def = defs; def->name != NULL; def++) {
if (end - arg == (int)strlen(def->name) &&
memcmp(arg, def->name, end - arg) == 0) {
*ret |= def->value;
goto found;
}
}
ns_main_earlyfatal("unrecognized flag '%.*s'", end - arg, arg);
found:
if (*end == '\0')
break;
arg = end + 1;
}
}
static void
parse_command_line(int argc, char *argv[]) {
int ch;
@@ -337,7 +280,7 @@ parse_command_line(int argc, char *argv[]) {
isc_commandline_errprint = ISC_FALSE;
while ((ch = isc_commandline_parse(argc, argv,
"c:C:d:fgi:lm:n:N:p:P:st:u:vx:")) !=
"c:C:d:fgi:ln:N:p:P:st:u:vx:")) !=
-1) {
switch (ch) {
case 'c':
@@ -371,10 +314,6 @@ parse_command_line(int argc, char *argv[]) {
case 'l':
ns_g_lwresdonly = ISC_TRUE;
break;
case 'm':
set_flags(isc_commandline_argument, mem_debug_flags,
&isc_mem_debugging);
break;
case 'N': /* Deprecated. */
case 'n':
ns_g_cpus = parse_int(isc_commandline_argument,
@@ -434,21 +373,16 @@ parse_command_line(int argc, char *argv[]) {
static isc_result_t
create_managers(void) {
isc_result_t result;
#ifdef ISC_PLATFORM_USETHREADS
unsigned int cpus_detected;
#endif
#ifdef ISC_PLATFORM_USETHREADS
cpus_detected = isc_os_ncpus();
if (ns_g_cpus == 0)
ns_g_cpus = cpus_detected;
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL, NS_LOGMODULE_SERVER,
ISC_LOG_INFO, "found %u CPU%s, using %u worker thread%s",
cpus_detected, cpus_detected == 1 ? "" : "s",
ns_g_cpus, ns_g_cpus == 1 ? "" : "s");
ns_g_cpus = isc_os_ncpus();
#else
ns_g_cpus = 1;
#endif
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL, NS_LOGMODULE_SERVER,
ISC_LOG_INFO, "using %u CPU%s",
ns_g_cpus, ns_g_cpus == 1 ? "" : "s");
result = isc_taskmgr_create(ns_g_mctx, ns_g_cpus, 0, &ns_g_taskmgr);
if (result != ISC_R_SUCCESS) {
UNEXPECTED_ERROR(__FILE__, __LINE__,
@@ -571,8 +505,6 @@ setup(void) {
ns_main_earlyfatal("create_managers() failed: %s",
isc_result_totext(result));
ns_builtin_init();
/*
* Add calls to register sdb drivers here.
*/
@@ -587,8 +519,6 @@ cleanup(void) {
ns_server_destroy(&ns_g_server);
ns_builtin_deinit();
/*
* Add calls to unregister sdb drivers here.
*/
@@ -599,25 +529,6 @@ cleanup(void) {
ns_log_shutdown();
}
static char *memstats = NULL;
void
ns_main_setmemstats(const char *filename) {
/*
* Caller has to ensure locking.
*/
if (memstats != NULL) {
free(memstats);
memstats = NULL;
}
if (filename == NULL)
return;
memstats = malloc(strlen(filename) + 1);
if (memstats)
strcpy(memstats, filename);
}
int
main(int argc, char *argv[]) {
isc_result_t result;
@@ -640,29 +551,17 @@ main(int argc, char *argv[]) {
ns_main_earlyfatal("isc_app_start() failed: %s",
isc_result_totext(result));
result = isc_mem_create(0, 0, &ns_g_mctx);
if (result != ISC_R_SUCCESS)
ns_main_earlyfatal("isc_mem_create() failed: %s",
isc_result_totext(result));
dns_result_register();
dst_result_register();
isccc_result_register();
parse_command_line(argc, argv);
/*
* Warn about common configuration error.
*/
if (ns_g_chrootdir != NULL) {
int len = strlen(ns_g_chrootdir);
if (strncmp(ns_g_chrootdir, ns_g_conffile, len) == 0 &&
(ns_g_conffile[len] == '/' || ns_g_conffile[len] == '\\'))
ns_main_earlywarning("config filename (-c %s) contains "
"chroot path (-t %s)",
ns_g_conffile, ns_g_chrootdir);
}
result = isc_mem_create(0, 0, &ns_g_mctx);
if (result != ISC_R_SUCCESS)
ns_main_earlyfatal("isc_mem_create() failed: %s",
isc_result_totext(result));
setup();
/*
@@ -691,19 +590,8 @@ main(int argc, char *argv[]) {
isc_mem_stats(ns_g_mctx, stdout);
isc_mutex_stats(stdout);
}
if (memstats != NULL) {
FILE *fp = NULL;
result = isc_stdio_open(memstats, "w", &fp);
if (result == ISC_R_SUCCESS) {
isc_mem_stats(ns_g_mctx, fp);
isc_mutex_stats(fp);
isc_stdio_close(fp);
}
}
isc_mem_destroy(&ns_g_mctx);
ns_main_setmemstats(NULL);
isc_app_finish();
ns_os_shutdown();

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: notify.c,v 1.26 2001/12/10 23:09:23 marka Exp $ */
/* $Id: notify.c,v 1.24 2001/03/31 01:03:26 bwelling Exp $ */
#include <config.h>
@@ -36,11 +36,11 @@
*/
static void
notify_log(ns_client_t *client, int level, const char *fmt, ...) {
notify_log(int level, const char *fmt, ...) {
va_list ap;
va_start(ap, fmt);
ns_client_logv(client, DNS_LOGCATEGORY_NOTIFY, NS_LOGMODULE_NOTIFY,
isc_log_vwrite(ns_g_lctx, DNS_LOGCATEGORY_NOTIFY, NS_LOGMODULE_NOTIFY,
level, fmt, ap);
va_end(ap);
}
@@ -83,7 +83,7 @@ ns_notify_start(ns_client_t *client) {
*/
result = dns_message_firstname(request, DNS_SECTION_QUESTION);
if (result != ISC_R_SUCCESS) {
notify_log(client, ISC_LOG_INFO, "notify question section empty");
notify_log(ISC_LOG_INFO, "notify question section empty");
goto failure;
}
@@ -94,7 +94,7 @@ ns_notify_start(ns_client_t *client) {
dns_message_currentname(request, DNS_SECTION_QUESTION, &zonename);
zone_rdataset = ISC_LIST_HEAD(zonename->list);
if (ISC_LIST_NEXT(zone_rdataset, link) != NULL) {
notify_log(client, ISC_LOG_INFO,
notify_log(ISC_LOG_INFO,
"notify question section contains multiple RRs");
goto failure;
}
@@ -102,14 +102,14 @@ ns_notify_start(ns_client_t *client) {
/* The zone section must have exactly one name. */
result = dns_message_nextname(request, DNS_SECTION_ZONE);
if (result != ISC_R_NOMORE) {
notify_log(client, ISC_LOG_INFO,
notify_log(ISC_LOG_INFO,
"notify question section contains multiple RRs");
goto failure;
}
/* The one rdataset must be an SOA. */
if (zone_rdataset->type != dns_rdatatype_soa) {
notify_log(client, ISC_LOG_INFO,
notify_log(ISC_LOG_INFO,
"notify question section contains no SOA");
goto failure;
}
@@ -118,13 +118,13 @@ ns_notify_start(ns_client_t *client) {
&zone);
if (result != ISC_R_SUCCESS) {
dns_name_format(zonename, str, sizeof(str));
notify_log(client, ISC_LOG_INFO,
notify_log(ISC_LOG_INFO,
"received notify for zone '%s': not authoritative",
str);
goto failure;
}
switch (dns_zone_gettype(zone)) {
switch(dns_zone_gettype(zone)) {
case dns_zone_master:
case dns_zone_slave:
case dns_zone_stub: /* Allow dialup passive to work. */
@@ -133,7 +133,7 @@ ns_notify_start(ns_client_t *client) {
break;
default:
dns_name_format(zonename, str, sizeof(str));
notify_log(client, ISC_LOG_INFO,
notify_log(ISC_LOG_INFO,
"received notify for zone '%s': not authoritative",
str);
goto failure;

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 1999-2001 Internet Software Consortium.
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: query.c,v 1.216 2002/01/23 08:46:37 bwelling Exp $ */
/* $Id: query.c,v 1.198.2.7 2002/03/28 05:10:09 marka Exp $ */
#include <config.h>
@@ -62,8 +62,8 @@
NS_QUERYATTR_CACHEGLUEOK) != 0)
#define WANTRECURSION(c) (((c)->query.attributes & \
NS_QUERYATTR_WANTRECURSION) != 0)
#define WANTDNSSEC(c) (((c)->attributes & \
NS_CLIENTATTR_WANTDNSSEC) != 0)
#define WANTDNSSEC(c) (((c)->query.attributes & \
NS_QUERYATTR_WANTDNSSEC) != 0)
#define NOAUTHORITY(c) (((c)->query.attributes & \
NS_QUERYATTR_NOAUTHORITY) != 0)
#define NOADDITIONAL(c) (((c)->query.attributes & \
@@ -204,44 +204,11 @@ query_maybeputqname(ns_client_t *client) {
}
}
static inline void
query_freefreeversions(ns_client_t *client, isc_boolean_t everything) {
ns_dbversion_t *dbversion, *dbversion_next;
unsigned int i;
for (dbversion = ISC_LIST_HEAD(client->query.freeversions), i = 0;
dbversion != NULL;
dbversion = dbversion_next, i++)
{
dbversion_next = ISC_LIST_NEXT(dbversion, link);
/*
* If we're not freeing everything, we keep the first three
* dbversions structures around.
*/
if (i > 3 || everything) {
ISC_LIST_UNLINK(client->query.freeversions, dbversion,
link);
isc_mem_put(client->mctx, dbversion,
sizeof(*dbversion));
}
}
}
void
ns_query_cancel(ns_client_t *client) {
LOCK(&client->query.fetchlock);
if (client->query.fetch != NULL) {
dns_resolver_cancelfetch(client->query.fetch);
client->query.fetch = NULL;
}
UNLOCK(&client->query.fetchlock);
}
static inline void
query_reset(ns_client_t *client, isc_boolean_t everything) {
isc_buffer_t *dbuf, *dbuf_next;
ns_dbversion_t *dbversion, *dbversion_next;
unsigned int i;
/*
* Reset the query state of a client to its default state.
@@ -250,7 +217,11 @@ query_reset(ns_client_t *client, isc_boolean_t everything) {
/*
* Cancel the fetch if it's running.
*/
ns_query_cancel(client);
if (client->query.fetch != NULL) {
dns_resolver_cancelfetch(client->query.fetch);
client->query.fetch = NULL;
}
/*
* Cleanup any active versions.
@@ -272,7 +243,24 @@ query_reset(ns_client_t *client, isc_boolean_t everything) {
if (client->query.authzone != NULL)
dns_zone_detach(&client->query.authzone);
query_freefreeversions(client, everything);
/*
* Clean up free versions.
*/
for (dbversion = ISC_LIST_HEAD(client->query.freeversions), i = 0;
dbversion != NULL;
dbversion = dbversion_next, i++) {
dbversion_next = ISC_LIST_NEXT(dbversion, link);
/*
* If we're not freeing everything, we keep the first three
* dbversions structures around.
*/
if (i > 3 || everything) {
ISC_LIST_UNLINK(client->query.freeversions, dbversion,
link);
isc_mem_put(client->mctx, dbversion,
sizeof *dbversion);
}
}
for (dbuf = ISC_LIST_HEAD(client->query.namebufs);
dbuf != NULL;
@@ -473,7 +461,7 @@ query_newdbversion(ns_client_t *client, unsigned int n) {
ns_dbversion_t *dbversion;
for (i = 0; i < n; i++) {
dbversion = isc_mem_get(client->mctx, sizeof(*dbversion));
dbversion = isc_mem_get(client->mctx, sizeof *dbversion);
if (dbversion != NULL) {
dbversion->db = NULL;
dbversion->version = NULL;
@@ -521,9 +509,6 @@ ns_query_init(ns_client_t *client) {
client->query.restarts = 0;
client->query.timerset = ISC_FALSE;
client->query.qname = NULL;
result = isc_mutex_init(&client->query.fetchlock);
if (result != ISC_R_SUCCESS)
return (result);
client->query.fetch = NULL;
client->query.authdb = NULL;
client->query.authzone = NULL;
@@ -531,17 +516,11 @@ ns_query_init(ns_client_t *client) {
client->query.isreferral = ISC_FALSE;
query_reset(client, ISC_FALSE);
result = query_newdbversion(client, 3);
if (result != ISC_R_SUCCESS) {
DESTROYLOCK(&client->query.fetchlock);
if (result != ISC_R_SUCCESS)
return (result);
}
dns_a6_init(&client->query.a6ctx, query_simplefind, query_adda6rrset,
NULL, NULL, client);
result = query_newnamebuf(client);
if (result != ISC_R_SUCCESS)
query_freefreeversions(client, ISC_TRUE);
return (result);
return (query_newnamebuf(client));
}
static inline ns_dbversion_t *
@@ -678,7 +657,7 @@ query_getzonedb(ns_client_t *client, dns_name_t *name, unsigned int options,
result = ns_client_checkaclsilent(client, queryacl, ISC_TRUE);
if (log) {
char msg[DNS_NAME_FORMATSIZE + DNS_RDATACLASS_FORMATSIZE
+ sizeof("query '/'")];
+ sizeof "query '/'"];
if (result == ISC_R_SUCCESS) {
if (isc_log_wouldlog(ns_g_lctx,
ISC_LOG_DEBUG(3)))
@@ -1420,7 +1399,7 @@ query_addadditional(void *arg, dns_name_t *name, dns_rdatatype_t qtype) {
*/
if (a6rdataset != NULL) {
dns_a6_reset(&client->query.a6ctx);
(void)dns_a6_foreach(&client->query.a6ctx, a6rdataset, client->now);
dns_a6_foreach(&client->query.a6ctx, a6rdataset, client->now);
}
cleanup:
@@ -1705,9 +1684,7 @@ query_addsoa(ns_client_t *client, dns_db_t *db, isc_boolean_t zero_ttl) {
result = dns_rdataset_first(rdataset);
RUNTIME_CHECK(result == ISC_R_SUCCESS);
dns_rdataset_current(rdataset, &rdata);
result = dns_rdata_tostruct(&rdata, &soa, NULL);
if (result != ISC_R_SUCCESS)
goto cleanup;
dns_rdata_tostruct(&rdata, &soa, NULL);
if (zero_ttl) {
rdataset->ttl = 0;
@@ -1838,8 +1815,7 @@ query_addcnamelike(ns_client_t *client, dns_name_t *qname, dns_name_t *tname,
isc_region_t r;
/*
* We assume the name data referred to by qname and tname won't
* go away.
* We assume the name data referred to by tname won't go away.
*/
REQUIRE(anamep != NULL);
@@ -1857,7 +1833,11 @@ query_addcnamelike(ns_client_t *client, dns_name_t *qname, dns_name_t *tname,
if (result != ISC_R_SUCCESS)
return (result);
dns_rdataset_init(rdataset);
dns_name_clone(qname, *anamep);
result = dns_name_dup(qname, client->mctx, *anamep);
if (result != ISC_R_SUCCESS) {
dns_message_puttemprdataset(client->message, &rdataset);
return (result);
}
rdatalist->type = type;
rdatalist->covers = 0;
@@ -1872,8 +1852,7 @@ query_addcnamelike(ns_client_t *client, dns_name_t *qname, dns_name_t *tname,
ISC_LIST_INIT(rdatalist->rdata);
ISC_LIST_APPEND(rdatalist->rdata, rdata, link);
RUNTIME_CHECK(dns_rdatalist_tordataset(rdatalist, rdataset)
== ISC_R_SUCCESS);
dns_rdatalist_tordataset(rdatalist, rdataset);
query_addrrset(client, anamep, &rdataset, NULL, NULL,
DNS_SECTION_ANSWER);
@@ -2055,8 +2034,7 @@ query_resume(isc_task_t *task, isc_event_t *event) {
REQUIRE(task == client->task);
REQUIRE(RECURSING(client));
LOCK(&client->query.fetchlock);
if (client->query.fetch != NULL) {
if (devent->fetch != NULL) {
/*
* This is the fetch we've been waiting for.
*/
@@ -2074,7 +2052,6 @@ query_resume(isc_task_t *task, isc_event_t *event) {
*/
fetch_cancelled = ISC_TRUE;
}
UNLOCK(&client->query.fetchlock);
INSIST(client->query.fetch == NULL);
client->query.attributes &= ~NS_QUERYATTR_RECURSING;
@@ -2094,10 +2071,7 @@ query_resume(isc_task_t *task, isc_event_t *event) {
if (devent->sigrdataset != NULL)
query_putrdataset(client, &devent->sigrdataset);
isc_event_free(&event);
if (fetch_cancelled)
query_error(client, DNS_R_SERVFAIL);
else
query_next(client, ISC_R_CANCELED);
query_next(client, ISC_R_CANCELED);
/*
* This may destroy the client.
*/
@@ -2127,20 +2101,8 @@ query_recurse(ns_client_t *client, dns_rdatatype_t qtype, dns_name_t *qdomain,
* connection was accepted (if allowed by the TCP quota).
*/
if (! client->mortal) {
isc_boolean_t killoldest = ISC_FALSE;
result = isc_quota_attach(&ns_g_server->recursionquota,
&client->recursionquota);
if (result == ISC_R_SOFTQUOTA) {
ns_client_log(client, NS_LOGCATEGORY_CLIENT,
NS_LOGMODULE_QUERY, ISC_LOG_WARNING,
"recursive-clients limit exceeded, "
"aborting oldest query");
killoldest = ISC_TRUE;
result = ISC_R_SUCCESS;
}
if (dns_resolver_nrunning(client->view->resolver) >
(unsigned int)ns_g_server->recursionquota.max)
result = ISC_R_QUOTA;
if (result == ISC_R_SUCCESS &&
(client->attributes & NS_CLIENTATTR_TCP) == 0)
result = ns_client_replace(client);
@@ -2151,7 +2113,6 @@ query_recurse(ns_client_t *client, dns_rdatatype_t qtype, dns_name_t *qdomain,
isc_result_totext(result));
return (result);
}
ns_client_recursing(client, killoldest);
}
/*
@@ -3075,8 +3036,8 @@ query_find(ns_client_t *client, dns_fetchevent_t *event, dns_rdatatype_t qtype)
* since the synthesized CNAME is NOT in the zone.
*/
dns_name_init(tname, NULL);
(void)query_addcnamelike(client, client->query.qname, fname,
0, &tname, dns_rdatatype_cname);
query_addcnamelike(client, client->query.qname, fname,
0, &tname, dns_rdatatype_cname);
if (tname != NULL)
dns_message_puttempname(client->message, &tname);
/*
@@ -3211,13 +3172,14 @@ query_find(ns_client_t *client, dns_fetchevent_t *event, dns_rdatatype_t qtype)
* Add NS records to the authority section (if we haven't already
* added them to the answer section).
*/
if (!want_restart && !NOAUTHORITY(client)) {
if (!want_restart && !NOAUTHORITY(client)
) {
if (is_zone) {
if (!((qtype == dns_rdatatype_ns ||
qtype == dns_rdatatype_any) &&
dns_name_equal(client->query.qname,
dns_db_origin(db))))
(void)query_addns(client, db);
query_addns(client, db);
} else if (qtype != dns_rdatatype_ns) {
if (fname != NULL)
query_releasename(client, &fname);
@@ -3317,8 +3279,7 @@ log_query(ns_client_t *client) {
dns_rdatatype_format(rdataset->type, typename, sizeof(typename));
ns_client_log(client, NS_LOGCATEGORY_QUERIES, NS_LOGMODULE_QUERY,
level, "query: %s %s %s %s", namebuf, classname,
typename, WANTRECURSION(client) ? "+" : "-");
level, "query: %s %s %s", namebuf, classname, typename);
}
void
@@ -3341,7 +3302,7 @@ ns_query_start(ns_client_t *client) {
if ((client->extflags & DNS_MESSAGEEXTFLAG_DO) != 0 ||
(message->flags & DNS_MESSAGEFLAG_AD) != 0)
client->attributes |= NS_CLIENTATTR_WANTDNSSEC;
client->query.attributes |= NS_QUERYATTR_WANTDNSSEC;
if (client->view->minimalresponses)
client->query.attributes |= (NS_QUERYATTR_NOAUTHORITY |
@@ -3555,7 +3516,7 @@ synth_fwd_startfind(ns_client_t *client) {
ptarget = query_newname(client, dbuf, &b);
if (ptarget == NULL)
goto fail;
RUNTIME_CHECK(dns_name_copy(target, ptarget, NULL) == ISC_R_SUCCESS);
dns_name_copy(target, ptarget, NULL);
dns_adb_destroyfind(&find);
@@ -3696,8 +3657,7 @@ synth_fwd_respond(ns_client_t *client, dns_adbfind_t *find) {
ISC_LIST_APPEND(rdatalist->rdata, rdata, link);
}
RUNTIME_CHECK(dns_rdatalist_tordataset(rdatalist, rdataset)
== ISC_R_SUCCESS);
dns_rdatalist_tordataset(rdatalist, rdataset);
query_addrrset(client, &tname, &rdataset, NULL, NULL,
DNS_SECTION_ANSWER);

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 1999-2001 Internet Software Consortium.
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: server.c,v 1.370 2002/01/30 00:55:15 bwelling Exp $ */
/* $Id: server.c,v 1.339.2.5 2002/03/29 01:35:24 marka Exp $ */
#include <config.h>
@@ -35,11 +35,9 @@
#include <isc/timer.h>
#include <isc/util.h>
#include <isccfg/namedconf.h>
#include <isccfg/cfg.h>
#include <isccfg/check.h>
#include <bind9/check.h>
#include <dns/adb.h>
#include <dns/cache.h>
#include <dns/db.h>
#include <dns/dispatch.h>
@@ -68,7 +66,6 @@
#include <named/log.h>
#include <named/logconf.h>
#include <named/lwresd.h>
#include <named/main.h>
#include <named/os.h>
#include <named/server.h>
#include <named/tkeyconf.h>
@@ -148,7 +145,7 @@ configure_view_acl(cfg_obj_t *vconfig, cfg_obj_t *config,
maps[i++] = cfg_tuple_get(vconfig, "options");
if (config != NULL) {
cfg_obj_t *options = NULL;
(void)cfg_map_get(config, "options", &options);
cfg_map_get(config, "options", &options);
if (options != NULL)
maps[i++] = options;
}
@@ -424,38 +421,36 @@ configure_peer(cfg_obj_t *cpeer, isc_mem_t *mctx, dns_peer_t **peerp) {
obj = NULL;
(void)cfg_map_get(cpeer, "bogus", &obj);
if (obj != NULL)
CHECK(dns_peer_setbogus(peer, cfg_obj_asboolean(obj)));
dns_peer_setbogus(peer, cfg_obj_asboolean(obj));
obj = NULL;
(void)cfg_map_get(cpeer, "provide-ixfr", &obj);
if (obj != NULL)
CHECK(dns_peer_setprovideixfr(peer, cfg_obj_asboolean(obj)));
dns_peer_setprovideixfr(peer, cfg_obj_asboolean(obj));
obj = NULL;
(void)cfg_map_get(cpeer, "request-ixfr", &obj);
if (obj != NULL)
CHECK(dns_peer_setrequestixfr(peer, cfg_obj_asboolean(obj)));
dns_peer_setrequestixfr(peer, cfg_obj_asboolean(obj));
obj = NULL;
(void)cfg_map_get(cpeer, "edns", &obj);
if (obj != NULL)
CHECK(dns_peer_setsupportedns(peer, cfg_obj_asboolean(obj)));
dns_peer_setsupportedns(peer, cfg_obj_asboolean(obj));
obj = NULL;
(void)cfg_map_get(cpeer, "transfers", &obj);
if (obj != NULL)
CHECK(dns_peer_settransfers(peer, cfg_obj_asuint32(obj)));
dns_peer_settransfers(peer, cfg_obj_asuint32(obj));
obj = NULL;
(void)cfg_map_get(cpeer, "transfer-format", &obj);
if (obj != NULL) {
str = cfg_obj_asstring(obj);
if (strcasecmp(str, "many-answers") == 0)
CHECK(dns_peer_settransferformat(peer,
dns_many_answers));
dns_peer_settransferformat(peer, dns_many_answers);
else if (strcasecmp(str, "one-answer") == 0)
CHECK(dns_peer_settransferformat(peer,
dns_one_answer));
dns_peer_settransferformat(peer, dns_one_answer);
else
INSIST(0);
}
@@ -484,8 +479,7 @@ configure_peer(cfg_obj_t *cpeer, isc_mem_t *mctx, dns_peer_t **peerp) {
*/
static isc_result_t
configure_view(dns_view_t *view, cfg_obj_t *config, cfg_obj_t *vconfig,
isc_mem_t *mctx, ns_aclconfctx_t *actx,
isc_boolean_t need_hints)
isc_mem_t *mctx, ns_aclconfctx_t *actx)
{
cfg_obj_t *maps[4];
cfg_obj_t *cfgmaps[3];
@@ -499,7 +493,6 @@ configure_view(dns_view_t *view, cfg_obj_t *config, cfg_obj_t *vconfig,
in_port_t port;
dns_cache_t *cache = NULL;
isc_result_t result;
isc_uint32_t max_adb_size;
isc_uint32_t max_cache_size;
isc_uint32_t lame_ttl;
dns_tsig_keyring_t *ring;
@@ -516,7 +509,7 @@ configure_view(dns_view_t *view, cfg_obj_t *config, cfg_obj_t *vconfig,
cmctx = NULL;
if (config != NULL)
(void)cfg_map_get(config, "options", &options);
cfg_map_get(config, "options", &options);
i = 0;
if (vconfig != NULL) {
@@ -535,6 +528,7 @@ configure_view(dns_view_t *view, cfg_obj_t *config, cfg_obj_t *vconfig,
cfgmaps[i++] = config;
cfgmaps[i] = NULL;
/*
* Set the view's port number for outgoing queries.
*/
@@ -598,7 +592,7 @@ configure_view(dns_view_t *view, cfg_obj_t *config, cfg_obj_t *vconfig,
obj = NULL;
result = ns_config_get(maps, "cache-file", &obj);
if (result == ISC_R_SUCCESS) {
CHECK(dns_cache_setfilename(cache, cfg_obj_asstring(obj)));
dns_cache_setfilename(cache, cfg_obj_asstring(obj));
if (!reused_cache)
CHECK(dns_cache_load(cache));
}
@@ -648,17 +642,6 @@ configure_view(dns_view_t *view, cfg_obj_t *config, cfg_obj_t *vconfig,
if (dispatch6 != NULL)
dns_dispatch_detach(&dispatch6);
/*
* Set the ADB cache size to 1/8th of the max-cache-size.
*/
max_adb_size = 0;
if (max_cache_size != 0) {
max_adb_size = max_cache_size / 8;
if (max_adb_size == 0)
max_adb_size = 1; /* Force minimum. */
}
dns_adb_setadbsize(view->adb, max_adb_size);
/*
* Set resolver's lame-ttl.
*/
@@ -692,21 +675,20 @@ configure_view(dns_view_t *view, cfg_obj_t *config, cfg_obj_t *vconfig,
* If we still have no hints, this is a non-IN view with no
* "hints zone" configured. Issue a warning, except if this
* is a root server. Root servers never need to consult
* their hints, so it's no point requiring users to configure
* their hints, so it's no point requireing users to configure
* them.
*/
if (view->hints == NULL) {
dns_zone_t *rootzone = NULL;
(void)dns_view_findzone(view, dns_rootname, &rootzone);
dns_view_findzone(view, dns_rootname, &rootzone);
if (rootzone != NULL) {
dns_zone_detach(&rootzone);
need_hints = ISC_FALSE;
}
if (need_hints)
} else {
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_SERVER, ISC_LOG_WARNING,
"no root hints for view '%s'",
view->name);
}
}
/*
@@ -872,6 +854,209 @@ configure_view(dns_view_t *view, cfg_obj_t *config, cfg_obj_t *vconfig,
return (result);
}
/*
* Create the special view that handles queries under "bind. CH".
*/
static isc_result_t
create_bind_view(dns_view_t **viewp) {
isc_result_t result;
dns_view_t *view = NULL;
REQUIRE(viewp != NULL && *viewp == NULL);
CHECK(dns_view_create(ns_g_mctx, dns_rdataclass_ch, "_bind", &view));
/* Transfer ownership. */
*viewp = view;
view = NULL;
result = ISC_R_SUCCESS;
cleanup:
if (view != NULL)
dns_view_detach(&view);
return (result);
}
/*
* Create the zone that handles queries for "version.bind. CH". The
* version string is returned either from the "version" configuration
* option or the global defaults.
*/
static isc_result_t
create_version_zone(cfg_obj_t **maps, dns_zonemgr_t *zmgr, dns_view_t *view) {
isc_result_t result;
dns_db_t *db = NULL;
dns_zone_t *zone = NULL;
dns_dbversion_t *dbver = NULL;
dns_difftuple_t *tuple = NULL;
dns_diff_t diff;
char *versiontext;
unsigned char buf[256];
isc_region_t r;
size_t len;
dns_rdata_t rdata = DNS_RDATA_INIT;
static unsigned char origindata[] = "\007version\004bind";
dns_name_t origin;
cfg_obj_t *obj = NULL;
dns_diff_init(ns_g_mctx, &diff);
dns_name_init(&origin, NULL);
r.base = origindata;
r.length = sizeof(origindata);
dns_name_fromregion(&origin, &r);
result = ns_config_get(maps, "version", &obj);
INSIST(result == ISC_R_SUCCESS);
versiontext = cfg_obj_asstring(obj);
len = strlen(versiontext);
if (len > 255)
len = 255; /* Silently truncate. */
buf[0] = len;
memcpy(buf + 1, versiontext, len);
r.base = buf;
r.length = 1 + len;
dns_rdata_fromregion(&rdata, dns_rdataclass_ch, dns_rdatatype_txt, &r);
CHECK(dns_zone_create(&zone, ns_g_mctx));
CHECK(dns_zone_setorigin(zone, &origin));
dns_zone_settype(zone, dns_zone_master);
dns_zone_setclass(zone, dns_rdataclass_ch);
dns_zone_setview(zone, view);
CHECK(dns_zonemgr_managezone(zmgr, zone));
CHECK(dns_db_create(ns_g_mctx, "rbt", &origin, dns_dbtype_zone,
dns_rdataclass_ch, 0, NULL, &db));
CHECK(dns_db_newversion(db, &dbver));
CHECK(dns_difftuple_create(ns_g_mctx, DNS_DIFFOP_ADD, &origin,
0, &rdata, &tuple));
dns_diff_append(&diff, &tuple);
CHECK(dns_diff_apply(&diff, db, dbver));
dns_db_closeversion(db, &dbver, ISC_TRUE);
CHECK(dns_zone_replacedb(zone, db, ISC_FALSE));
CHECK(dns_view_addzone(view, zone));
result = ISC_R_SUCCESS;
cleanup:
if (zone != NULL)
dns_zone_detach(&zone);
if (dbver != NULL)
dns_db_closeversion(db, &dbver, ISC_FALSE);
if (db != NULL)
dns_db_detach(&db);
dns_diff_clear(&diff);
return (result);
}
/*
* Create the special zone that handles queries for "authors.bind. CH".
* The strings returned list the BIND 9 authors.
*/
static isc_result_t
create_authors_zone(cfg_obj_t *options, dns_zonemgr_t *zmgr, dns_view_t *view)
{
isc_result_t result;
dns_db_t *db = NULL;
dns_zone_t *zone = NULL;
dns_dbversion_t *dbver = NULL;
dns_difftuple_t *tuple;
dns_diff_t diff;
isc_constregion_t r;
isc_constregion_t cr;
dns_rdata_t rdata = DNS_RDATA_INIT;
static const char origindata[] = "\007authors\004bind";
dns_name_t origin;
int i;
static const char *authors[] = {
"\014Mark Andrews",
"\015James Brister",
"\014Ben Cottrell",
"\015Michael Graff",
"\022Andreas Gustafsson",
"\012Bob Halley",
"\016David Lawrence",
"\013Danny Mayer",
"\013Damien Neil",
"\013Matt Nelson",
"\016Michael Sawyer",
"\020Brian Wellington",
NULL,
};
cfg_obj_t *obj = NULL;
/*
* If a version string is specified, disable the authors.bind zone.
*/
if (options != NULL &&
cfg_map_get(options, "version", &obj) == ISC_R_SUCCESS)
return (ISC_R_SUCCESS);
dns_diff_init(ns_g_mctx, &diff);
dns_name_init(&origin, NULL);
r.base = origindata;
r.length = sizeof(origindata);
dns_name_fromregion(&origin, (isc_region_t *)&r);
CHECK(dns_zone_create(&zone, ns_g_mctx));
CHECK(dns_zone_setorigin(zone, &origin));
dns_zone_settype(zone, dns_zone_master);
dns_zone_setclass(zone, dns_rdataclass_ch);
dns_zone_setview(zone, view);
CHECK(dns_zonemgr_managezone(zmgr, zone));
CHECK(dns_db_create(ns_g_mctx, "rbt", &origin, dns_dbtype_zone,
dns_rdataclass_ch, 0, NULL, &db));
CHECK(dns_db_newversion(db, &dbver));
for (i = 0; authors[i] != NULL; i++) {
cr.base = authors[i];
cr.length = strlen(authors[i]);
INSIST(cr.length == ((const unsigned char *)cr.base)[0] + 1U);
dns_rdata_fromregion(&rdata, dns_rdataclass_ch,
dns_rdatatype_txt, (isc_region_t *)&cr);
tuple = NULL;
CHECK(dns_difftuple_create(ns_g_mctx, DNS_DIFFOP_ADD, &origin,
0, &rdata, &tuple));
dns_diff_append(&diff, &tuple);
dns_rdata_reset(&rdata);
}
CHECK(dns_diff_apply(&diff, db, dbver));
dns_db_closeversion(db, &dbver, ISC_TRUE);
CHECK(dns_zone_replacedb(zone, db, ISC_FALSE));
CHECK(dns_view_addzone(view, zone));
result = ISC_R_SUCCESS;
cleanup:
if (zone != NULL)
dns_zone_detach(&zone);
if (dbver != NULL)
dns_db_closeversion(db, &dbver, ISC_FALSE);
if (db != NULL)
dns_db_detach(&db);
dns_diff_clear(&diff);
return (result);
}
static isc_result_t
configure_hints(dns_view_t *view, const char *filename) {
isc_result_t result;
@@ -1153,8 +1338,6 @@ configure_zone(cfg_obj_t *config, cfg_obj_t *zconfig, cfg_obj_t *vconfig,
/*
* We already have this zone!
*/
cfg_obj_log(zconfig, ns_g_lctx, ISC_LOG_ERROR,
"zone '%s' already exists", zname);
dns_zone_detach(&dupzone);
result = ISC_R_EXISTS;
goto cleanup;
@@ -1209,7 +1392,7 @@ configure_zone(cfg_obj_t *config, cfg_obj_t *zconfig, cfg_obj_t *vconfig,
if (cfg_map_get(zoptions, "forwarders", &forwarders) == ISC_R_SUCCESS)
{
forwardtype = NULL;
(void)cfg_map_get(zoptions, "forward", &forwardtype);
cfg_map_get(zoptions, "forward", &forwardtype);
CHECK(configure_forward(config, view, origin, forwarders,
forwardtype));
}
@@ -1332,41 +1515,34 @@ heartbeat_timer_tick(isc_task_t *task, isc_event_t *event) {
}
}
/*
* Replace the current value of '*field', a dynamically allocated
* string or NULL, with a dynamically allocated copy of the
* null-terminated string pointed to by 'value', or NULL.
*/
static isc_result_t
setstring(ns_server_t *server, char **field, const char *value) {
char *copy;
setstatsfile(ns_server_t *server, const char *name) {
char *p;
if (value != NULL) {
copy = isc_mem_strdup(server->mctx, value);
if (copy == NULL)
return (ISC_R_NOMEMORY);
} else {
copy = NULL;
}
REQUIRE(name != NULL);
if (*field != NULL)
isc_mem_free(server->mctx, *field);
*field = copy;
p = isc_mem_strdup(server->mctx, name);
if (p == NULL)
return (ISC_R_NOMEMORY);
if (server->statsfile != NULL)
isc_mem_free(server->mctx, server->statsfile);
server->statsfile = p;
return (ISC_R_SUCCESS);
}
}
/*
* Replace the current value of '*field', a dynamically allocated
* string or NULL, with another dynamically allocated string
* or NULL if whether 'obj' is a string or void value, respectively.
*/
static isc_result_t
setoptstring(ns_server_t *server, char **field, cfg_obj_t *obj) {
if (cfg_obj_isvoid(obj))
return (setstring(server, field, NULL));
else
return (setstring(server, field, cfg_obj_asstring(obj)));
setdumpfile(ns_server_t *server, const char *name) {
char *p;
REQUIRE(name != NULL);
p = isc_mem_strdup(server->mctx, name);
if (p == NULL)
return (ISC_R_NOMEMORY);
if (server->dumpfile != NULL)
isc_mem_free(server->mctx, server->dumpfile);
server->dumpfile = p;
return (ISC_R_SUCCESS);
}
static void
@@ -1423,7 +1599,6 @@ load_configuration(const char *filename, ns_server_t *server,
cfg_obj_t *views;
cfg_obj_t *obj;
cfg_obj_t *maps[3];
cfg_obj_t *builtin_views;
cfg_listelt_t *element;
dns_view_t *view = NULL;
dns_view_t *view_next;
@@ -1497,7 +1672,7 @@ load_configuration(const char *filename, ns_server_t *server,
/*
* Check the validity of the configuration.
*/
CHECK(bind9_check_namedconf(config, ns_g_lctx, ns_g_mctx));
CHECK(cfg_check_namedconf(config, ns_g_lctx, ns_g_mctx));
/*
* Fill in the maps array, used for resolving defaults.
@@ -1641,15 +1816,14 @@ load_configuration(const char *filename, ns_server_t *server,
INSIST(result == ISC_R_SUCCESS);
interface_interval = cfg_obj_asuint32(obj) * 60;
if (interface_interval == 0) {
CHECK(isc_timer_reset(server->interface_timer,
isc_timertype_inactive,
NULL, NULL, ISC_TRUE));
isc_timer_reset(server->interface_timer,
isc_timertype_inactive,
NULL, NULL, ISC_TRUE);
} else if (server->interface_interval != interface_interval) {
isc_interval_t interval;
isc_interval_set(&interval, interface_interval, 0);
CHECK(isc_timer_reset(server->interface_timer,
isc_timertype_ticker,
NULL, &interval, ISC_FALSE));
isc_timer_reset(server->interface_timer, isc_timertype_ticker,
NULL, &interval, ISC_FALSE);
}
server->interface_interval = interface_interval;
@@ -1661,15 +1835,14 @@ load_configuration(const char *filename, ns_server_t *server,
INSIST(result == ISC_R_SUCCESS);
heartbeat_interval = cfg_obj_asuint32(obj) * 60;
if (heartbeat_interval == 0) {
CHECK(isc_timer_reset(server->heartbeat_timer,
isc_timertype_inactive,
NULL, NULL, ISC_TRUE));
isc_timer_reset(server->heartbeat_timer,
isc_timertype_inactive,
NULL, NULL, ISC_TRUE);
} else if (server->heartbeat_interval != heartbeat_interval) {
isc_interval_t interval;
isc_interval_set(&interval, heartbeat_interval, 0);
CHECK(isc_timer_reset(server->heartbeat_timer,
isc_timertype_ticker,
NULL, &interval, ISC_FALSE));
isc_timer_reset(server->heartbeat_timer, isc_timertype_ticker,
NULL, &interval, ISC_FALSE);
}
server->heartbeat_interval = heartbeat_interval;
@@ -1684,13 +1857,14 @@ load_configuration(const char *filename, ns_server_t *server,
element != NULL;
element = cfg_list_next(element))
{
cfg_obj_t *vconfig = cfg_listelt_value(element);
view = NULL;
cfg_obj_t *vconfig;
view = NULL;
vconfig = cfg_listelt_value(element);
CHECK(create_view(vconfig, &viewlist, &view));
INSIST(view != NULL);
CHECK(configure_view(view, config, vconfig,
ns_g_mctx, &aclconfctx, ISC_TRUE));
ns_g_mctx, &aclconfctx));
dns_view_freeze(view);
dns_view_detach(&view);
}
@@ -1708,30 +1882,20 @@ load_configuration(const char *filename, ns_server_t *server,
*/
CHECK(create_view(NULL, &viewlist, &view));
CHECK(configure_view(view, config, NULL, ns_g_mctx,
&aclconfctx, ISC_TRUE));
&aclconfctx));
dns_view_freeze(view);
dns_view_detach(&view);
}
/*
* Create (or recreate) the built-in views. Currently
* there is only one, the _bind view.
* Create (or recreate) the internal _bind view.
*/
builtin_views = NULL;
RUNTIME_CHECK(cfg_map_get(ns_g_config, "view",
&builtin_views) == ISC_R_SUCCESS);
for (element = cfg_list_first(builtin_views);
element != NULL;
element = cfg_list_next(element))
{
cfg_obj_t *vconfig = cfg_listelt_value(element);
CHECK(create_view(vconfig, &viewlist, &view));
CHECK(configure_view(view, ns_g_defaults, vconfig, ns_g_mctx,
&aclconfctx, ISC_FALSE));
dns_view_freeze(view);
dns_view_detach(&view);
view = NULL;
}
CHECK(create_bind_view(&view));
ISC_LIST_APPEND(viewlist, view, link);
CHECK(create_version_zone(maps, server->zonemgr, view));
CHECK(create_authors_zone(options, server->zonemgr, view));
dns_view_freeze(view);
view = NULL;
/*
* Swap our new view list with the production one.
@@ -1875,53 +2039,21 @@ load_configuration(const char *filename, ns_server_t *server,
obj = NULL;
if (ns_config_get(maps, "pid-file", &obj) == ISC_R_SUCCESS)
if (cfg_obj_isvoid(obj))
ns_os_writepidfile(NULL);
else
ns_os_writepidfile(cfg_obj_asstring(obj));
ns_os_writepidfile(cfg_obj_asstring(obj));
else if (ns_g_lwresdonly)
ns_os_writepidfile(lwresd_g_defaultpidfile);
else
ns_os_writepidfile(ns_g_defaultpidfile);
obj = NULL;
if (options != NULL &&
cfg_map_get(options, "memstatistics-file", &obj) == ISC_R_SUCCESS)
ns_main_setmemstats(cfg_obj_asstring(obj));
else
ns_main_setmemstats(NULL);
obj = NULL;
result = ns_config_get(maps, "statistics-file", &obj);
INSIST(result == ISC_R_SUCCESS);
CHECKM(setstring(server, &server->statsfile, cfg_obj_asstring(obj)),
"strdup");
CHECKM(setstatsfile(server, cfg_obj_asstring(obj)), "strdup");
obj = NULL;
result = ns_config_get(maps, "dump-file", &obj);
INSIST(result == ISC_R_SUCCESS);
CHECKM(setstring(server, &server->dumpfile, cfg_obj_asstring(obj)),
"strdup");
obj = NULL;
result = ns_config_get(maps, "version", &obj);
if (result == ISC_R_SUCCESS) {
CHECKM(setoptstring(server, &server->version, obj), "strdup");
server->version_set = ISC_TRUE;
} else {
server->version_set = ISC_FALSE;
}
obj = NULL;
result = ns_config_get(maps, "hostname", &obj);
if (result == ISC_R_SUCCESS) {
CHECKM(setoptstring(server, &server->hostname, obj), "strdup");
server->hostname_set = ISC_TRUE;
} else {
server->hostname_set = ISC_FALSE;
}
result = ISC_R_SUCCESS;
CHECKM(setdumpfile(server, cfg_obj_asstring(obj)), "strdup");
cleanup:
ns_aclconfctx_destroy(&aclconfctx);
@@ -2143,7 +2275,6 @@ ns_server_create(isc_mem_t *mctx, ns_server_t **serverp) {
RUNTIME_CHECK(result == ISC_R_SUCCESS);
result = isc_quota_init(&server->recursionquota, 100);
RUNTIME_CHECK(result == ISC_R_SUCCESS);
isc_quota_soft(&server->recursionquota, ISC_FALSE);
result = dns_aclenv_init(mctx, &server->aclenv);
RUNTIME_CHECK(result == ISC_R_SUCCESS);
@@ -2205,19 +2336,13 @@ ns_server_create(isc_mem_t *mctx, ns_server_t **serverp) {
CHECKFATAL(server->statsfile == NULL ? ISC_R_NOMEMORY : ISC_R_SUCCESS,
"isc_mem_strdup");
server->querystats = NULL;
CHECKFATAL(dns_stats_alloccounters(ns_g_mctx, &server->querystats),
"dns_stats_alloccounters");
server->dumpfile = isc_mem_strdup(server->mctx, "named_dump.db");
CHECKFATAL(server->dumpfile == NULL ? ISC_R_NOMEMORY : ISC_R_SUCCESS,
"isc_mem_strdup");
server->hostname_set = ISC_FALSE;
server->hostname = NULL;
server->version_set = ISC_FALSE;
server->version = NULL;
CHECKFATAL(dns_stats_alloccounters(ns_g_mctx, &server->querystats),
"dns_stats_alloccounters");
server->flushonshutdown = ISC_FALSE;
server->log_queries = ISC_FALSE;
@@ -2237,14 +2362,9 @@ ns_server_destroy(ns_server_t **serverp) {
ns_controls_destroy(&server->controls);
dns_stats_freecounters(server->mctx, &server->querystats);
isc_mem_free(server->mctx, server->statsfile);
isc_mem_free(server->mctx, server->dumpfile);
if (server->version != NULL)
isc_mem_free(server->mctx, server->version);
if (server->hostname != NULL)
isc_mem_free(server->mctx, server->hostname);
isc_mem_free(server->mctx, server->dumpfile);
dns_zonemgr_detach(&server->zonemgr);
@@ -2390,10 +2510,8 @@ zone_from_args(ns_server_t *server, char *args, dns_zone_t **zonep) {
/* Look for the zone name. */
zonetxt = next_token(&input, " \t");
if (zonetxt == NULL) {
*zonep = NULL;
if (zonetxt == NULL)
return (ISC_R_SUCCESS);
}
/* Look for the optional class name. */
classtxt = next_token(&input, " \t");
@@ -2430,37 +2548,14 @@ zone_from_args(ns_server_t *server, char *args, dns_zone_t **zonep) {
result = dns_zt_find(view->zonetable, dns_fixedname_name(&name),
0, NULL, zonep);
if (result != ISC_R_SUCCESS)
goto fail2;
fail2:
/* Partial match? */
if (result != ISC_R_SUCCESS && *zonep != NULL)
dns_zone_detach(zonep);
dns_view_detach(&view);
fail1:
return (result);
}
/*
* Act on a "retransfer" command from the command channel.
*/
isc_result_t
ns_server_retransfercommand(ns_server_t *server, char *args) {
isc_result_t result;
dns_zone_t *zone = NULL;
dns_zonetype_t type;
result = zone_from_args(server, args, &zone);
if (result != ISC_R_SUCCESS)
return (result);
if (zone == NULL)
return (ISC_R_UNEXPECTEDEND);
type = dns_zone_gettype(zone);
if (type == dns_zone_slave || type == dns_zone_stub)
dns_zone_forcereload(zone);
else
result = ISC_R_NOTFOUND;
dns_zone_detach(&zone);
return (result);
}
/*
* Act on a "reload" command from the command channel.
*/
@@ -2480,10 +2575,10 @@ ns_server_reloadcommand(ns_server_t *server, char *args) {
if (type == dns_zone_slave || type == dns_zone_stub)
dns_zone_refresh(zone);
else
result = dns_zone_load(zone);
dns_zone_load(zone);
dns_zone_detach(&zone);
}
return (result);
return (ISC_R_SUCCESS);
}
/*
@@ -2761,58 +2856,6 @@ ns_server_flushcache(ns_server_t *server, char *args) {
return (result);
}
isc_result_t
ns_server_flushname(ns_server_t *server, char *args) {
char *ptr, *target, *viewname;
dns_view_t *view;
isc_boolean_t flushed = ISC_FALSE;
isc_result_t result;
isc_buffer_t b;
dns_fixedname_t fixed;
dns_name_t *name;
/* Skip the command name. */
ptr = next_token(&args, " \t");
if (ptr == NULL)
return (ISC_R_UNEXPECTEDEND);
/* Find the domain name to flush. */
target = next_token(&args, " \t");
if (target == NULL)
return (ISC_R_UNEXPECTEDEND);
isc_buffer_init(&b, target, strlen(target));
isc_buffer_add(&b, strlen(target));
dns_fixedname_init(&fixed);
name = dns_fixedname_name(&fixed);
result = dns_name_fromtext(name, &b, dns_rootname, ISC_FALSE, NULL);
if (result != ISC_R_SUCCESS)
return (result);
/* Look for the view name. */
viewname = next_token(&args, " \t");
result = isc_task_beginexclusive(server->task);
RUNTIME_CHECK(result == ISC_R_SUCCESS);
flushed = ISC_TRUE;
for (view = ISC_LIST_HEAD(server->viewlist);
view != NULL;
view = ISC_LIST_NEXT(view, link))
{
if (viewname != NULL && strcasecmp(viewname, view->name) != 0)
continue;
result = dns_view_flushname(view, name);
if (result != ISC_R_SUCCESS)
flushed = ISC_FALSE;
}
if (flushed)
result = ISC_R_SUCCESS;
else
result = ISC_R_FAILURE;
isc_task_endexclusive(server->task);
return (result);
}
isc_result_t
ns_server_status(ns_server_t *server, isc_buffer_t *text) {
int zonecount, xferrunning, xferdeferred, soaqueries;
@@ -2841,71 +2884,3 @@ ns_server_status(ns_server_t *server, isc_buffer_t *text) {
isc_buffer_add(text, n);
return (ISC_R_SUCCESS);
}
/*
* Act on a "freeze" or "unfreeze" command from the command channel.
*/
isc_result_t
ns_server_freeze(ns_server_t *server, isc_boolean_t freeze, char *args) {
isc_result_t result;
dns_zone_t *zone = NULL;
dns_zonetype_t type;
char classstr[DNS_RDATACLASS_FORMATSIZE];
char zonename[DNS_NAME_FORMATSIZE];
dns_view_t *view;
char *journal;
const char *vname, *sep;
isc_boolean_t frozen;
result = zone_from_args(server, args, &zone);
if (result != ISC_R_SUCCESS)
return (result);
if (zone == NULL)
return (ISC_R_UNEXPECTEDEND);
type = dns_zone_gettype(zone);
if (type != dns_zone_master) {
dns_zone_detach(&zone);
return (ISC_R_NOTFOUND);
}
frozen = dns_zone_getupdatedisabled(zone);
if (freeze) {
if (frozen)
result = DNS_R_FROZEN;
if (result == ISC_R_SUCCESS)
result = dns_zone_flush(zone);
if (result == ISC_R_SUCCESS) {
journal = dns_zone_getjournal(zone);
if (journal != NULL)
(void)isc_file_remove(journal);
}
} else {
if (frozen)
result = dns_zone_load(zone);
}
if (result == ISC_R_SUCCESS)
dns_zone_setupdatedisabled(zone, freeze);
view = dns_zone_getview(zone);
if (strcmp(view->name, "_bind") == 0 ||
strcmp(view->name, "_default") == 0)
{
vname = "";
sep = "";
} else {
vname = view->name;
sep = " ";
}
dns_rdataclass_format(dns_zone_getclass(zone), classstr,
sizeof(classstr));
dns_name_format(dns_zone_getorigin(zone),
zonename, sizeof(zonename));
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_SERVER, ISC_LOG_INFO,
"%s zone '%s/%s'%s%s: %s",
freeze ? "freezing" : "unfreezing",
zonename, classstr, sep, vname,
isc_result_totext(result));
dns_zone_detach(&zone);
return (result);
}

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: sortlist.c,v 1.8 2001/10/30 20:19:32 gson Exp $ */
/* $Id: sortlist.c,v 1.5 2001/03/26 23:36:00 gson Exp $ */
#include <config.h>
@@ -42,58 +42,40 @@ ns_sortlist_setup(dns_acl_t *acl, isc_netaddr_t *clientaddr, void **argp) {
* in the sortlist (see ARM).
*/
dns_aclelement_t *e = &acl->elements[i];
dns_aclelement_t *try_elt;
dns_aclelement_t *order_elt = NULL;
dns_aclelement_t *matched_elt = NULL;
dns_aclelement_t *matchelt = NULL;
dns_acl_t *inner;
if (e->type == dns_aclelementtype_nestedacl) {
dns_acl_t *inner = e->u.nestedacl;
if (e->type != dns_aclelementtype_nestedacl)
goto dont_sort;
if (inner->length < 1 || inner->length > 2)
goto dont_sort;
if (inner->elements[0].negative)
goto dont_sort;
try_elt = &inner->elements[0];
if (inner->length == 2)
order_elt = &inner->elements[1];
} else {
/*
* BIND 8 allows bare elements at the top level
* as an undocumented feature.
*/
try_elt = e;
}
inner = e->u.nestedacl;
if (dns_aclelement_match(clientaddr, NULL, try_elt,
if (inner->length < 1 || inner->length > 2)
goto dont_sort;
if (inner->elements[0].negative)
goto dont_sort;
if (dns_aclelement_match(clientaddr, NULL,
&inner->elements[0],
&ns_g_server->aclenv,
&matched_elt)) {
if (order_elt != NULL) {
if (order_elt->type ==
dns_aclelementtype_nestedacl) {
*argp = order_elt->u.nestedacl;
return (NS_SORTLISTTYPE_2ELEMENT);
} else if (order_elt->type ==
dns_aclelementtype_localhost &&
ns_g_server->aclenv.localhost != NULL) {
&matchelt)) {
if (inner->length == 2) {
dns_aclelement_t *elt1 = &inner->elements[1];
if (elt1->type == dns_aclelementtype_nestedacl)
*argp = elt1->u.nestedacl;
else if (elt1->type == dns_aclelementtype_localhost &&
ns_g_server->aclenv.localhost != NULL)
*argp = ns_g_server->aclenv.localhost;
return (NS_SORTLISTTYPE_2ELEMENT);
} else if (order_elt->type ==
dns_aclelementtype_localnets &&
ns_g_server->aclenv.localnets != NULL) {
else if (elt1->type == dns_aclelementtype_localnets &&
ns_g_server->aclenv.localnets != NULL)
*argp = ns_g_server->aclenv.localnets;
return (NS_SORTLISTTYPE_2ELEMENT);
} else {
/*
* BIND 8 allows a bare IP prefix as
* the 2nd element of a 2-element
* sortlist statement.
*/
*argp = order_elt;
return (NS_SORTLISTTYPE_1ELEMENT);
}
else
goto dont_sort;
return (NS_SORTLISTTYPE_2ELEMENT);
} else {
INSIST(matched_elt != NULL);
*argp = matched_elt;
INSIST(matchelt != NULL);
*argp = matchelt;
return (NS_SORTLISTTYPE_1ELEMENT);
}
}

View File

@@ -13,13 +13,13 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.7 2001/09/20 15:16:26 marka Exp $
# $Id: Makefile.in,v 1.6 2001/01/09 21:40:37 bwelling Exp $
srcdir = @srcdir@
VPATH = @srcdir@
top_srcdir = @top_srcdir@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = -I${srcdir}/include -I${srcdir}/../include \
${DNS_INCLUDES} ${ISC_INCLUDES}

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: os.h,v 1.18 2001/12/01 00:34:24 marka Exp $ */
/* $Id: os.h,v 1.14 2001/01/09 21:40:39 bwelling Exp $ */
#ifndef NS_OS_H
#define NS_OS_H 1
@@ -46,10 +46,4 @@ ns_os_writepidfile(const char *filename);
void
ns_os_shutdown(void);
isc_result_t
ns_os_gethostname(char *buf, size_t len);
void
ns_os_shutdownmsg(char *command, isc_buffer_t *text);
#endif /* NS_OS_H */

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: os.c,v 1.57 2001/12/01 00:34:23 marka Exp $ */
/* $Id: os.c,v 1.46.2.1 2001/10/22 23:28:12 gson Exp $ */
#include <config.h>
#include <stdarg.h>
@@ -33,7 +33,6 @@
#include <syslog.h>
#include <unistd.h>
#include <isc/buffer.h>
#include <isc/file.h>
#include <isc/print.h>
#include <isc/result.h>
@@ -45,10 +44,6 @@
static char *pidfile = NULL;
#ifndef ISC_FACILITY
#define ISC_FACILITY LOG_DAEMON
#endif
/*
* If there's no <linux/capability.h>, we don't care about <sys/prctl.h>
*/
@@ -144,10 +139,10 @@ linux_setcaps(unsigned int caps) {
if ((getuid() != 0 && !non_root_caps) || non_root)
return;
memset(&caphead, 0, sizeof(caphead));
memset(&caphead, 0, sizeof caphead);
caphead.version = _LINUX_CAPABILITY_VERSION;
caphead.pid = 0;
memset(&cap, 0, sizeof(cap));
memset(&cap, 0, sizeof cap);
cap.effective = caps;
cap.permitted = caps;
cap.inheritable = caps;
@@ -272,7 +267,8 @@ setup_syslog(const char *progname) {
#ifdef LOG_NDELAY
options |= LOG_NDELAY;
#endif
openlog(isc_file_basename(progname), options, ISC_FACILITY);
openlog(isc_file_basename(progname), options, LOG_DAEMON);
}
void
@@ -325,11 +321,11 @@ ns_os_daemonize(void) {
*/
fd = open("/dev/null", O_RDWR, 0);
if (fd != -1) {
(void)close(STDIN_FILENO);
close(STDIN_FILENO);
(void)dup2(fd, STDIN_FILENO);
(void)close(STDOUT_FILENO);
close(STDOUT_FILENO);
(void)dup2(fd, STDOUT_FILENO);
(void)close(STDERR_FILENO);
close(STDERR_FILENO);
(void)dup2(fd, STDERR_FILENO);
if (fd != STDIN_FILENO &&
fd != STDOUT_FILENO &&
@@ -483,9 +479,6 @@ ns_os_writepidfile(const char *filename) {
cleanup_pidfile();
if (filename == NULL)
return;
len = strlen(filename);
pidfile = malloc(len + 1);
if (pidfile == NULL) {
@@ -527,57 +520,3 @@ ns_os_shutdown(void) {
closelog();
cleanup_pidfile();
}
isc_result_t
ns_os_gethostname(char *buf, size_t len) {
int n;
n = gethostname(buf, len);
return ((n == 0) ? ISC_R_SUCCESS : ISC_R_FAILURE);
}
static char *
next_token(char **stringp, const char *delim) {
char *res;
do {
res = strsep(stringp, delim);
if (res == NULL)
break;
} while (*res == '\0');
return (res);
}
void
ns_os_shutdownmsg(char *command, isc_buffer_t *text) {
char *input, *ptr;
unsigned int n;
pid_t pid;
input = command;
/* Skip the command name. */
ptr = next_token(&input, " \t");
if (ptr == NULL)
return;
ptr = next_token(&input, " \t");
if (ptr == NULL)
return;
if (strcmp(ptr, "-p") != 0)
return;
#ifdef HAVE_LINUXTHREADS
pid = mainpid;
#else
pid = getpid();
#endif
n = snprintf((char *)isc_buffer_used(text),
isc_buffer_availablelength(text),
"pid: %d", pid);
/* Only send a message if it is complete. */
if (n < isc_buffer_availablelength(text))
isc_buffer_add(text, n);
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 1999-2001 Internet Software Consortium.
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: update.c,v 1.97 2002/01/22 22:26:45 gson Exp $ */
/* $Id: update.c,v 1.88.2.3 2002/02/08 03:57:15 marka Exp $ */
#include <config.h>
@@ -36,7 +36,6 @@
#include <dns/rdataclass.h>
#include <dns/rdataset.h>
#include <dns/rdatasetiter.h>
#include <dns/rdatatype.h>
#include <dns/soa.h>
#include <dns/ssu.h>
#include <dns/view.h>
@@ -107,34 +106,6 @@
if (result != ISC_R_SUCCESS) goto failure; \
} while (0)
#define FAILN(code, name, msg) \
do { \
result = (code); \
if (isc_log_wouldlog(ns_g_lctx, LOGLEVEL_PROTOCOL)) { \
char _nbuf[DNS_NAME_FORMATSIZE]; \
dns_name_format(name, _nbuf, sizeof(_nbuf)); \
update_log(client, zone, LOGLEVEL_PROTOCOL, \
"update failed: %s: %s (%s)", _nbuf, \
msg, isc_result_totext(result)); \
} \
if (result != ISC_R_SUCCESS) goto failure; \
} while (0)
#define FAILNT(code, name, type, msg) \
do { \
result = (code); \
if (isc_log_wouldlog(ns_g_lctx, LOGLEVEL_PROTOCOL)) { \
char _nbuf[DNS_NAME_FORMATSIZE]; \
char _tbuf[DNS_RDATATYPE_FORMATSIZE]; \
dns_name_format(name, _nbuf, sizeof(_nbuf)); \
dns_rdatatype_format(type, _tbuf, sizeof(_tbuf)); \
update_log(client, zone, LOGLEVEL_PROTOCOL, \
"update failed: %s/%s: %s (%s)", \
_nbuf, _tbuf, msg, \
isc_result_totext(result)); \
} \
if (result != ISC_R_SUCCESS) goto failure; \
} while (0)
/*
* Fail unconditionally and log as a server error.
* The test against ISC_R_SUCCESS is there to keep the Solaris compiler
@@ -205,7 +176,7 @@ update_log(ns_client_t *client, dns_zone_t *zone,
sizeof(classbuf));
va_start(ap, fmt);
vsnprintf(message, sizeof(message), fmt, ap);
vsnprintf(message, sizeof message, fmt, ap);
va_end(ap);
ns_client_log(client, NS_LOGCATEGORY_UPDATE, NS_LOGMODULE_UPDATE,
@@ -754,13 +725,11 @@ temp_order(const void *av, const void *bv) {
*
* Return ISC_R_SUCCESS if the prerequisites are satisfied,
* rcode(dns_rcode_nxrrset) if not.
*
* 'temp' must be pre-sorted.
*/
static isc_result_t
temp_check(isc_mem_t *mctx, dns_diff_t *temp, dns_db_t *db,
dns_dbversion_t *ver, dns_name_t *tmpname, dns_rdatatype_t *typep)
dns_dbversion_t *ver)
{
isc_result_t result;
dns_name_t *name;
@@ -768,6 +737,18 @@ temp_check(isc_mem_t *mctx, dns_diff_t *temp, dns_db_t *db,
dns_difftuple_t *t;
dns_diff_t trash;
/* Exit early if the list is empty (for efficiency only). */
if (ISC_LIST_HEAD(temp->tuples) == NULL)
return (ISC_R_SUCCESS);
/*
* Sort the prerequisite records by owner name,
* type, and rdata.
*/
result = dns_diff_sort(temp, temp_order);
if (result != ISC_R_SUCCESS)
return (result);
dns_diff_init(mctx, &trash);
/*
@@ -778,8 +759,6 @@ temp_check(isc_mem_t *mctx, dns_diff_t *temp, dns_db_t *db,
t = ISC_LIST_HEAD(temp->tuples);
while (t != NULL) {
name = &t->name;
(void)dns_name_copy(name, tmpname, NULL);
*typep = t->rdata.type;
/* A new unique name begins here. */
node = NULL;
@@ -798,7 +777,7 @@ temp_check(isc_mem_t *mctx, dns_diff_t *temp, dns_db_t *db,
dns_diff_t u_rrs; /* Update RRs with
this name and type */
*typep = type = t->rdata.type;
type = t->rdata.type;
if (type == dns_rdatatype_sig)
covers = dns_rdata_covers(&t->rdata);
else
@@ -1261,8 +1240,9 @@ namelist_append_subdomain(dns_db_t *db, dns_name_t *name, dns_diff_t *affected)
result = dns_dbiterator_next(dbit))
{
dns_dbnode_t *node = NULL;
CHECK(dns_dbiterator_current(dbit, &node, child));
result = dns_dbiterator_current(dbit, &node, child);
dns_db_detachnode(db, &node);
CHECK(result);
if (! dns_name_issubdomain(child, name))
break;
CHECK(namelist_append_name(affected, child));
@@ -1414,7 +1394,7 @@ next_active(dns_db_t *db, dns_dbversion_t *ver, dns_name_t *oldname,
goto failure;
}
}
CHECK(dns_dbiterator_current(dbit, &node, newname));
dns_dbiterator_current(dbit, &node, newname);
dns_db_detachnode(db, &node);
/*
@@ -1499,7 +1479,7 @@ add_placeholder_nxt(dns_db_t *db, dns_dbversion_t *ver, dns_name_t *name,
dns_rdata_t rdata = DNS_RDATA_INIT;
r.base = data;
r.length = sizeof(data);
r.length = sizeof data;
dns_rdata_fromregion(&rdata, dns_db_class(db), dns_rdatatype_nxt, &r);
CHECK(dns_difftuple_create(diff->mctx, DNS_DIFFOP_ADD, name, 0,
&rdata, &tuple));
@@ -1509,16 +1489,14 @@ add_placeholder_nxt(dns_db_t *db, dns_dbversion_t *ver, dns_name_t *name,
}
static isc_result_t
find_zone_keys(dns_zone_t *zone, dns_db_t *db, dns_dbversion_t *ver,
isc_mem_t *mctx, unsigned int maxkeys,
dst_key_t **keys, unsigned int *nkeys)
find_zone_keys(dns_db_t *db, dns_dbversion_t *ver, isc_mem_t *mctx,
unsigned int maxkeys, dst_key_t **keys, unsigned int *nkeys)
{
isc_result_t result;
dns_dbnode_t *node = NULL;
const char *directory = dns_zone_getkeydirectory(zone);
CHECK(dns_db_findnode(db, dns_db_origin(db), ISC_FALSE, &node));
CHECK(dns_dnssec_findzonekeys2(db, ver, node, dns_db_origin(db),
directory, mctx, maxkeys, keys, nkeys));
CHECK(dns_dnssec_findzonekeys(db, ver, node, dns_db_origin(db),
mctx, maxkeys, keys, nkeys));
failure:
if (node != NULL)
dns_db_detachnode(db, &node);
@@ -1585,9 +1563,9 @@ add_sigs(dns_db_t *db, dns_dbversion_t *ver, dns_name_t *name,
* The SIGs generated will be valid for 'sigvalidityinterval' seconds.
*/
static isc_result_t
update_signatures(isc_mem_t *mctx, dns_zone_t *zone, dns_db_t *db,
dns_dbversion_t *oldver, dns_dbversion_t *newver,
dns_diff_t *diff, isc_uint32_t sigvalidityinterval)
update_signatures(isc_mem_t *mctx, dns_db_t *db, dns_dbversion_t *oldver,
dns_dbversion_t *newver, dns_diff_t *diff,
isc_uint32_t sigvalidityinterval)
{
isc_result_t result;
dns_difftuple_t *t;
@@ -1609,7 +1587,7 @@ update_signatures(isc_mem_t *mctx, dns_zone_t *zone, dns_db_t *db,
dns_diff_init(mctx, &nxt_diff);
dns_diff_init(mctx, &nxt_mindiff);
result = find_zone_keys(zone, db, newver, mctx,
result = find_zone_keys(db, newver, mctx,
MAXZONEKEYS, zone_keys, &nkeys);
if (result != ISC_R_SUCCESS) {
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_UPDATE,
@@ -1791,9 +1769,10 @@ update_signatures(isc_mem_t *mctx, dns_zone_t *zone, dns_db_t *db,
*/
CHECK(rrset_exists(db, newver, &t->name,
dns_rdatatype_nxt, 0, &flag));
if (! flag)
CHECK(add_placeholder_nxt(db, newver, &t->name,
diff));
if (! flag) {
add_placeholder_nxt(db, newver, &t->name,
diff);
}
}
}
@@ -2033,8 +2012,6 @@ update_action(isc_task_t *task, isc_event_t *event) {
dns_rdataclass_t zoneclass;
dns_name_t *zonename;
dns_ssutable_t *ssutable = NULL;
dns_fixedname_t tmpnamefixed;
dns_name_t *tmpname = NULL;
INSIST(event->ev_type == DNS_EVENT_UPDATE);
@@ -2069,7 +2046,7 @@ update_action(isc_task_t *task, isc_event_t *event) {
FAILC(DNS_R_FORMERR, "prerequisite TTL is not zero");
if (! dns_name_issubdomain(name, zonename))
FAILN(DNS_R_NOTZONE, name,
FAILC(DNS_R_NOTZONE,
"prerequisite name is out of zone");
if (update_class == dns_rdataclass_any) {
@@ -2080,7 +2057,7 @@ update_action(isc_task_t *task, isc_event_t *event) {
if (rdata.type == dns_rdatatype_any) {
CHECK(name_exists(db, ver, name, &flag));
if (! flag) {
FAILN(DNS_R_NXDOMAIN, name,
FAILC(DNS_R_NXDOMAIN,
"'name in use' prerequisite "
"not satisfied");
}
@@ -2089,7 +2066,7 @@ update_action(isc_task_t *task, isc_event_t *event) {
rdata.type, covers, &flag));
if (! flag) {
/* RRset does not exist. */
FAILNT(DNS_R_NXRRSET, name, rdata.type,
FAILC(DNS_R_NXRRSET,
"'rrset exists (value independent)' "
"prerequisite not satisfied");
}
@@ -2102,7 +2079,7 @@ update_action(isc_task_t *task, isc_event_t *event) {
if (rdata.type == dns_rdatatype_any) {
CHECK(name_exists(db, ver, name, &flag));
if (flag) {
FAILN(DNS_R_YXDOMAIN, name,
FAILC(DNS_R_YXDOMAIN,
"'name not in use' prerequisite "
"not satisfied");
}
@@ -2111,9 +2088,9 @@ update_action(isc_task_t *task, isc_event_t *event) {
rdata.type, covers, &flag));
if (flag) {
/* RRset exists. */
FAILNT(DNS_R_YXRRSET, name, rdata.type,
"'rrset does not exist' "
"prerequisite not satisfied");
FAILC(DNS_R_YXRRSET,
"'rrset does not exist' "
"prerequisite not satisfied");
}
}
} else if (update_class == zoneclass) {
@@ -2132,31 +2109,14 @@ update_action(isc_task_t *task, isc_event_t *event) {
if (result != ISC_R_NOMORE)
FAIL(result);
/*
* Perform the final check of the "rrset exists (value dependent)"
* prerequisites.
*/
if (ISC_LIST_HEAD(temp.tuples) != NULL) {
dns_rdatatype_t type;
/*
* Sort the prerequisite records by owner name,
* type, and rdata.
*/
result = dns_diff_sort(&temp, temp_order);
if (result != ISC_R_SUCCESS)
FAILC(result, "'RRset exists (value dependent)' "
"prerequisite not satisfied");
dns_fixedname_init(&tmpnamefixed);
tmpname = dns_fixedname_name(&tmpnamefixed);
result = temp_check(mctx, &temp, db, ver, tmpname, &type);
if (result != ISC_R_SUCCESS)
FAILNT(result, tmpname, type,
"'RRset exists (value dependent)' "
"prerequisite not satisfied");
}
result = temp_check(mctx, &temp, db, ver);
if (result != ISC_R_SUCCESS)
FAILC(result, "'RRset exists (value dependent)' "
"prerequisite not satisfied");
update_log(client, zone, LOGLEVEL_DEBUG,
"prerequisites are OK");
@@ -2165,8 +2125,6 @@ update_action(isc_task_t *task, isc_event_t *event) {
* Check Requestor's Permissions. It seems a bit silly to do this
* only after prerequisite testing, but that is what RFC2136 says.
*/
if (dns_zone_getupdatedisabled(zone))
FAILC(DNS_R_REFUSED, "dynamic update temporarily disabled");
if (ssutable == NULL) {
char msg[DNS_RDATACLASS_FORMATSIZE + DNS_NAME_FORMATSIZE
+ sizeof("update '/'")];
@@ -2288,20 +2246,6 @@ update_action(isc_task_t *task, isc_event_t *event) {
&name, &rdata, &covers, &ttl, &update_class);
if (update_class == zoneclass) {
/*
* RFC 1123 doesn't allow MF and MD in master zones. */
if (rdata.type == dns_rdatatype_md ||
rdata.type == dns_rdatatype_mf) {
char typebuf[DNS_RDATATYPE_FORMATSIZE];
dns_rdatatype_format(rdata.type, typebuf,
sizeof(typebuf));
update_log(client, zone, LOGLEVEL_PROTOCOL,
"attempt to add %s ignored",
typebuf);
continue;
}
if (rdata.type == dns_rdatatype_cname) {
CHECK(cname_incompatible_rrset_exists(db, ver,
name,
@@ -2352,19 +2296,9 @@ update_action(isc_task_t *task, isc_event_t *event) {
}
soa_serial_changed = ISC_TRUE;
}
if (isc_log_wouldlog(ns_g_lctx, LOGLEVEL_PROTOCOL)) {
char namestr[DNS_NAME_FORMATSIZE];
char typestr[DNS_RDATATYPE_FORMATSIZE];
dns_name_format(name, namestr,
sizeof(namestr));
dns_rdatatype_format(rdata.type, typestr,
sizeof(typestr));
update_log(client, zone,
LOGLEVEL_PROTOCOL,
"adding an RR at '%s' %s",
namestr, typestr);
}
update_log(client, zone,
LOGLEVEL_PROTOCOL, "adding an RR");
/* Prepare the affected RRset for the addition. */
{
@@ -2394,17 +2328,9 @@ update_action(isc_task_t *task, isc_event_t *event) {
}
} else if (update_class == dns_rdataclass_any) {
if (rdata.type == dns_rdatatype_any) {
if (isc_log_wouldlog(ns_g_lctx,
LOGLEVEL_PROTOCOL))
{
char namestr[DNS_NAME_FORMATSIZE];
dns_name_format(name, namestr,
sizeof(namestr));
update_log(client, zone,
LOGLEVEL_PROTOCOL,
"delete all rrsets from "
"name '%s'", namestr);
}
update_log(client, zone,
LOGLEVEL_PROTOCOL,
"delete all rrsets from a name");
if (dns_name_equal(name, zonename)) {
CHECK(delete_if(type_not_soa_nor_ns_p,
db, ver, name,
@@ -2424,21 +2350,9 @@ update_action(isc_task_t *task, isc_event_t *event) {
"or NS records ignored");
continue;
} else {
if (isc_log_wouldlog(ns_g_lctx,
LOGLEVEL_PROTOCOL))
{
char namestr[DNS_NAME_FORMATSIZE];
char typestr[DNS_RDATATYPE_FORMATSIZE];
dns_name_format(name, namestr,
sizeof(namestr));
dns_rdatatype_format(rdata.type,
typestr,
sizeof(typestr));
update_log(client, zone,
LOGLEVEL_PROTOCOL,
"deleting rrset at '%s' %s",
namestr, typestr);
}
update_log(client, zone,
LOGLEVEL_PROTOCOL,
"deleting an rrset");
CHECK(delete_if(true_p, db, ver, name,
rdata.type, covers, &rdata,
&diff));
@@ -2499,7 +2413,7 @@ update_action(isc_task_t *task, isc_event_t *event) {
}
if (dns_db_issecure(db)) {
result = update_signatures(mctx, zone, db, oldver, ver,
result = update_signatures(mctx, db, oldver, ver,
&diff, dns_zone_getsigvalidityinterval(zone));
if (result != ISC_R_SUCCESS) {
update_log(client, zone,

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: os.h,v 1.5 2001/12/01 00:34:27 marka Exp $ */
/* $Id: os.h,v 1.1 2001/07/18 03:43:18 mayer Exp $ */
#ifndef NS_OS_H
#define NS_OS_H 1
@@ -46,10 +46,4 @@ ns_os_writepidfile(const char *filename);
void
ns_os_shutdown(void);
isc_result_t
ns_os_gethostname(char *buf, size_t len);
void
ns_os_shutdownmsg(char *command, isc_buffer_t *text);
#endif /* NS_OS_H */

View File

@@ -42,7 +42,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MD /W3 /GX /O2 /I "./" /I "../../../" /I "../win32/include" /I "../include" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/win32/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/isccc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MD /W3 /GX /O2 /I "./" /I "../../../" /I "../win32/include" /I "../include" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/win32/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/isccc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/isccfg/include" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
@@ -50,7 +50,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
# ADD LINK32 user32.lib advapi32.lib kernel32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccc/win32/Release/libisccc.lib ../../../lib/lwres/win32/Release/liblwres.lib ../../../lib/isccfg/win32/Release/libisccfg.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/named.exe"
# ADD LINK32 user32.lib advapi32.lib kernel32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccc/win32/Release/libisccc.lib ../../../lib/lwres/win32/Release/liblwres.lib ../../../lib/isccfg/win32/Release/libisccfg.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/named.exe"
!ELSEIF "$(CFG)" == "named - Win32 Debug"
@@ -66,7 +66,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../win32/include" /I "../include" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/win32/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/isccc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /D "i386" /FR /FD /GZ /c
# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../win32/include" /I "../include" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/win32/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/isccc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/isccfg/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /D "i386" /FR /FD /GZ /c
# SUBTRACT CPP /X /YX
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
@@ -75,7 +75,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib kernel32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccc/win32/Debug/libisccc.lib ../../../lib/lwres/win32/Debug/liblwres.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /map /debug /machine:I386 /out:"../../../Build/Debug/named.exe" /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib kernel32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccc/win32/Debug/libisccc.lib ../../../lib/lwres/win32/Debug/liblwres.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib /nologo /subsystem:console /map /debug /machine:I386 /out:"../../../Build/Debug/named.exe" /pdbtype:sept
!ENDIF
@@ -92,10 +92,6 @@ SOURCE=..\aclconf.c
# End Source File
# Begin Source File
SOURCE=..\builtin.c
# End Source File
# Begin Source File
SOURCE=..\client.c
# End Source File
# Begin Source File

View File

@@ -25,31 +25,16 @@ NULL=
NULL=nul
!ENDIF
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "named - Win32 Release"
OUTDIR=.\Release
INTDIR=.\Release
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Release\named.exe"
!ELSE
ALL : "libisccfg - Win32 Release" "libisccc - Win32 Release" "liblwres - Win32 Release" "libbind9 - Win32 Release" "libisc - Win32 Release" "libdns - Win32 Release" "..\..\..\Build\Release\named.exe"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 ReleaseCLEAN" "libisc - Win32 ReleaseCLEAN" "libbind9 - Win32 ReleaseCLEAN" "liblwres - Win32 ReleaseCLEAN" "libisccc - Win32 ReleaseCLEAN" "libisccfg - Win32 ReleaseCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\aclconf.obj"
-@erase "$(INTDIR)\builtin.obj"
-@erase "$(INTDIR)\client.obj"
-@erase "$(INTDIR)\config.obj"
-@erase "$(INTDIR)\control.obj"
@@ -85,13 +70,46 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MD /W3 /GX /O2 /I "./" /I "../../../" /I "../win32/include" /I "../include" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/win32/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/isccc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\named.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
CPP=cl.exe
CPP_PROJ=/nologo /MD /W3 /GX /O2 /I "./" /I "../../../" /I "../win32/include" /I "../include" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/win32/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/isccc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/isccfg/include" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\named.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\named.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib kernel32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccc/win32/Release/libisccc.lib ../../../lib/lwres/win32/Release/liblwres.lib ../../../lib/isccfg/win32/Release/libisccfg.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\named.pdb" /machine:I386 /out:"../../../Build/Release/named.exe"
LINK32_FLAGS=user32.lib advapi32.lib kernel32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccc/win32/Release/libisccc.lib ../../../lib/lwres/win32/Release/liblwres.lib ../../../lib/isccfg/win32/Release/libisccfg.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\named.pdb" /machine:I386 /out:"../../../Build/Release/named.exe"
LINK32_OBJS= \
"$(INTDIR)\aclconf.obj" \
"$(INTDIR)\client.obj" \
@@ -122,14 +140,7 @@ LINK32_OBJS= \
"$(INTDIR)\tsigconf.obj" \
"$(INTDIR)\update.obj" \
"$(INTDIR)\xfrout.obj" \
"$(INTDIR)\zoneconf.obj" \
"$(INTDIR)\builtin.obj" \
"..\..\..\lib\dns\win32\Release\libdns.lib" \
"..\..\..\lib\isc\win32\Release\libisc.lib" \
"..\..\..\lib\bind9\win32\Release\libbind9.lib" \
"..\..\..\lib\lwres\win32\Release\liblwres.lib" \
"..\..\..\lib\isccc\win32\Release\libisccc.lib" \
"..\..\..\lib\isccfg\win32\Release\libisccfg.lib"
"$(INTDIR)\zoneconf.obj"
"..\..\..\Build\Release\named.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
@@ -144,25 +155,12 @@ INTDIR=.\Debug
OutDir=.\Debug
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Debug\named.exe" "$(OUTDIR)\named.bsc"
!ELSE
ALL : "libisccfg - Win32 Debug" "libisccc - Win32 Debug" "liblwres - Win32 Debug" "libbind9 - Win32 Debug" "libisc - Win32 Debug" "libdns - Win32 Debug" "..\..\..\Build\Debug\named.exe" "$(OUTDIR)\named.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 DebugCLEAN" "libisc - Win32 DebugCLEAN" "libbind9 - Win32 DebugCLEAN" "liblwres - Win32 DebugCLEAN" "libisccc - Win32 DebugCLEAN" "libisccfg - Win32 DebugCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\aclconf.obj"
-@erase "$(INTDIR)\aclconf.sbr"
-@erase "$(INTDIR)\builtin.obj"
-@erase "$(INTDIR)\builtin.sbr"
-@erase "$(INTDIR)\client.obj"
-@erase "$(INTDIR)\client.sbr"
-@erase "$(INTDIR)\config.obj"
@@ -232,7 +230,40 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../win32/include" /I "../include" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/win32/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/isccc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /D "i386" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
CPP=cl.exe
CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../win32/include" /I "../include" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/dns/win32/include" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/isccc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/isccfg/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /D "i386" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\named.bsc"
BSC32_SBRS= \
@@ -265,8 +296,7 @@ BSC32_SBRS= \
"$(INTDIR)\tsigconf.sbr" \
"$(INTDIR)\update.sbr" \
"$(INTDIR)\xfrout.sbr" \
"$(INTDIR)\zoneconf.sbr" \
"$(INTDIR)\builtin.sbr"
"$(INTDIR)\zoneconf.sbr"
"$(OUTDIR)\named.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
@@ -274,7 +304,7 @@ BSC32_SBRS= \
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib kernel32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccc/win32/Debug/libisccc.lib ../../../lib/lwres/win32/Debug/liblwres.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\named.pdb" /map:"$(INTDIR)\named.map" /debug /machine:I386 /out:"../../../Build/Debug/named.exe" /pdbtype:sept
LINK32_FLAGS=user32.lib advapi32.lib kernel32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccc/win32/Debug/libisccc.lib ../../../lib/lwres/win32/Debug/liblwres.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\named.pdb" /map:"$(INTDIR)\named.map" /debug /machine:I386 /out:"../../../Build/Debug/named.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\aclconf.obj" \
"$(INTDIR)\client.obj" \
@@ -305,14 +335,7 @@ LINK32_OBJS= \
"$(INTDIR)\tsigconf.obj" \
"$(INTDIR)\update.obj" \
"$(INTDIR)\xfrout.obj" \
"$(INTDIR)\zoneconf.obj" \
"$(INTDIR)\builtin.obj" \
"..\..\..\lib\dns\win32\Debug\libdns.lib" \
"..\..\..\lib\isc\win32\Debug\libisc.lib" \
"..\..\..\lib\bind9\win32\Debug\libbind9.lib" \
"..\..\..\lib\lwres\win32\Debug\liblwres.lib" \
"..\..\..\lib\isccc\win32\Debug\libisccc.lib" \
"..\..\..\lib\isccfg\win32\Debug\libisccfg.lib"
"$(INTDIR)\zoneconf.obj"
"..\..\..\Build\Debug\named.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
@@ -321,36 +344,6 @@ LINK32_OBJS= \
!ENDIF
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("named.dep")
@@ -378,24 +371,6 @@ SOURCE=..\aclconf.c
$(CPP) $(CPP_PROJ) $(SOURCE)
!ENDIF
SOURCE=..\builtin.c
!IF "$(CFG)" == "named - Win32 Release"
"$(INTDIR)\builtin.obj" : $(SOURCE) "$(INTDIR)"
$(CPP) $(CPP_PROJ) $(SOURCE)
!ELSEIF "$(CFG)" == "named - Win32 Debug"
"$(INTDIR)\builtin.obj" "$(INTDIR)\builtin.sbr" : $(SOURCE) "$(INTDIR)"
$(CPP) $(CPP_PROJ) $(SOURCE)
!ENDIF
SOURCE=..\client.c
@@ -916,162 +891,6 @@ SOURCE=..\zoneconf.c
!ENDIF
!IF "$(CFG)" == "named - Win32 Release"
"libdns - Win32 Release" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release"
cd "..\..\..\bin\named\win32"
"libdns - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ELSEIF "$(CFG)" == "named - Win32 Debug"
"libdns - Win32 Debug" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug"
cd "..\..\..\bin\named\win32"
"libdns - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ENDIF
!IF "$(CFG)" == "named - Win32 Release"
"libisc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release"
cd "..\..\..\bin\named\win32"
"libisc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ELSEIF "$(CFG)" == "named - Win32 Debug"
"libisc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug"
cd "..\..\..\bin\named\win32"
"libisc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ENDIF
!IF "$(CFG)" == "named - Win32 Release"
"libbind9 - Win32 Release" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release"
cd "..\..\..\bin\named\win32"
"libbind9 - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ELSEIF "$(CFG)" == "named - Win32 Debug"
"libbind9 - Win32 Debug" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug"
cd "..\..\..\bin\named\win32"
"libbind9 - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ENDIF
!IF "$(CFG)" == "named - Win32 Release"
"liblwres - Win32 Release" :
cd "\bind-9.3.0a03\lib\lwres\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\liblwres.mak" CFG="liblwres - Win32 Release"
cd "..\..\..\bin\named\win32"
"liblwres - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\lwres\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\liblwres.mak" CFG="liblwres - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ELSEIF "$(CFG)" == "named - Win32 Debug"
"liblwres - Win32 Debug" :
cd "\bind-9.3.0a03\lib\lwres\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\liblwres.mak" CFG="liblwres - Win32 Debug"
cd "..\..\..\bin\named\win32"
"liblwres - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\lwres\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\liblwres.mak" CFG="liblwres - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ENDIF
!IF "$(CFG)" == "named - Win32 Release"
"libisccc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isccc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccc.mak" CFG="libisccc - Win32 Release"
cd "..\..\..\bin\named\win32"
"libisccc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isccc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccc.mak" CFG="libisccc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ELSEIF "$(CFG)" == "named - Win32 Debug"
"libisccc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isccc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccc.mak" CFG="libisccc - Win32 Debug"
cd "..\..\..\bin\named\win32"
"libisccc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isccc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccc.mak" CFG="libisccc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ENDIF
!IF "$(CFG)" == "named - Win32 Release"
"libisccfg - Win32 Release" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Release"
cd "..\..\..\bin\named\win32"
"libisccfg - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ELSEIF "$(CFG)" == "named - Win32 Debug"
"libisccfg - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Debug"
cd "..\..\..\bin\named\win32"
"libisccfg - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\named\win32"
!ENDIF
!ENDIF

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: ntservice.c,v 1.5 2002/02/02 00:56:40 mayer Exp $ */
/* $Id: ntservice.c,v 1.3.2.1 2001/09/04 19:40:20 gson Exp $ */
#include <config.h>
#include <stdio.h>
@@ -135,7 +135,6 @@ ServiceControl(DWORD dwCtrlCode) {
UpdateSCM(0);
break;
case SERVICE_CONTROL_SHUTDOWN:
case SERVICE_CONTROL_STOP:
ns_server_flushonshutdown(ns_g_server, ISC_TRUE);
isc_app_shutdown();

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: os.c,v 1.13 2001/12/01 00:34:26 marka Exp $ */
/* $Id: os.c,v 1.5 2001/08/09 23:44:13 mayer Exp $ */
#include <config.h>
#include <stdarg.h>
@@ -33,7 +33,6 @@
#include <isc/print.h>
#include <isc/result.h>
#include <isc/strerror.h>
#include <isc/string.h>
#include <isc/ntpaths.h>
@@ -165,7 +164,6 @@ ns_os_writepidfile(const char *filename) {
FILE *lockfile;
size_t len;
pid_t pid;
char strbuf[ISC_STRERRORSIZE];
/*
* The caller must ensure any required synchronization.
@@ -173,30 +171,22 @@ ns_os_writepidfile(const char *filename) {
cleanup_pidfile();
if (strcmp(filename, "none") == 0)
return;
len = strlen(filename);
pidfile = malloc(len + 1);
if (pidfile == NULL) {
isc__strerror(errno, strbuf, sizeof(strbuf));
if (pidfile == NULL)
ns_main_earlyfatal("couldn't malloc '%s': %s",
filename, strbuf);
}
filename, strerror(errno));
/* This is safe. */
strcpy(pidfile, filename);
fd = safe_open(filename, ISC_FALSE);
if (fd < 0) {
isc__strerror(errno, strbuf, sizeof(strbuf));
if (fd < 0)
ns_main_earlyfatal("couldn't open pid file '%s': %s",
filename, strbuf);
}
filename, strerror(errno));
lockfile = fdopen(fd, "w");
if (lockfile == NULL) {
isc__strerror(errno, strbuf, sizeof(strbuf));
if (lockfile == NULL)
ns_main_earlyfatal("could not fdopen() pid file '%s': %s",
filename, strbuf);
}
filename, strerror(errno));
pid = getpid();
if (fprintf(lockfile, "%ld\n", (long)pid) < 0)
@@ -214,17 +204,3 @@ ns_os_shutdown(void) {
cleanup_pidfile();
ntservice_shutdown(); /* This MUST be the last thing done */
}
isc_result_t
ns_os_gethostname(char *buf, size_t len) {
int n;
n = gethostname(buf, len);
return ((n == 0) ? ISC_R_SUCCESS : ISC_R_FAILURE);
}
void
ns_os_shutdownmsg(char *command, isc_buffer_t *text) {
UNUSED(command);
UNUSED(text);
}

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: xfrout.c,v 1.107 2001/11/30 01:58:51 gson Exp $ */
/* $Id: xfrout.c,v 1.101.2.3 2001/10/30 01:28:29 marka Exp $ */
#include <config.h>
@@ -242,7 +242,7 @@ db_rr_iterator_next(db_rr_iterator_t *it) {
static void
db_rr_iterator_pause(db_rr_iterator_t *it) {
RUNTIME_CHECK(dns_dbiterator_pause(it->dbit) == ISC_R_SUCCESS);
dns_dbiterator_pause(it->dbit);
}
static void
@@ -724,7 +724,7 @@ compound_rrstream_first(rrstream_t *rs) {
do {
rrstream_t *curstream = s->components[s->state];
s->result = curstream->methods->first(curstream);
} while (s->result == ISC_R_NOMORE && s->state < 2);
} while (s->result == ISC_R_NOMORE && s->state < 2) ;
return (s->result);
}
@@ -1326,7 +1326,7 @@ sendstream(xfrout_ctx_t *xfr) {
msg->flags = DNS_MESSAGEFLAG_QR | DNS_MESSAGEFLAG_AA;
if ((xfr->client->attributes & NS_CLIENTATTR_RA) != 0)
msg->flags |= DNS_MESSAGEFLAG_RA;
CHECK(dns_message_settsigkey(msg, xfr->tsigkey));
dns_message_settsigkey(msg, xfr->tsigkey);
CHECK(dns_message_setquerytsig(msg, xfr->lasttsig));
if (xfr->lasttsig != NULL)
isc_buffer_free(&xfr->lasttsig);

View File

@@ -15,14 +15,12 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: zoneconf.c,v 1.100 2002/01/23 02:12:24 marka Exp $ */
/* $Id: zoneconf.c,v 1.87.2.4 2001/11/13 01:15:33 gson Exp $ */
#include <config.h>
#include <isc/buffer.h>
#include <isc/file.h>
#include <isc/mem.h>
#include <isc/print.h>
#include <isc/string.h> /* Required for HP/UX (and others?) */
#include <isc/util.h>
@@ -315,7 +313,6 @@ ns_zone_configure(cfg_obj_t *config, cfg_obj_t *vconfig, cfg_obj_t *zconfig,
dns_dialuptype_t dialup = dns_dialuptype_no;
dns_zonetype_t ztype;
int i;
isc_int32_t journal_size;
i = 0;
if (zconfig != NULL) {
@@ -411,7 +408,7 @@ ns_zone_configure(cfg_obj_t *config, cfg_obj_t *vconfig, cfg_obj_t *zconfig,
obj = NULL;
result = ns_config_get(maps, "zone-statistics", &obj);
INSIST(result == ISC_R_SUCCESS);
RETERR(dns_zone_setstatistics(zone, cfg_obj_asboolean(obj)));
dns_zone_setstatistics(zone, cfg_obj_asboolean(obj));
/*
* Configure master functionality. This applies
@@ -456,12 +453,12 @@ ns_zone_configure(cfg_obj_t *config, cfg_obj_t *vconfig, cfg_obj_t *zconfig,
obj = NULL;
result = ns_config_get(maps, "notify-source", &obj);
INSIST(result == ISC_R_SUCCESS);
RETERR(dns_zone_setnotifysrc4(zone, cfg_obj_assockaddr(obj)));
dns_zone_setnotifysrc4(zone, cfg_obj_assockaddr(obj));
obj = NULL;
result = ns_config_get(maps, "notify-source-v6", &obj);
INSIST(result == ISC_R_SUCCESS);
RETERR(dns_zone_setnotifysrc6(zone, cfg_obj_assockaddr(obj)));
dns_zone_setnotifysrc6(zone, cfg_obj_assockaddr(obj));
RETERR(configure_zone_acl(zconfig, vconfig, config,
"allow-transfer", ac, zone,
@@ -477,36 +474,6 @@ ns_zone_configure(cfg_obj_t *config, cfg_obj_t *vconfig, cfg_obj_t *zconfig,
result = ns_config_get(maps, "max-transfer-idle-out", &obj);
INSIST(result == ISC_R_SUCCESS);
dns_zone_setidleout(zone, cfg_obj_asuint32(obj) * 60);
obj = NULL;
result = ns_config_get(maps, "max-journal-size", &obj);
INSIST(result == ISC_R_SUCCESS);
dns_zone_setjournalsize(zone, -1);
if (cfg_obj_isstring(obj)) {
const char *str = cfg_obj_asstring(obj);
INSIST(strcasecmp(str, "unlimited") == 0);
journal_size = ISC_UINT32_MAX / 2;
} else {
isc_resourcevalue_t value;
value = cfg_obj_asuint64(obj);
if (value > ISC_UINT32_MAX / 2) {
cfg_obj_log(obj, ns_g_lctx,
ISC_LOG_ERROR,
"'max-journal-size "
"%" ISC_PRINT_QUADFORMAT "d' "
"is too large",
value);
RETERR(ISC_R_RANGE);
}
journal_size = (isc_uint32_t)value;
}
dns_zone_setjournalsize(zone, journal_size);
obj = NULL;
result = ns_config_get(maps, "ixfr-from-differences", &obj);
INSIST(result == ISC_R_SUCCESS);
dns_zone_setoption(zone, DNS_ZONEOPT_IXFRFROMDIFFS,
cfg_obj_asboolean(obj));
}
/*
@@ -535,20 +502,6 @@ ns_zone_configure(cfg_obj_t *config, cfg_obj_t *vconfig, cfg_obj_t *zconfig,
INSIST(result == ISC_R_SUCCESS);
dns_zone_setsigvalidityinterval(zone,
cfg_obj_asuint32(obj) * 86400);
obj = NULL;
result = ns_config_get(maps, "key-directory", &obj);
if (result == ISC_R_SUCCESS) {
filename = cfg_obj_asstring(obj);
if (!isc_file_isabsolute(filename)) {
cfg_obj_log(obj, ns_g_lctx, ISC_LOG_ERROR,
"key-directory '%s' "
"is not absolute", filename);
return (ISC_R_FAILURE);
}
RETERR(dns_zone_setkeydirectory(zone, filename));
}
} else if (ztype == dns_zone_slave) {
RETERR(configure_zone_acl(zconfig, vconfig, config,
"allow-update-forwarding", ac, zone,
@@ -611,12 +564,12 @@ ns_zone_configure(cfg_obj_t *config, cfg_obj_t *vconfig, cfg_obj_t *zconfig,
obj = NULL;
result = ns_config_get(maps, "transfer-source", &obj);
INSIST(result == ISC_R_SUCCESS);
RETERR(dns_zone_setxfrsource4(zone, cfg_obj_assockaddr(obj)));
dns_zone_setxfrsource4(zone, cfg_obj_assockaddr(obj));
obj = NULL;
result = ns_config_get(maps, "transfer-source-v6", &obj);
INSIST(result == ISC_R_SUCCESS);
RETERR(dns_zone_setxfrsource6(zone, cfg_obj_assockaddr(obj)));
dns_zone_setxfrsource6(zone, cfg_obj_assockaddr(obj));
break;

View File

@@ -13,7 +13,7 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.19 2001/11/21 02:19:01 gson Exp $
# $Id: Makefile.in,v 1.15 2001/06/01 00:45:01 bwelling Exp $
srcdir = @srcdir@
VPATH = @srcdir@
@@ -21,29 +21,24 @@ top_srcdir = @top_srcdir@
@BIND9_VERSION@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = ${LWRES_INCLUDES} ${DNS_INCLUDES} ${BIND9_INCLUDES} \
${ISC_INCLUDES}
CINCLUDES = ${LWRES_INCLUDES} ${DNS_INCLUDES} ${ISC_INCLUDES}
CDEFINES =
CWARNINGS =
LWRESLIBS = ../../lib/lwres/liblwres.@A@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
BIND9LIBS = ../../lib/bind9/libbind9.@A@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCLIBS = ../../lib/isc/libisc.@A@
ISCCFGLIBS = ../../lib/isccfg/libisccfg.@A@
LWRESDEPLIBS = ../../lib/lwres/liblwres.@A@
DNSDEPLIBS = ../../lib/dns/libdns.@A@
BIND9DEPLIBS = ../../lib/bind9/libbind9.@A@
ISCDEPLIBS = ../../lib/isc/libisc.@A@
ISCCFGDEPLIBS = ../../lib/isccfg/libisccfg.@A@
DEPLIBS = ${DNSDEPLIBS} ${BIND9DEPLIBS} ${ISCDEPLIBS} ${ISCCFGDEPLIBS}
DEPLIBS = ${DNSDEPLIBS} ${ISCDEPLIBS}
LIBS = ${LWRESLIBS} ${DNSLIBS} ${BIND9LIBS} ${ISCLIBS} ${ISCCFGLIBS} @LIBS@
LIBS = ${LWRESLIBS} ${DNSLIBS} ${ISCLIBS} @LIBS@
SUBDIRS =

View File

@@ -52,10 +52,10 @@ made and the replies received from the name server.
.PP
Transaction signatures can be used to authenticate the Dynamic DNS
updates.
These use the TSIG resource record type described in RFC2845 or the
SIG(0) record described in RFC3535 and RFC2931.
TSIG relies on a shared secret that should only be known to
\fBnsupdate\fR and the name server.
These use the TSIG resource record type described in RFC2845.
The signatures rely on a shared secret that should only be known to
\fBnsupdate\fR
and the name server.
Currently, the only supported encryption algorithm for TSIG is
HMAC-MD5, which is defined in RFC 2104.
Once other algorithms are defined for TSIG, applications will need to
@@ -70,8 +70,6 @@ statements would be added to
so that the name server can associate the appropriate secret key
and algorithm with the IP address of the
client application that will be using TSIG authentication.
SIG(0) uses public key cryptography. To use a SIG(0) key, the public
key must be stored in a KEY record in a zone served by the name server.
\fBnsupdate\fR
does not read
\fI/etc/named.conf\fR.
@@ -81,8 +79,8 @@ uses the
\fB-y\fR
or
\fB-k\fR
option (with an HMAC-MD5 key) to provide the shared secret needed to generate
a TSIG record for authenticating Dynamic DNS update requests.
option to provide the shared secret needed to generate a TSIG record
for authenticating Dynamic DNS update requests.
These options are mutually exclusive.
With the
\fB-k\fR
@@ -112,10 +110,6 @@ This may be visible in the output from
\fBps\fR(1)
or in a history file maintained by the user's shell.
.PP
The \fB-k\fR may also be used to specify a SIG(0) key used
to authenticate Dynamic DNS update requests. In this case, the key
specified is not an HMAC-MD5 key.
.PP
By default
\fBnsupdate\fR
uses UDP to send update requests to the name server.
@@ -337,7 +331,6 @@ base-64 encoding of HMAC-MD5 key created by
\fBRFC2845\fR,
\fBRFC1034\fR,
\fBRFC2535\fR,
\fBRFC2931\fR,
\fBnamed\fR(8),
\fBdnssec-keygen\fR(8).
.SH "BUGS"

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2000, 2001 Internet Software Consortium.
* Copyright (C) 2000-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
@@ -15,13 +15,14 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: nsupdate.c,v 1.116 2002/01/21 07:59:15 bwelling Exp $ */
/* $Id: nsupdate.c,v 1.103.2.9 2002/02/08 03:57:18 marka Exp $ */
#include <config.h>
#include <ctype.h>
#include <errno.h>
#include <limits.h>
#include <netdb.h>
#include <stdlib.h>
#include <unistd.h>
@@ -33,7 +34,6 @@
#include <isc/event.h>
#include <isc/lex.h>
#include <isc/mem.h>
#include <isc/parseint.h>
#include <isc/region.h>
#include <isc/sockaddr.h>
#include <isc/socket.h>
@@ -46,7 +46,6 @@
#include <dns/callbacks.h>
#include <dns/dispatch.h>
#include <dns/dnssec.h>
#include <dns/events.h>
#include <dns/fixedname.h>
#include <dns/masterdump.h>
@@ -67,8 +66,6 @@
#include <lwres/lwres.h>
#include <lwres/net.h>
#include <bind9/getaddresses.h>
#ifdef HAVE_ADDRINFO
#ifdef HAVE_GETADDRINFO
#ifdef HAVE_GAISTRERROR
@@ -86,6 +83,8 @@ extern int h_errno;
#define MAXCMD (4 * 1024)
#define INITDATA (32 * 1024)
#define MAXDATA (64 * 1024)
#define NAMEBUF 512
#define WORDLEN 512
#define PACKETSIZE ((64 * 1024) - 1)
#define INITTEXT (2 * 1024)
#define MAXTEXT (128 * 1024)
@@ -119,8 +118,7 @@ static dns_fixedname_t resolvdomain; /* from resolv.conf's domain line */
static dns_name_t *origin; /* Points to one of above, or dns_rootname */
static dns_fixedname_t fuserzone;
static dns_name_t *userzone = NULL;
static dns_tsigkey_t *tsigkey = NULL;
static dst_key_t *sig0key;
static dns_tsigkey_t *key = NULL;
static lwres_context_t *lwctx = NULL;
static lwres_conf_t *lwconf;
static isc_sockaddr_t *servers;
@@ -322,7 +320,7 @@ setup_keystr(void) {
debug("keycreate");
result = dns_tsigkey_create(keyname, dns_tsig_hmacmd5_name,
secret, secretlen, ISC_TRUE, NULL,
0, 0, mctx, NULL, &tsigkey);
0, 0, mctx, NULL, &key);
if (result != ISC_R_SUCCESS)
fprintf(stderr, "could not create key from %s: %s\n",
keystr, dns_result_totext(result));
@@ -345,19 +343,16 @@ setup_keyfile(void) {
keyfile, isc_result_totext(result));
return;
}
if (dst_key_alg(dstkey) == DST_ALG_HMACMD5) {
result = dns_tsigkey_createfromkey(dst_key_name(dstkey),
dns_tsig_hmacmd5_name,
dstkey, ISC_FALSE, NULL,
0, 0, mctx, NULL, &tsigkey);
if (result != ISC_R_SUCCESS) {
fprintf(stderr, "could not create key from %s: %s\n",
keyfile, isc_result_totext(result));
dst_key_free(&dstkey);
return;
}
} else
sig0key = dstkey;
result = dns_tsigkey_createfromkey(dst_key_name(dstkey),
dns_tsig_hmacmd5_name,
dstkey, ISC_FALSE, NULL,
0, 0, mctx, NULL, &key);
if (result != ISC_R_SUCCESS) {
fprintf(stderr, "could not create key from %s: %s\n",
keyfile, isc_result_totext(result));
dst_key_free(&dstkey);
return;
}
}
static void
@@ -370,14 +365,9 @@ doshutdown(void) {
if (localaddr != NULL)
isc_mem_put(mctx, localaddr, sizeof(isc_sockaddr_t));
if (tsigkey != NULL) {
ddebug("Freeing TSIG key");
dns_tsigkey_detach(&tsigkey);
}
if (sig0key != NULL) {
ddebug("Freeing SIG(0) key");
dst_key_free(&sig0key);
if (key != NULL) {
ddebug("Freeing key");
dns_tsigkey_detach(&key);
}
if (updatemsg != NULL)
@@ -577,16 +567,60 @@ setup_system(void) {
static void
get_address(char *host, in_port_t port, isc_sockaddr_t *sockaddr) {
int count;
isc_result_t result;
struct in_addr in4;
struct in6_addr in6;
#ifdef USE_GETADDRINFO
struct addrinfo *res = NULL, hints;
int result;
#else
struct hostent *he;
#endif
isc_app_block();
result = bind9_getaddresses(host, port, sockaddr, 1, &count);
isc_app_unblock();
if (result != ISC_R_SUCCESS)
fatal("couldn't get address for '%s': %s",
host, isc_result_totext(result));
INSIST(count == 1);
ddebug("get_address()");
/*
* Assume we have v4 if we don't have v6, since setup_libs
* fatal()'s out if we don't have either.
*/
if (have_ipv6 && inet_pton(AF_INET6, host, &in6) == 1)
isc_sockaddr_fromin6(sockaddr, &in6, port);
else if (inet_pton(AF_INET, host, &in4) == 1)
isc_sockaddr_fromin(sockaddr, &in4, port);
else {
#ifdef USE_GETADDRINFO
memset(&hints, 0, sizeof(hints));
if (!have_ipv6)
hints.ai_family = PF_INET;
else if (!have_ipv4)
hints.ai_family = PF_INET6;
else
hints.ai_family = PF_UNSPEC;
debug ("before getaddrinfo()");
isc_app_block();
result = getaddrinfo(host, NULL, &hints, &res);
isc_app_unblock();
if (result != 0) {
fatal("couldn't find server '%s': %s",
host, gai_strerror(result));
}
memcpy(&sockaddr->type.sa,res->ai_addr, res->ai_addrlen);
sockaddr->length = res->ai_addrlen;
isc_sockaddr_setport(sockaddr, port);
freeaddrinfo(res);
#else
debug ("before gethostbyname()");
isc_app_block();
he = gethostbyname(host);
isc_app_unblock();
if (he == NULL)
fatal("couldn't find server '%s' (h_errno=%d)",
host, h_errno);
INSIST(he->h_addrtype == AF_INET);
isc_sockaddr_fromin(sockaddr,
(struct in_addr *)(he->h_addr_list[0]),
port);
#endif
}
}
static void
@@ -670,7 +704,7 @@ parse_name(char **cmdlinep, dns_message_t *msg, dns_name_t **namep) {
result = dns_message_gettempname(msg, namep);
check_result(result, "dns_message_gettempname");
result = isc_buffer_allocate(mctx, &namebuf, DNS_NAME_MAXWIRE);
result = isc_buffer_allocate(mctx, &namebuf, NAMEBUF);
check_result(result, "isc_buffer_allocate");
dns_name_init(*namep, NULL);
dns_name_setbuffer(*namep, namebuf);
@@ -1022,11 +1056,11 @@ evaluate_key(char *cmdline) {
}
secretlen = isc_buffer_usedlength(&secretbuf);
if (tsigkey != NULL)
dns_tsigkey_detach(&tsigkey);
if (key != NULL)
dns_tsigkey_detach(&key);
result = dns_tsigkey_create(keyname, dns_tsig_hmacmd5_name,
secret, secretlen, ISC_TRUE, NULL, 0, 0,
mctx, NULL, &tsigkey);
mctx, NULL, &key);
isc_mem_free(mctx, secret);
if (result != ISC_R_SUCCESS) {
fprintf(stderr, "could not create key from %s %s: %s\n",
@@ -1067,7 +1101,7 @@ static isc_uint16_t
update_addordelete(char *cmdline, isc_boolean_t isdelete) {
isc_result_t result;
dns_name_t *name = NULL;
isc_uint32_t ttl;
unsigned long ttl;
char *word;
dns_rdataclass_t rdataclass;
dns_rdatatype_t rdatatype;
@@ -1075,6 +1109,7 @@ update_addordelete(char *cmdline, isc_boolean_t isdelete) {
dns_rdatalist_t *rdatalist = NULL;
dns_rdataset_t *rdataset = NULL;
isc_textregion_t region;
char *endp;
isc_uint16_t retval;
ddebug("update_addordelete()");
@@ -1112,14 +1147,13 @@ update_addordelete(char *cmdline, isc_boolean_t isdelete) {
goto doneparsing;
}
}
result = isc_parse_uint32(&ttl, word, 10);
if (result != ISC_R_SUCCESS) {
ttl = strtoul(word, &endp, 10);
if (!isdigit((unsigned char)*word) || *endp != '\0') {
if (isdelete) {
ttl = 0;
goto parseclass;
} else {
fprintf(stderr, "ttl '%s': %s\n", word,
isc_result_totext(result));
fprintf(stderr, "ttl '%s' is not legal\n", word);
goto failure;
}
}
@@ -1461,19 +1495,11 @@ send_update(dns_name_t *zonename, isc_sockaddr_t *master,
if (usevc)
options |= DNS_REQUESTOPT_TCP;
if (tsigkey == NULL && sig0key != NULL) {
result = dns_message_setsig0key(updatemsg, sig0key);
check_result(result, "dns_message_setsig0key");
}
result = dns_request_createvia(requestmgr, updatemsg, srcaddr,
master, options, tsigkey,
master, options, key,
FIND_TIMEOUT, global_task,
update_completed, NULL, &request);
check_result(result, "dns_request_createvia");
if (debugging)
show_message(updatemsg);
requests++;
}

View File

@@ -16,7 +16,7 @@
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: nsupdate.docbook,v 1.10 2002/01/29 23:30:12 bwelling Exp $ -->
<!-- $Id: nsupdate.docbook,v 1.8.2.1 2001/11/27 18:57:40 gson Exp $ -->
<refentry>
<refentryinfo>
@@ -81,10 +81,10 @@ made and the replies received from the name server.
<para>
Transaction signatures can be used to authenticate the Dynamic DNS
updates.
These use the TSIG resource record type described in RFC2845 or the
SIG(0) record described in RFC3535 and RFC2931.
TSIG relies on a shared secret that should only be known to
<command>nsupdate</command> and the name server.
These use the TSIG resource record type described in RFC2845.
The signatures rely on a shared secret that should only be known to
<command>nsupdate</command>
and the name server.
Currently, the only supported encryption algorithm for TSIG is
HMAC-MD5, which is defined in RFC 2104.
Once other algorithms are defined for TSIG, applications will need to
@@ -99,8 +99,6 @@ statements would be added to
so that the name server can associate the appropriate secret key
and algorithm with the IP address of the
client application that will be using TSIG authentication.
SIG(0) uses public key cryptography. To use a SIG(0) key, the public
key must be stored in a KEY record in a zone served by the name server.
<command>nsupdate</command>
does not read
<filename>/etc/named.conf</filename>.
@@ -111,8 +109,8 @@ uses the
<option>-y</option>
or
<option>-k</option>
option (with an HMAC-MD5 key) to provide the shared secret needed to generate
a TSIG record for authenticating Dynamic DNS update requests.
option to provide the shared secret needed to generate a TSIG record
for authenticating Dynamic DNS update requests.
These options are mutually exclusive.
With the
<option>-k</option>
@@ -146,11 +144,6 @@ This may be visible in the output from
or in a history file maintained by the user's shell.
</para>
<para>
The <option>-k</option> may also be used to specify a SIG(0) key used
to authenticate Dynamic DNS update requests. In this case, the key
specified is not an HMAC-MD5 key.
</para>
<para>
By default
<command>nsupdate</command>
uses UDP to send update requests to the name server.
@@ -544,9 +537,6 @@ base-64 encoding of HMAC-MD5 key created by
<refentrytitle>RFC2535</refentrytitle>
</citerefentry>,
<citerefentry>
<refentrytitle>RFC2931</refentrytitle>
</citerefentry>,
<citerefentry>
<refentrytitle>named</refentrytitle><manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>

View File

@@ -130,13 +130,13 @@ made and the replies received from the name server.</P
><P
>Transaction signatures can be used to authenticate the Dynamic DNS
updates.
These use the TSIG resource record type described in RFC2845 or the
SIG(0) record described in RFC3535 and RFC2931.
TSIG relies on a shared secret that should only be known to
These use the TSIG resource record type described in RFC2845.
The signatures rely on a shared secret that should only be known to
<B
CLASS="COMMAND"
>nsupdate</B
> and the name server.
>
and the name server.
Currently, the only supported encryption algorithm for TSIG is
HMAC-MD5, which is defined in RFC 2104.
Once other algorithms are defined for TSIG, applications will need to
@@ -160,8 +160,6 @@ CLASS="FILENAME"
so that the name server can associate the appropriate secret key
and algorithm with the IP address of the
client application that will be using TSIG authentication.
SIG(0) uses public key cryptography. To use a SIG(0) key, the public
key must be stored in a KEY record in a zone served by the name server.
<B
CLASS="COMMAND"
>nsupdate</B
@@ -186,8 +184,8 @@ or
CLASS="OPTION"
>-k</TT
>
option (with an HMAC-MD5 key) to provide the shared secret needed to generate
a TSIG record for authenticating Dynamic DNS update requests.
option to provide the shared secret needed to generate a TSIG record
for authenticating Dynamic DNS update requests.
These options are mutually exclusive.
With the
<TT
@@ -261,13 +259,6 @@ CLASS="REFENTRYTITLE"
>
or in a history file maintained by the user's shell.</P
><P
>The <TT
CLASS="OPTION"
>-k</TT
> may also be used to specify a SIG(0) key used
to authenticate Dynamic DNS update requests. In this case, the key
specified is not an HMAC-MD5 key.</P
><P
>By default
<B
CLASS="COMMAND"
@@ -290,7 +281,7 @@ This may be preferable when a batch of update requests is made.</P
><DIV
CLASS="REFSECT1"
><A
NAME="AEN67"
NAME="AEN65"
></A
><H2
>INPUT FORMAT</H2
@@ -761,7 +752,7 @@ CLASS="COMMAND"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN225"
NAME="AEN223"
></A
><H2
>EXAMPLES</H2
@@ -832,7 +823,7 @@ SIG, KEY and NXT records.)</P
><DIV
CLASS="REFSECT1"
><A
NAME="AEN238"
NAME="AEN236"
></A
><H2
>FILES</H2
@@ -888,7 +879,7 @@ CLASS="REFENTRYTITLE"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN262"
NAME="AEN260"
></A
><H2
>SEE ALSO</H2
@@ -939,13 +930,6 @@ CLASS="REFENTRYTITLE"
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>RFC2931</SPAN
></SPAN
>,
<SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>named</SPAN
>(8)</SPAN
>,
@@ -960,7 +944,7 @@ CLASS="REFENTRYTITLE"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN285"
NAME="AEN281"
></A
><H2
>BUGS</H2

View File

@@ -42,7 +42,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/lwres/win32/include/lwres" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/lwres/win32/include/lwres" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
@@ -50,7 +50,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
# ADD LINK32 ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/lwres/win32/Release/liblwres.lib user32.lib advapi32.lib ws2_32.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/nsupdate.exe"
# ADD LINK32 ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/lwres/win32/Release/liblwres.lib user32.lib advapi32.lib ws2_32.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/nsupdate.exe"
!ELSEIF "$(CFG)" == "nsupdate - Win32 Debug"
@@ -66,7 +66,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/lwres/win32/include/lwres" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/lwres/win32/include/lwres" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# SUBTRACT CPP /X /u /YX
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
@@ -75,7 +75,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/lwres/win32/Debug/liblwres.lib user32.lib advapi32.lib ws2_32.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/nsupdate.exe" /pdbtype:sept
# ADD LINK32 ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/lwres/win32/Debug/liblwres.lib user32.lib advapi32.lib ws2_32.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/nsupdate.exe" /pdbtype:sept
!ENDIF

View File

@@ -25,29 +25,15 @@ NULL=
NULL=nul
!ENDIF
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "nsupdate - Win32 Release"
OUTDIR=.\Release
INTDIR=.\Release
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Release\nsupdate.exe"
!ELSE
ALL : "libbind9 - Win32 Release" "libisc - Win32 Release" "libdns - Win32 Release" "..\..\..\Build\Release\nsupdate.exe"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 ReleaseCLEAN" "libisc - Win32 ReleaseCLEAN" "libbind9 - Win32 ReleaseCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\nsupdate.obj"
-@erase "$(INTDIR)\vc60.idb"
-@erase "..\..\..\Build\Release\nsupdate.exe"
@@ -55,84 +41,8 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/lwres/win32/include/lwres" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\nsupdate.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\nsupdate.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/lwres/win32/Release/liblwres.lib user32.lib advapi32.lib ws2_32.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\nsupdate.pdb" /machine:I386 /out:"../../../Build/Release/nsupdate.exe"
LINK32_OBJS= \
"$(INTDIR)\nsupdate.obj" \
"..\..\..\lib\dns\win32\Release\libdns.lib" \
"..\..\..\lib\isc\win32\Release\libisc.lib" \
"..\..\..\lib\bind9\win32\Release\libbind9.lib"
"..\..\..\Build\Release\nsupdate.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "nsupdate - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Debug\nsupdate.exe" "$(OUTDIR)\nsupdate.bsc"
!ELSE
ALL : "libbind9 - Win32 Debug" "libisc - Win32 Debug" "libdns - Win32 Debug" "..\..\..\Build\Debug\nsupdate.exe" "$(OUTDIR)\nsupdate.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libdns - Win32 DebugCLEAN" "libisc - Win32 DebugCLEAN" "libbind9 - Win32 DebugCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\nsupdate.obj"
-@erase "$(INTDIR)\nsupdate.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\nsupdate.bsc"
-@erase "$(OUTDIR)\nsupdate.pdb"
-@erase "..\..\..\Build\Debug\nsupdate.exe"
-@erase "..\..\..\Build\Debug\nsupdate.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/lwres/win32/include/lwres" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\nsupdate.bsc"
BSC32_SBRS= \
"$(INTDIR)\nsupdate.sbr"
"$(OUTDIR)\nsupdate.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/lwres/win32/Debug/liblwres.lib user32.lib advapi32.lib ws2_32.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\nsupdate.pdb" /debug /machine:I386 /out:"../../../Build/Debug/nsupdate.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\nsupdate.obj" \
"..\..\..\lib\dns\win32\Debug\libdns.lib" \
"..\..\..\lib\isc\win32\Debug\libisc.lib" \
"..\..\..\lib\bind9\win32\Debug\libbind9.lib"
"..\..\..\Build\Debug\nsupdate.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
CPP=cl.exe
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/lwres/win32/include/lwres" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "__STDC__" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\nsupdate.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
@@ -164,6 +74,101 @@ LINK32_OBJS= \
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\nsupdate.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/lwres/win32/Release/liblwres.lib user32.lib advapi32.lib ws2_32.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\nsupdate.pdb" /machine:I386 /out:"../../../Build/Release/nsupdate.exe"
LINK32_OBJS= \
"$(INTDIR)\nsupdate.obj"
"..\..\..\Build\Release\nsupdate.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "nsupdate - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
ALL : "..\..\..\Build\Debug\nsupdate.exe" "$(OUTDIR)\nsupdate.bsc"
CLEAN :
-@erase "$(INTDIR)\nsupdate.obj"
-@erase "$(INTDIR)\nsupdate.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\nsupdate.bsc"
-@erase "$(OUTDIR)\nsupdate.pdb"
-@erase "..\..\..\Build\Debug\nsupdate.exe"
-@erase "..\..\..\Build\Debug\nsupdate.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../include" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/lwres/win32/include" /I "../../../lib/lwres/include" /I "../../../lib/lwres/win32/include/lwres" /I "../../../lib/dns/include" /I "../../../lib/dns/sec/dst/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\nsupdate.bsc"
BSC32_SBRS= \
"$(INTDIR)\nsupdate.sbr"
"$(OUTDIR)\nsupdate.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/lwres/win32/Debug/liblwres.lib user32.lib advapi32.lib ws2_32.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\nsupdate.pdb" /debug /machine:I386 /out:"../../../Build/Debug/nsupdate.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\nsupdate.obj"
"..\..\..\Build\Debug\nsupdate.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("nsupdate.dep")
@@ -193,84 +198,6 @@ SOURCE=..\nsupdate.c
!ENDIF
!IF "$(CFG)" == "nsupdate - Win32 Release"
"libdns - Win32 Release" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release"
cd "..\..\..\bin\nsupdate\win32"
"libdns - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\nsupdate\win32"
!ELSEIF "$(CFG)" == "nsupdate - Win32 Debug"
"libdns - Win32 Debug" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug"
cd "..\..\..\bin\nsupdate\win32"
"libdns - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\dns\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libdns.mak" CFG="libdns - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\nsupdate\win32"
!ENDIF
!IF "$(CFG)" == "nsupdate - Win32 Release"
"libisc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release"
cd "..\..\..\bin\nsupdate\win32"
"libisc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\nsupdate\win32"
!ELSEIF "$(CFG)" == "nsupdate - Win32 Debug"
"libisc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug"
cd "..\..\..\bin\nsupdate\win32"
"libisc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\nsupdate\win32"
!ENDIF
!IF "$(CFG)" == "nsupdate - Win32 Release"
"libbind9 - Win32 Release" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release"
cd "..\..\..\bin\nsupdate\win32"
"libbind9 - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\nsupdate\win32"
!ELSEIF "$(CFG)" == "nsupdate - Win32 Debug"
"libbind9 - Win32 Debug" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug"
cd "..\..\..\bin\nsupdate\win32"
"libbind9 - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\nsupdate\win32"
!ENDIF
!ENDIF

View File

@@ -1,4 +1,4 @@
# Copyright (C) 2000, 2001 Internet Software Consortium.
# Copyright (C) 2000-2002 Internet Software Consortium.
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
@@ -13,7 +13,7 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.37 2001/11/21 02:19:02 gson Exp $
# $Id: Makefile.in,v 1.32.2.3 2002/02/12 12:02:03 marka Exp $
srcdir = @srcdir@
VPATH = @srcdir@
@@ -21,10 +21,10 @@ top_srcdir = @top_srcdir@
@BIND9_VERSION@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = -I${srcdir}/include ${ISC_INCLUDES} ${ISCCC_INCLUDES} \
${ISCCFG_INCLUDES} ${DNS_INCLUDES} ${BIND9_INCLUDES}
${ISCCFG_INCLUDES} ${DNS_INCLUDES}
CDEFINES =
CWARNINGS =
@@ -32,17 +32,15 @@ CWARNINGS =
ISCCFGLIBS = ../../lib/isccfg/libisccfg.@A@
ISCCCLIBS = ../../lib/isccc/libisccc.@A@
ISCLIBS = ../../lib/isc/libisc.@A@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
BIND9LIBS = ../../lib/bind9/libbind9.@A@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCCFGDEPLIBS = ../../lib/isccfg/libisccfg.@A@
ISCCCDEPLIBS = ../../lib/isccc/libisccc.@A@
ISCDEPLIBS = ../../lib/isc/libisc.@A@
DNSDEPLIBS = ../../lib/dns/libdns.@A@
BIND9DEPLIBS = ../../lib/bind9/libbind9.@A@
RNDCLIBS = ${ISCCFGLIBS} ${ISCCCLIBS} ${BIND9LIBS} ${DNSLIBS} ${ISCLIBS} @LIBS@
RNDCDEPLIBS = ${ISCCFGDEPLIBS} ${ISCCCDEPLIBS} ${BIND9DEPLIBS} ${DNSDEPLIBS} ${ISCDEPLIBS}
RNDCLIBS = ${ISCCFGLIBS} ${DNSLIBS} ${ISCCCLIBS} ${ISCLIBS} @LIBS@
RNDCDEPLIBS = ${ISCCFGDEPLIBS} ${DNSDEPLIBS} ${ISCCCDEPLIBS} ${ISCDEPLIBS}
CONFLIBS = ${DNSLIBS} ${ISCLIBS} @LIBS@
CONFDEPLIBS = ${DNSDEPLIBS} ${ISCDEPLIBS}

View File

@@ -1,5 +1,4 @@
.\"
.\" Copyright (C) 2000, 2001 Internet Software Consortium.
.\" Copyright (C) 2001 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
@@ -14,6 +13,8 @@
.\" NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
.\" WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: rndc-confgen.8,v 1.3.2.1 2002/02/08 03:57:20 marka Exp $
.TH "RNDC-CONFGEN" "8" "Aug 27, 2001" "BIND9" ""
.SH NAME
rndc-confgen \- rndc key generation tool
@@ -46,23 +47,13 @@ and \fBnamed\fR on startup. The
\fIrndc.key\fR file defines a default
command channel and authentication key allowing
\fBrndc\fR to communicate with
\fBnamed\fR on the local host
with no further configuration.
\fBnamed\fR with no further configuration.
Running \fBrndc-confgen -a\fR allows
BIND 9 and \fBrndc\fR to be used as drop-in
replacements for BIND 8 and \fBndc\fR,
with no changes to the existing BIND 8
\fInamed.conf\fR file.
If a more elaborate configuration than that
generated by \fBrndc-confgen -a\fR
is required, for example if rndc is to be used remotely,
you should run \fBrndc-confgen\fR without the
\fB-a\fR option and set up a
\fIrndc.conf\fR and
\fInamed.conf\fR
as directed.
.TP
\fB-b \fIkeysize\fB\fR
Specifies the size of the authentication key in bits.

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: rndc-confgen.c,v 1.15 2001/11/30 01:09:11 gson Exp $ */
/* $Id: rndc-confgen.c,v 1.9.2.4 2001/11/30 01:10:09 gson Exp $ */
#include <config.h>
@@ -115,7 +115,6 @@ write_key_file(const char *keyfile, const char *user,
fprintf(stderr, "fclose(%s) failed\n", keyfile);
return;
}
fprintf(stderr, "wrote key file \"%s\"\n", keyfile);
}
int
@@ -182,7 +181,7 @@ main(int argc, char **argv) {
keyname = isc_commandline_argument;
break;
case 'M':
isc_mem_debugging = ISC_MEM_DEBUGTRACE;
isc_mem_debugging = 1;
break;
case 'm':

View File

@@ -16,7 +16,7 @@
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: rndc-confgen.docbook,v 1.4 2001/09/11 19:18:11 gson Exp $ -->
<!-- $Id: rndc-confgen.docbook,v 1.3 2001/08/29 03:27:57 marka Exp $ -->
<refentry>
<refentryinfo>
@@ -86,8 +86,7 @@
<filename>rndc.key</filename> file defines a default
command channel and authentication key allowing
<command>rndc</command> to communicate with
<command>named</command> on the local host
with no further configuration.
<command>named</command> with no further configuration.
</para>
<para>
Running <command>rndc-confgen -a</command> allows
@@ -96,16 +95,6 @@
with no changes to the existing BIND 8
<filename>named.conf</filename> file.
</para>
<para>
If a more elaborate configuration than that
generated by <command>rndc-confgen -a</command>
is required, for example if rndc is to be used remotely,
you should run <command>rndc-confgen</command> without the
<command>-a</command> option and set up a
<filename>rndc.conf</filename> and
<filename>named.conf</filename>
as directed.
</para>
</listitem>
</varlistentry>

View File

@@ -1,10 +1,10 @@
<!--
- Copyright (C) 2000, 2001 Internet Software Consortium.
-
- Copyright (C) 2001 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
-
- THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM
- DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL
@@ -14,6 +14,9 @@
- NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
- WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: rndc-confgen.html,v 1.3.2.1 2002/02/08 03:57:21 marka Exp $ -->
<HTML
><HEAD
><TITLE
@@ -238,8 +241,7 @@ CLASS="COMMAND"
<B
CLASS="COMMAND"
>named</B
> on the local host
with no further configuration.
> with no further configuration.
</P
><P
> Running <B
@@ -260,31 +262,6 @@ CLASS="FILENAME"
>named.conf</TT
> file.
</P
><P
> If a more elaborate configuration than that
generated by <B
CLASS="COMMAND"
>rndc-confgen -a</B
>
is required, for example if rndc is to be used remotely,
you should run <B
CLASS="COMMAND"
>rndc-confgen</B
> without the
<B
CLASS="COMMAND"
>-a</B
> option and set up a
<TT
CLASS="FILENAME"
>rndc.conf</TT
> and
<TT
CLASS="FILENAME"
>named.conf</TT
>
as directed.
</P
></DD
><DT
>-b <TT
@@ -474,7 +451,7 @@ CLASS="COMMAND"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN147"
NAME="AEN141"
></A
><H2
>EXAMPLES</H2
@@ -523,7 +500,7 @@ CLASS="USERINPUT"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN160"
NAME="AEN154"
></A
><H2
>SEE ALSO</H2
@@ -558,7 +535,7 @@ CLASS="CITETITLE"
><DIV
CLASS="REFSECT1"
><A
NAME="AEN173"
NAME="AEN167"
></A
><H2
>AUTHOR</H2

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: rndc.c,v 1.91 2002/01/30 00:20:50 bwelling Exp $ */
/* $Id: rndc.c,v 1.77.2.2 2001/11/28 23:37:50 gson Exp $ */
/*
* Principal Author: DCL
@@ -31,6 +31,7 @@
#include <isc/file.h>
#include <isc/log.h>
#include <isc/mem.h>
#include <isc/netdb.h>
#include <isc/socket.h>
#include <isc/stdtime.h>
#include <isc/string.h>
@@ -38,7 +39,7 @@
#include <isc/thread.h>
#include <isc/util.h>
#include <isccfg/namedconf.h>
#include <isccfg/cfg.h>
#include <isccc/alist.h>
#include <isccc/base64.h>
@@ -49,11 +50,21 @@
#include <isccc/types.h>
#include <isccc/util.h>
#include <bind9/getaddresses.h>
#include "util.h"
#define SERVERADDRS 10
#ifdef HAVE_ADDRINFO
#ifdef HAVE_GETADDRINFO
#ifdef HAVE_GAISTRERROR
#define USE_GETADDRINFO
#endif
#endif
#endif
#ifndef USE_GETADDRINFO
#ifndef ISC_PLATFORM_NONSTDHERRNO
extern int h_errno;
#endif
#endif
char *progname;
isc_boolean_t verbose;
@@ -62,9 +73,6 @@ static const char *admin_conffile;
static const char *admin_keyfile;
static const char *version = VERSION;
static const char *servername = NULL;
static isc_sockaddr_t serveraddrs[SERVERADDRS];
static int nserveraddrs;
static int currentaddr = 0;
static unsigned int remoteport = 0;
static isc_socketmgr_t *socketmgr = NULL;
static unsigned char databuf[2048];
@@ -78,8 +86,6 @@ static char *args;
static char program[256];
static isc_socket_t *sock = NULL;
static void rndc_startconnect(isc_sockaddr_t *addr, isc_task_t *task);
static void
usage(int status) {
fprintf(stderr, "\
@@ -93,29 +99,17 @@ command is one of the following:\n\
Reload a single zone.\n\
refresh zone [class [view]]\n\
Schedule immediate maintenance for a zone.\n\
retransfer zone [class [view]]\n\
Retransfer a single zone without checking serial number.\n\
freeze zone [class [view]]\n\
Suspend updates to a dynamic zone.\n\
unfreeze zone [class [view]]\n\
Enable updates to a frozen dynamic zone and reload it.\n\
reconfig Reload configuration file and new zones only.\n\
stats Write server statistics to the statistics file.\n\
querylog Toggle query logging.\n\
dumpdb Dump cache(s) to the dump file (named_dump.db).\n\
stop Save pending updates to master files and stop the server.\n\
stop -p Save pending updates to master files and stop the server\n\
reporting process id.\n\
halt Stop the server without saving pending updates.\n\
halt -p Stop the server without saving pending updates reporting\n\
process id.\n\
trace Increment debugging level by one.\n\
trace level Change the debugging level.\n\
notrace Set debugging level to 0.\n\
flush Flushes all of the server's caches.\n\
flush [view] Flushes the server's cache for a view.\n\
flushname name [view]\n\
Flush the give name from the server's cache(s)\n\
status Display status of the server.\n\
*restart Restart the server.\n\
\n\
@@ -127,17 +121,60 @@ Version: %s\n",
}
static void
get_addresses(const char *host, in_port_t port) {
isc_result_t result;
get_address(const char *host, in_port_t port, isc_sockaddr_t *sockaddr) {
struct in_addr in4;
struct in6_addr in6;
isc_boolean_t have_ipv6;
#ifdef USE_GETADDRINFO
struct addrinfo *res = NULL, hints;
int result;
#else
struct hostent *he;
#endif
isc_app_block();
result = bind9_getaddresses(servername, port,
serveraddrs, SERVERADDRS, &nserveraddrs);
isc_app_unblock();
if (result != ISC_R_SUCCESS)
fatal("couldn't get address for '%s': %s",
host, isc_result_totext(result));
INSIST(nserveraddrs > 0);
have_ipv6 = ISC_TF(isc_net_probeipv6() == ISC_R_SUCCESS);
/*
* Assume we have v4 if we don't have v6, since setup_libs
* fatal()'s out if we don't have either.
*/
if (have_ipv6 && inet_pton(AF_INET6, host, &in6) == 1)
isc_sockaddr_fromin6(sockaddr, &in6, port);
else if (inet_pton(AF_INET, host, &in4) == 1)
isc_sockaddr_fromin(sockaddr, &in4, port);
else {
#ifdef USE_GETADDRINFO
memset(&hints, 0, sizeof(hints));
if (!have_ipv6)
hints.ai_family = PF_INET;
else if (isc_net_probeipv4() != ISC_R_SUCCESS)
hints.ai_family = PF_INET6;
else
hints.ai_family = PF_UNSPEC;
hints.ai_socktype = SOCK_STREAM;
isc_app_block();
result = getaddrinfo(host, NULL, &hints, &res);
isc_app_unblock();
if (result != 0)
fatal("Couldn't find server '%s': %s",
host, gai_strerror(result));
memcpy(&sockaddr->type.sa, res->ai_addr, res->ai_addrlen);
sockaddr->length = res->ai_addrlen;
isc_sockaddr_setport(sockaddr, port);
freeaddrinfo(res);
#else
isc_app_block();
he = gethostbyname(host);
isc_app_unblock();
if (he == NULL)
fatal("Couldn't find server '%s' (h_errno=%d)",
host, h_errno);
INSIST(he->h_addrtype == AF_INET);
isc_sockaddr_fromin(sockaddr,
(struct in_addr *)(he->h_addr_list[0]),
port);
#endif
}
}
static void
@@ -202,7 +239,7 @@ rndc_recvdone(isc_task_t *task, isc_event_t *event) {
isccc_sexpr_free(&response);
isc_socket_detach(&sock);
isc_task_shutdown(task);
RUNTIME_CHECK(isc_app_shutdown() == ISC_R_SUCCESS);
isc_app_shutdown();
}
static void
@@ -219,20 +256,8 @@ rndc_connected(isc_task_t *task, isc_event_t *event) {
connects--;
if (sevent->result != ISC_R_SUCCESS) {
if (sevent->result != ISC_R_CANCELED &&
currentaddr < nserveraddrs)
{
notify("connection failed: %s",
isc_result_totext(sevent->result));
isc_socket_detach(&sock);
isc_event_free(&event);
rndc_startconnect(&serveraddrs[currentaddr++], task);
return;
} else
fatal("connect failed: %s",
isc_result_totext(sevent->result));
}
if (sevent->result != ISC_R_SUCCESS)
fatal("connect failed: %s", isc_result_totext(sevent->result));
isc_stdtime_get(&now);
srandom(now + isc_thread_self());
@@ -266,33 +291,27 @@ rndc_connected(isc_task_t *task, isc_event_t *event) {
}
static void
rndc_startconnect(isc_sockaddr_t *addr, isc_task_t *task) {
rndc_start(isc_task_t *task, isc_event_t *event) {
isc_sockaddr_t addr;
isc_result_t result;
char socktext[ISC_SOCKADDR_FORMATSIZE];
isc_sockaddr_format(addr, socktext, sizeof(socktext));
isc_event_free(&event);
get_address(servername, (in_port_t) remoteport, &addr);
isc_sockaddr_format(&addr, socktext, sizeof(socktext));
notify("using server %s (%s)", servername, socktext);
DO("create socket", isc_socket_create(socketmgr,
isc_sockaddr_pf(addr),
isc_sockaddr_pf(&addr),
isc_sockettype_tcp, &sock));
DO("connect", isc_socket_connect(sock, addr, task, rndc_connected,
DO("connect", isc_socket_connect(sock, &addr, task, rndc_connected,
NULL));
connects++;
}
static void
rndc_start(isc_task_t *task, isc_event_t *event) {
isc_event_free(&event);
get_addresses(servername, (in_port_t) remoteport);
currentaddr = 0;
rndc_startconnect(&serveraddrs[currentaddr++], task);
}
static void
parse_config(isc_mem_t *mctx, isc_log_t *log, const char *keyname,
cfg_parser_t **pctxp, cfg_obj_t **configp)
@@ -351,7 +370,7 @@ parse_config(isc_mem_t *mctx, isc_log_t *log, const char *keyname,
fatal("no server specified and no default");
if (!key_only) {
(void)cfg_map_get(config, "server", &servers);
cfg_map_get(config, "server", &servers);
if (servers != NULL) {
for (elt = cfg_list_first(servers);
elt != NULL;
@@ -427,7 +446,7 @@ parse_config(isc_mem_t *mctx, isc_log_t *log, const char *keyname,
if (server != NULL)
(void)cfg_map_get(server, "port", &defport);
if (defport == NULL && options != NULL)
(void)cfg_map_get(options, "default-port", &defport);
cfg_map_get(options, "default-port", &defport);
}
if (defport != NULL) {
remoteport = cfg_obj_asuint32(defport);
@@ -464,9 +483,7 @@ main(int argc, char **argv) {
admin_conffile = RNDC_CONFFILE;
admin_keyfile = RNDC_KEYFILE;
result = isc_app_start();
if (result != ISC_R_SUCCESS)
fatal("isc_app_start() failed: %s", isc_result_totext(result));
isc_app_start();
while ((ch = isc_commandline_parse(argc, argv, "c:k:Mmp:s:Vy:"))
!= -1) {
@@ -480,7 +497,7 @@ main(int argc, char **argv) {
break;
case 'M':
isc_mem_debugging = ISC_MEM_DEBUGTRACE;
isc_mem_debugging = 1;
break;
case 'm':
@@ -576,9 +593,7 @@ main(int argc, char **argv) {
DO("post event", isc_app_onrun(mctx, task, rndc_start, NULL));
result = isc_app_run();
if (result != ISC_R_SUCCESS)
fatal("isc_app_run() failed: %s", isc_result_totext(result));
isc_app_run();
if (connects > 0 || sends > 0 || recvs > 0)
isc_socket_cancel(sock, task, ISC_SOCKCANCEL_ALL);

View File

@@ -1,4 +1 @@
Makefile
.libs
*.la
*.lo

View File

@@ -13,13 +13,13 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.2 2001/09/20 15:16:30 marka Exp $
# $Id: Makefile.in,v 1.1 2001/08/03 05:56:22 marka Exp $
srcdir = @srcdir@
VPATH = @srcdir@
top_srcdir = @top_srcdir@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = -I${srcdir}/include -I${srcdir}/../include \
${DNS_INCLUDES} ${ISC_INCLUDES}

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: os.c,v 1.3 2001/11/18 06:21:35 mayer Exp $ */
/* $Id: os.c,v 1.2 2001/08/08 23:26:58 gson Exp $ */
#include <config.h>
@@ -26,7 +26,6 @@
#include <sys/types.h>
#include <errno.h>
#include <stdio.h>
#include <io.h>
#include <sys/stat.h>
int

View File

@@ -42,7 +42,7 @@ RSC=rc.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccc/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccc/include" /I "../../../lib/isccfg/include" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
@@ -50,7 +50,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccfg/win32/Release/libisccfg.lib ../../../lib/isccc/win32/Release/libisccc.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /profile /machine:I386 /out:"../../../Build/Release/rndc.exe"
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccfg/win32/Release/libisccfg.lib ../../../lib/isccc/win32/Release/libisccc.lib /nologo /subsystem:console /machine:I386 /out:"../../../Build/Release/rndc.exe"
!ELSEIF "$(CFG)" == "rndc - Win32 Debug"
@@ -66,7 +66,7 @@ LINK32=link.exe
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccc/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccc/include" /I "../../../lib/isccfg/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR /FD /GZ /c
# SUBTRACT CPP /X /YX
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
@@ -75,7 +75,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib ../../../lib/isccc/win32/Debug/libisccc.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/rndc.exe" /pdbtype:sept
# ADD LINK32 user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib ../../../lib/isccc/win32/Debug/libisccc.lib /nologo /subsystem:console /debug /machine:I386 /out:"../../../Build/Debug/rndc.exe" /pdbtype:sept
!ENDIF

View File

@@ -25,29 +25,15 @@ NULL=
NULL=nul
!ENDIF
CPP=cl.exe
RSC=rc.exe
!IF "$(CFG)" == "rndc - Win32 Release"
OUTDIR=.\Release
INTDIR=.\Release
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Release\rndc.exe"
!ELSE
ALL : "libbind9 - Win32 Release" "libisccfg - Win32 Release" "libisccc - Win32 Release" "libisc - Win32 Release" "..\..\..\Build\Release\rndc.exe"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libisc - Win32 ReleaseCLEAN" "libisccc - Win32 ReleaseCLEAN" "libisccfg - Win32 ReleaseCLEAN" "libbind9 - Win32 ReleaseCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\rndc.obj"
-@erase "$(INTDIR)\util.obj"
-@erase "$(INTDIR)\vc60.idb"
@@ -56,91 +42,8 @@ CLEAN :
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccc/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\rndc.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\rndc.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccfg/win32/Release/libisccfg.lib ../../../lib/isccc/win32/Release/libisccc.lib ../../../lib/bind9/win32/Release/libbind9.lib /nologo /subsystem:console /profile /machine:I386 /out:"../../../Build/Release/rndc.exe"
LINK32_OBJS= \
"$(INTDIR)\rndc.obj" \
"$(INTDIR)\util.obj" \
"..\..\..\lib\isc\win32\Release\libisc.lib" \
"..\..\..\lib\isccc\win32\Release\libisccc.lib" \
"..\..\..\lib\isccfg\win32\Release\libisccfg.lib" \
"..\..\..\lib\bind9\win32\Release\libbind9.lib"
"..\..\..\Build\Release\rndc.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "rndc - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
!IF "$(RECURSE)" == "0"
ALL : "..\..\..\Build\Debug\rndc.exe" "$(OUTDIR)\rndc.bsc"
!ELSE
ALL : "libbind9 - Win32 Debug" "libisccfg - Win32 Debug" "libisccc - Win32 Debug" "libisc - Win32 Debug" "..\..\..\Build\Debug\rndc.exe" "$(OUTDIR)\rndc.bsc"
!ENDIF
!IF "$(RECURSE)" == "1"
CLEAN :"libisc - Win32 DebugCLEAN" "libisccc - Win32 DebugCLEAN" "libisccfg - Win32 DebugCLEAN" "libbind9 - Win32 DebugCLEAN"
!ELSE
CLEAN :
!ENDIF
-@erase "$(INTDIR)\rndc.obj"
-@erase "$(INTDIR)\rndc.sbr"
-@erase "$(INTDIR)\util.obj"
-@erase "$(INTDIR)\util.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\rndc.bsc"
-@erase "$(OUTDIR)\rndc.pdb"
-@erase "..\..\..\Build\Debug\rndc.exe"
-@erase "..\..\..\Build\Debug\rndc.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccc/include" /I "../../../lib/isccfg/include" /I "../../../lib/bind9/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\rndc.bsc"
BSC32_SBRS= \
"$(INTDIR)\rndc.sbr" \
"$(INTDIR)\util.sbr"
"$(OUTDIR)\rndc.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib ../../../lib/isccc/win32/Debug/libisccc.lib ../../../lib/bind9/win32/Debug/libbind9.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\rndc.pdb" /debug /machine:I386 /out:"../../../Build/Debug/rndc.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\rndc.obj" \
"$(INTDIR)\util.obj" \
"..\..\..\lib\isc\win32\Debug\libisc.lib" \
"..\..\..\lib\isccc\win32\Debug\libisccc.lib" \
"..\..\..\lib\isccfg\win32\Debug\libisccfg.lib" \
"..\..\..\lib\bind9\win32\Debug\libbind9.lib"
"..\..\..\Build\Debug\rndc.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
CPP=cl.exe
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccc/include" /I "../../../lib/isccfg/include" /D "WIN32" /D "NDEBUG" /D "__STDC__" /D "_CONSOLE" /D "_MBCS" /Fp"$(INTDIR)\rndc.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
@@ -172,6 +75,106 @@ LINK32_OBJS= \
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\rndc.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Release/libisc.lib ../../../lib/dns/win32/Release/libdns.lib ../../../lib/isccfg/win32/Release/libisccfg.lib ../../../lib/isccc/win32/Release/libisccc.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\rndc.pdb" /machine:I386 /out:"../../../Build/Release/rndc.exe"
LINK32_OBJS= \
"$(INTDIR)\rndc.obj" \
"$(INTDIR)\util.obj"
"..\..\..\Build\Release\rndc.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "rndc - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
ALL : "..\..\..\Build\Debug\rndc.exe" "$(OUTDIR)\rndc.bsc"
CLEAN :
-@erase "$(INTDIR)\rndc.obj"
-@erase "$(INTDIR)\rndc.sbr"
-@erase "$(INTDIR)\util.obj"
-@erase "$(INTDIR)\util.sbr"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\rndc.bsc"
-@erase "$(OUTDIR)\rndc.pdb"
-@erase "..\..\..\Build\Debug\rndc.exe"
-@erase "..\..\..\Build\Debug\rndc.ilk"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MTd /W3 /Gm /GX /ZI /Od /I "./" /I "../../../" /I "../../../lib/isc/win32" /I "../../../lib/isc/win32/include" /I "../../../lib/isc/include" /I "../../../lib/isccc/include" /I "../../../lib/isccfg/include" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"$(INTDIR)\\" /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
RSC=rc.exe
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\rndc.bsc"
BSC32_SBRS= \
"$(INTDIR)\rndc.sbr" \
"$(INTDIR)\util.sbr"
"$(OUTDIR)\rndc.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
$(BSC32) @<<
$(BSC32_FLAGS) $(BSC32_SBRS)
<<
LINK32=link.exe
LINK32_FLAGS=user32.lib advapi32.lib ws2_32.lib ../../../lib/isc/win32/Debug/libisc.lib ../../../lib/dns/win32/Debug/libdns.lib ../../../lib/isccfg/win32/Debug/libisccfg.lib ../../../lib/isccc/win32/Debug/libisccc.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\rndc.pdb" /debug /machine:I386 /out:"../../../Build/Debug/rndc.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\rndc.obj" \
"$(INTDIR)\util.obj"
"..\..\..\Build\Debug\rndc.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("rndc.dep")
@@ -219,110 +222,6 @@ SOURCE=..\util.c
!ENDIF
!IF "$(CFG)" == "rndc - Win32 Release"
"libisc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release"
cd "..\..\..\bin\rndc\win32"
"libisc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\rndc\win32"
!ELSEIF "$(CFG)" == "rndc - Win32 Debug"
"libisc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug"
cd "..\..\..\bin\rndc\win32"
"libisc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisc.mak" CFG="libisc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\rndc\win32"
!ENDIF
!IF "$(CFG)" == "rndc - Win32 Release"
"libisccc - Win32 Release" :
cd "\bind-9.3.0a03\lib\isccc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccc.mak" CFG="libisccc - Win32 Release"
cd "..\..\..\bin\rndc\win32"
"libisccc - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isccc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccc.mak" CFG="libisccc - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\rndc\win32"
!ELSEIF "$(CFG)" == "rndc - Win32 Debug"
"libisccc - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isccc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccc.mak" CFG="libisccc - Win32 Debug"
cd "..\..\..\bin\rndc\win32"
"libisccc - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isccc\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccc.mak" CFG="libisccc - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\rndc\win32"
!ENDIF
!IF "$(CFG)" == "rndc - Win32 Release"
"libisccfg - Win32 Release" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Release"
cd "..\..\..\bin\rndc\win32"
"libisccfg - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\rndc\win32"
!ELSEIF "$(CFG)" == "rndc - Win32 Debug"
"libisccfg - Win32 Debug" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Debug"
cd "..\..\..\bin\rndc\win32"
"libisccfg - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\isccfg\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libisccfg.mak" CFG="libisccfg - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\rndc\win32"
!ENDIF
!IF "$(CFG)" == "rndc - Win32 Release"
"libbind9 - Win32 Release" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release"
cd "..\..\..\bin\rndc\win32"
"libbind9 - Win32 ReleaseCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Release" RECURSE=1 CLEAN
cd "..\..\..\bin\rndc\win32"
!ELSEIF "$(CFG)" == "rndc - Win32 Debug"
"libbind9 - Win32 Debug" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug"
cd "..\..\..\bin\rndc\win32"
"libbind9 - Win32 DebugCLEAN" :
cd "\bind-9.3.0a03\lib\bind9\win32"
$(MAKE) /$(MAKEFLAGS) /F ".\libbind9.mak" CFG="libbind9 - Win32 Debug" RECURSE=1 CLEAN
cd "..\..\..\bin\rndc\win32"
!ENDIF
!ENDIF

View File

@@ -1,4 +1,4 @@
# Copyright (C) 1998-2001 Internet Software Consortium.
# Copyright (C) 1998-2002 Internet Software Consortium.
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
@@ -13,13 +13,13 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.116 2001/11/06 20:05:05 bwelling Exp $
# $Id: Makefile.in,v 1.113.2.1 2002/02/12 12:02:05 marka Exp $
srcdir = @srcdir@
VPATH = @srcdir@
top_srcdir = @top_srcdir@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = ${DNS_INCLUDES} ${ISC_INCLUDES} ${ISCCFG_INCLUDES} \
${LWRES_INCLUDES} ${OMAPI_INCLUDES}
@@ -27,7 +27,7 @@ CINCLUDES = ${DNS_INCLUDES} ${ISC_INCLUDES} ${ISCCFG_INCLUDES} \
CDEFINES =
CWARNINGS =
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
DNSLIBS = ../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCLIBS = ../../lib/isc/libisc.@A@
ISCCFGLIBS = ../../lib/isccfg/libisccfg.@A@
LWRESLIBS = ../../lib/lwres/liblwres.@A@
@@ -279,9 +279,9 @@ journalprint: journalprint.@O@ ${ISCDEPLIBS} ${DNSDEPLIBS}
${LIBTOOL} ${PURIFY} ${CC} ${CFLAGS} -o $@ journalprint.@O@ \
${DNSLIBS} ${ISCLIBS} ${LIBS}
cfg_test: cfg_test.@O@ ${ISCCFGDEPLIBS} ${ISCDEPLIBS}
cfg_test: cfg_test.@O@ ${ISCCFGDEPLIBS} ${DNSDEPLIBS} ${ISCDEPLIBS}
${LIBTOOL} ${CC} ${CFLAGS} -o $@ cfg_test.@O@ \
${ISCCFGLIBS} ${ISCLIBS} ${LIBS}
${ISCCFGLIBS} ${DNSLIBS} ${ISCLIBS} ${LIBS}
distclean::
rm -f headerdep_test.sh
@@ -290,8 +290,6 @@ clean distclean::
rm -f ${TARGETS} ${XTARGETS}
rm -f t_journal
check: test
test:
@for dir in $(SUBDIRS) ;\
do \

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: cfg_test.c,v 1.13 2002/01/04 02:32:07 gson Exp $ */
/* $Id: cfg_test.c,v 1.11.2.1 2001/10/22 23:52:19 gson Exp $ */
#include <config.h>
@@ -26,7 +26,7 @@
#include <isc/string.h>
#include <isc/util.h>
#include <isccfg/namedconf.h>
#include <isccfg/cfg.h>
#include <dns/log.h>

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: compress_test.c,v 1.26 2001/11/27 01:55:13 gson Exp $ */
/* $Id: compress_test.c,v 1.24 2001/01/09 21:40:56 bwelling Exp $ */
#include <config.h>
@@ -72,42 +72,42 @@ main(int argc, char *argv[]) {
dns_name_init(&name1, NULL);
region.base = plain1;
region.length = sizeof(plain1);
region.length = sizeof plain1;
dns_name_fromregion(&name1, &region);
dns_name_init(&name2, NULL);
region.base = plain2;
region.length = sizeof(plain2);
region.length = sizeof plain2;
dns_name_fromregion(&name2, &region);
dns_name_init(&name3, NULL);
region.base = plain3;
region.length = sizeof(plain3);
region.length = sizeof plain3;
dns_name_fromregion(&name3, &region);
test(DNS_COMPRESS_NONE, &name1, &name2, &name3, plain, sizeof(plain));
test(DNS_COMPRESS_NONE, &name1, &name2, &name3, plain, sizeof plain);
test(DNS_COMPRESS_GLOBAL14, &name1, &name2, &name3, plain,
sizeof(plain));
test(DNS_COMPRESS_ALL, &name1, &name2, &name3, plain, sizeof(plain));
sizeof plain);
test(DNS_COMPRESS_ALL, &name1, &name2, &name3, plain, sizeof plain);
dns_name_init(&name1, NULL);
region.base = bit1;
region.length = sizeof(bit1);
region.length = sizeof bit1;
dns_name_fromregion(&name1, &region);
dns_name_init(&name2, NULL);
region.base = bit2;
region.length = sizeof(bit2);
region.length = sizeof bit2;
dns_name_fromregion(&name2, &region);
dns_name_init(&name3, NULL);
region.base = bit3;
region.length = sizeof(bit3);
region.length = sizeof bit3;
dns_name_fromregion(&name3, &region);
test(DNS_COMPRESS_NONE, &name1, &name2, &name3, bit, sizeof(bit));
test(DNS_COMPRESS_GLOBAL14, &name1, &name2, &name3, bit, sizeof(bit));
test(DNS_COMPRESS_ALL, &name1, &name2, &name3, bit, sizeof(bit));
test(DNS_COMPRESS_NONE, &name1, &name2, &name3, bit, sizeof bit);
test(DNS_COMPRESS_GLOBAL14, &name1, &name2, &name3, bit, sizeof bit);
test(DNS_COMPRESS_ALL, &name1, &name2, &name3, bit, sizeof bit);
return (0);
}
@@ -158,7 +158,7 @@ test(unsigned int allowed, dns_name_t *name1, dns_name_t *name2,
if (raw) {
unsigned int i;
for (i = 0; i < source.used; /* */ ) {
for (i = 0 ; i < source.used ; /* */ ) {
fprintf(stdout, "%02x",
((unsigned char *)source.base)[i]);
if ((++i % 20) == 0)
@@ -195,7 +195,7 @@ test(unsigned int allowed, dns_name_t *name1, dns_name_t *name2,
if (raw) {
unsigned int i;
for (i = 0; i < target.used; /* */ ) {
for (i = 0 ; i < target.used ; /* */ ) {
fprintf(stdout, "%02x",
((unsigned char *)target.base)[i]);
if ((++i % 20) == 0)

View File

@@ -13,20 +13,20 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.23 2001/11/06 20:05:06 bwelling Exp $
# $Id: Makefile.in,v 1.21 2001/08/01 22:06:09 gson Exp $
srcdir = @srcdir@
VPATH = @srcdir@
top_srcdir = @top_srcdir@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = ${TEST_INCLUDES} ${DNS_INCLUDES} ${ISC_INCLUDES}
CDEFINES =
CWARNINGS =
DNSLIBS = ../../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
DNSLIBS = ../../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCLIBS = ../../../lib/isc/libisc.@A@
DNSDEPLIBS = ../../../lib/dns/libdns.@A@

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: db_test.c,v 1.58 2001/11/30 01:58:56 gson Exp $ */
/* $Id: db_test.c,v 1.56 2001/01/09 21:40:57 bwelling Exp $ */
/*
* Principal Author: Bob Halley
@@ -248,7 +248,7 @@ load(const char *filename, const char *origintext, isc_boolean_t cache) {
dbinfo *dbi;
unsigned int i;
dbi = isc_mem_get(mctx, sizeof(*dbi));
dbi = isc_mem_get(mctx, sizeof *dbi);
if (dbi == NULL)
return (ISC_R_NOMEMORY);
@@ -281,7 +281,7 @@ load(const char *filename, const char *origintext, isc_boolean_t cache) {
dns_rdataclass_in,
0, NULL, &dbi->db);
if (result != ISC_R_SUCCESS) {
isc_mem_put(mctx, dbi, sizeof(*dbi));
isc_mem_put(mctx, dbi, sizeof *dbi);
return (result);
}
@@ -289,7 +289,7 @@ load(const char *filename, const char *origintext, isc_boolean_t cache) {
result = dns_db_load(dbi->db, filename);
if (result != ISC_R_SUCCESS && result != DNS_R_SEENINCLUDE) {
dns_db_detach(&dbi->db);
isc_mem_put(mctx, dbi, sizeof(*dbi));
isc_mem_put(mctx, dbi, sizeof *dbi);
return (result);
}
printf("loaded\n");
@@ -301,7 +301,7 @@ load(const char *filename, const char *origintext, isc_boolean_t cache) {
} else {
if (dns_dbtable_add(dbtable, dbi->db) != ISC_R_SUCCESS) {
dns_db_detach(&dbi->db);
isc_mem_put(mctx, dbi, sizeof(*dbi));
isc_mem_put(mctx, dbi, sizeof *dbi);
return (result);
}
}
@@ -325,7 +325,7 @@ unload_all(void) {
}
dns_db_detach(&dbi->db);
ISC_LIST_UNLINK(dbs, dbi, link);
isc_mem_put(mctx, dbi, sizeof(*dbi));
isc_mem_put(mctx, dbi, sizeof *dbi);
}
}
@@ -466,13 +466,13 @@ main(int argc, char *argv[]) {
version = NULL;
if (time_lookups) {
TIME_NOW(&start);
(void)isc_time_now(&start);
}
while (!done) {
if (!quiet)
printf("\n");
if (fgets(s, sizeof(s), stdin) == NULL) {
if (fgets(s, sizeof s, stdin) == NULL) {
done = ISC_TRUE;
continue;
}
@@ -923,7 +923,7 @@ main(int argc, char *argv[]) {
if (time_lookups) {
isc_uint64_t usec;
TIME_NOW(&finish);
(void)isc_time_now(&finish);
usec = isc_time_microdiff(&finish, &start);

View File

@@ -13,20 +13,20 @@
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.32 2001/11/06 20:05:07 bwelling Exp $
# $Id: Makefile.in,v 1.30 2001/08/01 22:06:10 gson Exp $
srcdir = @srcdir@
VPATH = @srcdir@
top_srcdir = @top_srcdir@
@BIND9_MAKE_INCLUDES@
@BIND9_INCLUDES@
CINCLUDES = ${TEST_INCLUDES} ${DNS_INCLUDES} ${ISC_INCLUDES}
CDEFINES =
CWARNINGS =
DNSLIBS = ../../../lib/dns/libdns.@A@ @DNS_CRYPTO_LIBS@
DNSLIBS = ../../../lib/dns/libdns.@A@ @DNS_OPENSSL_LIBS@ @DNS_GSSAPI_LIBS@
ISCLIBS = ../../../lib/isc/libisc.@A@
DNSDEPLIBS = ../../../lib/dns/libdns.@A@

Some files were not shown because too many files have changed in this diff Show More