ChangeLog 133 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305
  1. 2012-04-23 Paul A. Rombouts <p.a.rombouts@home.nl>
  2. * src/dns_query.c
  3. Refine the return values of p_dns_cached_resolve(), p_dns_resolve() and
  4. p_recursive_query() so that they distinguish between answers found in
  5. the cache and replies obtained by querying other servers.
  6. This, among other things, can be used to prevent data that was recently
  7. obtained from the cache needlessly being added back to the cache.
  8. 2012-04-22 Paul A. Rombouts <p.a.rombouts@home.nl>
  9. * configure.in
  10. On the Linux platform, check if we can compile and link with the
  11. -pthread flag instead of linking with -lpthread.
  12. 2012-04-21 Paul A. Rombouts <p.a.rombouts@home.nl>
  13. * src/dns_query.c
  14. When following the delegation chain trying to get an authoritative
  15. answer, pdnsd would answer with SERVFAIL if it failed to get a reply
  16. from the last server in the chain. Instead pdnsd will now use the last
  17. reply in the chain with RCode=0 that raised the AA or RA flag, if there
  18. is one.
  19. 2012-04-19 Paul A. Rombouts <p.a.rombouts@home.nl>
  20. * src/cache.c
  21. In report_cache_stat(), make copies of volatile data to get a
  22. consistent data set before making calculations with cache size and
  23. entry numbers.
  24. 2012-04-16 Paul A. Rombouts <p.a.rombouts@home.nl>
  25. * src/netdev.c
  26. If we can't open /proc/net/if_inet6 in is_local_addr() log a warning
  27. message.
  28. 2012-04-15 Paul A. Rombouts <p.a.rombouts@home.nl>
  29. * src/dns_query.c
  30. The code checking for duplicate IP addresses obtained from NS records
  31. in auth_ok() has been slightly optimized.
  32. 2012-04-12 Paul A. Rombouts <p.a.rombouts@home.nl>
  33. * src/dns_query.c
  34. When resolving nameservers obtained from NS records, allow pdnsd to use
  35. more than one IP address per nameserver.
  36. In rare cases, using just one IP address for each nameserver will cause
  37. unnecessary resolve failures if the address chosen for each nameserver
  38. happens to be unreachable while the other addresses would lead to
  39. successful resolution, as demonstrated by Yuri Vorobyev.
  40. 2012-03-16 Paul A. Rombouts <p.a.rombouts@home.nl>
  41. * src/cache.c
  42. When adding RR records one by one to a cache entry using add_cent_rr(),
  43. use the smallest ttl value in case of conflicting ttls.
  44. Code for local/nonlocal conflict resolution has been taken out of
  45. add_cent_rr_int() and put into add_cent_rr() and cr_check_add()
  46. which should be slightly more efficient.
  47. 2012-03-15 Paul A. Rombouts <p.a.rombouts@home.nl>
  48. * src/dns_query.c
  49. Enforcing strict RFC 2181 compliance by rejecting all the answers
  50. with inconsistent ttl timestamps can cause undesirable resolve failures.
  51. I have tried to implement a more compromising solution, whereby
  52. inconsistent answers that should be normally rejected are still never
  53. cached, but are nevertheless used as intermediary or temporary results
  54. if all else fails.
  55. 2012-03-13 Paul A. Rombouts <p.a.rombouts@home.nl>
  56. * src/dns_query.c
  57. Fixed a typo in rr_to_cache() that caused pdnsd to fail to compile when
  58. configured with the --enable-strict-rfc2181 option.
  59. Thanks to Gonzalo L. R. for reporting this problem.
  60. Also changed the return value of rr_to_cache() from a simple boolean to
  61. an RC code in order to properly distinguish between memory allocation
  62. errors and time-stamp inconsistencies.
  63. 2012-02-21 Paul A. Rombouts <p.a.rombouts@home.nl>
  64. * src/dns_query.c
  65. If we have used EDNS in a query and the remote server answered
  66. with rcode "format error", try again with the OPT pseudo-record
  67. removed from the additional section of the query.
  68. Also fixed a bug in p_exec_query() that caused pdnsd to behave
  69. as if every reply with a non-empty additional section contained
  70. an OPT record.
  71. 2012-02-15 Paul A. Rombouts <p.a.rombouts@home.nl>
  72. * src/dns_answer.c,src/helpers.c,src/helpers.h,src/icmp.c,
  73. src/ipvers.h,src/main.c,src/netdev.c
  74. Introduced a new macro SEL_IPVER() to reduce some of the clutter in the
  75. code caused by having to support both IPv4 and IPv6.
  76. 2012-01-31 Paul A. Rombouts <p.a.rombouts@home.nl>
  77. * configure.in
  78. Add AM_PROG_CC_C_O line to configure.in to prevent automake warning.
  79. 2012-01-29 Paul A. Rombouts <p.a.rombouts@home.nl>
  80. * src/cache.c
  81. In report_cache_stat(), add the average number of bytes used per cache
  82. entry when reporting the cache status, as suggested by M. Galabant.
  83. 2012-01-28 Paul A. Rombouts <p.a.rombouts@home.nl>
  84. * src/dns_answer.c,src/dns_query.c
  85. Cleaned up the code a bit to avoid warning messages when
  86. compiling with '-Wall -Winline' flags.
  87. 2012-01-18 Paul A. Rombouts <p.a.rombouts@home.nl>
  88. * src/conff.c
  89. Set the default of the edns_query option to false.
  90. 2011-07-31 Paul Rombouts <p.a.rombouts@home.nl>
  91. * src/cache.c
  92. Use a slightly more sophisticated merge-sort algorithm in sort_rrl().
  93. 2011-05-09 Paul Rombouts <p.a.rombouts@home.nl>
  94. * src/dns_answer.c
  95. In compose_answer(), also add an OPT pseudo-RR to the additional section
  96. of a NXDOMAIN reply when appropriate.
  97. 2011-05-08 Paul Rombouts <p.a.rombouts@home.nl>
  98. * src/cache.c,src/cache.h,src/dns_query.c,src/status.c
  99. Make the dns_cent_t struct more compact by putting the fields that are
  100. only used for either non-existent or existent domains, but not both,
  101. into a union so that these fields can share memory.
  102. When saving the cache to file, only write the TTL and time-stamp for
  103. a whole domain when it is negatively cached.
  104. 2011-05-06 Paul Rombouts <p.a.rombouts@home.nl>
  105. * src/cache.c,src/cache.h,src/dns_query.c
  106. At the request of Andrei Caraman, the TTL of a negatively cached domain
  107. is now adjusted in accordance with the min_ttl and max_ttl options, just
  108. as it is done for (negatively) cached records.
  109. Additional change to the TTL policy is that for negative records (and
  110. negative domains) the neg_ttl setting overrides min_ttl if
  111. neg_ttl < min_ttl.
  112. 2011-04-26 Paul Rombouts <p.a.rombouts@home.nl>
  113. * src/conf-parser.c
  114. Fixed memory leak that can occur when the configuration file is reloaded
  115. and an error is encountered while parsing the definition of a TXT
  116. record.
  117. 2011-03-21 Paul Rombouts <p.a.rombouts@home.nl>
  118. * src/make_rr_types_h.pl,src/cache.h,src/cache.c,src/dns_answer.c
  119. Introduced arrays rrmuiterlist and rrcachiterlist to make iterating
  120. over all possible RR types in a cache entry in strict ascending order
  121. a little more efficient.
  122. 2011-03-09 Paul Rombouts <p.a.rombouts@home.nl>
  123. * src/dns_query.c,src/conf-parser.c,src/conf-keywords.h
  124. Implemented a new config option "outgoing_ip", which
  125. makes it possible to bind outgoing connections to
  126. a specific interface.
  127. 2011-02-21 Paul Rombouts <p.a.rombouts@home.nl>
  128. * src/netdev.c
  129. Fixed UDP socket descriptors leak in the implementation of
  130. is_local_addr() for the FreeBSD platform. Thanks to Ashish Shukla for
  131. reporting this bug.
  132. 2011-02-14 Paul Rombouts <p.a.rombouts@home.nl>
  133. * src/cache.c
  134. In purge_all_rrsets(), also free the rrext array if it has become empty after
  135. purging all the RR sets.
  136. 2011-02-04 Paul Rombouts <p.a.rombouts@home.nl>
  137. * src/conff.c,src/conff.h,src/conf-parser.c,src/conf-keywords.h,
  138. src/dns_query.c,src/dns_query.h,src/servers.c
  139. Changed "edns_query" from a "global" option to a "server"
  140. configuration option.
  141. 2011-02-04 Paul Rombouts <p.a.rombouts@home.nl>
  142. * src/conff.c,src/conff.h,src/dns_query.c,src/dns_query.h,src/servers.c,
  143. src/conf-parser.c
  144. The query uptest sometimes fails because some DNS servers are configured
  145. to ignore empty queries. The new config option "query_test_name" makes
  146. it possible to query for a specific name instead.
  147. 2011-02-01 Paul Rombouts <p.a.rombouts@home.nl>
  148. * src/dns_query.c
  149. When processing a reply from a remote name server which seems to delegate
  150. to other name servers, check if the names for which NS records have
  151. been supplied have locally defined NS records. If so, the local
  152. records will now override those supplied by the remote server.
  153. 2011-01-31 Paul Rombouts <p.a.rombouts@home.nl>
  154. * src/conf-parser.c
  155. Added support for defining TXT records in the configuration file.
  156. 2011-01-30 Paul Rombouts <p.a.rombouts@home.nl>
  157. * src/dns_query.c
  158. Do not cache additional records from a response that is rejected because
  159. it contains IP addresses in the reject list, even when the reply
  160. is processed as a NXDOMAIN reply.
  161. 2011-01-25 Paul Rombouts <p.a.rombouts@home.nl>
  162. * src/conf-parser.c
  163. Modified the function scan_string() to allow back-slashed escape
  164. sequences in strings.
  165. 2011-01-21 Paul Rombouts <p.a.rombouts@home.nl>
  166. * src/dns_answer.c,src/dns_query.c,src/conff.h,src/conff.c,
  167. src/conf-parser.c
  168. Added support for EDNS (Extension mechanisms for DNS).
  169. Currently this is only useful for allowing UDP message sizes
  170. to be larger than 512 bytes.
  171. 2011-01-20 Paul Rombouts <p.a.rombouts@home.nl>
  172. * src/dns_answer.c
  173. To avoid frequent reallocs when composing a DNS reply message,
  174. grow the message buffer in multiples of a certain minimum chunk size.
  175. 2011-01-19 Paul Rombouts <p.a.rombouts@home.nl>
  176. * src/dns.c,src/dns.h,src/dns_answer.c
  177. Extended debugging info with DNS-message lengths and flags of incoming
  178. messages.
  179. 2011-01-17 Paul Rombouts <p.a.rombouts@home.nl>
  180. * src/conff.c,src/conff.h,src/conf-parser.c,src/dns_answer.c
  181. Made "ignore_cd" option obsolete. It is now effectively always on.
  182. 2010-12-27 Paul Rombouts <p.a.rombouts@home.nl>
  183. * src/cache.c,src/cache.h,src/dns_answer.c,src/dns_query.c,
  184. src/make_rr_types.pl,src/rr_types.in,src/rr_types.c
  185. The array of pointers to rr_set_t structs in the dns_cent_t struct
  186. contains mostly null pointers in practice, so is somewhat
  187. inefficient in storage usage. This problem is exacerbated if we add
  188. support for caching more RR-types. To ameliorate to the problem
  189. I have decided to split the array in two, with one part fixed in the
  190. dns_cent_t struct as before, and an extension part that will be
  191. separately allocated, if necessary. If the extension part is used only
  192. for very rarely cached types, in most cases the extension array will not
  193. need to be allocated thus hopefully saving memory overall.
  194. The lookup tables which are necessary to support the new cache entry
  195. structure are cumbersome to write by hand, so I have written a perl
  196. script to do this automatically. As an additional benefit, which RR
  197. types are cache-able is now configurable for each type separately via
  198. rr_types.in.
  199. 2010-03-14 Paul Rombouts <p.a.rombouts@home.nl>
  200. * src/dns_query.c
  201. Using randomized source ports for outgoing queries in IPv6 mode failed
  202. with the warning "Out of ports in the range 1024-65535, dropping query!",
  203. because the pdnsd tried to bind to the fixed port for incoming queries,
  204. instead of the dynamically chosen port. This is a very old bug, but it
  205. has only become apparent since source port randomization has become the
  206. default.
  207. Thanks to Philip-André Fillion, Phil Sutter, Radoslaw Szkodzinski and
  208. others for reporting this bug and sending patches.
  209. 2009-12-25 Paul Rombouts <p.a.rombouts@home.nl>
  210. * src/status.c,src/status.h,src/pdnsd-ctl/pdnsd-ctl.c
  211. Add a magic number to pdnsd-ctl command codes to guard against
  212. possible incompatibility between the pdnsd-ctl utility and the
  213. pdnsd server.
  214. 2009-10-18 Paul Rombouts <p.a.rombouts@home.nl>
  215. * src/dns_query.c
  216. Make root-server discovery a little more fault tolerant, i.e. if some
  217. of the root-server names don't resolve don't necessarily reject the
  218. whole result.
  219. 2009-10-17 Paul Rombouts <p.a.rombouts@home.nl>
  220. * src/servers.c,src/dns_query.c,src/dns_query.h
  221. Implemented automatic root-server discovery, which can now be configured
  222. by setting "root_server=discover".
  223. 2009-06-14 Paul Rombouts <p.a.rombouts@home.nl>
  224. * src/dns_query.c,src/consts.c,src/consts.h,src/conf-parser.c
  225. Changed the default behaviour of the "neg_rrs_pol" option. The default
  226. used to be to only cache records negatively in case the AA (authoritive
  227. answer) bit in the reply was set. The new default is to also allow
  228. negative caching in case the reply has the RA (recursion available) bit
  229. set and the query had the RD (recursion desired) bit set.
  230. This gives the behaviour that is usually wanted in case "proxy_only=on"
  231. is set without having to set "neg_rrs_pol=on", which can be more
  232. problematic. The new default can be explicitly set using
  233. "neg_rrs_pol=default". The values "on","off" and "auth" are also
  234. still available.
  235. 2009-06-13 Paul Rombouts <p.a.rombouts@home.nl>
  236. * src/conff.c,src/conff.h,src/dns_answer.c,src/conf-parser.c,src/conf-keywords.h
  237. Included a patch contributed by Andreas Steinmetz that implements a new
  238. global configuration option "ignore_cd". pdnsd used to check that the CD
  239. bit in the DNS header of queries is zero and return the error code
  240. "format error" if it is not. However, considering the meaning of this
  241. bit today it appears to be harmless to ignore it, so the new "ignore_cd"
  242. is on by default. Setting "ignore_cd=off" gives the earlier strict
  243. behavior.
  244. Also renamed the the Z1, AU, Z2 bits to correspond with their modern names
  245. CD, AD, Z.
  246. 2008-12-19 Paul Rombouts <p.a.rombouts@home.nl>
  247. * pdnsd-1.2.7/src/dns_query.c
  248. If pdnsd receives a SERVFAIL response with a non-empty answer section,
  249. use the information tentatively if no better response is available.
  250. The previous behaviour was to discard the reply completely, which could
  251. cause failure to resolve some names.
  252. Thanks to Rafal Wijata for providing an example involving PowerDNS servers
  253. replying with CNAME records.
  254. 2008-09-01 Paul Rombouts <p.a.rombouts@home.nl>
  255. * src/dns_query.c
  256. In p_dns_resolve(), try to reduce the burden on root servers further for
  257. names ending in "arpa".
  258. 2008-08-31 Paul Rombouts <p.a.rombouts@home.nl>
  259. * src/dns_query.c
  260. In p_exec_query(), if the reply from a remote name server is negative
  261. (either because the rcode is NXDOMAIN or because the answer section
  262. contains no records for the queried name), ignore the remaining records
  263. in the answer section (in particular do not add them to the cache).
  264. 2008-07-29 Paul Rombouts <p.a.rombouts@home.nl>
  265. * src/conff.c,src/dns_query.c
  266. Made the default of the configuration option query_port_start equal to
  267. 1024. Also improved the algorithm used by pdnsd to select random source
  268. ports to ensure that each (free) port gets an equal chance of being
  269. selected. This should guarantee random source ports in the range
  270. 1024-65535, making pdnsd less vulnerable to some of the issues described
  271. in CERT VU#800113.
  272. The old situation, where pdnsd lets the kernel select the source ports,
  273. is still available by specifying query_port_start=none.
  274. 2008-07-25 Paul Rombouts <p.a.rombouts@home.nl>
  275. * src/dns_query.c
  276. Fixed a dangling pointer bug in p_exec_query(), which could cause pdnsd
  277. to crash when processing a long reply with many entries in the answer
  278. section.
  279. 2008-05-12 Paul Rombouts <p.a.rombouts@home.nl>
  280. * src/conf-parser.c,src/conff.c
  281. Added a recursive-depth counter to the read_config_file() and
  282. confparse() functions to prevent the possibility of infinite
  283. recursion when processing include files.
  284. In confparse(), warn when in a server section the root_server option is
  285. set in combination with policy=simple_only or policy=fqdn_only.
  286. 2008-05-10 Paul Rombouts <p.a.rombouts@home.nl>
  287. * src/ipvers.h
  288. Included a patch contributed by Georg Schwarz which selectively undoes
  289. a Debian patch contributed by Juliusz Chroboczek on platforms for which
  290. the IPV6_RECVPKTINFO macro is not defined (e.g. MacOS X).
  291. 2008-05-08 Paul Rombouts <p.a.rombouts@home.nl>
  292. * src/status.c,src/pdnsd-ctl/pdnsd-ctl.c
  293. The pdnsd-ctl add command can now also be used to define NS records.
  294. A wildcard record defined with this command now behaves the same way as
  295. one defined in the config file.
  296. 2008-05-07 Paul Rombouts <p.a.rombouts@home.nl>
  297. * src/conf-parser.c,src/conf-keywords.h,src/conff.c
  298. Added the ability to process "include" sections in the configuration
  299. file. This makes it possible to place local definitions in separate
  300. files and include them from the main configuration file.
  301. 2008-05-05 Paul Rombouts <p.a.rombouts@home.nl>
  302. * src/conff.c,src/conf-parser.c,src/status.c,src/pdnsd-ctl/pdnsd-ctl.c
  303. Implemented two new pdnsd-ctl commands, which make it easier to add
  304. definitions to the pdnsd cache at run time. "pdnsd-ctl include" is
  305. similar to "pdnsd-ctl config" but only processes configuration sections
  306. that effect the cache and disallows global and server sections.
  307. "pdnsd-ctl eval" directly parses its string arguments as if they were
  308. part of a configuration (include) file.
  309. 2007-09-15 Paul Rombouts <p.a.rombouts@home.nl>
  310. * src/dns.h,src/dns_answer.c,src/dns_query.c
  311. Changed the declarations of various packed structs, by moving the
  312. __attribute__((packed)) specifiers from the field level to the struct level.
  313. This was necessary to get the correct value for sizeof(rr_hdr_t) when
  314. compiling with gcc for the ARM architecture.
  315. Thanks to Dirk Armbrust for reporting the problem and supplying the solution.
  316. 2007-08-10 Paul Rombouts <p.a.rombouts@home.nl>
  317. * src/dns_answer.c
  318. Applied a Debian patch contributed by Juliusz Chroboczek which
  319. reportedly fixes a problem with pdnsd running in IPv6 mode
  320. (IPV6_RECVPKTINFO instead of IPV6_PKTINFO).
  321. 2007-08-04 Paul Rombouts <p.a.rombouts@home.nl>
  322. * src/dns_query.c
  323. When resolving a name recursively, pdnsd would stop querying further
  324. name servers as soon as it received a reply with the authority (aa) flag
  325. set. Unfortunately, it appears this flag is sometimes raised erroneously
  326. in replies. I have implemented a work-around that ignores the aa flag
  327. when there appears to be a clear delegation to a sub-domain.
  328. Thanks to Nico Erfurth for reporting this problem.
  329. It appears that pdnsd would also fail to consult servers in the authority
  330. section when configured with neg_rrs_pol=on. This has been fixed.
  331. 2007-08-01 Paul Rombouts <p.a.rombouts@home.nl>
  332. * src/pdnsd-ctl/pdnsd-ctl.c
  333. Made the matching of pdnsd-ctl command names and most of the arguments
  334. case-insensitive.
  335. 2007-07-22 Paul Rombouts <p.a.rombouts@home.nl>
  336. * src/dns_answer.c
  337. Instead of sharing the responsibility for freeing the answer buffer in
  338. case of an error amongst different functions, only free it in
  339. compose_answer().
  340. * configure.in, src/Makefile.am, src/test/Makefile.am
  341. Merged patch contributed by Pierre Habouzit to deal with CFLAGS the
  342. automake way (allowing packagers to override CFLAGS properly).
  343. 2007-07-21 Paul Rombouts <p.a.rombouts@home.nl>
  344. * src/dns_answer.c
  345. For each target name in a SRV record in the answer section, add
  346. addresses to the additional section of the response, as is recommended
  347. by the RFCs.
  348. 2007-07-14 Paul Rombouts <p.a.rombouts@home.nl>
  349. * src/list.c,src/list.h
  350. Made modifications to the implementation of dynamic arrays, which
  351. should ensure proper alignment on all supported architectures.
  352. 2007-07-10 Paul Rombouts <p.a.rombouts@home.nl>
  353. * Upgraded pdnsd's license to GPL version 3.
  354. 2007-07-08 Paul Rombouts <p.a.rombouts@home.nl>
  355. * src/cache.h,src/dns_query.c
  356. The data field of the rr_bucket_t struct is now aligned such that
  357. it possible to use straightforward assignment to copy IP addresses,
  358. making memcpy unnecessary for this purpose.
  359. 2007-07-07 Paul Rombouts <p.a.rombouts@home.nl>
  360. * src/dns_query.c
  361. If pdnsd fails to connect to a name server using a IPv6 address, it will
  362. now retry the connection using a IPv4 address, if available. This allows
  363. pdnsd to recover from situations where IPv6 connectivity is temporarily
  364. unavailable, but IPv4 connectivity still functions.
  365. Thanks to Andreas Ferber for reporting this problem.
  366. 2007-07-04 Paul Rombouts <p.a.rombouts@home.nl>
  367. * src/dns_answer.c
  368. I have reordered the arguments of the add_rr() and related
  369. functions to make them more consistent with each other.
  370. 2007-07-03 Paul Rombouts <p.a.rombouts@home.nl>
  371. * src/cache.c,src/hash.c
  372. pdnsd will no longer immediately abort in add_dns_hash() if it fails
  373. to allocate memory for a new hash entry.
  374. 2007-07-01 Paul Rombouts <p.a.rombouts@home.nl>
  375. * src/conff.c,src/conff.h,src/consts.c,src/consts.h,
  376. src/conf-parser.c,src/conf-keywords.h,src/dns_query.c
  377. Implemented the new "reject", "reject_policy" and "reject_recursively"
  378. options for the server section of the configuration file.
  379. * src/ipvers.h,src/conf-parser.c,src/dns.c,src/status.c,
  380. src/pdnsd-ctl/pdnsd-ctl.c
  381. Allow local AAAA records to be defined even if pdnsd is compiled
  382. without --enable-ipv6, provided there is sufficient support in the
  383. C libraries and --disable-new-rrs was not used.
  384. 2007-06-30 Paul Rombouts <p.a.rombouts@home.nl>
  385. * src/dns_answer.c
  386. Previously, when the answer buffer was realloced in add_rr(), an
  387. extra 2 bytes used to be reserved, which are unnecessary, as far
  388. as I can tell. I have decided to do without these extra 2 bytes,
  389. which originate from Thomas Moestl's code. As compensation, I have
  390. added extra PDNSD_ASSERT() statements to check that the answer
  391. buffer does not overflow.
  392. 2007-06-27 Paul Rombouts <p.a.rombouts@home.nl>
  393. * src/status.c, src/pdnsd-ctl/pdnsd-ctl.c
  394. Extended the pdnsd-ctl 'add a' and 'add aaaa' commands to allow
  395. multiple IP addresses to be specified.
  396. 2007-06-25 Paul Rombouts <p.a.rombouts@home.nl>
  397. * src/conff.c,src/conff.h,src/conf-parser.c,src/conf-keywords.h,
  398. src/dns_query.c
  399. Implemented a new option for the server section of the configuration
  400. file: randomize_servers.
  401. * src/servers.c
  402. Improved the debug messages in uptest().
  403. 2007-01-30 Paul Rombouts <p.a.rombouts@home.nl>
  404. * src/icmp.c
  405. Fixed up the code implementing the ping test in icmp.c,
  406. which was broken for 64-bit systems.
  407. Thanks to Michael Uleysky for reporting this bug.
  408. 2007-01-09 Paul Rombouts <p.a.rombouts@home.nl>
  409. * src/dns_query.c
  410. auth_ok() now returns 1 if the cache entry has the DF_NEGATIVE flag set,
  411. without providing a list of authoritative servers to continue querying.
  412. Otherwise if we receive a non-authoritative NXDOMAIN reply and pdnsd
  413. is configured with neg_domain_pol=on, pdnsd will continue to try to
  414. get an authoritative answer. The intention is that pdnsd
  415. stops querying as soon as it gets an "unknown domain" answer.
  416. 2006-04-29 Paul Rombouts <p.a.rombouts@home.nl>
  417. * src/main.c
  418. pdnsd would segfault if it tried to call log_message() (via the
  419. log_warn() and log_error() macros) before the FILE pointer to the debug
  420. output stream was properly initialized.
  421. Thanks to Thomas Cort for discovering this problem and suggesting a fix.
  422. 2006-04-09 Paul Rombouts <p.a.rombouts@home.nl>
  423. * src/conf-parser.c,src/helpers.c,src/conff.h,src/conff.c
  424. I have included a patch contributed by Jan-Marek Glogowski, that
  425. implements the configuration option "use_nss". With use_nss=off pdnsd
  426. will avoid system functions that may use NSS (i.e. initgroups()), which
  427. may need DNS for LDAP lookups, which can lead to long timeouts and
  428. stalls if pdnsd itself is used for the DNS lookup.
  429. 2006-03-26 Paul Rombouts <p.a.rombouts@home.nl>
  430. * src/dns_query.c
  431. Negative caching of RR sets is now also supported with lean_query=off.
  432. 2006-03-25 Paul Rombouts <p.a.rombouts@home.nl>
  433. * src/dns_query.c,src/conf-parser.c,src/main.c
  434. I have implemented a new query method: udp_tcp. With this method a UDP
  435. query is tried first and, if the UDP answer is truncated, the query is
  436. repeated using TCP. This is the behaviour that seems to be recommended
  437. by the DNS standards. However, pdnsd wil not discard the truncated
  438. answer if the TCP requery fails.
  439. 2006-03-24 Paul Rombouts <p.a.rombouts@home.nl>
  440. * src/dns_answer.c
  441. Previously, pdnsd would add at most one additional A (and AAA) record
  442. for each record in the answer and authority sections. At the request of
  443. Angel Marin, pdnsd will now add all A and AAA records it can find in the
  444. cache for each name that produces additional records.
  445. 2006-01-02 Paul Rombouts <p.a.rombouts@home.nl>
  446. * src/dns_answer.c
  447. compose_answer() would leak memory if the query contained
  448. an unsupported QTYPE or QCLASS. This has now been fixed.
  449. 2005-12-27 Paul Rombouts <p.a.rombouts@home.nl>
  450. * configure.in
  451. TCP-query support is now compiled in by default.
  452. It can still be disabled using the configure option
  453. --disable-tcp-queries.
  454. 2005-12-23 Paul Rombouts <p.a.rombouts@home.nl>
  455. * src/dns_answer.c
  456. Queries received from clients with non-empty answer, authority or
  457. additional sections are now treated as malformed and rejected with
  458. rcode 1 (format error).
  459. 2005-11-06 Paul Rombouts <p.a.rombouts@home.nl>
  460. * src/conf-parser.c
  461. Time intervals in the configuration files can now be expressed in
  462. seconds, minutes, hours, days and weeks, using the suffixes
  463. s,m,h,d,and w.
  464. 2005-10-14 Paul Rombouts <p.a.rombouts@home.nl>
  465. * src/consts.c
  466. In the pdnsd configuration file, true/false and yes/no are now accepted
  467. as synonyms for the constants on/off.
  468. 2005-08-24 Paul Rombouts <p.a.rombouts@home.nl>
  469. * src/helpers.c
  470. I have fixed a potential buffer overflow problem that could occur with
  471. the 'pdnsd-ctl dump' command.
  472. In case of the root domain, the function rhn2str() would write 2 bytes
  473. to the output buffer even if size==1. Theoretically (under pathological
  474. circumstances) this could have allowed the dbuf buffer in the function
  475. dump_cent() to overflow by one byte.
  476. 2005-08-21 Paul Rombouts <p.a.rombouts@home.nl>
  477. * acconfig.h,src/cache.c,src/conff.c,src/conf-parser.c,src/dns.c,
  478. src/dns_answer.c,src/dns_query.c,src/error.h,src/helpers.c,src/main.c,
  479. status.c
  480. It appears the newer versions of gcc won't convert a pointer to char
  481. into a pointer to unsigned char and vice versa without complaining.
  482. The changes I have made should get rid of these distracting warning
  483. messages. Unfortunately I had to introduce casts in some cases,
  484. which reduces type safety :-(.
  485. 2005-08-16 Paul Rombouts <p.a.rombouts@home.nl>
  486. * src/dns.h
  487. Some changes were made to the endianess detection code to
  488. address problems on Mac OS X v10.4 Tiger.
  489. 2005-08-15 Paul Rombouts <p.a.rombouts@home.nl>
  490. * configure.in
  491. Some changes where made to address the reported problems with the
  492. configure script on Mac OS X v10.4 Tiger.
  493. 2005-08-05 Paul Rombouts <p.a.rombouts@home.nl>
  494. * src/status.c,src/dns_answer.c
  495. The output of the 'pdnsd-ctl status' command now includes some
  496. statistics on the number of query threads.
  497. 2005-07-29 Paul Rombouts <p.a.rombouts@home.nl>
  498. * src/main.c
  499. It appears that sigwait() can return EINTR under certain conditions.
  500. This explains the problems reported by Sanjoy Mahajan with strace
  501. and ACPI S3 sleep, which both caused pdnsd to exit prematurely.
  502. The return value of sigwait() is now checked and sigwait() is retried
  503. if the return value is EINTR.
  504. 2005-07-04 Paul Rombouts <p.a.rombouts@home.nl>
  505. * src/dns_query.c
  506. It appears that some servers that do not support recursive queries
  507. answer with "query refused" instead of "not supported". The
  508. p_exec_query() function now takes that possibility into account.
  509. 2005-07-01 Paul Rombouts <p.a.rombouts@home.nl>
  510. * src/dns_query.c
  511. In the processing of queries, I will make a distinction between
  512. recoverable errors and non-recoverable ones (typically caused by out of
  513. memory conditions). In the case of non-recoverable errors, no attempt to
  514. query alternative name servers is made.
  515. 2005-06-26 Paul Rombouts <p.a.rombouts@home.nl>
  516. * src/dns_query.c
  517. In p_recursive_query(), as soon as one of the servers in the q list
  518. replied "no error" or "name error", only this reply was examined and
  519. the other servers in the q list were ignored. Joshua Coombs has brought
  520. to my attention that this strategy sometimes fails when this reply is not
  521. authoritative and doesn't contain any usable references to name servers
  522. in the authority section.
  523. I have modified p_recursive_query() to allow pdnsd to continue querying
  524. the remaining servers in the q list as long as we haven't received an
  525. authoritative answer or usable authority information. This will allow
  526. pdnsd to arrive at the correct answer in some cases where it would
  527. formerly fail.
  528. 2005-06-25 Paul Rombouts <p.a.rombouts@home.nl>
  529. * src/status.c
  530. The "pdnsd dump" command may now also be given an argument
  531. consisting of a name beginning with a dot. This will dump information
  532. about all names in the cache ending in the given name. An argument
  533. consisting of a name without a leading dot will only give information
  534. about the exact name, as it did before.
  535. 2005-06-24 Paul Rombouts <p.a.rombouts@home.nl>
  536. * src/servers.c,src/status.c
  537. All uptests are now conducted by the server status thread. If a retest
  538. is requested via a "pdnsd-ctl server", an existing server status thread
  539. is signaled or a new server status thread is spawned if the old one has
  540. exited. This has the effect that a "pdnsd-ctl server label retest"
  541. command will now return immediately without waiting for the tests to
  542. finish.
  543. 2005-06-20 Paul Rombouts <p.a.rombouts@home.nl>
  544. * src/conf-parser.c,src/servers.c,src/servers.h
  545. At the request of Al-Junaid Walker I have added a new configuration
  546. option for the uptest interval. With "interval=ontimeout" the server is
  547. not tested at startup/reconfig, or at regular intervals, but only after
  548. a DNS query to a server times out. However, once a server is declared
  549. dead it is never considered again unless it is revived using a
  550. "pdnsd-ctl config" or "pdnsd-ctl server" command.
  551. 2005-06-19 Paul Rombouts <p.a.rombouts@home.nl>
  552. * src/servers.c,src/dns_query.c,src/icmp.c
  553. During an uptest the server configuration data is locked. Especially
  554. with ping or query uptests of unresponsive servers this means that the
  555. execution of "pdnsd-ctl config" or "pdnsd-ctl server" commands can be
  556. delayed for a long time (or even time out). I have made modifications
  557. that allow a "pdnsd-ctl config" or "pdnsd-ctl server" commands to
  558. interrupt pending uptests to allow these commands to proceed without
  559. delay in most cases.
  560. * src/thread.h
  561. Use the POSIX sigaction() instead of signal() to install signal handlers.
  562. 2005-06-08 Paul Rombouts <p.a.rombouts@home.nl>
  563. * src/dns_answer.c,src/dns_query.c
  564. I have defined a struct dns_msg_t that includes a message length field.
  565. In the case of sending a DNS message over TCP, we no longer need a
  566. separate write() call to send the message length. This prevents possible
  567. packet fragmentation.
  568. 2005-06-07 Paul Rombouts <p.a.rombouts@home.nl>
  569. * src/dns_query.c
  570. The query_method=tcp_udp option only used to work with cooperative name
  571. servers, i.e. servers that either send back a TCP reply or explicitly
  572. refuse the TCP connection request. This wasn't sufficiently satisfactory
  573. in practice, because some name servers are completely unresponsive to TCP
  574. connection requests. I have made modifications to allow pdnsd to try UDP
  575. queries in case TCP connections time out. When a short server timeout is
  576. combined with a global timeout that is at least twice as long, this may
  577. allow a query to a name server that only responds to UDP queries to
  578. succeed with query_method=tcp_udp.
  579. 2005-04-20 Paul Rombouts <p.a.rombouts@home.nl>
  580. * src/cache.c,src/hash.c,src/conff.c,src/status.c,src/pdnsd-ctl/pdnsd-ctl.c
  581. The "pdnsd-ctl empty-cache" command now accepts additional arguments;
  582. these are interpreted as include/exclude names. During execution of the
  583. command the name of each cache entry is matched against the names in the
  584. include/exclude list. If the name ends in a name to be included, the
  585. cache entry is deleted, otherwise not.
  586. This feature was added at the request of Joshua Coombs.
  587. 2005-04-19 Paul Rombouts <p.a.rombouts@home.nl>
  588. * src/cache.c, src/hash.c
  589. pdnsd will now (temporarily) unlock the cache between emptying hash
  590. buckets, this should allow pdnsd to remain responsive while executing
  591. the "pdnsd-ctl empty-cache" command. However, this only applies to DNS
  592. queries; pdnsd will not accept any new pdnsd-ctl commands while a
  593. pdnsd-ctl command is still running.
  594. 2005-03-29 Paul Rombouts <p.a.rombouts@home.nl>
  595. * configure.in, src/hash.h
  596. I have added a new configure option --with-hash-buckets=...
  597. This makes it possible to specify a different number of
  598. hash buckets without editing the source files.
  599. 2005-03-17 Paul Rombouts <p.a.rombouts@home.nl>
  600. * src/error.c
  601. When running in both daemon and debug mode, print warning and
  602. error messages to debug file as well as the syslog.
  603. 2005-03-15 Paul Rombouts <p.a.rombouts@home.nl>
  604. * src/dns_answer.c
  605. Only call pthread_setspecific() in debug mode, because
  606. pthread_getspecific() is also only used in debug mode.
  607. If pthread_setspecific() fails, treat this as a non-fatal error.
  608. 2005-03-10 Paul Rombouts <p.a.rombouts@home.nl>
  609. * configure.in
  610. On Linux systems the configure script will now try to detect automatically
  611. whether the system implements the Native POSIX Thread Library, but
  612. the method is not necessarily foolproof.
  613. * src/dns.c
  614. Local PTR records generated for resolving numeric IPv6 addresses back into
  615. names, are now based on ip6.arpa instead of ip6.int, because the latter domain
  616. will be phased out eventually.
  617. 2005-03-06 Paul Rombouts <p.a.rombouts@home.nl>
  618. * Makefile.am,src/cache.c
  619. Create an empty cache-file at install time and don't complain about empty
  620. cache files at start up.
  621. 2005-02-20 Paul Rombouts <p.a.rombouts@home.nl>
  622. * acconfig.h,configure.in,src/conf-parser.c,src/conff.h,src/dns.h,
  623. src/dns_answer.c,src/dns_query.c,src/error.h,src/helpers.h,src/icmp.c,
  624. src/ipvers.h
  625. I have applied some changes to the code proposed by Rodney Brown to improve
  626. portability. In particular, pdnsd should now compile on the Darwin platform
  627. (Apple Mac OS X).
  628. To support some of these changes, the source package is now built with a
  629. slightly more modern version of autoconf (2.57) and automake (1.6.3).
  630. 2005-01-29 Paul Rombouts <p.a.rombouts@home.nl>
  631. * src/dns.c,src/dns_answer.c,src/dns_query.c
  632. I have added some extra debug code to make it easier to discover the
  633. reason that pdnsd considers a query or reply malformed (format error).
  634. 2005-01-12 Paul Rombouts <p.a.rombouts@home.nl>
  635. * src/dns.c,src/dns_answer.c,src/dns_query.c
  636. I have extended some debug code contributed by Kiyo Kelvin Lee to dump
  637. the data received by pdnsd in debug mode (queries from clients, replies
  638. from name servers). Because this will give very verbose debug output,
  639. I've arranged it so that this data dump only occurs if pdnsd has been
  640. configured and compiled with --with-debug=9 and pdnsd has been called
  641. with -v9.
  642. Additionally, in the case that pdnsd rejects a reply from a name server
  643. because it is not well formed, I have refined the debug messages to
  644. distinguish between format errors due to unexpected truncation and
  645. others kinds of format errors.
  646. 2004-10-30 Paul Rombouts <p.a.rombouts@home.nl>
  647. * src/rr_types.c
  648. I have included some changes proposed by Joseph Pecquet to address
  649. the compilation problems reported by FreeBSD users.
  650. 2004-10-18 Paul Rombouts <p.a.rombouts@home.nl>
  651. * acconfig.h,configure.in,src/helpers.c,src/helpers.h,src/dns.h
  652. I have merged a patch for CYGWIN support by Kiyo Kelvin Lee into
  653. my version of the code.
  654. 2004-10-15 Paul Rombouts <p.a.rombouts@home.nl>
  655. * src/cache.c
  656. Invalidating local records with the pdnsd-ctl did not work the way the
  657. documentation described. An invalidated local record would be always be
  658. purged at the next lookup, thus invalidation would practically have the
  659. same effect as deletion. An invalidated local record is of no use at all and
  660. would occupy space until it is purged during a lookup (but not by purge_cache).
  661. The function invalidate_record() now behaves as the documentation describes, i.e.
  662. invalidation of local records has no effect.
  663. 2004-09-27 Paul Rombouts <p.a.rombouts@home.nl>
  664. * doc/pdnsd.conf.5.in
  665. A new man page describing the format of the pdnsd config file has been
  666. added to the pdnsd package. I've used a customized Perl script to generate
  667. one automatically from the html documentation.
  668. 2004-09-14 Paul Rombouts <p.a.rombouts@home.nl>
  669. * src/hash.c
  670. The cache entries in a hash chain are now stored in order of increasing long hash
  671. value. The advantage is that if an name is looked up that is not present in the
  672. cache, this can be done by comparing with only half (on average) of the number
  673. of entries in the hash chain. Not a huge speed up, but still worth while, I think.
  674. Additionally, the number of hash computations for each add_cache() call has
  675. been halved.
  676. 2004-09-11 Paul Rombouts <p.a.rombouts@home.nl>
  677. * src/cache.c
  678. insert_rrl() will no longer add local records to the rr_l list, because
  679. purge_cache() ignores them anyway.
  680. 2004-09-08 Paul Rombouts <p.a.rombouts@home.nl>
  681. * src/dns.h,src/cache.c,src/dns_query.c,src/dns_answer.c,src/conf-parser.c
  682. I've started using GETINT16,GETINT32,PUTINT16,PUTINT32 macros, which are based
  683. on the NS_GET/NS_PUT macros that can be found in the BIND source, instead of memcpy
  684. for fetching and storing non-aligned integer data.
  685. 2004-09-08 Paul Rombouts <p.a.rombouts@home.nl>
  686. * src/cache.c,src/status.c,src/pdnsd-ctl/pdnsd-ctl.c
  687. New pdnsd-ctl command: "pdnsd-ctl dump" will print information about all the
  688. entries contained in the cache.
  689. "pdnsd-ctl dump <name>" will only print entries belonging to <name>.
  690. The data fields of the more common rr-types will be printed in human readable
  691. form, the remaining ones in a hexadecimal representation.
  692. With thanks to Dan Jacobson for suggesting this feature.
  693. 2004-08-31 Paul Rombouts <p.a.rombouts@home.nl>
  694. * src/conf-parser.c
  695. At the suggestion of Dan Tihelka, I have expanded to the server_ip= option
  696. to allow the name of an interface to be specified instead of an IP address.
  697. pdnsd will not bind to the interface name, but will lookup the address the
  698. interface has at start up, and listen on that address. If the address
  699. of the interface changes while pdnsd is running, pdnsd will not notice that.
  700. 2004-08-30 Paul Rombouts <p.a.rombouts@home.nl>
  701. * src/cache.h,src/cache.c
  702. I've reversed the meaning of the CF_NOAUTH and renamed it CF_AUTH.
  703. I've also added a domain level flag DF_AUTH, which is used to
  704. mark cache entries obtained from authoritave replies in response to
  705. a query of type * (all)..
  706. 2004-08-30 Paul Rombouts <p.a.rombouts@home.nl>
  707. * src/cache.c
  708. I've changed the format of the cache file. A typical cache entry has empty
  709. sets for most RR types (even more if DNS_NEW_RRS is defined). In the old
  710. format, each empty RR set was represented by a zero byte.
  711. In the new format only non-empty sets are respresented, leading
  712. to a (modest) reduction is size.
  713. 2004-08-28 Paul Rombouts <p.a.rombouts@home.nl>
  714. * src/conf-parser.c
  715. New option for "rr" sections in the config file: reverse=on/off.
  716. If you want a locally defined name to resolve to a numeric address and vice
  717. versa, you can now achieve this by setting reverse=on before defining the
  718. A record, making it unnecessary to define a seperate PTR record for the reverse
  719. resolving.
  720. 2004-08-20 Paul Rombouts <p.a.rombouts@home.nl>
  721. * src/cache.h,src/cache.c,src/conf-parser.c,src/dns_query.c
  722. At the request of Daniel Black, I have added support for defining local wildcard records
  723. in pdnsd. The only type supported presently is records beginning with '*.'.
  724. 2004-08-10 Paul Rombouts <p.a.rombouts@home.nl>
  725. * src/hash.c,src/cache.c,src/dns_query.c,src/dns_answer.c
  726. Sampo Lehtinen has remarked that pdnsd sometimes failed to resolve classless
  727. reversed-delegated IP addresses, and that this has something to do with the fact
  728. that pdnsd did not accept '/' characters in domain names. After reading Sampo's
  729. and Thomas' remarks, and also rfc2317 and some of the rfc's referenced in rfc2317,
  730. I decided pdnsd should place no restrictions at all on the types of characters it
  731. allows in domain names, only on the lengths of the byte sequences.
  732. This led me to make some quite extensive internal changes to pdnsd. Among other
  733. things domain names are now stored in transport format (sequences of bytes preceded
  734. by length bytes) instead of C strings. This is also more efficient because there
  735. is no need any more to convert from one representation to the other, except when
  736. reading the config file, interacting with pdnsd-ctl or running in debug mode.
  737. Conversion between the two representations isn't always possible, though.
  738. For example, domain names in transport format might contain non-printable characters.
  739. These are now printed as escape sequences (three octal digits preceded by a back slash).
  740. Presently there are still restrictions on the characters in the domain names that can
  741. be defined in local records. I doubt this will ever be considered a problem.
  742. 2004-08-02 Paul Rombouts <p.a.rombouts@home.nl>
  743. * src/dns_query.c
  744. The code for handling NXT records was flawed. A response from a remote server
  745. containing NXT records (even well-formed ones) could cause pdnsd to crash.
  746. The code for handling NAPTR records contained incorrect PDNSD_ASSERT statements,
  747. which could cause pdnsd to abort unnecessarily.
  748. 2004-07-25 Paul A. Rombouts <p.a.rombouts@home.nl>
  749. * src/list.h,src/list.c,src/dns.c,src/dns_query,src/dns_answer.c
  750. I've noticed that some of the (dynamic) arrays that pdnsd uses are quite sparse.
  751. Instead of using an array structure with elements that are large enough to contain
  752. the largest possible domain name, I've implemented a "list" data structure that
  753. is more compact. The elements of a list can only be accessed sequentially from
  754. beginning to end, but it allows more efficient memory use in case the names are
  755. significantly shorter that the maximum.
  756. 2004-07-22 Paul Rombouts <p.a.rombouts@home.nl>
  757. * src/conf-parser.c
  758. I've expanded pdnsd's configuration options by adding support in pdnsd for reading
  759. /etc/resolv.conf style files. Instead of specifying IP addresses in a server section,
  760. the option "file=<filename>" can be used.
  761. The IP addresses in the lines beginning with "nameserver" will be added to
  762. the list of address for that section, the remaining lines will be ignored.
  763. To avoid the possibility that pdnsd will query itself, local addresses are skipped
  764. (unless pdnsd is configured to listen on a different port number).
  765. 2004-07-21 Paul Rombouts <p.a.rombouts@home.nl>
  766. * src/cache.h,src/cache.c,src/dns_query.c,src/conf-parser.c
  767. New option for "server" sections in the config file: root_server=on/off.
  768. In case a server section contains only addresses of root servers, which
  769. usually only give the nameservers of top level domains in their reply,
  770. setting root_server=on will enable certain optimizations. This involves using
  771. cached information to reduce queries to the root servers, thus speeding up
  772. the resolving of new names. This option is also necessary to make the
  773. delegation_only option work in combination with root servers.
  774. 2004-07-16 Paul Rombouts <p.a.rombouts@home.nl>
  775. * src/cache.c,src/status.c,src/pdnsd-ctl/pdnsd-ctl.c
  776. New pdnsd-ctl command: "pdnsd-ctl empty-cache" will make pdnsd delete its entire
  777. cache, freeing all entries. This is useful for debugging purposes, or in situations
  778. where you suspect that stale cache entries are causing you problems, but you are not
  779. sure which ones.
  780. 2004-07-11 Paul Rombouts <p.a.rombouts@home.nl>
  781. * src/cache.c,src/dns_query.c
  782. I've removed the use of the function add_cache_rr_add(), which was used to
  783. add additional RR records to the cache one at a time. I've changed the code
  784. in dns_query.c such that additional (or off-topic) records are first collected
  785. in arrays of dns_cent_t structures, and then added to the cache using add_cache().
  786. With this approach only one function, viz. add_cache(), is used for adding
  787. new entries to the cache, which I believe leads to a cleaner programming
  788. interface. Added benefit is that query serial numbers are no longer
  789. necessary.
  790. 2004-07-10 Paul Rombouts <p.a.rombouts@home.nl>
  791. * src/cache.h,src/cache.c,src/dns_query.c,src/dns_answer.c
  792. I've added two new field to the dns_cent_t struct, namely c_ns and c_soa.
  793. These will be used to remember references to NS and SOA records in the authority
  794. sections of replies from remote name servers.
  795. This information can be used by pdnsd to fill in the authority section of its
  796. own reply.
  797. 2004-06-25 Paul Rombouts <p.a.rombouts@home.nl>
  798. * src/dns_query.c,src/servers.c,src/consts.c
  799. I've added an new server availability test which can be selected with "uptest=query".
  800. This can be useful as an alternative to "uptest=ping" in case the remote server does not
  801. respond to ICMP_ECHO requests at all, which unfortunately is quite common these days.
  802. "uptest=query" causes pdnsd to send an empty query to remote nameservers. Any well-formed
  803. response (apart from SERVFAIL) within the timeout period will be interpreted as a sign that the
  804. server is "up".
  805. In a sense this new availability test can actually be considered more reliable than the
  806. other ones that pdnsd supports.
  807. With thanks to Juliusz Chroboczek for suggesting this feature.
  808. 2004-06-24 Paul Rombouts <p.a.rombouts@home.nl>
  809. * src/helpers.c
  810. Don't use getpwnam() while we are multi-threaded, because it returns a pointer to
  811. a statically allocated structure. I will use getpwnam_r() instead, which is thread
  812. safe. Unfortunately there seem to be some portability problems with getpwnam_r().
  813. For those platforms that lack getpwnam_r(), I will keep the old code with getpwnam()
  814. as an alternative.
  815. 2004-06-23 Paul Rombouts <p.a.rombouts@home.nl>
  816. * src/servers.c
  817. Check that the number of IP addresses in a server section is nonzero before
  818. testing servers for availability. Otherwise pdnsd could crash in debug mode.
  819. 2004-06-21 Paul Rombouts <p.a.rombouts@home.nl>
  820. * src/conff.c,src/conf-parser.c,src/status.c,src/pdnsd-ctl/pdnsd-ctl.c
  821. New pdnsd-ctl command: "pdnsd-ctl config" will make pdnsd re-load its configuration file.
  822. In most cases (but there are still some exceptions) this is preferable
  823. to restarting pdnsd after making changes to the configuration file.
  824. An important advantage is that there should be no perceptible interruption in the dns service
  825. when using the reload command.
  826. An alternative config file can be specified with "pdnsd-ctl config <filename>".
  827. 2004-05-31 Paul Rombouts <p.a.rombouts@home.nl>
  828. * src/dns_answer.c,src/dns_query.c,src/dns_query.h
  829. I've made an adjustment to p_recursive_query() and related functions, so that
  830. when pdnsd chases name servers in pursuit of authoritative records, it avoids
  831. all the name servers already queried for the same name in the recursive calling
  832. chain, not just the servers most recently used.
  833. Although the hops counter will already break any possible cycles, this will
  834. allow pdnsd to detect pathological cycles earlier and waste less resources.
  835. * src/cache.c
  836. In add_cache(), don't add empty entries to the cache. Empty cache entries
  837. waste memory and are more persistent than non-empty ones, because purge_cache()
  838. cannot get rid of them.
  839. 2004-05-30 Paul Rombouts <p.a.rombouts@home.nl>
  840. * src/dns_answer.c,src/dns_query.c,src/icmp.c,src/netdev.c
  841. I've removed the calls to getprotobyname() and used the constants IPPROTO_TCP
  842. and IPPROTO_UDP instead. First of all, it doesn't seem very efficient to call
  843. a function repeatedly to look up the same well-known protocol numbers.
  844. More importantly, getprotobyname() stores its results in a statically-allocated
  845. structure and thus cannot be considered thread safe. (getprotobyname_r()
  846. is thread safe, but is not portable.)
  847. 2004-05-27 Paul Rombouts <p.a.rombouts@home.nl>
  848. * src/dns_answer.c
  849. I've noticed that when pdnsd is restarted shortly after it has answered a TCP
  850. query, it is often not able to bind to the TCP socket again, resulting in a
  851. disabled TCP server thread. The solution appears to be to set the SO_REUSEADDR
  852. socket option before binding the socket. This allows you to use the same port even
  853. if it is busy (in the TIME_WAIT state).
  854. I found the code for this in a patch file from an old Debian package.
  855. 2004-05-20 Paul Rombouts <p.a.rombouts@home.nl>
  856. * src/dns_query.c
  857. Joseph Pecquet has reported that version 1.1.11 does not compile under FreeBSD v4.x
  858. because the macro ENONET is undefined. I've bypassed the problem by surrounding
  859. the case line using this value with conditional preprocessor directives.
  860. 2004-05-08 Paul Rombouts <p.a.rombouts@home.nl>
  861. * src/rc/Slackware/rc.pdnsd
  862. I've included a Slackware start-up script contributed by Nikola Kotur.
  863. 2004-05-05 Paul Rombouts <p.a.rombouts@home.nl>
  864. * doc/pdnsd.8
  865. I'm very grateful to Mahesh T. Pai for contributing a pdnsd man page,
  866. which was still missing up till now.
  867. 2004-04-30 Paul Rombouts <p.a.rombouts@home.nl>
  868. * src/servers.c,src/dns_query.c
  869. After considering some suggestions made by Juliusz Chroboczek I have made the
  870. following changes:
  871. - After receiving a reply from a remote server mark the server up and update the
  872. timestamp so that pdnsd doesn't bother testing this server for availability for a
  873. while.
  874. - After detecting an error with an send/recv call that indicates a server is
  875. unavailable, mark a server down so that pdnsd doesn't bother testing this server
  876. for a while.
  877. - After server timeouts, uptests are never performed by a query/answer thread,
  878. because this may delay the sending of an answer to the client. Instead the
  879. timestamp of a server that needs to be tested for availability is set to zero and
  880. a condition signal is sent to alert the server status thread, which will carry out
  881. the test. Unresponsive servers with uptest=ping will not be marked down
  882. immediately any more, but only after the ping test has definitely failed.
  883. * src/error.c,src/error.h
  884. I've moved most of the code previously contained in the DEBUG_MSG macro to a new
  885. function debug_msg().
  886. The DEBUG_MSG macro now simply expands to "if(debug_p) debug_msg();".
  887. This should make the executable a little smaller, and be just as fast when
  888. debugging is off. The DEBUG_MSG macro still expands to nothing if pdnsd is built
  889. without debugging support.
  890. 2004-04-28 Paul Rombouts <p.a.rombouts@home.nl>
  891. * src/dns_query.h,src/dns_query.c
  892. I've tried to simplify the finite state machine used for processing parallel
  893. queries, by merging the "state" and "nstate" variables used by p_exec_query() and
  894. p_query_sm() resp. into one "state" variable.
  895. By introducing an extra field "iolen" to keep track of the number of bytes read
  896. from or written to a socket, I could also reduce the number of states for TCP
  897. queries. The new code has the additional advantage that it can handle situations
  898. that require multiple read() calls to receive a response.
  899. 2004-04-14 Paul Rombouts <p.a.rombouts@home.nl>
  900. * src/dns_query.c
  901. I've added an extra check comparing the number if poll/select events actually
  902. handled to the return value of poll/select. This should reduce the chance that
  903. pdnsd will get caught in a busy spin due to unknown remaining bugs. An error
  904. message is logged and an error code is returned when this comparison fails.
  905. 2004-04-13 Paul Rombouts <p.a.rombouts@home.nl>
  906. * src/dns_query.h,src/dns_query.c
  907. I got rid of the event field in the query_stat_t struct.
  908. I think it is redundant, because its value can be quite simply derived from
  909. the nstate field.
  910. 2004-04-12 Paul Rombouts <p.a.rombouts@home.nl>
  911. * src/dns_query.c
  912. I appears there was flaw in the code for handling a "Not Implemented" response
  913. from a remote server with the RA (recursion available) bit equal to zero. This
  914. could cause pdnsd to get into a busy spin. I traced the flaw back to Thomas
  915. Moestl's code, so it must be in all the versions of pdnsd I know of. In previous
  916. versions of pdnsd the busy spin would eventually time out. Due to some recent
  917. changes the loop would no longer time out, making the bug more noticeable.
  918. With thanks to Nicolas George for reporting the bug.
  919. I also discovered a closely related flaw that would cause pdnsd to poll() closed
  920. file descriptors. It usually works out OK in practice, but it is definitively not
  921. the correct way to do it.
  922. Additionally, I discovered some opportunities to save memory, e.g. by replacing
  923. the nsname buffer in the query_stat_t struct by a pointer to an already existing
  924. copy of a name.
  925. 2004-04-10 Paul Rombouts <p.a.rombouts@home.nl>
  926. * src/cache.c
  927. Nicolas George remarked that he thought it was strange that subdomains of domains
  928. negated with "neg" sections in the config file were not also negated. I thought that
  929. he had a point, and I've implemented a change so that negating example.com will
  930. now also negate www.example.com, xxx.adserver.example.com, etc.
  931. 2004-04-09 Paul Rombouts <p.a.rombouts@home.nl>
  932. * src/error.c,src/error.h
  933. I noticed that the code for the log_warn() and log_error() functions was almost
  934. identical, even to the point that log_warn() called syslog() with LOG_ERR
  935. priority. I've merged these two functions into one log_message() function.
  936. 2004-04-08 Paul Rombouts <p.a.rombouts@home.nl>
  937. * src/main.c,src/conf-parser.c
  938. The -4 and -6 command-line options should now work as advertised.
  939. This wasn't entirely trivial. The rule is that options on the command line
  940. override those in the configuration file. The easiest way to implement this is to
  941. process the command-line options after reading the configuration file. But this
  942. doesn't work for the -4 and -6 options, because the run_ipv4 flag determines how
  943. IP addresses in the config file are parsed. I've inserted some extra tests and
  944. warning messages that will hopefully make this setting nearly foolproof.
  945. I've added two new command-line options, "-a" and "-i <prefix>".
  946. With the -a flag pdnsd will try to detect automatically if IPv6 support is
  947. available on a system, and fall back to IPv4 if not. The -a flag can be used
  948. instead of -4 or -6.
  949. In IPv6 mode, pdnsd will now automatically convert IPv4 addresses to IPv6-mapped
  950. addresses. The -i option can be used to specify a prefix for this mapping. The
  951. default is ::ffff.0.0.0.0
  952. There is also a corresponding ipv4_6_prefix= option for the config file.
  953. In IPv4 mode, if IPv6 support is compiled in, pdnsd will now skip IPv6 addresses
  954. in the config file (except for the server_ip and ping_ip options) with a warning
  955. message. This allows you to have mixed sets of IPv4 and IPv6 address in the same
  956. config file, although in IPv4 mode some server sections may become inactive.
  957. With thanks to Juliusz Chroboczek for suggesting these changes.
  958. 2004-04-07 Paul Rombouts <p.a.rombouts@home.nl>
  959. * src/cache.c
  960. I've changed some of the cache-flag definitions to make debugging a little simpler.
  961. Unfortunately, this makes the cache files of previous pdnsd versions incompatible
  962. with the new one. I've introduced a cache version identifier to be added at the
  963. beginning of each cache file. This enables pdnsd to recognize and discard
  964. incompatible cache files.
  965. 2004-04-05 Paul Rombouts <p.a.rombouts@home.nl>
  966. * src/cache.h,src/cache.c
  967. I've changed the way CACHE_LAT (cache latency, normally 120 secs) is used to
  968. determine whether a cache entry has timed out. Instead of simply adding it to the
  969. ttl (time to live), I use CACHE_LAT if the ttl is less then CACHE_LAT, else the
  970. ttl itself, making CACHE_LAT the minimum ammount of time a cache entry stays in
  971. the cache.
  972. 2004-04-02 Paul Rombouts <p.a.rombouts@home.nl>
  973. * src/dns_query.c
  974. I've introduced a global timeout parameter. This is the minimum period of time
  975. pdnsd will wait after sending the first query to a remote server before giving
  976. up without having received a reply.
  977. The timeout options in the configuration file are now only minimum timeout intervals.
  978. Setting the global timeout option makes it possible to specify quite short timeout
  979. intervals in the server sections. This will have the effect that pdnsd will start
  980. querying additional servers fairly quickly if the first servers are slow to respond
  981. (but will still continue to listen for responses from the first ones).
  982. This may allow pdnsd to get an answer more quickly in certain situations.
  983. * src/dns_query.c
  984. When receiving a NXDOMAIN (unknown domain) response from a remote name server,
  985. I think it is still useful to process the authority and additional sections,
  986. so that pdnsd can possibly add a SOA record to its own response.
  987. 2004-04-01 Paul Rombouts <p.a.rombouts@home.nl>
  988. * src/dns_query.c
  989. In p_recursive_query(), I've slightly changed the way pdnsd does parallel
  990. queries. Active queries or not canceled until we have received a useful response
  991. from a remote name server, or all the queries have failed or timed out.
  992. Thus the par_queries parameter is no longer the maximum number of parallel
  993. queries, but rather the increment with which the number of parallel queries is
  994. increased when the previous set has timed out.
  995. In the worst case all the servers in the list of available servers will be queried
  996. simultaneously. We may be wasting more system resources this way, but the advantage
  997. is that we have a greater chance of catching a reply.
  998. After all, if we wait longer anyway, why not for more servers.
  999. 2004-03-31 Paul Rombouts <p.a.rombouts@home.nl>
  1000. * src/dns_answer.c
  1001. I've noticed that in compose_answer() that while adding the name in the query
  1002. section it was not passed through compress_name(). While it is true that the
  1003. first name occurrence cannot be compressed, it is still sensible to process the
  1004. query name with compress_name() so that the offset can be stored and provide
  1005. additional opportunities for future compressions.
  1006. I've tested this with dig and the responses of pdnsd are now usually a little
  1007. smaller in size or can hold more information within the 512 byte limit.
  1008. 2004-03-30 Paul Rombouts <p.a.rombouts@home.nl>
  1009. * src/cache.c
  1010. I've noticed that pdnsd stored rr records (of the same type) in reverse order
  1011. in the cache.
  1012. Although I don't see anything inherently wrong with that, I think it's neater to
  1013. store them in the order they are processed.
  1014. 2004-03-29 Paul Rombouts <p.a.rombouts@home.nl>
  1015. * src/cache.c
  1016. I've rearranged the order of the arguments of some of the functions in cache.c
  1017. to obtain a more consistent calling interface.
  1018. * src/dns_answer.c
  1019. I've noticed that pdnsd would only add NS records to an authority section if it could
  1020. find such records matching the queried name (or the last CNAME in the answer) exactly.
  1021. However, I understand that a server should try to give NS records as close as possible
  1022. to the target name in the naming hierarchy.
  1023. I also understand that if a domain name is reported as nonexisting, or no record of
  1024. the requested type exists, it is customary to provide a SOA record, searching up the
  1025. name hierarchy if necessary.
  1026. I've tried to implement this in compose_answer(), although with some limitations.
  1027. I only look in the cache, I don't search more then three levels up, and stop before
  1028. the top level.
  1029. 2004-03-28 Paul Rombouts <p.a.rombouts@home.nl>
  1030. * src/cache.c,src/dns_answer.c
  1031. There were some issues with add_cache_rr_add().
  1032. First of all, the way it was used in rr_to_cache() (or rather not used) meant
  1033. that if an "off topic" record was added for a name that lacked an entry in the
  1034. cache, the rr set would be created with an incorrect serial number (namely zero).
  1035. I've rewritten add_cache_rr_add so that it can create new cache entries if necessary.
  1036. This simplifies the code in rr_to_cache() and ensures correct serial numbers.
  1037. Secondly, in add_cache_rr_add() the ttl was compared with that of an existing rrset
  1038. without adjusting for the min_ttl and max_ttl options. This could lead to all the
  1039. previous records being deleted, retaining only the last one.
  1040. 2004-03-27 Paul Rombouts <p.a.rombouts@home.nl>
  1041. * src/dns_answer.c
  1042. In compose_answer(), if the rd (recursion desired) bit is set in the query
  1043. and the response contains a CNAME record (while a different type of record was
  1044. requested), always do a recursive query on the CNAME, even if we have already
  1045. added a record of the requested type to the response.
  1046. Failing to honor the rd bit will cause some resolver libraries to complain,
  1047. even if the answer contains a record of the requested type.
  1048. I've slightly changed the calling interfaces of add_to_response() and add_rrset()
  1049. to make them more consistent and efficient.
  1050. In add_rrset() I've fixed a memory leak on one of the error paths.
  1051. In add_additional_rr(), the return value of add_rr() was not checked.
  1052. If add_rr() fails, it will free *ans, and functions higher up the calling
  1053. chain could be referencing freed memory.
  1054. I've fixed a potential referencing of freed memory or double freeing in add_additional_a().
  1055. If a call of add_additional_rr() fails, it will free *ans.
  1056. Previously, add_additional_rr() could be called a second time, in which case
  1057. the second call would be referencing freed memory or freeing it a second time..
  1058. 2004-03-23 Paul Rombouts <p.a.rombouts@home.nl>
  1059. * configure.in, src/Makefile.in,src/pdnsd-ctl/Makefile.in,src/test/Makefile.in
  1060. Frédéric L. W. Meunier has reported that configure --srcdir option (for building
  1061. in directory separate from the source directory) was broken.
  1062. Should be fixed now.
  1063. 2004-03-20 Paul Rombouts <p.a.rombouts@home.nl>
  1064. * src/dns_answer.c,src/dns_query.c,src/helpers.c,src/icmp.c,src/main.c,src/netdev.c,src/ipvers.h,src/test/if_up.c,src/test/is_local_addr.c,src/test/tping.c,src/test/random.c,src/conf-parser.c
  1065. I've eliminated the global variable run_ipv6 from the code.
  1066. Enabling both the IPv4 and IPv6 protocols at the same time is not supported
  1067. in pdnsd, so the value of run_ipv6 (if it is defined) is simply !run_ipv4.
  1068. * src/dns.c,src/test/is_local_addr.c,src/test/tping.c
  1069. It appears the option to compile pdnsd without IPv4 support (i.e. only IPv6
  1070. support) was broken. Should be fixed now.
  1071. 2004-03-19 Paul Rombouts <p.a.rombouts@home.nl>
  1072. * src/cache.c
  1073. I've discovered an incorrect use of cache locks in lookup_cache().
  1074. We only read locks in place, it is possible for purge_cent() to delete a cache
  1075. entry while another thread is trying to read it at the same time, which could
  1076. lead to trouble. I've rewritten purge_cent() so that it can be used to test
  1077. whether something needs to be purged without actually deleting anything.
  1078. If something needs to be deleted, purge_cent() will be called again with
  1079. the proper read/write locks in place, excluding access to the cache for all
  1080. other threads.
  1081. 2004-03-18 Paul Rombouts <p.a.rombouts@home.nl>
  1082. * src/cache.c
  1083. I've added a new function sort_rrl() for sorting the rr_l list using a merge-sort
  1084. algorithm. Usually the insertion sort used by insert_rrl() is good enough, because
  1085. new entries belong near the end most of the time. Reading entries from disk forms
  1086. an exception, though, because the rrsets in the file are completely out of order
  1087. w.r.t. timestamps, leading to quadratic time complexity of the insertion sort method.
  1088. In that case it should be faster to simply append items at the end of the rr_l list
  1089. and sort using a more efficient algorithm afterwords.
  1090. pdnsd now seems to start up noticeably faster when reading large cache files.
  1091. I've also considered using a more sophisticated data structure than a doubly linked
  1092. list, but this will add considerable complexity to the code and use more memory.
  1093. 2004-03-13 Paul Rombouts <p.a.rombouts@home.nl>
  1094. * src/dns_answer.c
  1095. Changed a declaration in udp_answer_thread() so that the buffer used for passing
  1096. control messages on to sendmsg() is exactly the right size, instead of an arbitrary
  1097. 512 bytes.
  1098. Also initialized the msg_flags of the struct msghdr passed on to sendmsg() to zero,
  1099. to keep Valgrind from complaining about uninitialized bytes.
  1100. 2004-03-12 Paul Rombouts <p.a.rombouts@home.nl>
  1101. * src/icmp.c
  1102. Fixed an incorrect call to select() in ping4(). A file descriptor set for detecting
  1103. exceptions was initialized but not passed on to select(). This would lead subsequent
  1104. code always to behave as if an IO exception had occurred.
  1105. Valgrind seems to indicate that when a poll() call times out and returns 0,
  1106. the revents field of the struct pollfd is not necessarily set.
  1107. I've changed the code to check that the return value is > 0 before examining the
  1108. revents field.
  1109. 2004-02-06 Paul Rombouts <p.a.rombouts@home.nl>
  1110. * src/conf-parser.c,src/conf-parser.h,src/conf-keywords.h
  1111. I've rewritten the parser for the configuration file in C from scratch.
  1112. (f)lex and yacc/bison are no longer needed to build pdnsd.
  1113. 2004-01-16 Paul Rombouts <p.a.rombouts@home.nl>
  1114. * src/main.c
  1115. Load the cache from disk without locking cache access because pdnsd
  1116. is still single-threaded at that point.
  1117. 2004-01-15 Paul Rombouts <p.a.rombouts@home.nl>
  1118. * src/cache.c,src/hash.c
  1119. Moved the responsibility for freeing the cache entries referred by
  1120. the hash buckets from destroy_cache() to free_dns_hash() (which is called
  1121. by destroy_cache()). Previously, the cache and hash tables were already
  1122. completely destroyed by the time free_dns_hash() was called, and there was
  1123. nothing left for free_dns_hash() to free.
  1124. 2004-01-14 Paul Rombouts <p.a.rombouts@home.nl>
  1125. * src/hash.c,src/make_hashconvtable.c
  1126. The hash conversion table is now generated at build time instead
  1127. of at run time when pdnsd is started up.
  1128. 2004-01-13 Paul Rombouts <p.a.rombouts@home.nl>
  1129. * src/dns.c
  1130. In add_host() fixed incorrect generation of IPV6 type of name for PTR record
  1131. due to use of && instead of & as masking operator.
  1132. 2004-01-13 Paul Rombouts <p.a.rombouts@home.nl>
  1133. * src/icmp.c, src/dns_answer.c
  1134. Use unsigned long instead of int error counters to reduce the danger
  1135. of wraparound.
  1136. 2004-01-06 Paul Rombouts <p.a.rombouts@home.nl>
  1137. * src/main.c,src/thread.c,src/thread.h,src/server.c,src/status.c,src/dns_answer.c
  1138. Initialize a global thread attribute object in main.c and use it to create all the detached
  1139. threads, instead of initializing a separate attribute object for each new thread.
  1140. 2004-01-06 Paul Rombouts <p.a.rombouts@home.nl>
  1141. * src/dns_answer.c
  1142. Check the return value of pthread_create() in udp_server_thread()
  1143. and tcp_server_thread() to ensure that a new answer thread has actually
  1144. been created and free resources if not.
  1145. 2004-01-04 Paul Rombouts <p.a.rombouts@home.nl>
  1146. * src/helpers.c,src/cache.c,src/conff.c,src/status.c
  1147. Stop writing to control socket after an error has been detected.
  1148. 2004-01-03 Paul Rombouts <p.a.rombouts@home.nl>
  1149. * src/pdnsd-ctl/pdnsd-ctl.c
  1150. Tried to make the error messages of pdnsd-ctl more helpful.
  1151. The complete usage description is now only printed if the 'help' command
  1152. is used. For problems with other commands a much shorter message is generated
  1153. specific for that command.
  1154. 2004-01-02 Paul Rombouts <p.a.rombouts@home.nl>
  1155. * src/helpers.h
  1156. Changed the definition of rhnlen(). For valid data this will make no difference,
  1157. but it may change the behaviour of pdnsd in certain error situations.
  1158. 2004-01-02 Paul Rombouts <p.a.rombouts@home.nl>
  1159. * src/dns.c
  1160. Optimized compress_name() some more.
  1161. 2004-01-02 Paul Rombouts <p.a.rombouts@home.nl>
  1162. * src/dns_answer.c
  1163. Additional code cleanup in compose_answer().
  1164. 2004-01-01 Paul Rombouts <p.a.rombouts@home.nl>
  1165. * doc/pdnsd-ctl.8
  1166. Updated the pdnsd-ctl man page.
  1167. 2003-12-31 Paul Rombouts <p.a.rombouts@home.nl>
  1168. * src/pdnsd-ctl/pdnsd-ctl.c
  1169. Cleaned up some code.
  1170. 2003-12-31 Paul Rombouts <p.a.rombouts@home.nl>
  1171. * src/status.c,src/conff.h,src/conff.c
  1172. Some further code cleanup in status.c.
  1173. Labels for server sections are no longer limited to 32 chars,
  1174. but can have arbitrary length. The string that is used to specify
  1175. new DNS-addresses with the "pdnsd-ctl server" command can now also
  1176. have arbitrary length.
  1177. 2003-12-30 Paul Rombouts <p.a.rombouts@home.nl>
  1178. * doc/html/doc.html
  1179. Added information about CNAME and MX resource records, that were
  1180. previously undocumented.
  1181. 2003-12-26 Paul Rombouts <p.a.rombouts@home.nl>
  1182. * src/dns_query.c
  1183. Removed the function p_dns_resolve_from(). This function was essentially
  1184. a call to p_recursive_query() with a dummy nocache argument.
  1185. p_recursive_query() can now be called with nocache=NULL instead.
  1186. 2003-12-26 Paul Rombouts <p.a.rombouts@home.nl>
  1187. * src/dns_query.c
  1188. Using a variable length array instead of an malloced buffer to hold the struct pollfd array
  1189. in p_recursive_query(). This has the potential for causing portability problems, but I
  1190. think that's unlikely because almost all the major C compilers I work with support variable
  1191. length arrays nowadays.
  1192. 2003-10-18 Paul Rombouts <p.a.rombouts@home.nl>
  1193. * src/helpers.h,src/helpers.c
  1194. Fixed a mistake that caused a compile error when using the --with-random-device
  1195. configuration option.
  1196. Thanks to Daniel Black for reporting this bug.
  1197. 2003-10-02 Paul Rombouts <p.a.rombouts@home.nl>
  1198. * conf-lex.l.in,src/conf-parse.y,src/conff.h,src/conff.c,src/dns_query.c
  1199. Made the "delegation_only" feature configurable.
  1200. 2003-09-25 Paul Rombouts <p.a.rombouts@home.nl>
  1201. * src/helpers.c,src/helpers.h
  1202. Added alternative implementations of strdup, strndup, stpcpy, getline and asprintf
  1203. in an effort to make the code more portable.
  1204. 2003-09-22 Paul Rombouts <p.a.rombouts@home.nl>
  1205. * src/helpers.c,src/conf-parse.y
  1206. Made some changes to the parser of the configuration file so that domain names
  1207. missing a dot at the end will be tolerated.
  1208. 2003-09-21 Paul Rombouts <p.a.rombouts@home.nl>
  1209. * src/dns_query.c
  1210. Implemented a first version of the "delegation-only" feature.
  1211. It has been "hard-coded" to work for "com" and "net" zones,
  1212. and is not yet configurable.
  1213. 2003-09-21 Paul Rombouts <p.a.rombouts@home.nl>
  1214. * src/dns.c
  1215. Rewrote domain_match(). Also changed the way it is used.
  1216. I believe it has a cleaner semantics now.
  1217. 2003-09-21 Paul Rombouts <p.a.rombouts@home.nl>
  1218. * src/dns_query.c
  1219. Changed the order of the arguments of p_exec_query() and p_recursive_query()
  1220. to make it more consistent with the other functions.
  1221. 2003-09-18 Paul Rombouts <p.a.rombouts@home.nl>
  1222. * src/dns_answer.c
  1223. Reordered the code in process_query() so that a buffer for an error response is
  1224. allocated only when it is actually needed.
  1225. 2003-09-17 Paul Rombouts <p.a.rombouts@home.nl>
  1226. * src/cache.c
  1227. Added parentheses to correct mistaken operator precedence assumption in cache.c.
  1228. !cent->flags&DF_NEGATIVE is parsed as (!(cent->flags))&DF_NEGATIVE but I think
  1229. what Thomas Moestl must have intended was !((cent->flags)&DF_NEGATIVE).
  1230. 2003-09-12 Paul Rombouts <p.a.rombouts@home.nl>
  1231. * src/dns_query.c
  1232. Fixed a mistake which caused the effect of the proxy_only option to be reversed.
  1233. Thanks to Andrew M. Bishop <amb@gedanken.demon.co.uk> for reporting this bug.
  1234. 2003-09-11 Paul Rombouts <p.a.rombouts@home.nl>
  1235. * src/helpers.c
  1236. Rewrote str2rhn() and rhn2str().
  1237. 2003-09-10 Paul Rombouts <p.a.rombouts@home.nl>
  1238. * src/dns.c
  1239. Rewrote read_hosts(), the function that reads /etc/hosts-style input.
  1240. I believe the parsing algorithm is more robust now.
  1241. 2003-09-09 Paul Rombouts <p.a.rombouts@home.nl>
  1242. * src/status.c,src/pdnsd-ctl/pdnsd-ctl.c
  1243. Fixed a bug (my fault) that caused improper passing on of flags for the
  1244. pdnsd-ctl source command.
  1245. Also reordered some of the code, so that data is validated after all of it
  1246. has been read from the control socket. This should prevent a "broken pipe"
  1247. error message if data validation fails.
  1248. Also fixed the reporting of success or failure of the pdnsd-ctl "neg" command.
  1249. 2003-09-08 Paul Rombouts <p.a.rombouts@home.nl>
  1250. * src/list.c
  1251. Rewrote da_grow1() and da_resize() so that they automatically allocate an array
  1252. if given a NULL argument. This makes the use of da_create() redundant in most cases.
  1253. 2003-09-08 Paul Rombouts <p.a.rombouts@home.nl>
  1254. * src/conf-parse.y,src/servers.c
  1255. At the suggestion of Greg Norris, I changed the code to allow server sections in the
  1256. configuration file that don't specify any IP addresses. Such a section will remain
  1257. inactive until one or more IP addresses are assigned with the control utility pdnsd-ctl.
  1258. 2003-09-04 Paul Rombouts <p.a.rombouts@home.nl>
  1259. * src/dns_answer.c,src/dns_query.c
  1260. Oops: in my zeal to declare variables in the smallest possible scope, I ended up
  1261. using a pointer to a struct that was out of scope. My understanding of compilers tells me
  1262. it should work out OK in practice, but it is definitely a no-no.
  1263. Used a union declared in a larger scope instead (which is ugly in another way,
  1264. but equally efficient).
  1265. Also removed a section of redundant code in udp_server_thread().
  1266. 2003-09-01 Paul Rombouts <p.a.rombouts@home.nl>
  1267. * src/dns_query.c
  1268. Corrected the iteration range of a for loop in p_dns_cached_resolve(), which would
  1269. otherwise cause an array to be indexed out of bounds in the function set_flags_ttl().
  1270. 2003-08-31 Paul Rombouts <p.a.rombouts@home.nl>
  1271. * src/dns_answer.c
  1272. Added cleanup handlers for freeing the resources passed on to udp_answer_thread() and
  1273. tcp_answer_thread(). This should ensure the resources are freed even if the threads get
  1274. canceled.
  1275. 2003-08-30 Paul Rombouts <p.a.rombouts@home.nl>
  1276. * src/cache.c
  1277. Revised large portions of code in src/cache.c, used for adding and deleting entries in
  1278. the cache. In particular, I rewrote purge_cache(), which I believe was incorrect.
  1279. I wouldn't be surprised if this was the cause of the crashed (defunct) threads that some
  1280. people were reporting.
  1281. Also fixed some memory leaks.
  1282. 2003-08-28 Paul Rombouts <p.a.rombouts@home.nl>
  1283. * src/cache.c
  1284. Eliminated the overhead of allocation debugging in the case that ALLOC_DEBUG is not defined.
  1285. 2003-08-24 Paul Rombouts <p.a.rombouts@home.nl>
  1286. * src/conf-parse.y
  1287. No longer allow certain settings of the query_method option in the configuration file
  1288. if pdnsd is not compiled with the necessary support.
  1289. Thanks to Nikolaus Rath <Nikolaus@rath.org> for reporting the bug.
  1290. 2003-08-23 Paul Rombouts <p.a.rombouts@home.nl>
  1291. * src/netdev.c
  1292. Fixed a bug in is_local_addr() where the result of fgetc(f) is restricted to type char
  1293. before being compared to EOF, which can result in the comparison always being false.
  1294. Thanks to Gerhard Tonn <GerhardTonn@gammatau.de> for reporting the bug.
  1295. 2003-07-28 Paul Rombouts <p.a.rombouts@home.nl>
  1296. * doc/html/index.html,doc/html/doc.html,doc/html/dl.html,doc/pdnsd-ctl.8,contrib/README
  1297. Revised the documentation.
  1298. 2003-07-21 Paul Rombouts <p.a.rombouts@home.nl>
  1299. * src/main.c,src/status.c,src/icmp.c
  1300. Setting stat_pipe=0 after opening or binding the control socket fails.
  1301. This should prevent further use of the control socket if a problem with
  1302. it has been detected previously.
  1303. Also properly initialized the global variable int ping_isocket in src/icmp.c
  1304. 2003-07-13 Paul Rombouts <p.a.rombouts@home.nl>
  1305. * src/main.c
  1306. Polished the code in main().
  1307. 2003-07-04 Paul Rombouts <p.a.rombouts@home.nl>
  1308. * src/helpers.c,src/dns_answer.c,src/dns_query.c
  1309. Eliminated the use of inet_ntoa() in favor of the more modern inet_ntop().
  1310. inet_ntop() makes more sense in threaded code and is also recommended in
  1311. the glibc info pages.
  1312. 2003-07-03 Paul Rombouts <p.a.rombouts@home.nl>
  1313. * src/dns_query.c
  1314. Fixed an allocation size error (not mine) in p_exec_query().
  1315. The erroneous size is almost always larger than necessary, so in practice this bug
  1316. just wastes memory. But there is also a possibility that the allocated buffer is too
  1317. small, which would mean trouble.
  1318. Also fixed two memory leaks on some of the error paths in p_exec_query().
  1319. 2003-06-28 Paul Rombouts <p.a.rombouts@home.nl>
  1320. * acconfig.h,configure.in,src/thread.h
  1321. Extended the configuration option --with-thread-lib.
  1322. Configuring with --with-thread-lib=linuxthreads2 will cause the alternative
  1323. definition of THREAD_SIGINIT suggested by Thomas Moestl to be used.
  1324. 2003-06-27 Paul Rombouts <p.a.rombouts@home.nl>
  1325. * src/consts.h,src/consts.c,src/conff.c,src/conf-parse.y,src/dns_answer.c
  1326. Added two new configuration options for policies of inclusion/exclusion lists.
  1327. The new policies options are "simple_only" and "fqdn_only".
  1328. This allows me to control to which name servers pdnsd will direct queries for
  1329. simple host names.
  1330. I also polished the code a bit in report_conf_stat(), used for reporting the current configuration.
  1331. 2003-06-20 Paul Rombouts <p.a.rombouts@home.nl>
  1332. * acconfig.h,configure.in,src/thread.h,src/thread.c
  1333. Added a configuration option --with-thread-lib=nptl.
  1334. This causes the macro THREAD_SIGINIT to be defined as empty in src/thread.h,
  1335. and thread_sig() in src/thread.c is never used.
  1336. 2003-06-11 Paul Rombouts <p.a.rombouts@home.nl>
  1337. * src/thread.h
  1338. Undid the change to the definition of THREAD_SIGINIT suggested to me by
  1339. Thomas Moestl, after receiving a report of a problem with this change
  1340. from someone running SuSE 7.0.
  1341. 2003-06-06 Paul Rombouts <p.a.rombouts@home.nl>
  1342. * src/dns_query.c:
  1343. Discovered that I failed to preserve the semantics of Thomas Moestl's code
  1344. when I rewrote a section of code in use_server(). Fixed.
  1345. 2003-05-19 Paul Rombouts <p.a.rombouts@home.nl>
  1346. * src/cache.c,src/conf-lex.l.in,src/conf-parse.y,src/conff.h,src/dns_answer.c,src/dns_query.c,src/servers.c:
  1347. Merged fixes contained in patch file sent to me by Thomas Moestl with my own version.
  1348. Changing the version to 1.1.8b1 as suggested by the patch file.
  1349. 2003-02-26 Paul Rombouts <p.a.rombouts@home.nl>
  1350. * pdnsd-1.1.7a-par.diff:
  1351. Made one big patch file from all the changes I made up till now.
  1352. Wrote a description of the changes in a file README.par
  1353. Posted patch file on the web so others can use it.
  1354. 2003-02-24 Paul Rombouts <p.a.rombouts@home.nl>
  1355. * src/cache.c
  1356. Changed the code that writes the cache to disk.
  1357. Data is now written strictly sequentially, eliminating the need for fseek().
  1358. This seems to have successfully solved the problem I had with corrupt cache files.
  1359. 2002-05-27 Paul Rombouts <p.a.rombouts@home.nl>
  1360. * ChangeLog:
  1361. Started experimenting with the source code.
  1362. Made many changes between 2002-05-27 and 2002-07-13.
  1363. Too lazy to maintain the ChangeLog.
  1364. 2002-01-06 Thomas Moestl <tmoestl@gmx.net>
  1365. * version: Call it 1.1.7.
  1366. 2002-01-04 Thomas Moestl <tmoestl@gmx.net>
  1367. * src/dns_answer.c, src/dns_query.c:
  1368. Comment and debug message fixes, more assertions.
  1369. 2002-01-03 Thomas Moestl <tmoestl@gmx.net>
  1370. * src/dns.c, src/dns_answer.c, src/dns_query.c:
  1371. More harmless fixes, correct some comments and debug messages, add more
  1372. assertions.
  1373. * NEWS, version: 1.1.7p2, correct NEWS entry.
  1374. * src/helpers.c:
  1375. Make sure the calling thread of pdnsd_exit() terminates immediately.
  1376. 2002-01-02 Thomas Moestl <tmoestl@gmx.net>
  1377. * src/dns_answer.c, src/helpers.c, src/icmp.c:
  1378. Fix a few more harmless bugs, more paranoia.
  1379. * src/status.c: Fix yet more, probably harmless, problems.
  1380. 2002-01-01 Thomas Moestl <tmoestl@gmx.net>
  1381. * src/dns.h, src/dns_answer.c, src/dns_query.c:
  1382. Fix a few more possible buffer size problems, and add a bunch of
  1383. assertions as last lines of defence.
  1384. 2001-12-30 Thomas Moestl <tmoestl@gmx.net>
  1385. * src/dns.c: Build fix (include error.h).
  1386. * NEWS, version: Call it 1.1.7p1, and add a NEWS entry.
  1387. * TODO: Reduce TODO to what actually is still needed.
  1388. * src/dns.c, src/error.h, src/helpers.c:
  1389. Add a bunch of robustness PDNSD_ASSERT()'s.
  1390. * src/dns_query.c:
  1391. Fix a bug which may possibly be remotely exploitable to gain access as
  1392. the user pdnsd runs as.
  1393. This was caused by a dumb single-character mistake :(
  1394. * doc/Makefile.am, configure.in:
  1395. Avoid confusing automake 1.5 by not putting a comment into a make rule.
  1396. Fix CONFDIR passing.
  1397. Submitted by: GoTaR <gotar@poczta.onet.pl>
  1398. * src/pdnsd-ctl/pdnsd-ctl.c:
  1399. Avoid crashing when the buffer contents received using the status command
  1400. are not terminated.
  1401. 2001-10-14 Thomas Moestl <tmoestl@gmx.net>
  1402. * src/rc/SuSE/pdnsd.in, THANKS:
  1403. Fix the stop case for the SuSE rc script: killproc requires the full
  1404. path of the binary as argument (reported by Bernhard Pelz).
  1405. 2001-09-23 Thomas Moestl <tmoestl@gmx.net>
  1406. * configure.in:
  1407. Revamp the OS autodetect test. OpenBSD and (hopefully) NetBSD are no longer
  1408. unsupported.
  1409. * src/helpers.c, THANKS:
  1410. Do not try to use arc4random when compiling for NetBSD (submitted by
  1411. Thomas Stromberg).
  1412. 2001-09-10 Thomas Moestl <tmoestl@gmx.net>
  1413. * COPYING.BSD: s/REGENTS/AUTHOR/ in one place.
  1414. * src/cache.c:
  1415. It is possible no record of the requested type is present after calling
  1416. cr_add_cent_rr_int() (when the record was marked as being local), so
  1417. check before dereferencing the pointer to the respective rrset.
  1418. Leave the record unmodified when cr_check_add() returns 0.x
  1419. 2001-07-26 Thomas Moestl <tmoestl@gmx.net>
  1420. * src/rc/RedHat/pdnsd.in:
  1421. Add a workaround for @sysconfdir@ substitutions containing ${prefix}.
  1422. Spotted by Robert Linden.
  1423. 2001-07-04 Thomas Moestl <tmoestl@gmx.net>
  1424. * src/rc/RedHat/pdnsd.in:
  1425. Add a condrestart handler to the Red Hat rc script, and do some general
  1426. cleanup. Contributed by Christian Engstler.
  1427. 2001-07-02 Thomas Moestl <tmoestl@gmx.net>
  1428. * src/error.h:
  1429. Attempt to detect a gcc that cannot yet handle ANSI variadic macros,
  1430. and work around this by using the old GCC-style variant.
  1431. * src/conff.c:
  1432. Remove a + at the start of a line that got in when merging a diff by
  1433. hand.
  1434. * src/servers.c: waitpid() returns a pid_t.
  1435. * src/dns.c:
  1436. It's sizeof, not sizof. This should unbreak the IPv6 build. Also silence
  1437. some warnings with appropriate casts.
  1438. * NEWS, version: Call it 1.1.6, and add a NEWS entry.
  1439. 2001-07-01 Thomas Moestl <tmoestl@gmx.net>
  1440. * src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/dns_query.c, THANKS, version, AUTHORS:
  1441. Added a modified version of Andreas Steinmetz's code for
  1442. query_port_start and query_port_range, and added him to AUTHORS and
  1443. THANKS.
  1444. 2001-06-23 Thomas Moestl <tmoestl@gmx.net>
  1445. * src/cache.c:
  1446. Fix a bogon: deleted would not be reset correctly in the first
  1447. purge_cache loop, which could cause pdnsd to loop forever when a
  1448. negative record was after a deleted rr.
  1449. 2001-06-21 Thomas Moestl <tmoestl@gmx.net>
  1450. * src/list.h:
  1451. Add (currently unused) list macros that are going to be used in future
  1452. code.
  1453. * src/cache.c:
  1454. Fix a bogon in the rw lock code: we need to wake up a writer if there
  1455. are no readers. The old code was a leftover from a time when
  1456. SUSP_THRESH was just r_pend * x.
  1457. Fix a typo.
  1458. 2001-06-13 Thomas Moestl <tmoestl@gmx.net>
  1459. * AUTHORS: Add mention of FreeBSD code to AUTHORS.
  1460. * src/netdev.c:
  1461. Add SIZEOF_ADDR_IFREQ (taken from FreeBSD: _SIZEOF_ADDR_IFREQ, net/if.h
  1462. rev. 1.58.2.1) and add an appropriate copyright notice.
  1463. The reason for this is that other BSDs don't have it, and we are not
  1464. supposed to use underscored macros in portable software.
  1465. 2001-06-12 Thomas Moestl <tmoestl@gmx.net>
  1466. * src/icmp.c: Fix double #inclusion of <netinet/ip.h>.
  1467. Noticed by Sebastian Stark.
  1468. 2001-06-08 Thomas Moestl <tmoestl@gmx.net>
  1469. * src/dns_query.c, THANKS:
  1470. Allow underscores in the query names reported back, as the comment next
  1471. to the decompress_name call already indicated (but the call gave NULL
  1472. as the uscore parameter, which disables underscores normally).
  1473. Add Michael Ströder, who spotted this, to THANKS.
  1474. 2001-06-06 Thomas Moestl <tmoestl@gmx.net>
  1475. * src/servers.c, THANKS:
  1476. Fix a bug discovered by Stefan Erhardt (and add him to THANKS): the
  1477. return value of waitpid was misinterpreted.
  1478. 2001-06-04 Thomas Moestl <tmoestl@gmx.net>
  1479. * Makefile.am, file-list.base.in, version:
  1480. Bump version to 1.1.6p1; wire up COPYING.BSD so that it gets included
  1481. in RPM's and tarballs.
  1482. * COPYING.BSD:
  1483. Add the BSD-Style copyright notice so that it can be included in binary
  1484. distributions.
  1485. 2001-06-03 Thomas Moestl <tmoestl@gmx.net>
  1486. * src/dns.c, src/dns_answer.c, src/dns_query.c, src/helpers.c, src/status.c, NEWS, version:
  1487. Bump version to 1.1.5, and add a NEWS entry for this release.
  1488. Miscellaneous cleanups, mainly in the status.c code; fix a bug that
  1489. could cause heap corruption (rhncpy always clobbered the whole buffer,
  1490. but only the needed space was reserved in add_rr). This should solve
  1491. the crashes some people were seeing (this bug is not an exploitable
  1492. security hole as far as I know; the respective buffer is on the heap,
  1493. as mentioned).
  1494. * src/error.c:
  1495. Paranoia: do not use the argument to crash_msg as a format string
  1496. (crash_msg is only used with constant strings, though).
  1497. 2001-06-02 Thomas Moestl <tmoestl@gmx.net>
  1498. * src/dns.c, src/dns.h, src/dns_answer.c, src/dns_query.c, src/error.h, src/hash.c, src/helpers.c:
  1499. Correct underscore handling for SRV records, and a few comment fixes.
  1500. * src/cache.c, src/conff.c, src/dns_query.c, src/error.h, src/helpers.h, src/status.c:
  1501. Numerous non-critical argument fixes for printf-like functions.
  1502. * src/dns.c: Remove superfluous \n's.
  1503. * src/conf-parse.y, src/dns_answer.c, src/status.c:
  1504. Correct some DEBUG_MSG nits, and fix two format string bugs. One of
  1505. them could allow users that are allowed to use pdnsd-ctl with the
  1506. server (when the status socket is enabled) to gain the privileges of
  1507. the user that runs (the run_as user or the user that started pdnsd on
  1508. Linux when strict_setuid is set to off) pdnsd. The status socket is
  1509. disabled by default, and if it is enabled, it's default permissions
  1510. are quite restrictive, so this isn't a problem for most.
  1511. 2001-05-30 Thomas Moestl <tmoestl@gmx.net>
  1512. * src/status.c:
  1513. Make the status permissions actually work (missed last time).
  1514. * src/dns_answer.c, src/main.c, src/status.c, src/status.h:
  1515. Move the status socket initialization to a place where it gets executed
  1516. before any threads are started; this way, we can use umask to set the
  1517. permissions, and avoid a (in this case harmless, but anyway) race
  1518. condition.
  1519. While being there, remove obsoleted comments and places referring to
  1520. the now-socket as fifo.
  1521. 2001-05-29 Thomas Moestl <tmoestl@gmx.net>
  1522. * src/cache.c:
  1523. Replace a misuse of CF_LOCAL with DF_LOCAL. This had no effect, because
  1524. the values are the same.
  1525. 2001-05-22 Thomas Moestl <tmoestl@gmx.net>
  1526. * src/hash.c, src/helpers.c, THANKS, acconfig.h, configure.in:
  1527. Add an option for allowing underscores (_) in domain names. This
  1528. violates the RFC's if enabled (which it isn't by default).
  1529. Thanks to Eelco Vriezekolk for an initial patch.
  1530. While being there, clean up configure.in and acconfig.c a bit.
  1531. * src/helpers.c, src/status.c:
  1532. Add a few comments about security implications.
  1533. * src/cache.c, src/dns_answer.c, src/dns_query.c, src/helpers.c:
  1534. Change some occurences of strcpy to strncpy. Again, no risk here, the
  1535. buffer lentgh was carefully chosen, and while the data was partially of
  1536. remote origin, it was carefully validated before entering the cache (and
  1537. thus having a chance of being used by us).
  1538. 3 occurences remain: 2 in cache.c, where we allocate a sufficient amount
  1539. of memory before (mimicking the non-portable strdup) and one where
  1540. we copy a constant and which is obviously correct.
  1541. * src/dns.c:
  1542. Change two occurences of strcat to strncat. Again, no risk here, the
  1543. buffer lentgh was carefully chosen, the data was validated and supplied
  1544. by the starting user.
  1545. * src/dns.c:
  1546. Change a sprintf to a snprintf and enlarge a buffer a bit. This is pure
  1547. paranoia (alrhough makes code review easier for others), because a.) the
  1548. lengths were carefully chosen so that no overrun could occur and
  1549. b.) this was locally supplied data.
  1550. 2001-05-21 Thomas Moestl <tmoestl@gmx.net>
  1551. * src/rc/RedHat/Makefile.am:
  1552. Add a missing semicolon in the RedHat rc Makefile.am (discovered by
  1553. Christian Engstler).
  1554. 2001-05-19 Thomas Moestl <tmoestl@gmx.net>
  1555. * HACKING: Remove the mostly outdated HACKING file.
  1556. * src/debug.c:
  1557. Catch a corner case in the allocation debug helpers: realloc() with a
  1558. size of 0 is effectively a free operation. To my knowledge, this is
  1559. not done in the pdnsd sources, however.
  1560. * src/test/test.sh:
  1561. Use the correct error function, forgotten in last commit.
  1562. * src/test/clnt-test.sh, src/test/srv-test.sh, src/test/test.sh:
  1563. Misc small improvements in the regression test scripts, mostly
  1564. adding configuration variables and common error handlers.
  1565. Comment a little on the tests that are done in clnt-test.sh
  1566. * src/rr_types.c: Fix a typo in a comment.
  1567. * src/cache.c, src/debug.c, src/dns_answer.c, src/dns_query.c, src/error.h, src/hash.c, src/list.c, src/main.c, src/status.c, src/thread.c, src/thread.h:
  1568. New ANSI variadic debug macros (finally), which print a timestamp and
  1569. a thread ID now for easier debugging with many parallel queries.
  1570. It should be considered to make those inline functions instead. However,
  1571. we have the advantage that we use printf in place here and benefit
  1572. from parameter checking without specifying obscure function attributes.
  1573. * src/rc/SuSE/.cvsignore, src/test/.cvsignore, src/rc/.cvsignore, src/rc/Debian/.cvsignore, src/rc/RedHat/.cvsignore, contrib/.cvsignore, doc/.cvsignore, src/.cvsignore, src/pdnsd-ctl/.cvsignore, .cvsignore:
  1574. Brush up the rotten (pre-autoconf!) .cvsignore files and add some where
  1575. necessary.
  1576. 2001-05-17 Thomas Moestl <tmoestl@gmx.net>
  1577. * src/rc/RedHat/Makefile.am, src/rc/RedHat/pdnsd.in, configure.in, pdnsd.spec.in:
  1578. Red Hat rc script and RPM improvements by Christian Engstler.
  1579. 2001-05-12 Thomas Moestl <tmoestl@gmx.net>
  1580. * src/pdnsd-ctl/pdnsd-ctl.c:
  1581. Fix a place missed when converting rr_info.
  1582. * version: It's 1.1.4, finally.
  1583. * src/rr_types.c, version:
  1584. Change some class values in the rr type structure to better values.
  1585. Bump beta version.
  1586. 2001-05-10 Thomas Moestl <tmoestl@gmx.net>
  1587. * src/cache.c, src/dns_answer.c, src/dns_query.c:
  1588. Fix a signedness bug that could cause erraneous 0 ttls to be returned.
  1589. Add some debug messages, and do some minor fixups.
  1590. 2001-05-09 Thomas Moestl <tmoestl@gmx.net>
  1591. * src/cache.c, src/rr_types.c:
  1592. Fix some bugs in the new conflict resolution code and make it more
  1593. complete.
  1594. * src/cache.c, version:
  1595. Add conflict resolution code. This needs a bit more checking, and
  1596. the tables might still need to be tweaked.
  1597. Bump version.
  1598. * src/pdnsd-ctl/pdnsd-ctl.c, src/Makefile.am, src/cache.c, src/cache.h, src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/consts.c, src/consts.h, src/debug.c, src/dns.c, src/dns_answer.c, src/dns_answer.h, src/dns_query.c, src/dns_query.h, src/error.c, src/error.h, src/hash.c, src/hash.h, src/helpers.c, src/helpers.h, src/icmp.c, src/icmp.h, src/list.c, src/main.c, src/netdev.c, src/netdev.h, src/rr_types.c, src/rr_types.h, src/servers.c, src/servers.h, src/status.c, src/status.h, src/thread.c, src/thread.h, configure.in, version:
  1599. Remove the old infrastructure that theoretically could have allowed for
  1600. multiple cache subsystems. This ability was never used, and if it should,
  1601. the caching should probably be split into two layers, a higher level
  1602. common one and the actual caching backends.
  1603. src/cacheing/cache.c and src/cacheing/native/*.[ch] were repo-copied to
  1604. src/.
  1605. Substitute "conf.h" with <conf.h> for includes.
  1606. Purge records a little more often (when adding records, and when
  1607. retrieving from the cache). Handle cache_size properly when using
  1608. purge_cent.
  1609. Introduce some infrastructure in rr_types.[ch] for a record conflict
  1610. checker which is to be introduced shortly to enforce cache consistency
  1611. even in the purge_cache=off case.
  1612. 2001-05-04 Thomas Moestl <tmoestl@gmx.net>
  1613. * src/rc/RedHat/pdnsd.in, src/rc/SuSE/pdnsd.in, src/rc/Debian/pdnsd.in:
  1614. Revert the last commit. It breaks the rc scripts by spamming them with
  1615. make style variable expansions.
  1616. * src/rc/SuSE/pdnsd.in, src/rc/RedHat/pdnsd.in, src/rc/Debian/pdnsd.in, AUTHORS, THANKS:
  1617. Fix a rc script bug spotted by Frank Elsner, and add him to AUTHORS and
  1618. THANKS.
  1619. 2001-05-01 Thomas Moestl <tmoestl@gmx.net>
  1620. * version: Bump version to 1.1.4p2.
  1621. * src/pdnsd-ctl/pdnsd-ctl.c, src/status.c:
  1622. Fix some bogons and remove some unneeded code in the pdnsd-ctl
  1623. interface.
  1624. Fix spelling and line length bugs.
  1625. 2001-04-30 Thomas Moestl <tmoestl@gmx.net>
  1626. * src/pdnsd-ctl/pdnsd-ctl.c, src/conf-parse.y, src/status.c:
  1627. Some corrections for the authrec config file and the pdnsd-ctl noauth
  1628. support.
  1629. * src/pdnsd-ctl/pdnsd-ctl.c:
  1630. Fix wrong argv index (using getopt changed the indices).
  1631. * src/pdnsd-ctl/pdnsd-ctl.c, src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/dns.c, src/dns.h, src/dns_query.c, src/status.c, THANKS, version, AUTHORS:
  1632. Accumulated changes that should go in before 1.1.4:
  1633. - merge Andrew M. Bishop's patch that adds a server label option
  1634. - make local records authoritative for the domain by default, and add
  1635. the authrec option to change this
  1636. - add the auth keyword to the pdnsd-ctl source option to support that
  1637. - fix a bug in the conf-parse.y grammar causing a shift/reduce conflict
  1638. - sync up AUTHORS and THANKS: add Andrew M. Bishop, Kevin A. Burton and
  1639. Michael Steinl
  1640. - bump version to 1.1.4p1
  1641. * src/conff.c, src/main.c:
  1642. Fix two small bugs: the wrong element of argv was used for the pidfile
  1643. option, which could cause pdnsd to segfault, and C_INCLUDED was always
  1644. used in slist_add, regardless of the tp parameter.
  1645. * src/helpers.c:
  1646. Fix a bogon discovered by Michael Steiner: the fread() return value
  1647. was tested against bytes, not the number of items.
  1648. * src/hash.c, src/hash.h, src/cache.c:
  1649. purge_cache used to walk over the cache quite inefficiently when it was
  1650. called from add_cache. Add a lazy mode for purge_cache which uses the
  1651. rrset_l to be efficient in this special case.
  1652. Add some #ifdef'ed-out-by-default code to debug the hash function.
  1653. 2001-04-12 Thomas Moestl <tmoestl@gmx.net>
  1654. * NEWS: Add NEWS entry for 1.1.3.
  1655. * src/dns.c, src/helpers.c, src/icmp.c, contrib/Makefile.am, contrib/README, version:
  1656. IPv6, ICMP and build fixes. It's 1.1.3 now!
  1657. * src/debug.c, src/debug.h: Add the new debug support files.
  1658. * src/test/clnt-test.sh, src/cache.c, src/cache.h, src/error.h, src/list.c, src/list.h, src/main.c, src/status.c, src/status.h, src/Makefile.am, src/conf-parse.y, src/conff.h, src/dns.c, src/dns_answer.c, src/dns_query.c:
  1659. Add allocation debug support. Some small cleanups before the upcoming
  1660. 1.1.3 release.
  1661. * src/dns_query.h, src/helpers.c, src/list.c, src/conff.c, src/dns.c, src/dns_answer.c, src/dns_query.c:
  1662. Lots of small bugfixes, cleanups, style and spelling fixes.
  1663. * src/test/clnt-test.sh: Fix nc arguments.
  1664. * src/test/clnt-test.sh, src/test/srv-test.sh, src/test/test.sh:
  1665. Add regression test scripts.
  1666. 2001-04-11 Thomas Moestl <tmoestl@gmx.net>
  1667. * src/pdnsd-ctl/pdnsd-ctl.c, src/cache.c, src/servers.c, src/dns_answer.c, src/helpers.c, src/helpers.h, src/icmp.c, src/main.c:
  1668. Further cleanups and bug, style and spelling fixes.
  1669. * configure.in: Use -g again in the CFLAGS for a while.
  1670. * version: Beta version bump.
  1671. * src/rc/SuSE/pdnsd.in:
  1672. killproc does not seem to take the full path, but only the process name
  1673. (which is what one would expect).
  1674. * src/hash.c, src/netdev.c, src/rr_types.c, src/status.c, src/conf-parse.y, src/conff.c, src/helpers.c:
  1675. Misc. smaller fixes, and fixes on the new features. Also clean up style
  1676. and spelling in some places.
  1677. * src/dns_answer.c:
  1678. Bring the glibc pthread_cleanup_push/pthread_cleanup_pop return bug
  1679. workaround into the main tree.
  1680. Without this, a return between those two macros would cause pdnsd
  1681. to crash on system using a glibc between 2.1.2 and 2.2.2 (and possibly
  1682. others). This could e.g. be cause by a TCP connect() port scan.
  1683. 2001-04-10 Thomas Moestl <tmoestl@gmx.net>
  1684. * src/pdnsd-ctl/pdnsd-ctl.c:
  1685. Minor fixes, direct error messages to stderr.
  1686. * src/list.c, src/list.h: Add the new list implementations.
  1687. * src/cache.c, src/cache.h, src/conf-parse.y, src/dns.c, src/dns_answer.c, src/dns_query.c, src/helpers.c, src/helpers.h, src/conf-lex.l.in:
  1688. Introduce rhnlen and rhncpy and make use of it instead of kluged-up
  1689. strcpy/strlen in the appropriate places.
  1690. Check that incoming names contain only legal characters in
  1691. decompress_name, return RC_FORMAT otherwise (this would result in
  1692. wrong handling only, but not in a security hole).
  1693. Reorganzie compose_answer and make it more correct for multiple
  1694. questions. Get rid of the algorithm that tries to add a higher
  1695. level name server; this might be readded in another place somewhen.
  1696. Use some more da_* instead of hand-built lists.
  1697. Some style cleanups.
  1698. * src/rc/RedHat/Makefile.am:
  1699. Add K45pdnsd links for rc6.d (reboot) and rc0.d (halt) following a
  1700. suggestion by Stas Sergeev.
  1701. 2001-04-06 Thomas Moestl <tmoestl@gmx.net>
  1702. * src/pdnsd-ctl/pdnsd-ctl.c, src/cache.h, src/error.h, src/helpers.c, src/helpers.h, src/main.c, src/servers.c, src/status.c, src/conf-parse.y, src/conff.c, src/conff.h, src/dns.c, src/dns.h, src/dns_answer.c, src/dns_query.c, src/Makefile.am, version:
  1703. Bump alpha version; introduce a generic dynamic array type and make use
  1704. of it to ged rid of some ugly casts and redundant code.
  1705. Minor fixes.
  1706. * src/icmp.h, src/ipvers.h, src/conff.h, src/consts.h, src/dns.h, src/dns_answer.h, src/dns_query.h, src/helpers.h:
  1707. Use macros without an underscore as first character to protect the
  1708. headers. Underscores are reserved and should not be used in the
  1709. application name space.
  1710. * src/error.h: Add PDNSD_ASSERT, change style a little.
  1711. 2001-04-03 Thomas Moestl <tmoestl@gmx.net>
  1712. * src/hash.c, src/netdev.c, src/servers.c, src/helpers.c, src/icmp.c, src/main.c:
  1713. Another slew of small bugfixes, minor updates and small fixes.
  1714. * src/rr_types.c, src/consts.c:
  1715. Update rr_types.c copyright date, consts.c should have a rcsid string.
  1716. * src/rr_types.c: cvs add rr_types.c.
  1717. * src/dns.h, src/helpers.h, src/ipvers.h, src/rr_types.h, src/status.h, src/conf-parse.y, src/conff.h:
  1718. cvs add rr_types.h that got missed before, update copyright dates,
  1719. remove some old config cruft, some minor fixups.
  1720. * src/conff.c, src/consts.c, src/dns_answer.c, src/error.c, src/conf-lex.l.in, src/conf-parse.y:
  1721. Update copyright dates, fix some minor bugs. Update copyright dates.
  1722. cvs add missed consts.c.
  1723. 2001-03-28 Thomas Moestl <tmoestl@gmx.net>
  1724. * src/cache.c, src/hash.c, src/error.c, src/servers.c, src/dns_answer.c, version:
  1725. Bump version to 1.1.3p4
  1726. Fix some non-critical locking issues (none of them could be fatal).
  1727. Adjust copyright dates.
  1728. * src/hash.c: Make the hash compare case insensitive.
  1729. 2001-03-25 Thomas Moestl <tmoestl@gmx.net>
  1730. * contrib/Makefile.am: Add Id tag to Makefile.am
  1731. * src/cache.c, src/dns_answer.c, src/icmp.c:
  1732. Some more type fixes overlooked in last commit.
  1733. * src/conf-parse.y, src/conff.h, src/dns.h, src/dns_answer.c, src/dns_query.c, src/icmp.c:
  1734. More type cleanups. Use time_t for time specifications throughout, and
  1735. make lengths singed longs. Cast cleanup in icmp.c to fix alpha
  1736. unalinged access faults.
  1737. * contrib/dhcp2pdnsd, contrib/pdnsd_dhcp.pl, contrib/save_ram.pl, contrib/Makefile.am, contrib/README, configure.in, version, Makefile.am:
  1738. It's 1.1.3p3 now.
  1739. Change the contrib infrastructure: there is a Makfile.am in contrib/
  1740. now. Rename Marko Stolle's pdnsd_update.pl to pdnsd_dhcp.pl and bring
  1741. it up to date (adding the rc script and save_ram.pl).
  1742. * src/helpers.c, src/dns.c, src/dns_query.c, AUTHORS, THANKS:
  1743. Bring in Bjoern Fischer's changes to make pdnsd conserve the case of
  1744. cached names, and add him to AUTHORS and THANKS.
  1745. * configure.in: The gdbm backend is discontinued.
  1746. * src/cache.c, src/hash.c:
  1747. Cleanup and small bugfixes of the cache code (esp. locking).
  1748. * AUTHORS, THANKS, file-list.base.in, pdnsd.spec.in:
  1749. SuSE fixes by Christian Engstler.
  1750. Add him to AUTHORS, THANKS.
  1751. 2001-03-14 Thomas Moestl <tmoestl@gmx.net>
  1752. * src/dns_query.c:
  1753. Fix a bug that could cause servers that were not used in the first
  1754. parallel query not to be used at all (failure would be returned
  1755. instead).
  1756. 2001-03-13 Thomas Moestl <tmoestl@gmx.net>
  1757. * src/icmp.c: Add define for ip_p equivalent on Linux.
  1758. * src/pdnsd-ctl/pdnsd-ctl.c, src/cache.c, src/dns_query.c, src/icmp.c, src/status.c, src/conf-parse.y, src/dns_answer.c, version:
  1759. Bump alpha version, more alignment fixes. All casts should be correct
  1760. now.
  1761. 2001-03-12 Thomas Moestl <tmoestl@gmx.net>
  1762. * src/dns_answer.c, src/dns_query.c, AUTHORS, THANKS:
  1763. Add the alpha fixes by P.J. Bostley, and add him to THANKS and AUTHORS.
  1764. 2001-03-10 Thomas Moestl <tmoestl@gmx.net>
  1765. * src/dns.h, src/helpers.h:
  1766. Remove prototype for removed function strtolower.
  1767. Use unit16_t and uint32_t instead of unsinged short/long for dns
  1768. protocol structures.
  1769. 2001-02-25 Thomas Moestl <tmoestl@gmx.net>
  1770. * src/pdnsd-ctl/pdnsd-ctl.c, src/status.c, src/conf-lex.l.in, src/conf-parse.y, AUTHORS, Makefile.am, version:
  1771. Add MX and CNAME for rr sections in the config file and MX setting
  1772. for pdnsd-ctl.
  1773. Typo fixes.
  1774. * src/netdev.c: Two more fixes.
  1775. * src/pdnsd-ctl/pdnsd-ctl.c, src/cache.c, src/dns.c, src/main.c:
  1776. More small robustness fixes.
  1777. * src/pdnsd-ctl/pdnsd-ctl.c, src/netdev.c, src/status.c, src/status.h, src/conf-parse.y, src/helpers.c, src/main.c, configure.in, version, Makefile.am, NEWS:
  1778. A batch of robustness fixes. Move the status socket to the cache
  1779. directory. Various cleanups.
  1780. It's 1.3 now (hopefully to be released soon).
  1781. 2001-02-21 Thomas Moestl <tmoestl@gmx.net>
  1782. * src/main.c, src/conf-lex.l.in:
  1783. Fix breakage of the -mtu option and the query_method option (the parser
  1784. would not recognize constants that contained underscores).
  1785. 2001-02-20 Thomas Moestl <tmoestl@gmx.net>
  1786. * contrib/README, contrib/pdnsd_dhcp.pl, AUTHORS, Makefile.am, THANKS, file-list.base.in:
  1787. Add Marko Stolle's pdnsd_update.pl DHCP update script, add him to THANKS,
  1788. and bring a contrib/ directory in place.
  1789. 2001-02-15 Thomas Moestl <tmoestl@gmx.net>
  1790. * src/dns_answer.c, configure.in, version:
  1791. Some minor build & misc fixes. Bump version to 1.1.2a and release a
  1792. version with the spec file fixes to get proper Red Hat RPM's.
  1793. 2001-02-09 Thomas Moestl <tmoestl@gmx.net>
  1794. * NEWS: Bring NEWS up to date.
  1795. * src/icmp.c: Do not close the socket on error.
  1796. * pdnsd.spec.in: Add spec file fixes for man pages by Sourav K. Mandal
  1797. 2001-02-07 Thomas Moestl <tmoestl@gmx.net>
  1798. * version: It is now 1.1.2.
  1799. * src/dns_query.c, src/main.c, Makefile.am, THANKS:
  1800. Fix a too strict length checking that could cause SERVFAIL to be returned
  1801. when the server returned NXDOMAIN. Add Markus Storm to THANKS (he has
  1802. reported this bug and supplied helpful information).
  1803. Minor tweaking in main.c.
  1804. Remove emptying of GZIP_ENV in Makefile.am (this normally contains --best).
  1805. 2001-01-27 Thomas Moestl <tmoestl@gmx.net>
  1806. * AUTHORS, THANKS:
  1807. Add Michael Wiedmann to AUTHORS and THANKS for his pdnsd-ctl.8 man page.
  1808. * doc/Makefile.am, doc/pdnsd-ctl.8, configure.in, Makefile.am:
  1809. Add the pdnsd-ctl man page contributed by Michael Wiedmann. For this to
  1810. build in a correct way, add doc/Makefile.am and move all doc and
  1811. pdnsd.conf.sample related stuff in there.
  1812. 2001-01-25 Thomas Moestl <tmoestl@gmx.net>
  1813. * src/main.c: Removed unneeded for the non-O_NOFOLLOW case.
  1814. 2001-01-24 Thomas Moestl <tmoestl@gmx.net>
  1815. * src/main.c:
  1816. Add a fchown and a fchmod to the new non-O_NOFOLLOW case (not yet used).
  1817. * src/conf-parse.y, src/main.c, src/status.c: Misc small fixups.
  1818. * version: It's called 1.1.1 now.
  1819. * src/pdnsd-ctl/pdnsd-ctl.c, src/status.c, src/main.c:
  1820. Fix command line parsing. Add code to securely create pid files under
  1821. OSs that do not support the O_NOFOLLOW flag (those OSs are not supported
  1822. yet, though).
  1823. Fix a possible race condition in socket creation/chmod. We now create
  1824. a directory in /tmp (or whatever TEMPDIR was set) to hold the socket.
  1825. * src/dns.c, src/dns_answer.c, src/icmp.c, src/main.c, src/status.c:
  1826. Another slew of copyright notice upgrades.
  1827. * version, configure.in:
  1828. Bump beta revision, fix typo (missing $) in configure.in
  1829. * src/dns.c, src/dns_answer.c, src/status.c:
  1830. Silence BSD compile time warnings.
  1831. * configure.in:
  1832. Cleanup, add autoconf code for building pdnsd on FreeBSD-CURRENT with the
  1833. new additionally-linked libc_r.
  1834. 2001-01-16 Thomas Moestl <tmoestl@gmx.net>
  1835. * src/dns_answer.c, src/icmp.c, version:
  1836. Bump beta revision, fix a comment. Also, generate ping id's using pdnsd's
  1837. random wrappers instead of using rand() for paranoia.
  1838. 2001-01-15 Thomas Moestl <tmoestl@gmx.net>
  1839. * src/helpers.c, configure.in: Improve wording.
  1840. * src/helpers.c: Update copyright year (forgotten in last commit).
  1841. * src/dns_answer.c, src/helpers.c, src/main.c, acconfig.h, configure.in, version:
  1842. Bump versions. Small fixes (move socket intitializations from
  1843. udp_server_thread to init_udp_sockets to prevent warning when startup
  1844. takes long.
  1845. Make arc4random an option for a query id RNG and make it the default
  1846. on FreeBSD.
  1847. 2000-12-07 Thomas Moestl <tmoestl@gmx.net>
  1848. * src/conf-parse.y, src/main.c, version:
  1849. We are at 1.1.1p1. Removed the exec-uptest security warning printef if no
  1850. explicit user is given in the strict_setuid case (it is not needed there,
  1851. and confuses users).
  1852. 2000-11-28 Thomas Moestl <tmoestl@gmx.net>
  1853. * src/cache.c, src/helpers.c:
  1854. Converted cache locks to use condition vars and have lock contention
  1855. prevention. Added comments where not converted.
  1856. 2000-11-25 Thomas Moestl <tmoestl@gmx.net>
  1857. * AUTHORS, THANKS, pdnsd.spec.in:
  1858. Added spec file patches by Bernd Leibing and added him to AUTHORS and
  1859. THANKS.
  1860. 2000-11-21 Thomas Moestl <tmoestl@gmx.net>
  1861. * src/rc/SuSE/Makefile.am: Fixed a hopefully last SuSE rpm build bug.
  1862. * src/rc/SuSE/Makefile.am:
  1863. Another one: allow rc.conf manipulation to fail for a clean
  1864. rpm build (SuSE only).
  1865. * file-list.base.in:
  1866. Last-minute fix: correct filelist for rpm build to reflect the new name
  1867. for the sample configuration.
  1868. * version: It's 1.1.0 now.
  1869. 2000-11-18 Thomas Moestl <tmoestl@gmx.net>
  1870. * src/pdnsd-ctl/pdnsd-ctl.c, src/cache.c, src/dns_query.c, version:
  1871. Fixed a condition where the cache code did not give up a lock.
  1872. Made the udp code use connect().
  1873. Some small changes.
  1874. 2000-11-16 Thomas Moestl <tmoestl@gmx.net>
  1875. * version: Calling it 1.1.0b3.
  1876. 2000-11-15 Thomas Moestl <tmoestl@gmx.net>
  1877. * src/test/Makefile.am, src/pdnsd-ctl/Makefile.am, src/cache.c, src/Makefile.am, src/dns_answer.c, src/error.h, src/icmp.c, src/icmp.h, src/main.c, src/netdev.c, src/servers.c, src/thread.c, Makefile.am, configure.in, version:
  1878. Enabled new rr support by default (some resolvers don't seem to like not
  1879. supported answers - not our bug, but well).
  1880. Made some globals volatile to avoid being bitten by optimisations.
  1881. 2000-11-12 Thomas Moestl <tmoestl@gmx.net>
  1882. * TODO, version: Called it the first beta.
  1883. 2000-11-11 Thomas Moestl <tmoestl@gmx.net>
  1884. * src/cache.c, src/conf-lex.l.in, src/conf-parse.y, doc/pdnsd.conf.in:
  1885. renanmed rrneg to neg in the config file.
  1886. Misc small fixes.
  1887. pdnsd-ctl record xxx inval will now also invalidate local records.
  1888. * src/conf-lex.l.in, src/conf-parse.y, src/dns_answer.c, src/status.c, pdnsd.spec.in:
  1889. Added --sysconfdir=/etc as argument to configure in the spec file.
  1890. Implemented the new rrneg config file section.
  1891. * src/test/Makefile.am, src/pdnsd-ctl/Makefile.am, src/pdnsd-ctl/pdnsd-ctl.c, src/cache.c, src/cache.h, src/status.c, src/status.h, TODO:
  1892. Added the neg option to pdnsd-ctl.
  1893. * src/cache.c, src/Makefile.am, src/conf-lex.l.in, src/consts.h, src/dns.c, src/dns.h, src/dns_answer.c, src/dns_query.c, src/helpers.c, src/main.c, configure.in:
  1894. Assorted fixes. The new features should be stabilized by now, will
  1895. integrate the missing few features now.
  1896. Also actived the tcp server by default.
  1897. 2000-11-07 Thomas Moestl <tmoestl@gmx.net>
  1898. * src/dns_answer.c, src/dns_query.c, src/icmp.c, src/ipvers.h, THANKS, TODO:
  1899. Fixed a possible memory and socket leak reported by Erich Reitz.
  1900. Implemented udp source address discovery for FreeBSD.
  1901. * src/dns_query.c: Part 2 of yesterdays fix.
  1902. 2000-11-06 Thomas Moestl <tmoestl@gmx.net>
  1903. * src/dns_query.c, version:
  1904. Fixed a bug reported by Erich Reitz: pdnsd could leak fd's and memory if
  1905. queries timed out.
  1906. * src/cache.c, src/cache.h, src/Makefile.am, src/dns_answer.c, src/dns_query.c, TODO, configure.in:
  1907. Sorted out some bugs for the new neg cacheing.
  1908. 2000-11-05 Thomas Moestl <tmoestl@gmx.net>
  1909. * src/cache.c, src/dns_query.c, TODO:
  1910. Negative cacheing support is now present, but largely untested.
  1911. * src/conff.c, TODO:
  1912. The output of pdnsd-ctl status is now complete with all currently
  1913. supported options.
  1914. * src/conf-parse.y, src/conff.c, src/conff.h, src/consts.h, src/conf-lex.l.in:
  1915. Added the config file options for the nefative cacheing support.
  1916. 2000-11-04 Thomas Moestl <tmoestl@gmx.net>
  1917. * src/cache.c, src/cache.h, src/conf-parse.y, src/dns.c, src/dns_query.c, src/status.c, version:
  1918. The new cache infrastructure for negative cacheing is in place.
  1919. Using and testing it remains.
  1920. * src/cache.c, src/cache.h:
  1921. First changes to support negative cacheing. This should not break
  1922. anything, but the cache file format will be incompatible.
  1923. * src/main.c, src/dns_answer.c:
  1924. init_udp_socket() and init_tcp_socket() are now called after
  1925. daemonizing on FreeBSD, as bind wants to lock the fd which
  1926. can cause later calls to fail after an exit.
  1927. 2000-11-03 Thomas Moestl <tmoestl@gmx.net>
  1928. * src/dns_query.c, src/icmp.c, src/servers.c:
  1929. Minor bugfixes and repository cleanup.
  1930. 2000-11-02 Thomas Moestl <tmoestl@gmx.net>
  1931. * src/icmp.c, TODO, version:
  1932. Called it 1.0.16p4. Fixed some compatability problems with the new code;
  1933. the ipv4 implementation seems to be fairly stable, the ipv6 one needs
  1934. some testing with dest unreach messages.
  1935. * src/icmp.c, src/main.c:
  1936. Rewrote large parts of the ping implementation to be more portable.
  1937. 2000-11-01 Thomas Moestl <tmoestl@gmx.net>
  1938. * acconfig.h, configure.in, version:
  1939. Some config fixes, version to 1.0.16p3. SOCKET_LOCKING should be
  1940. off by default, as sendmsg can block.
  1941. * src/pdnsd-ctl/pdnsd-ctl.c, src/error.h, configure.in:
  1942. Removed -W* arguments from CFLAGS that were implied by -Wall.
  1943. * src/thread.c, configure.in:
  1944. Added some more safety tests to configure.in, and made it give
  1945. an error on some conditions. Also made configure do poll and usleep
  1946. detectione.
  1947. * src/cache.h, src/test/Makefile.am, src/dns_answer.c, src/error.c, src/error.h, src/helpers.c, src/main.c, src/servers.c, src/status.c, src/thread.c, src/thread.h, src/Makefile.am:
  1948. Code cleanup. Beautified some macros, and moved the thread
  1949. specific things from error.[ch] over to the new thread.[ch].
  1950. Also introduced usleep_r which tries to be thread safe for
  1951. different Unices.
  1952. 2000-10-31 Thomas Moestl <tmoestl@gmx.net>
  1953. * src/pdnsd-ctl/pdnsd-ctl, src/pdnsd-ctl/pdnsd-ctl.c:
  1954. The pdnsd-ctl binary got into cvs. Fixed that.
  1955. * src/pdnsd-ctl/pdnsd-ctl, src/cache.c, src/cache.h, src/error.c, src/helpers.c, src/main.c, version:
  1956. Another set of FreeBSD compatability patches. This seems to catch
  1957. most of the problems, and pdnsd should be useable with libc_r now.
  1958. 2000-10-30 Thomas Moestl <tmoestl@gmx.net>
  1959. * src/pdnsd-ctl/pdnsd-ctl, src/conff.c, src/dns_answer.c, src/dns_query.c, src/helpers.c, src/icmp.c, src/main.c, AUTHORS, Makefile.am, THANKS, configure.in, version:
  1960. FreeBSD fixes, mostly contributed by Roman Shterenzon.
  1961. 2000-10-25 Thomas Moestl <tmoestl@gmx.net>
  1962. * src/pdnsd-ctl/Makefile.am, src/pdnsd-ctl/pdnsd-ctl:
  1963. pdnsd-ctl was not in cvs.
  1964. * src/dns_query.c, src/error.h, configure.in: Some fixups for 1.0.15.
  1965. 2000-10-23 Thomas Moestl <tmoestl@gmx.net>
  1966. * src/dns_answer.c, src/dns_query.c, configure.in:
  1967. Several fixes for pdnsd to work better when it receives error replys.
  1968. * src/dns.c, src/dns_answer.c:
  1969. Fixed another memory leak on an error path in dns_answer.c and did
  1970. a pointer signedness fixup in dns.c
  1971. 2000-10-21 Thomas Moestl <tmoestl@gmx.net>
  1972. * src/dns_answer.c, AUTHORS:
  1973. Applied a patch by Paul Wagland that fixes some spelling mistakes
  1974. and some memory leaks on error paths.
  1975. * src/dns_query.c, src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/dns_answer.c, NEWS, version:
  1976. Bug fixes. Added the randomize_recs option and turned it on
  1977. by default.
  1978. 2000-10-20 Thomas Moestl <tmoestl@gmx.net>
  1979. * src/helpers.c, src/dns.c, src/dns_query.c:
  1980. Fixes for the paranoid option to work with root servers
  1981. properly.
  1982. * src/dns_query.c, src/dns.h, src/dns_answer.c, AUTHORS, THANKS:
  1983. Applied a patch by Paul Wagland for bind9-compatability and added
  1984. him to AUTHORS and THANKS.
  1985. 2000-10-19 Thomas Moestl <tmoestl@gmx.net>
  1986. * src/dns_answer.c, NEWS, version:
  1987. Another POLL_* fix. It is now called 1.0.14.
  1988. * src/dns_answer.c, src/dns_query.c, src/icmp.c: BSD build fixes.
  1989. * src/dns_query.c:
  1990. Made p_recurdive_query return immediately if a query returns
  1991. NXDOMAIN.
  1992. * src/dns_query.c, Makefile.am:
  1993. Some bugifixes. It is now called 1.0.13. Releasing.
  1994. * src/cache.c, src/dns_query.c, AUTHORS, NEWS:
  1995. Updated AUTHORS and NEWS. Made destroy_cache() lock the cache so
  1996. that no thread can access the cache afterwards (could lead to
  1997. crashes).
  1998. * src/helpers.c, NEWS, THANKS:
  1999. Integrated a security fix contributed by Olaf Kirch: when
  2000. changing user IDs, pdnsd did not reinitialize the supplementary
  2001. group list, meaning that the process still had the privileges
  2002. of the supplementary groups the original user was member of.
  2003. * src/conf-lex.l.in, src/conf-parse.y, Makefile.am, TODO, version:
  2004. Introduced the par_queries option.
  2005. * src/dns_answer.c, src/dns_query.c, TODO:
  2006. Updated TODO, did some fixups for string handling.
  2007. * HACKING: Added HACKING with some comments about coding style.
  2008. 2000-10-18 Thomas Moestl <tmoestl@gmx.net>
  2009. * src/dns_answer.c, src/dns_query.c, src/error.h, src/main.c, TODO:
  2010. Revieved and fixed the new dns_query.c-poll/select loops.
  2011. * src/test/tping.c, src/dns_query.c, src/icmp.c:
  2012. Fixed the new poll/select ping support.
  2013. 2000-10-17 Thomas Moestl <tmoestl@gmx.net>
  2014. * src/dns_query.c, src/icmp.c, TODO:
  2015. Got rid of the O_NONBLOCK loop in the icmp.c ping implementation.
  2016. Beta tesing pending.
  2017. * src/rc/Debian/Makefile.am, src/conff.c, src/conff.h, src/dns_query.c, src/dns_query.h, THANKS, TODO, acconfig.h, configure.in:
  2018. Corrected the Debian rc script (bug reported by Michael Müller).
  2019. Got rid of the nonblocking socket things in dns_query.c, and
  2020. using poll/select now.
  2021. Testing (esp. --no-poll) remains.
  2022. * src/dns_answer.c:
  2023. Got rid of O_NONBLOCK read loops in dns_answer.c, using poll/select
  2024. now instead (after one issue about boundaries was cleared up).
  2025. 2000-10-16 Thomas Moestl <tmoestl@gmx.net>
  2026. * src/rc/SuSE/Makefile.am, src/rc/RedHat/Makefile.am, src/rc/Debian/Makefile.am:
  2027. The generated rc scripts do not need to be in the distribution.
  2028. * src/conff.c, src/main.c:
  2029. Fixed a server structure members in conff.c. Only delete the socket
  2030. if we are in status pipe mode now.
  2031. * src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/dns_answer.c, src/dns_query.c, acconfig.h, configure.in:
  2032. Added the --enable-tcp-subseq and --with-tcp-qtimeout configure
  2033. options, added the tcp_qtimeout conf file option, tested things.
  2034. 1.0.12 is ready for release.
  2035. 2000-10-15 Thomas Moestl <tmoestl@gmx.net>
  2036. * src/dns_answer.c, TODO, acconfig.h:
  2037. Added TCP timeouts to the answer code. Still need an option in the
  2038. conf file and documentation for that (besides beta testing).
  2039. * src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/consts.h, src/dns_query.c, src/helpers.c, src/helpers.h, NEWS, TODO:
  2040. Introduced domain inclusion/exclusion lists in the server section
  2041. (new options include=, exclude=, policy=).
  2042. 2000-10-14 Thomas Moestl <tmoestl@gmx.net>
  2043. * src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/dns_answer.c, src/main.c, NEWS, TODO, version:
  2044. Upped version, updated NEWS and TODO and implemented a process
  2045. count limit.
  2046. 2000-10-13 Thomas Moestl <tmoestl@gmx.net>
  2047. * src/rc/Debian/pdnsd.in, src/main.c:
  2048. Added the --pdnsd-user option, and made the Debian rc script
  2049. use it rather than trying to parse the config file itself.
  2050. 2000-10-11 Thomas Moestl <tmoestl@gmx.net>
  2051. * src/rc/SuSE/pdnsd, src/rc/SuSE/pdnsd.in, src/rc/RedHat/pdnsd, src/rc/RedHat/pdnsd.in, src/rc/Debian/pdnsd, src/rc/Debian/pdnsd.in, AUTHORS, THANKS, configure.in:
  2052. Added the 'configure'-able rc scripts contributed by Carsten Block
  2053. and added him to THANKS and AUTHORS.
  2054. * src/main.c:
  2055. Added O_NOFOLLOW to the pidfile open() call (if it is defined)
  2056. to prevent users creating files as the pdnsd user (using links)
  2057. if the admin put the pidfile in a world-writeable directory
  2058. against all good advice.
  2059. This is not a bug fix! Admins were not, and are still not supposed
  2060. to put the pidfile in a directory that is writeable for untrusted
  2061. users!
  2062. 2000-10-10 Thomas Moestl <tmoestl@gmx.net>
  2063. * THANKS: Added Milan P. Stanic to THANKS.
  2064. * src/main.c:
  2065. Fixed a missing O_WRONLY in the open() call for pidfile operation.
  2066. 2000-10-08 Thomas Moestl <tmoestl@gmx.net>
  2067. * src/Makefile.am, src/dns.c, src/dns_answer.c, configure.in, version, acconfig.h:
  2068. Released 1.0.11.
  2069. Two security fixes in dns.c and dns_answer.c, and misc. smaller issues.
  2070. * src/Makefile.am, src/conf-parse.y, src/dns_answer.c, src/dns_query.c, src/icmp.c, src/servers.c, AUTHORS, THANKS, TODO, acconfig.h, configure.in, version:
  2071. 1.0.10 was released some time ago ;-)
  2072. This had some IPv6 fixes.
  2073. Also fixed minor bug when using SOCKET_LOCKING.
  2074. 2000-08-28 Thomas Moestl <tmoestl@gmx.net>
  2075. * src/dns_answer.c: Fixed a parameter mismatch in getsockopt()
  2076. * Makefile.am:
  2077. Applied Sourav K. Mandal's rpm build patch to the toplevel
  2078. Makefile.am
  2079. 2000-08-27 Thomas Moestl <tmoestl@gmx.net>
  2080. * src/conf-lex.l.in, src/conf-parse.y, src/consts.h, src/servers.c, version:
  2081. Added diald support. It's now called 1.0.9.
  2082. * src/conf-parse.y, src/conff.c, src/netdev.c, pdnsd.spec.in:
  2083. Fixed some ugly typos in conf-parse.y and netdev.c.
  2084. Since I have no further bug reports and these bugs make some
  2085. things inconvenient, I will release 1.0.9 immediately.
  2086. 2000-08-26 Thomas Moestl <tmoestl@gmx.net>
  2087. * pdnsd.spec.in: small spec fix.
  2088. * NEWS, configure.in: Last fixups for 1.0.8. Released it.
  2089. * Makefile.am: Set mode and owner for cache file.
  2090. * src/conf-parse.y, src/dns_answer.c, src/netdev.c, acconfig.h, configure.in, version:
  2091. Misc fixes. Hopefully fixed the UDP socket problems under Linux SMP.
  2092. 2000-08-20 Thomas Moestl <tmoestl@gmx.net>
  2093. * src/cache.c, src/dns_answer.c, AUTHORS, THANKS, configure.in, pdnsd.spec.in, version:
  2094. Build fixes by Alexandre Nunes, spec fixes (does now set distro for
  2095. configure), first attempt at an "error in udp send"-fix, and fix
  2096. for a problem with having records for the root domain in the disk
  2097. cache file.
  2098. 2000-08-13 Thomas Moestl <tmoestl@gmx.net>
  2099. * src/netdev.h, src/servers.c, src/status.c, src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/consts.h, src/dns.c, src/dns.h, src/main.c, src/netdev.c, AUTHORS, THANKS:
  2100. Some minor fixes. Integrated the ppp device patch by Ron Yorston.
  2101. 2000-08-12 Thomas Moestl <tmoestl@gmx.net>
  2102. * configure.in:
  2103. configure.in was missing in repository. Also removed debugging
  2104. flag for build.
  2105. * src/main.c: Made the pid file handling safe for directories.
  2106. * src/dns.c: Part II of the last fix.
  2107. * src/dns.c:
  2108. Fixed a nasty bug in decompress_name which would produce errors very
  2109. rarely. That was a off-by-one bug, but on the safe side (no overflow,
  2110. stopping one by too early).
  2111. * src/main.c:
  2112. Fixed several possible problems with strncat(). None of these was
  2113. critical or involved remote data.
  2114. 2000-08-08 Thomas Moestl <tmoestl@gmx.net>
  2115. * src/main.c: Changed FreeBSD signal latency to 250 ms.
  2116. * src/main.c, acconfig.h:
  2117. A set of last-minute FreeBSD fixes. pdnsd does now NEED linuxthreads on
  2118. BSD.
  2119. 2000-08-07 Thomas Moestl <tmoestl@gmx.net>
  2120. * version: It's now called 1.0.7.
  2121. * src/main.c, doc/pdnsd.conf.in, Makefile.am: Misc build&BSD fixes.
  2122. * src/conff.c, src/conf-parse.y, version:
  2123. Version set to the hopefully last beta. Fixed the proxy_only option.
  2124. 2000-08-05 Thomas Moestl <tmoestl@gmx.net>
  2125. * src/rc/SuSE/Makefile.am, src/rc/RedHat/Makefile.am, src/rc/Debian/Makefile.am, src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/dns_query.c, src/status.c, doc/pdnsd.conf.in, Makefile.am, TODO:
  2126. Added the proxy_only options. Some build fixups.
  2127. 2000-07-30 Thomas Moestl <tmoestl@gmx.net>
  2128. * src/rc/SuSE/Makefile.am, src/rc/RedHat/Makefile.am, src/rc/Debian/Makefile.am, src/rc/Makefile.am, src/main.c, src/status.h, AUTHORS, INSTALL, Makefile.am, TODO, version:
  2129. Many small fixups for 1.0.7.
  2130. 2000-07-29 Thomas Moestl <tmoestl@gmx.net>
  2131. * src/rc/SuSE/Makefile.am, src/rc/RedHat/Makefile.am, src/rc/Debian/Makefile.am, src/rc/README, src/status.c, src/servers.c, Makefile.am, TODO, acconfig.h:
  2132. Assorted fixes.
  2133. * src/cache.c, src/hash.c, src/dns.h, src/dns_answer.c, src/dns_query.c, src/icmp.c, src/ipvers.h, src/servers.c, src/servers.h, src/status.c, src/status.h, src/Makefile.am, src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/dns.c, AUTHORS, Makefile.am, THANKS:
  2134. Big heap of updates and fixes. Incorporated build changes from Sourav
  2135. K. Mandal and pcmcia SCHEME support by Stephan Boettcher.
  2136. 2000-07-22 Thomas Moestl <tmoestl@gmx.net>
  2137. * src/rc/Debian/pdnsd:
  2138. Applied a patch by Markus Mohr to his debian rc script, which I had
  2139. broken in some way.
  2140. 2000-07-21 Thomas Moestl <tmoestl@gmx.net>
  2141. * src/cache.c, src/main.c, src/status.c, src/status.h:
  2142. Worked on the new status socket (pdnsd-ctl) option.
  2143. * src/Makefile.am, version: Upped version, fixed Makefile.am
  2144. * src/cache.c, src/hash.c, src/hash.h, src/cache.h, src/Makefile.am, src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/dns.c, src/dns.h, src/dns_answer.c, src/dns_query.c, src/dns_query.h, src/helpers.c, src/helpers.h, src/ipvers.h, src/main.c, src/status.c, src/status.h, AUTHORS, Makefile.am, THANKS, acconfig.h:
  2145. Updated AUTHORS and THANKS. Merged in patches by Sourav K. Mandal
  2146. and Lyonel Vincent.
  2147. 2000-07-20 Thomas Moestl <tmoestl@gmx.net>
  2148. * doc/pdnsd.conf: Added pdnsd.conf. Well...
  2149. * src/dns_query.c, src/dns_query.h, doc/pdnsd.conf:
  2150. Added some ommited files.
  2151. * src/test/Makefile.am, src/test/if_up.c, src/test/is_local_addr.c, src/test/random.c, src/test/tping.c, src/rc/SuSE/Makefile.am, src/rc/SuSE/pdnsd, src/rc/RedHat/Makefile.am, src/rc/RedHat/pdnsd, src/rc/Debian/pdnsd, src/rc/Makefile.am, src/rc/README, src/Makefile.am, src/conf-lex.l.in, src/conf-parse.y, src/conff.c, src/conff.h, src/consts.h, src/dns.c, src/dns.h, src/dns_answer.c, src/dns_answer.h, src/error.c, src/error.h, src/helpers.c, src/helpers.h, src/icmp.c, src/icmp.h, src/ipvers.h, src/main.c, src/netdev.c, src/netdev.h, src/servers.c, src/servers.h, src/status.c, src/status.h, doc/pdnsd.conf.in, Makefile.am, acconfig.h, file-list.base.in, pdnsd.spec.in:
  2152. Checked in the pdnsd files at their new locations.
  2153. * doc/pdnsd.conf, Makefile, a-conf.sh, cache.c, cache.h, conf.l.templ, conf.y, conff.c, conff.h, config.h.templ, consts.h, dns.c, dns.h, dns_answer.c, dns_answer.h, dns_query.c, dns_query.h, error.c, error.h, exec-flex.sh, hash.c, hash.h, helpers.c, helpers.h, icmp.c, icmp.h, ipvers.h, main.c, netdev.c, netdev.h, pdnsd-redhat.spec.templ, pdnsd-suse.spec.templ, servers.c, servers.h, status.c, status.h, version:
  2154. Removed the moved files. Will add the new ones soon.
  2155. 2000-07-16 Thomas Moestl <tmoestl@gmx.net>
  2156. * TODO: New tasks in TODO.
  2157. 2000-07-15 Thomas Moestl <tmoestl@gmx.net>
  2158. * TODO:
  2159. Updated TODO: Autoconf support was contributed by Sourav K. Mandal
  2160. * conff.h, dns_query.c, ipvers.h, cache.c:
  2161. Fixed some minor bugs and a showstopper in cache.c that caused
  2162. crashes in some situations.
  2163. 2000-07-12 Thomas Moestl <tmoestl@gmx.net>
  2164. * dns_query.c, error.c, error.h, main.c:
  2165. Made pdnsd ignore SIGPIPE, which seemed to be responsible for some
  2166. crashes.
  2167. Accept (grudgingly) SOA rr's where NS ones would be The Right Thing.
  2168. 2000-07-10 Thomas Moestl <tmoestl@gmx.net>
  2169. * AUTHORS, THANKS, conff.c:
  2170. Updated AUTHORS, THANKS, and the fprintfs for the status pipe in
  2171. conff.c
  2172. * TODO, config.h.templ, dns.h, dns_answer.c, dns_query.c, dns_query.h, main.c, version:
  2173. Added UDP queries and gave the user the choice between TCP and UDP
  2174. queries (UDP is the default now). Made the TCP server optional.
  2175. Fixed a authoritative record handling bug. Added pidfile support.
  2176. 2000-07-07 Thomas Moestl <tmoestl@gmx.net>
  2177. * doc/pdnsd.conf:
  2178. Inserted run_as="nobody"; again, it is The Right Thing and people
  2179. should use it.
  2180. * Makefile:
  2181. The pdnsd cache directory is now created as nobody, since the
  2182. default run_as in the example pdnsd.conf is also nobody.
  2183. * doc/pdnsd.conf:
  2184. Commented the run_as option out (people may run into permission
  2185. problems).
  2186. * version: Upped version to 1.0.5
  2187. * AUTHORS, THANKS, conf.l.templ, conf.y, conff.c, conff.h, dns_answer.c, icmp.c, icmp.h, main.c, version:
  2188. Folded in the server_ip option code as contributed by Wolfgang Ocker
  2189. and extended it to IPv6. Fixed a bug in IPv4 ping in IPv6 mode.
  2190. 2000-07-06 Thomas Moestl <tmoestl@gmx.net>
  2191. * cache.c, dns_query.c:
  2192. Killed a bug which could cause crashes with more than 2 servers.
  2193. * cache.c: Fixed a bug reported by Bert Frederiks that would break the
  2194. serve_aliases option when only one character was between official
  2195. name and alias in the /etc/hosts-style file.
  2196. 2000-07-04 Thomas Moestl <tmoestl@gmx.net>
  2197. * pdnsd-suse.spec.templ: The SuSE spec now uses the new makefile rule.
  2198. * Makefile, THANKS, dns_query.c, helpers.c, version:
  2199. Added people to THANKS, fixed a bug that caused uppercase hosts/
  2200. rr-section entries to be ignored in the cache, fixed the SuSE
  2201. makefile for pdnsd to run_as nobody, and other small fixups.
  2202. 2000-07-03 Thomas Moestl <tmoestl@gmx.net>
  2203. * dns_answer.c:
  2204. First change after release of 1.0.4: The questions received
  2205. are now properly written into the debug file when starting
  2206. with -g -d.
  2207. * config.h.templ, dns_query.c:
  2208. Fixed a possible way to get around paranoid restrictions.
  2209. * version: Set version to 1.0.4
  2210. * doc/pdnsd.conf: Added an entry for the paranoid option.
  2211. * cache.c, config.h.templ, dns_answer.c, dns_query.c, ipvers.h:
  2212. Revisions and fixups. The complete code revision is now complete.
  2213. 2000-06-29 Thomas Moestl <tmoestl@gmx.net>
  2214. * dns_query.c: Overhaul.
  2215. * dns_answer.c, dns_query.c, config.h.templ:
  2216. Code overhault continued. dns_answer.c is finished.
  2217. 2000-06-27 Thomas Moestl <tmoestl@gmx.net>
  2218. * conff.c, dns_answer.c, icmp.c, netdev.c, servers.c, status.c:
  2219. Continued code overhaul. Fixed several bugs, and simplified some
  2220. code.
  2221. * conf.l.templ, conf.y, conff.c, ipvers.h, version: Fixups.
  2222. 2000-06-26 Thomas Moestl <tmoestl@gmx.net>
  2223. * hash.c: Revised; fixed a minor bug.
  2224. * cache.c: Overhauled.
  2225. * dns_query.c, error.c, helpers.c, helpers.h, ipvers.h, main.c, version, dns.c:
  2226. Manual code overhaul. Numerous small patches, greatly simplified
  2227. decompress_name().
  2228. 2000-06-25 Thomas Moestl <tmoestl@gmx.net>
  2229. * config.h.templ:
  2230. Made the C random() RNG the default (using /dev/urandom, we suck up
  2231. too much randomness on high load).
  2232. * error.c, error.h, icmp.c, icmp.h, main.c:
  2233. Small cleanups. Makes the testsuite compilation easier.
  2234. * Makefile, config.h.templ: Preparing for release of 1.0.4.
  2235. 2000-06-24 Thomas Moestl <tmoestl@gmx.net>
  2236. * Makefile, THANKS, a-conf.sh, dns_answer.c, dns_query.c, error.c, version:
  2237. Fixed bugs with the paranoid option, connect() timeout handling, and
  2238. a incompatability in response handling that caused the glibc
  2239. resolver to misunderstand error messages pdnsd generated on unknown
  2240. query types. This bug, that was reported by James MacLean, could
  2241. for example cause ssh to hang some time.
  2242. * Makefile, NEWS, conf.l.templ, conf.y, conff.c, conff.h, config.h.templ, dns.c, dns_query.c, dns_query.h, helpers.c, helpers.h, icmp.c, icmp.h, main.c:
  2243. Added the paranoid option, and modified the ping uptest so that it
  2244. works with strict_setuid. Also made strict_setuid=on the default.
  2245. 1.0.4 should be out soon.
  2246. 2000-06-23 Thomas Moestl <tmoestl@gmx.net>
  2247. * doc/pdnsd.conf: Added a run_as= line, which is sensible normally.
  2248. * Makefile, conf.l.templ, conf.y, conff.c, conff.h, dns_answer.c, dns_answer.h, helpers.c, helpers.h, main.c, servers.c, status.c, version:
  2249. Some fixups, added the run_as and strict_setuid security options.
  2250. * THANKS: Updated.
  2251. * AUTHORS, ipvers.h, main.c, netdev.c, version:
  2252. Fixed some definitions for glibc2.0-users. Repaced the return at the
  2253. end of main() with _exit(). Should not build and run OK on glibc 2.0
  2254. boxen.
  2255. Fixed a typo in netdev.c
  2256. * ipvers.h:
  2257. Fixed a typo in ipvers.h to fix compile problems on systems without
  2258. an IPv6-supporting C library, and possible IPv6 problems using the
  2259. status pipe.
  2260. * error.c, version:
  2261. Fixed a bug that could cause signals to be delivered to the wrong
  2262. process.
  2263. 2000-06-22 Thomas Moestl <tmoestl@gmx.net>
  2264. * version: Set version to 1.0.1.
  2265. * cache.c, dns_answer.c, error.c, error.h, main.c, pdnsd-suse.spec.templ:
  2266. Fixed misc issues reported by Jonathan Hudson and Joachim Dorner, one
  2267. of them a real showstopper in cache.c.
  2268. * Makefile, NEWS, README, cache.h, config.h.templ, version:
  2269. Updated things for 1.0.0 and released it finally.
  2270. * AUTHORS, THANKS: Updated THANKS and AUTHORS
  2271. * NEWS, a-conf.sh, cache.c, conf.l.templ, conf.y, conff.c, conff.h, dns_answer.c, dns_query.c, error.c, error.h, main.c, servers.c, status.c:
  2272. Fixed a-conf.sh and cleaned up signal handling as far as it can be
  2273. done ;-). Added the max_ttl option.
  2274. 2000-06-21 Thomas Moestl <tmoestl@gmx.net>
  2275. * dns_answer.c, error.c, error.h, main.c, servers.c, status.c:
  2276. More signal fixes. This is a real pain with LinuxThreads.
  2277. * NEWS, cache.c, dns_answer.c, error.c, error.h, helpers.c, helpers.h, main.c, servers.c, status.c, version:
  2278. Fixups for signal handling. This is more than only a little tricky
  2279. using the linuxthreads library. This hopefully fixes the deadlocks
  2280. we had on signals.
  2281. 2000-06-13 Thomas Moestl <tmoestl@gmx.net>
  2282. * AUTHORS, THANKS: Updated credits.
  2283. * a-conf.sh:
  2284. A primitive configure-like script intended as drop-in replacement
  2285. until autoconf support finally comes.
  2286. * .cvsignore, Makefile, cache.c, dns_query.c, ipvers.h, servers.c, version:
  2287. Added a primitive configuration script as drop-in. Killed some bugs
  2288. and changed the recently added linkdown_kluge option following
  2289. suggestions from Daniel Smolik.
  2290. 2000-06-12 Thomas Moestl <tmoestl@gmx.net>
  2291. * dns_query.h, exec-flex.sh, Makefile, cache.c, conf.l.templ, conf.y, conff.c, conff.h, config.h.templ, dns_query.c:
  2292. Numerous cleanups and fixes. Implemented the linkdown_kluge option
  2293. as proposed by Daniel Smolik. Hope to get ready for 1.0.0 know.
  2294. 2000-06-10 Thomas Moestl <tmoestl@gmx.net>
  2295. * Makefile, NEWS, TODO, dns_answer.c:
  2296. Modified some stuff in dns_answer.c (if no nameserver for a knot in
  2297. the dns namespace is found now, its predecessors are tried now in
  2298. order to return accurate authority results). This will be paid with a
  2299. little more beta time, so the Makefile has developer switches again.
  2300. Corrected NEWS and TODO.
  2301. * Makefile, config.h.templ, dns_answer.c, dns_query.c, dns_query.h, hash.h, helpers.c, version:
  2302. Removed some dead code, fixed some really minor bugs. Version is up
  2303. to 1.0.0p7, which is hopefully the last beta.
  2304. * Makefile, config.h.templ:
  2305. Fixed things up for the 1.0.0 distribution version
  2306. 2000-06-06 Thomas Moestl <tmoestl@gmx.net>
  2307. * Makefile, config.h.templ, icmp.c, netdev.c:
  2308. Some minor comment fixes.
  2309. * Makefile, TODO, main.c, version:
  2310. BSD fix in Makefile and help update. It is now called 1.0.0p6. TODO
  2311. was updated to reflect the project status.
  2312. * dns_answer.c:
  2313. BSD & misc fixes. pdnsd runs now nicely on my FreeBSD 4.0 box.
  2314. * dns_answer.c, ipvers.h:
  2315. Fixed IPv6 UDP dest address recovery. Also fixed a real stupid bug in
  2316. ipvers.h.
  2317. * cache.h, dns_query.c, error.h:
  2318. Added DEBUG_MSG6 macros. Cleaned up requery handling.
  2319. * dns.c, dns_answer.c, dns_query.c, dns_query.h:
  2320. Fixed another heap of bugs, introduced some sanity checks, no requery
  2321. on answers that have ra not set now.
  2322. 2000-06-05 Thomas Moestl <tmoestl@gmx.net>
  2323. * cache.c:
  2324. Fixed write_disk_cache.
  2325. * cache.c, cache.h:
  2326. Fixes for rr handling.
  2327. 2000-06-04 Thomas Moestl <tmoestl@gmx.net>
  2328. * cache.c, dns_answer.c, dns_query.c:
  2329. Fixes again: some missing checks for rrset existence added.
  2330. * cache.c, dns_answer.c, helpers.c, icmp.c:
  2331. Fixes for the new/modified code and its side effects on old code ;-)
  2332. * ChangeLog.old, NEWS, cache.c, conf.l.templ, conf.y, conff.c, config.h.templ, dns.c, dns_answer.c, dns_query.c, error.c, hash.c, helpers.c, icmp.c, main.c, netdev.c, servers.c, status.c:
  2333. Folded the ChangeLog and NEWS of the 0.9.x tree back in and added NEWS for the
  2334. upcoming 1.0.0 release. Some compile fixes. Reorganized config.h.templ. Made
  2335. the inclusion of the rcsid strings into the executable optional.
  2336. * cache.c, dns_answer.c:
  2337. Pile of fixes on recently added/modified code.
  2338. 2000-06-03 Thomas Moestl <tmoestl@gmx.net>
  2339. * .cvsignore, Makefile, lex.inc.h:
  2340. lex.inc.h should not be in CVS (it is automatically generated by
  2341. exec-flex.sh). It should also be deleted by 'make mclean'.
  2342. * TODO, cache.c, dns_answer.c, dns_query.c, lex.inc.h:
  2343. rfc2181 conformance should be reached by now. Updated TODO. Bugfixing
  2344. remains.
  2345. * doc/html/.cvsignore, doc/html/dl.html, doc/html/doc.html, doc/html/faq.html, doc/html/index.html:
  2346. Removed the html documentation from CVS. It is maintained separately.
  2347. * doc/pdnsd.conf:
  2348. Added CVS/RCS $Id$ tag.
  2349. * cache.h, conf.l.templ, conf.y, conff.c, conff.h, config.h.templ, consts.h, dns.c, dns.h, dns_answer.c, dns_answer.h, dns_query.c, dns_query.h, error.c, error.h, exec-flex.sh, hash.c, hash.h, helpers.c, helpers.h, icmp.c, icmp.h, ipvers.h, main.c, netdev.c, netdev.h, pdnsd-redhat.spec.templ, pdnsd-suse.spec.templ, servers.c, servers.h, status.c, status.h, version, AUTHORS, INSTALL, Makefile, NEWS, README, THANKS, TODO, cache.c:
  2350. Added CVS/RCS $Id$ tags to most files, did some cleanups, introduced
  2351. the new rrset granularity caching. The new code is still much of beta,
  2352. use with care.
  2353. 2000-06-01 Thomas Moestl <tmoestl@gmx.net>
  2354. * Makefile, cache.c, hash.c, helpers.c, icmp.c, netdev.c:
  2355. Yet another set of BSD fixes (test programs do now work for me
  2356. under FreeBSD). Some other minor fixes.
  2357. * Makefile, error.c, error.h, helpers.c, helpers.h:
  2358. Transplanted kill_pdnsd from error.c to helpers.c in order to get the
  2359. tests compiled without the thread library.
  2360. 2000-05-31 Thomas Moestl <tmoestl@gmx.net>
  2361. * pdnsd:
  2362. Ooops, executable got in.
  2363. * Makefile, pdnsd:
  2364. Added test suite programs.
  2365. * icmp.c, netdev.c:
  2366. All basic BSD patches have been folded in. pdnsd will now compile on
  2367. FreeBSD with (hopefully) all features.
  2368. * dns_answer.c, Makefile:
  2369. Disabled udp targed address discovery for BSD builds (this sadly ist
  2370. OS specific at least for IPv4. Must be rewritten under BSD as it is
  2371. an RFC compatability issue under some circumstances)
  2372. * cache.c, cache.h, conf.y, conff.c, conff.h, config.h.templ, dns_answer.c, helpers.c, icmp.c, ipvers.h, netdev.c, Makefile:
  2373. BSD include & misc build fixes. More to follow...
  2374. * Makefile, cache.h:
  2375. BSD Fixes: Makefile should work with BSD make, sed command line,
  2376. sorted out naming clash in cache.h
  2377. * .cvsignore:
  2378. Added ChangeLog to .cvsignore
  2379. * THANKS, conff.c:
  2380. Fixed a bug reported by Jonathan Hudson and added him to THANKS
  2381. * ChangeLog.old:
  2382. Added the pre-CVS ChangeLog.
  2383. * .cvsignore, AUTHORS, COPYING, INSTALL, Makefile, NEWS, README, THANKS, TODO, cache.c, cache.h, conf.l.templ, conf.y, conff.c, conff.h, config.h.templ, consts.h, dns.c, dns.h, dns_answer.c, dns_answer.h, dns_query.c, dns_query.h, doc/.cvsignore, doc/html/dl.html, doc/html/doc.html, doc/html/faq.html, doc/html/index.html, doc/pdnsd.conf, doc/txt/.cvsignore, error.c, error.h, exec-flex.sh, hash.c, hash.h, helpers.c, helpers.h, icmp.c, icmp.h, ipvers.h, lex.inc.h, main.c, netdev.c, netdev.h, pdnsd-redhat.spec.templ, pdnsd-suse.spec.templ, servers.c, servers.h, status.c, status.h, version:
  2384. Initial import of pdnsd-1.0.0p3 source tree into CVS.
  2385. * .cvsignore, AUTHORS, COPYING, INSTALL, Makefile, NEWS, README, THANKS, TODO, cache.c, cache.h, conf.l.templ, conf.y, conff.c, conff.h, config.h.templ, consts.h, dns.c, dns.h, dns_answer.c, dns_answer.h, dns_query.c, dns_query.h, doc/.cvsignore, doc/html/dl.html, doc/html/doc.html, doc/html/faq.html, doc/html/index.html, doc/pdnsd.conf, doc/txt/.cvsignore, error.c, error.h, exec-flex.sh, hash.c, hash.h, helpers.c, helpers.h, icmp.c, icmp.h, ipvers.h, lex.inc.h, main.c, netdev.c, netdev.h, pdnsd-redhat.spec.templ, pdnsd-suse.spec.templ, servers.c, servers.h, status.c, status.h, version:
  2386. New file.