To Do list for Net::DNS ======================= * Work on Net::DNS::Nameserver. - Write tests. - Write a demo script. * Add an option to Net::DNS::Resolver to keep TCP sessions open. Suggested by George Michaelson. * Net::DNS has problems with SOCKS; problem appears to be with the Perl socket code. Can test if we're running under a SOCKSified Perl by checking $Config::Config{"usesocks"}. Problem noted by George Michaelson. * Make sure demo/check_soa checks all IP addresses for all nameservers. * Add a "use_connected_udp" method to Net::DNS::Resolver to optionally use connected UDP sockets. * Explicitly close TCP sockets when done with them. * Check code for proper use of 0.0.0.0 address. * Check for unknown types and classes. * Add documentation on use of dot-termination. * Work on TSIG support: - Add additional documentation and examples. - Study RFC 2845 to make sure the implementation is complete and correct. - Add examples of checking for BADKEY, BADSIG, and BADTIME errors. - The TSIG time_signed and other_data fields should be 48-bit unsigned integers. The current implementation ignores the upper 16 bits; this will cause problems for times later than 19 Jan 2038 03:14:07 UTC. - Add support for TSIG-signed zone transfers. - Add code to validate TSIG-signed responses. - Consider changing the Net::DNS::Resolver->search and query methods to return an error if the server rejects a TSIG-signed query or update, or if a TSIG-signed response doesn't validate. The send method should continue to be low-level enough to return the TSIG record. - Add a "-k" option to perldig and other demo programs so they can read keys from a file. - Make the installation of Digest::HMAC_MD5 and MIME::Base64 optional. These are only needed for TSIG support. * Decide what to do if $res->send is called with no arguments, or if $res->search or $res->query are called with a Packet object as an argument. * Consider writing a Net::DNS::Examples manual page. * Consider writing a Net::DNS::FAQ manual page. * Consider adding "use strict" to the examples. * Consider changing the comment for the MINIMUM field when printing SOA records. RFC 2308 defines a new meaning for this field. * Consider writing a Net::DNS::AXFR module to handle zone transfers. * Figure out how to handle responses that come back from a different address than the address to which the query was sent. May have been solved by new IO::Socket code. * Kevin DeBruhl has volunteered to help test Net::DNS on ActivePerl 5.6 on NT. Need to get the development code running on Perl 5.6 & ActivePerl 5.6. * Look at Mark Ferlatte's patches for Win32. * Finish demo/time-query. * Look at problems identified by various Net::DNS users via email. * Finish mresolv2. Some things to do: - Keep track of CNAME records so we can map the original IP address to the answer. - Add retries. * Add DNSSEC. * Find out if returning the answer in the authority section is proper behavior. Problem noted by Michael McKibben. Example: #!/usr/local/bin/perl -w use Net::DNS; use strict; my $res = Net::DNS::Resolver->new; $res->debug(1); $res->nameservers("134.24.132.240"); $res->send("intel.cerf.net", "SOA"); * When $res->debug(1), add some output to indicate there were no nameservers. Suggested by Neil Harkins. * Consider adding WINS support (see RFC 1002). Suggested by Philip D. Pokorny. * Add patches suggested by Graham Barr (see mail archive 19981219). * Consider randomizing query IDs. Idea from a thread in bind-workers. * Make sure we check label length when compressing names. * Check for loops when uncompressing names. * Find out why I'm getting "no nameservers" when doing $res->query on an IP address. [Answer: IO::Socket's _sock_info subroutine refers to $1 after a substitute. If the substitute failed, $1 is still set from an earlier regexp. Workaround: surround port numbers with ()]. * Specify the peer address in send() rather than in new(). This should avoid a timeout when creating a UDP socket object. Suggested by Ken Neighbors. Should look something like this: $peer = sockaddr_in($port, inet_aton($ns)); $sock->send($buf, 0, $peer); Problem: We don't seem to get errors back like "connection refused" when doing this. Solution: Add optional support for connected UDP sockets. Not supported on all platforms. * Add a way to disable reading of environment variables like RES_NAMESERVERS. Suggested by Ken Neighbors. * Add examples of using dynamic updates for every RR type. * rr_add and rr_del: Check for a reference (RR). * Add to res_init_microsoft checks for DhcpDomain and DhcpNameServer if Domain and NameServer aren't set. Suggested by Petja van der Lek and Peter Sorensen. [ DONE BUT NOT TESTED ]. * Add optional support for Time::HiRes to time queries. Inspired by a suggestion from Roy Alcala. * Check out the "no nameservers" weirdness when doing $res->send inside a "while(/.../g". * Add Milivoj Ivkovic's changes to res_init_microsoft: #WinNT : my $root = 'SYSTEM\CurrentControlSet\Services\Tcpip\Parameters'; #Win95 : my $root = 'SYSTEM\CurrentControlSet\Services\VxD\MSTCP'; and split on "," instead of space. * Documentation for Net::DNS::Select. * Handle emtpy search and domain fields (Net::DNS::Resolver). * After setting $res->srcport(53), $res->send returns "no nameservers" if the port is already in use. * Undefined value in Question.pm (lines 47, 130) when parsing a bogus packet. * Consider adding IQUERY. * When the query is a dotted quad, only assume a PTR query if no type was specified. Suggested by Jay Soffian. * Check for tc in partial packets. Example: (microsoft.com, ANY). [ 7 Apr 1998 -- can't reproduce ]. * Add better private tests for TCP transfers. * Make sure Net::DNS runs with taint checks on. Look at the patch contributed by Chris Garrigues. * Work on Resolver.pm: - Check for igntc on large outgoing packets. - Work on axfr_start & axfr_next. Things remaining to do: * Find out why some zone transfers (e.g., sub5.test) terminate prematurely. Tcpdump shows Net::DNS sending FIN before all of the data has been read. Debugging shows that recv sometimes returns "Resource temporarily unavailable" -- this appears to happen only on TCP sockets that were created with "Timeout" set, and then only under certain conditions (Perl 5.004_04, IO-1.19, FreeBSD 2.2.6-STABLE, BIND-8.1.2-T3A). * Error checking (e.g., header->rcode). * Rewrite axfr to call axfr_start & axfr_next. * Add to the Changes file. - Add an optional argument to Net::DNS::Resolver->new to read a specific configuration file instead of using the default files. - Accept options in resolver config files. - Show more info about the query when $res->debug(1). - Work on a way to use the same socket for background queries. - Add callbacks. - Document $res->errorstring messages. - Work on efficiency of IO::Socket handling. - Add an IXFR method (see RFC 1995). - Implement AAONLY queries. Here's a code fragment to set the nameserver list to the hosts returned in the authority section: $res->nameservers(map { $_->nsdname } grep { $_->type eq "NS" } $ans->authority); * Work on the manual pages: - Review the examples in the Net::DNS manual page. - Make "->" non-breaking. - Reorganize to put the most frequently-used methods first. Suggested by John Line. - Add manual pages for individual RR types to the homepage. - Consider putting all POD after an __END__ line in each file. Will this speed up initial loading? Need to research. * Consider using function prototypes. * Get rid of .* in AAAA.pm; write more tests for AAAA.pm. * Allow Net::DNS::RR::LOC->latlon to set the lat/lon. * Work on the dynamic update code. Some things remaining to do: - Append the default zone in update packets if the name doesn't contain a dot. - Add the "new_from_string" method to the following RR types: EID NIMLOC NSAP NULL - Do sanity checking on user-created RR objects. Update the BUGS section in RR.pm when this is complete. - Allow yxrrset & friends to take an RR object as an argument. - Do more sanity checking on yxrrset & friends. - Add an "update" method to the resolver class to send the update packet to the zone's authoritative nameservers (see also RFC 2136, Section 4). Or consider sending update packets to only the first nameserver listed in the resolver configuration. - Do case-insensitive comparisons in Net::DNS::Packet->dn_comp. * Consider getting rid of the "; no data" string from $rr->rdatastr. Add it possibly in $rr->string. * Improve the error handling and reporting. Some things to do: - Get rid of Carp::confess as many places as possible. - Make sure empty RDATA sections don't cause the program to print the obnoxious "no such method" warning. - Check for invalid RR types or classes. - Handle "host is down" error in Resolver.pm. - Set a more descriptive error if a zone transfer fails, especially if the nameserver isn't authoritative (current code returns NOERROR if the nameserver answered but wasn't authoritative). - Consider documenting the use of "eval" to avoid a fatal error in certain places. Idea by Dirk Herr-Hoyman. * Restructure some of the code. Some things to look at: - Net::DNS::Resolver->send (needs to be broken into smaller pieces). - Net::DNS::Packet->dn_expand (get rid of the recursive call). - Passing of references between Net::DNS::Packet and Net::DNS::RR. * Add more RR types. Currently unimplemented are: MD RFC 1035 (obsolete) MF RFC 1035 (obsolete) WKS RFC 1035 NSAP_PTR RFC 1348 (deprecated) SIG RFC 2535 KEY RFC 2535 GPOS RFC 1712 (withdrawn) NXT RFC 2535 EID [Patton] (was draft-ietf-nimrod-dns-xx.txt) NIMLOC [Patton] (was draft-ietf-nimrod-dns-xx.txt) ATMA [Dobrowski] (ftp://ftp.atmforum.com/pub/approved-specs/af-saa-0069.000.pdf) KX RFC 2230 CERT RFC 2358 A6 RFC 2874 DNAME RFC 2672 SINK [Eastlake] OPT RFC 2671 UINFO [IANA-Reserved] UID [IANA-Reserved] GID [IANA-Reserved] UNSPEC [IANA-Reserved] TKEY RFC 2930 IXFR RFC 1995 MAILB RFC 1035 MAILA RFC 1035 * Fix the TXT RR to handle more than 1 string in the RDATA section (RFC 1035, Section 3.3.14). * Check the EID, NIMLOC, and NULL RR handling. * Add test cases for NULL, EID, and NIMLOC to private zone data. NULL isn't allowed in master files per RFC 1035, Section 3.3.10; BIND 8.1-REL doesn't appear to implement EID or NIMLOC (perhaps via dynamic update?). * Write some front-end methods to do CNAME translations automagically. * Work on demo scripts: - Add a copyright notice to the demo scripts. - Work on demo/axfr: * Add a print statement to tell whether the zone info comes from a file or a zone transfer. - Work on demo/srv (not included with the distribution). Remaining to do: * Documentation. Don't forget to add a reference to it in the other demo scripts. * Consider adding "sub srv" to DNS.pm. * Add to the Changes file. - Work on nsupdate.pl (not included with the distribution) and add it to the demo directory. Remaining to do: * Write documentation. * Make it more robust. - Work on dns.cgi (not included with the distribution) and add it to the demo directory. Some things remaining to do: * Check for HTTP_USER_AGENT in zone transfers. * Add a way to change resolver settings. Edit do_axfr and remove the query for the zone's nameservers when this is finished. * Add support for dynamic updates. - Consider writing a simple nameserver with Net::DNS. * Do more study of resolver behavior as recommended in RFCs 1035, 1123, and 2136. * Add some text- and html-specific sections to the manual pages. * Check code for conformance to the guidelines listed in The Perl 5 Module List. Check style & efficiency according to the perlstyle manpage and the Camel. * Consider providing an .xs file for those who wish to link against libresolv or libbind instead of using the entirely-Perl resolver. * Consider rewriting the packet-parsing code in C for increased speed, or possibly going back to using Dave Shield's resparse library. --- $Id: TODO,v 1.17 2001/02/07 05:10:53 mfuhr Exp mfuhr $