forked from guns/dnsmasq
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CHANGELOG.archive
2509 lines (1905 loc) · 103 KB
/
CHANGELOG.archive
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
release 0.4 - initial public release
release 0.5 - added caching, removed compiler warning on linux PPC
release 0.6 - TCP handling: close socket and return to connect state if we
can't read the first byte. This corrects a problem seen very
occasionally where dnsmasq would loop using all available CPU.
Added a patch from Cris Bailiff <[email protected]>
to set SO_REUSEADDR on the tcp socket which stops problems when
dnsmasq is restarted and old connections still exist.
Stopped claiming in doc.html that smail is the default Debian
mailer, since it isn't any longer. (Pointed out by
David Karlin <[email protected]>)
release 0.7 Create a pidfile at /var/run/dnsmasq.pid
Extensive armouring against "poison packets" courtesy of
Thomas Moestl <[email protected]>
Set sockaddr.sa_family on outgoing address, patch from
David Symonds <[email protected]>
Patch to clear cache on SIGHUP
from Jason L. Wagner <[email protected]>
Fix bad bug resulting from not initialising value-result
address-length parameter to recvfrom() and accept() - it
worked by luck before!
release 0.95 Major rewrite: remove calls to gethostbyname() and talk
directly to the upstream server(s) instead.
This has many advantages.
(1) Dnsmasq no longer blocks during long lookups.
(2) All query types are handled now, (eg MX) not just internet
address queries. Addresses are cached, all other
queries are forwarded directly.
(3) Time-to-live data from upstream server is read and
used by dnsmasq to purge entries from the cache.
(4) /etc/hosts is still read and its contents served (unless
the -h option is given).
(5) Dnsmasq can get its upstream servers from
a file other than /etc/resolv.conf (-r option) this allows
dnsmasq to serve names to the machine it is running
on (put nameserver 127.0.0.1 in /etc/resolv.conf and
give dnsmasq the option -r /etc/resolv.dnsmasq)
(6) Dnsmasq will re-read its servers if the
modification time of resolv.conf changes. Along with
4 above this allows nameservers to be set
automatically by ppp or dhcp.
A really clever NAT-like technique allows the daemon to have lots
of queries in progress, but still remain very lightweight.
Dnsmasq has a small footprint and normally doesn't allocate
any more memory after start-up. The NAT-like forwarding was
inspired by a suggestion from Eli Chen <[email protected]>
release 0.96 Fixed embarrasing thinko in cache linked-list code.
release 0.98 Some enhancements and bug-fixes.
Thanks to "Denis Carre" <[email protected]> and Martin
Otte <[email protected]>
(1) Dnsmasq now always sets the IP source address
of its replies correctly. Older versions would not always
do this on multi-homed and IP aliased hosts, which violates
the RFC.
(2) Dnsmasq no longer crashes if a server loop is created
(ie dnsmasq is told to use itself as an upstream server.)
Now it just logs the problem and doesn't use the bad
server address.
(3) Dnsmasq should now forward (but not cache) inverse queries
and server status queries; this feature has not been tested.
(4) Don't write the pid file when in non-daemon mode.
(5) Create the pid file mode 644, rather then 666 (!).
(6) Generate queries to upstream nameservers with unpredictable
ids, to thwart DNS spoofers.
(7) Dnsmasq no longer forwards queries when the
"recursion desired" bit is not set in the header.
(8) Fixed getopt code to work on compliers with unsigned char.
release 0.991 Added -b flag: when set causes dnsmasq to always answer
reverse queries on the RFC 1918 private IP space itself and
never forward them to an upstream server. If the name is not in
/etc/hosts, dnsmasq replies with the dotted-quad address.
Fixed a bug which stopped dnsmasq working on a box with
two or more interfaces with the same IP address.
Fixed cacheing of CNAMEs. Previously, a CNAME which pointed
to a name with many A records would not have all the addresses
returned when being answered from the cache.
Thanks to "Steve Hardy" <[email protected]> for his input
on these fixes.
Fixed race which could cause dnsmasq to miss the second of
two closely-spaced updates of resolv.conf (Thanks to Eli Chen
for pointing this out.)
Fixed a bug which could cause dnsmasq to fail to cache some
dns names.
release 0.992 Small change to memory allocation so that names in /etc/hosts
don't use cache slots. Also make "-c 0" flag meaningfully
disable caching completely.
release 0.993 Return only the first (canonical) name from an entry in
/etc/hosts as reply to reverse query.
Handle wildcard queries for names/addresses in /etc/hosts
this is mainly to allow reverse lookups by dig to succeed.
(Bug reported by Simon J. Rowe" <[email protected]>)
Subtle change to the logic which selects which of multiple
upstream servers we send queries to. This fixes a problem
where dnsmasq continuously sends queries to a server which
is returning error codes and ignores one which is working.
release 0.994 Fixed bug which broke lookup of names in /etc/hosts
which have upper-case letters in them. Thanks for Joao Clemente
for spotting that one.
Output cache statistics on receipt of SIGUSR1. These go
to syslog except in debug (-d) mode, when a complete cache
dump goes to stdout. Suggestion from Joao Clemente, code
based in John Volpe's.
Accept GNU long options on the command line. Code from
John Volpe for this.
Split source code into multiple files and produced
a proper makefile.
Included code from John Volpe to parse dhcp.leases file
written by ISC dhcpd. The hostnames in the leases file are
added to the cache and updated as dhcpd updates the
leases file. The code has been heavily re-worked by me,
so any bugs are probably mine.
release 0.995 Small tidy-ups to signal handling and cache code.
release 0.996 Added negative caching: If dnsmasq gets a "no such domain" reply
from an upstream nameserver, it will cache that information
for a time specified by the SOA RR in the reply. See RFC 2308
for details. This is useful with resolver libraries
which append assorted suffices to non-FQDN in an attempt to
resolve them, causing useless cache misses.
Added -i flag, which restricts dnsmasq to offering name service
only on specified interfaces.
release 0.997 Deleted INSTALL script and added "install" target to makefile.
Stopped distributing binaries in the tarball to avoid
libc version clashes.
Fixed interface detection code to
remove spurious startup errors in rare circumstances.
Dnsmasq now changes its uid, irrevocably, to nobody after
startup for security reasons. Thanks to Peter Bailey for
this patch.
Cope with infinite DHCP leases. Patch thanks to
Yaacov Akiba Slama.
Added rpm control files to .tar.gz distribution. Thanks to
Peter Baldwin at ClarkConnect for those.
Improved startup script for rpms. Thanks to Yaacov Akiba Slama.
release 1.0 Stable release: dnsmasq is now considered feature-complete
and stable.
release 1.1 Added --user argument to allow user to change to
a different userid.
Added --mx-target argument to allow mail to be delivered
away from the gateway machine running dnsmasq.
Fixed highly obscure bug with wildcard queries for
DHCP lease derived names.
Moved manpage from section 1 to section 8.
Added --no-poll option.
Added Suse-rpm support.
Thanks to Joerg Mayer for the last two.
release 1.2 Added IPv6 DNS record support. AAAA records are cached
and read from /etc/hosts. Reverse-lookups in the
ip6.int and ip6.arpa domains are suppored. Dnsmasq can
talk to upstream servers via IPv6 if it finds IP6 addresses
in /etc/resolv.conf and it offers DNS service automatically
if IPv6 support is present in the kernel.
Extended negative caching to NODATA replies.
Re-vamped CNAME processing to cope with RFC 2317's use of
CNAMES to PTR RRs in CIDR.
Added config.h and a couple of symbols to aid
compilation on non-linux systems.
release 1.3 Some versions of the Linux kernel return EINVAL rather
then ENPROTONOSUPPORT when IPv6 is not available,
causing dnsmasq to bomb out. This release fixes that.
Thanks to Steve Davis for pointing this one out.
Trivial change to startup logic so that dnsmasq logs
its stuff and reads config files straight away on
starting, rather than after the first query - principle
of least surprise applies here.
release 1.4 Fix a bug with DHPC lease parsing which broke in
non-UTC timezones. Thanks to Mark Wormgoor for
spotting and diagnosing this. Fixed versions in
the .spec files this time. Fixed bug in Suse startup
script. Thanks to Didi Niklaus for pointing this out.
release 1.5 Added --filterwin2k option which stops dnsmasq from forwarding
"spam" queries from win2k boxes. This is useful to stop spurious
connections over dial-on-demand links. Thanks to Steve Hardy
for this code.
Clear "truncated" bit in replies we return from upstream. This
stops resolvers from switching to TCP, which is pointless since
dnsmasq doesn't support TCP. This should solve problems
in resolving hotmail.com domains.
Don't include getopt.h when Gnu-long-options are disabled -
hopefully this will allow compilation on FreeBSD.
Added the --listen-address and --pid-file flags.
Fixed a bug which caused old entries in the DHCP leases file
to be used in preference to current ones under certain
circumstances.
release 1.6 If a machine gets named via DHCP and the DHCP name doesn't have
a domain part and domain suffix is set using the -s flag, then
that machine has two names with the same address, with and
without the domain suffix. When doing a _reverse_ lookup to
get the name, the "without suffix" name used to be returned,
now the "with suffix" one gets returned instead. This change
suggested by Arnold Schulz.
Fixed assorted typos in the documentation. Thanks
to David Kimdon.
Subtle rearrangement to the downloadable tarball, and stopped
distributing .debs, since dnsmasq is now an official Debian
package.
release 1.7 Fix a problem with cache not clearing properly
on receipt of SIGHUP. Bug spotted by Sat Deshpande.
In group-id changing code:
1) Drop supplimentary groups.
2) Change gid before dropping root (patch from Soewono Effendi.)
3) Change group to "dip" if it exists, to allow access
to /etc/ppp/resolv.conf (suggestion from Jorg Sommer.)
Update docs to reflect above changes.
Other documentation changes from David Miller.
Added suggested script fragment for dhcpcd.exe.
release 1.8 Fix unsafe use of tolower() macro - allows linking against
ulibc. (Patches from Soewono Effendi and Bjorn Andersson.)
Fix typo in usage string.
Added advice about RedHat PPP configuration to
documentation. (Thanks to C. Lee Taylor.)
Patches to fix problems on BSD systems from Marc Huber
and Can Erkin Acar. These add the options
HAVE_ARC4RANDOM and HAVE_SOCKADDR_SA_LEN to config.h.
Elaborated config.h - should really use autoconf.
Fix time-to-live calculation when chasing CNAMEs.
Fix use-after-free and missing initialisation bugs in
the cache code. (Thanks to Marc Huber.)
Builds on Solaris 9. (Thanks to Marc Huber.)
release 1.9 Fixes to rpm .spec files.
Don't put expired DHCP entries into the cache only to
throw them away again.
Put dnsmasq on a severe memory diet: this reduces both
the amount of heap space used and the stack size
required. The difference is not really visible with
bloated libcs like glibc, but should dramatically reduce
memory requirements when linked against ulibc for use on
embeded routers, and that's the point really. Thanks to
Matthew Natalier for prompting this.
Changed debug mode (-d) so that all logging appears on
stderr as well as going to syslogd.
Added HAVE_IPV6 config symbol to allow compilation
against a libc which doesn't have IPv6 support.
Added a facility to log all queries, enabled with -q flag.
Fixed packet size checking bug in address extraction code.
Halved default cache size - 300 was way OTT in typical use.
Added self-MX function, enabled by -e flag. Thanks to
Lyonel Vincent for the patch.
Added HAVE_FORK config symbol and stuff to support
uClinux. Thanks to Matthew Natalier for uClinux stuff.
release 1.10 Log warnings if resolv.conf or dhcp.leases are not
accessable for any reason, as suggested by Hinrich Eilts.
Fixed wrong address printing in error message about
no interface with address.
Updated docs and split installation instuctions into setup.html.
Fix bug in CNAME chasing code: One CNAME pointing
to many A records would lose A records after the
first. This bug was introduced in version 1.9.
Log startup failures at level Critical as well as
printing them to standard error.
Exit with return code 1 when given bad options.
Cleaned up code for no-cache operation.
Added -o option which forces dnsmasq to use to
upstream servers in the order they appear in /etc/resolv.conf.
Added upstream server use logging.
Log full cache dump on receipt of SIGUSR1 when query
logging is enabled (-q switch).
Added -S option to directly specify upstream servers and
added ability to direct queries for specific domains to
specfic servers. Suggested by Jens Vonderheide.
Upgraded random ID generation - patch from Rob Funk.
Fixed reading of domains in arguments with capital
letters or trailing periods.
Fixed potential SEGV when given bad options.
Read options from /etc/dnsmasq.conf if it exists.
Do sensible things with missing parameters, eg
"--resolv-file=" turns off reading /etc/resolv.conf.
release 1.11 Actually implement the -R flag promised in the 1.10 man page.
Improve and rationalise the return codes in answers to
queries. In the case that there are no available
upstream servers to forward a query to, return REFUSED.
This makes sendmail work better on modem connected
systems when the modem link is down (Thanks to Roger Plant).
Cache and return the NXDOMAIN status of failed queries:
this makes the `host` command work when traversing search
paths (Thanks to Peter Bailey). Set the "authoritative"
bit in replies containing names from /etc/hosts or DHCP.
Tolerate MS-DOS style line ending codes in /etc/hosts
and /etc/resolv.conf, for people who copy from winsock
installations.
Allow specification of more than one resolv.conf file. This is
intended for laptops which connect via DHCP or
PPP. Whichever resolv.conf was updated last is used.
Allow -S flags which specify a domain but no server
address. This gives local domains which are never forwarded.
Add -E flag to automatically add the domain suffix to
names in /etc/hosts -suggestion from Phil Harman.
Always return a zero time-to-live for names derived from
DHCP which stops anthing else caching these
names. Previously the TTL was derived from the lease
time but that is incorrect since a lease can be given
up early: dnsmasq would know this but anything with the
name cached with long TTL would not be updated.
Extended HAVE_IPV6 config flag to allow compliation on
old systems which don't have modern library routines
like inet_ntop(). Thanks to Phil Harman for the patch.
release 1.12 Allow more than one domain in server config lines and
make "local" a synonym for "server". This makes things
like "local=/localnet/thekelleys.org.uk/" legal. Allow
port to specified as part of server address.
Allow whole domains to have an IP address specified
in /etc/dnsmasq.conf. (/etc/hosts doesn't work domains).
address=/doubleclick.net/127.0.0.1 should catch all
those nasty banner ads. Inspired by a patch
from Daniel Gryniewicz
Log the source of each query when logging switched on.
Fix bug in script fragment for dhcpcd - thanks to Barry Stewart.
Fix bug which meant that strict-order and self-mx were
always enabled.
Builds with Linux libc5 now - for the Freesco project.
Fixed Makefile installation script (patch from Silvan
Minghetti) and added CC and CFLAGS variables.
Improve resource allocation to reduce vulnerability to
DOS attacks - the old version could have all queries
blocked by a continuous high-speed stream of
queries. Now some queries will succeed, and the excess
will be rejected with a server fail error. This change also
protects against server-loops; setting up a resolving
loop between two instances of dnsmasq is no longer
catastrophic. The servers will continue to run, looped
queries fail and a warning is logged. Thanks to C. Lee
Taylor for help with this.
release 1.13 Added support for building rpms suitable for modern Suse
systems. (patch from Andi <[email protected]>)
Added options --group, --localmx, --local-ttl,
--no-negcache, --addn-host.
Moved all the various rpm-building bits into /rpm.
Fix builds with glibc 2.1 (thanks to Cristian
Ionescu-Idbohrn)
Preserve case in domain names, as per RFC1035.
Fixed ANY queries to domains with --address specification.
Fixed FreeBSD build. (thanks to Steven Honson)
Added -Q option which allows a specified port to be used
to talk to upstream servers. Useful for people who want
very paranoid firewalls which open individual UDP port.
(thanks to David Coe for the patch)
release 1.14 Fixed man page description of -b option which confused
/etc/hosts with /etc/resolv.conf. (thanks to Christopher
Weimann)
Fixed config.h to allow building under MACOS X and glibc
2.0.x. (thanks to Matthew Gregan and Serge Caron)
Added --except-interface option. (Suggested by Serge Caron)
Added SIGUSR2 facility to re-scan for new
interfaces. (Suggested by Serge Caron)
Fixed SEGV in option-reading code for invalid options.
(Thanks to Klaas Teschauer)
Fixed man page to clarify effect of SIGUSR1 on
/etc/resolv.conf.
(Thanks to Klaas Teschauer)
Check that recieved queries have only rfc1035-legal characters
in them. This check is mainly to avoid bad strings being
sent to syslog.
Fixed &&/& confusion in option.c and added DESTDIR
variable for "make install" (Thanks to Osvaldo
Marques for the patch.)
Fixed /etc/hosts parsing code to cope with MS-DOS
line-ends in the file. This was supposed to be done in
version 1.11, but something got missed. (Thanks to Doug
Copestake for helping to find this.)
Squash repeated name/address pairs read from hosts
files.
Tidied up resource handling in util.c (Thanks to
Cristian Ionescu-Idbohrn).
Added hashed searching of domain names. People are starting
to use dnsmasq with larger loads now, and bigger caches,
and large lists of ad-block addresses. This means doing
linear searches can start to use lots of CPU so I added hashed
searching and seriously optimised the cache code for
algorithmic efficiency. Also upped the limit on cache
size to 10000.
Fixed logging of the source of names from the additional
hosts file and from the "bogus private address" option.
Fixed spurious re-reading of empty lease files. (Thanks
to Lewis Baughman for spotting this.)
Fixed building under uclibc (patch from Cristian Ionescu-Idbohrn)
Do some socket tweaking to allow dnsmasq to co-exist
with BIND. Thanks to Stefan 'Sec' Zehl for the patch.
release 1.15 Added --bogus-nxdomain option.
Restrict checking of resolv.conf and DHCP leases files
to once per second. This is intended to improve
performance under heavy loads. Also make a system call
to get the current time once per query, rather than four
times.
Increased number of outstanding queries to 150 in
config.h
release 1.16 Allow "/" characters in domain names - this fixes
caching of RFC 2317 CNAME-PTR records.
Fixed brain-fart in -B option when GETOPT_LONG not
enabled - thanks to Steven Young and Jason Miller
for pointing this out.
Generalised bogus-nxdomain code: allow more than one
address to check, and deal with replies with multiple
answer records. (Based on contribution from Humberto
Massa.)
Updated the documentation to include information about
bogus-nxdomain and the Verisign tragedy.
Added libraries needed on Solaris to Makefile.
Added facility to set source address in queries to
upstream nameservers. This is useful with multihomed
hosts, especially when using VPNs. Thanks to Tom Fanning
for suggesting this feature.
Tweaked logging: log to facility LOCAL0 when in
debug/no-daemon mode and changed level of query logging
from INFO to DEBUG. Make log options controllable in
config.h
release 1.17 Fixed crash with DHCP hostnames > 40 characters.
Fixed name-comparision routines to not depend on Locale,
in theory this versions since 1.15 could lock up or give
wrong results when run with locale != 'C'.
Fix potential lockup in cache code. (thanks to Henning
Glawe for help chasing this down.)
Made lease-file reader bullet-proof.
Added -D option, suggested by Peter Fichtner.
release 1.18 Added round-robin DNS for names which have more than one
address. In this case all the addresses will be
returned, as before, but the order will change on each
query.
Remove stray tolower() and isalnum() calls missed in
last release to complete LOCALE independence.
Allow port numbers in source-address specifications.
For hostnames without a domain part which don't get
forwarded because -D is in effect, return NXDOMAIN not
an empty reply.
Add code to return the software version in repsonse to the
correct magic query in the same way as BIND. Use
"dig version.bind chaos txt" to make the query.
Added negative caching for PTR (address to name) records.
Ensure that names of the form typically used in PTR queries
(ie w.x.yz.in-addr.arpa and IPv6 equivalents) get
correct answers when queried as other types. It's
unlikely that anyone would do this, but the change makes
things pedantically correct.
Taught dnsmasq to understand "bitstring" names, as these
are used for PTR lookups of IPv6 addresses by some
resolvers and lookup tools. Dnsmasq now understands both
the ip6.int domain and the ip6.arpa domain and both
nibble and bitstring formats so it should work with any
client code. Standards for this stuff have flip-flopped
over the last few years, leaving many different clients
in their wake. See RFC2673 for details of bitstrings.
Allow '_' characters in domain names: Legal characters
are now [a-z][A-Z].-_ Check names read from hosts files
and leases files and reject illegal ones with a message
in syslog.
Make empty domain names in server and address options
have the special meaning "unqualified
names". (unqualified names are names without any dots in
them). It's now possible to do server=//1.2.3.4 and have
unqualified names sent to a special nameserver.
release 2.0rc1
Moved source code into src/ directory.
Fixes to cure compilation breakage when HAVE_IPV6 not
set, thanks to Claas Hilbrecht.
BIG CHANGE: added an integrated DHCP server and removed
the code to read ISC dhcp.leases. This wins in terms
of ease of setup and configuration flexibility and
total machine resources consumed.
Re-jiged the signal handling code to remove a race
condition and to be more portable.
release 2.0
Thanks to David Ashworth for feedback which informed many
of the fixes below.
Allow hosts to be specified by client ID in dhcp-hosts
options. These are now one of
dhcp-host=<hardware addr>,....
dhcp-host=id:<hex client id>,.....
dhcp-host=id:<ascii client id>,.....
Allow dhcp-host options to specify any IP address on the
DHCP-served network, not just the range available for
dynamic allocation.
Allow dhcp-host options for the same host with different
IP adresses where the correct one will be selected for
the network the host appears on.
Fix parsing of --dhcp-option to allow more than one
IP address and to allow text-type options.
Inhibit use of --dhcp-option to send hostname DHCP options.
Update the DNS with DHCP information after re-reading
/etc/hosts so that any DHCP derived names which have been
shadowed by now-deleted hosts entries become visible.
Fix typos in dnsmasq.conf.example
Fixes to Makefile(s) to help pkgsrc packaging - patch
from "pancake".
Add dhcp-boot option to support network boot.
Check for duplicate IP addresses in dhcp-hosts lines
and refuse to run if found. If allowed to remain these
can provoke an infinite loop in the DHCP protocol.
Attempted to rationalise the .spec files for rpm
building. There are now files for Redhat, Suse and
Mandrake. I hope they work OK.
Fixed hard-to-reproduce crash involving use of local
domains and IPv6 queries. Thanks to Roy Marples for
helping to track that one down.
release 2.1
Thanks to Matt Swift and Dag Wieers for many suggestions
which went into this release.
Tweak include files to allow compilation on FreeBSD 5
Fix unaligned access warnings on BSD/Alpha.
Allow empty DHCP options, like so: dhpc-option=44
Allow single-byte DHCP options like so: dhcp-option=20,1
Allow comments on the same line as options in
/etc/dnsmasq.conf
Don't complain when the same name and address is
allocated to a host using DHCP and /etc/hosts.
Added to the example configuration the dnsmasq equivalent
of the ISC dhcpd settings given in
http://www.samba.org/samba/ftp/docs/textdocs/DHCP-Server-Configuration.txt
Fixed long-existing strangeness in Linux IPv6 interface
discovery code. The flags field in /proc/net/if_inet6 is
_not_ the interface flags.
Fail gracefully when getting an ENODEV error when trying
to bind an IPv6 socket, rather than bailing out. Thanks
to Jan Ischebeck for feedback on that.
Allow the name->address mapping for static DHCP leases to
be set by /etc/hosts. It's now possible to have
dhcp-host=<mac addr>,wibble
or even
dhcp-host=wibble
and in /etc/hosts have
wibble 1.2.3.4
and for the correct thing to happen. Note that some sort
of dhcp-host line is still needed, it's not possible for
random host to claim an address in /etc/hosts without
some explicit configuration.
Make 0.0.0.0 in a dhcp-option to mean "the machine
running dnsmasq".
Fix lease time spec when specified in dhcp-range and not
in dhcp-host, previously this was always one hour.
Fix problem with setting domains as "local only". -
thanks to Chris Schank.
Added support for max message size DHCP option.
release 2.2
Fix total lack for DHCP functionality on
Linux systems with IPv6 enabled. - thanks to
Jonathon Hudson for spotting that.
Move default config file under FreeBSD - patch from
Steven Honson
release 2.3
Fix "install" makefile target. (reported by Rob Stevens)
Ensure that "local=/domain/" flag is obeyed for all
queries on a domain, not just A and AAAA. (Reported by
Peter Fichtner.)
Handle DHCPDECLINE messages and provide an error message
in DHCPNAK messages.
Add "domain" setting example to
dnsmasq.conf.example. Thanks to K P Kirchdorfer for
spotting that it was missing.
Subtle change to the DHCPREQUEST handling code to work
around a bug in the DHCP client in HP Jetdirect printers.
Thanks to Marko Stolle for finding this problem.
Return DHCP T1 and T2 times, with "fuzz" to desychronise lease
renewals, as specified in the RFC.
Ensure that the END option is always present in DHCP
packets , even if the packet is too small to fit all
the requested options.
Handle larger-than-default DHCP packets if required, up
to the ethernet MTU.
Fix a couple of places where the return code from
malloc() was not checked.
Cope with a machine taking a DHCP lease and then moving
network so that the lease address is no longer valid.
The DHCP server will now work via a BOOTP relay - remote
networks are configured with the dhcp-range option the
same as directly connected ones, but they need an
additional netmask parameter. Eg
--dhcp-range=192.168.4.10,192.168.4.50,255.255,255.0
will enable DHCP service via a BOOTP relay on the
192.168.4.0 network.
Add a limit on the number of available DHCP leases,
otherwise the daemon could be DOSed by a malicious
host. The default is 150, but it can be changed by the
dhcp-lease-max option.
Fixed compilation on OpenBSD (thanks to Frederic Brodbeck
for help with that.)
Reworked the DHCP network handling code for two good
effects: (1) The limit of one network only for DHCP on
FreeBSD is now gone, (2) The DHCP server copes with
dynamically created interfaces. The one-interface
limitation remains for OpenBSD, which is missing
extensions to the socket API which have been in Linux
since version 2.2 and FreeBSD since version 4.8.
Reworked the DNS network code to also cope with
dynamically created interfaces. dnsmasq will now listen
to the wildcard address and port 53 by default, so if no
--interface or --address options are given it will handle
dynamically created interfaces. The old behaviour can be
restored with --bind-interfaces for people running BIND
on one interface and dnsmasq on another. Note that
--interface and --address options still work, but the
filtering is done by dnsmasq, rather then the kernel.
This works on Linux, and FreeBSD>=5.0. On systems which
don't support the required API extensions, the old
behaviour is used, just as if --bind-interfaces had been set.
Allow IPv6 support to be disabled at compile time. To do
that, add -DNO_IPV6 to the CFLAGS. Thanks to Oleg
I. Vdovikin for the suggestion to do that.
Add ability to set DHCP options per network. This is done
by giving a network an identifier like this:
dhcp-range=red-net,192.168.0.10,192.168.0.50
and then labeling options intended for that network only
like this:
dhcp-option=red-net,6,1.1.1.1
Thanks to Oleg Vdovikin for arguing that one through.
Made errors in the configuration file non-fatal: dnsmasq
will now complain bitterly, but continue.
Added --read-ethers option, to allow dnsmasq to pull
static DHCP information from that file.
Thanks to Andi Cambeis for that suggestion.
Added HAVE_BROKEN_RTC compilation option to support
embedded systems without a stable RTC. Oleg Vdovikin
helped work out how to make that work.
release 2.4
Fixed inability to start when the lease file doesn't
already exist. Thanks to Dag Wieers for reporting that.
Fixed problem were dhcp-host configuration options did
not play well with entries in /etc/ethers for the same
host. Thanks again to Dag Wieers.
Tweaked DHCP code to favour moving to a newly-configured
static IP address rather than an old lease when doing
DHCP allocation.
Added --alias configuration option. This provides IPv4
rewrite facilities like Cisco "DNS doctoring". Suggested
by Chad Skeeters.
Fixed bug in /etc/ethers parsing code triggered by tab
characters. Qudos to Dag Wieers for hepling to nail that
one.
Added "bind-interfaces" option correctly.
release 2.5
Made "where are we allocating addresses?" code in DHCP
server cope with requests via a relay which is on a
directly connected network for which there is not a
configured netmask. This strange state of affairs occurs
with win4lin. Thanks to Alex Melt and Jim Horner for bug
reports and testing with this.
Fixed trivial-but-irritating missing #include which broke
compilation on *BSD.
Force --bind-interfaces if IP-aliased interface
specifications are used, since the sockets API provides
no other sane way to determine which alias of an
interface a packet was sent to. Thanks to Javier Kohen
for the bug report.
release 2.6
Support Token Ring DHCP. Thanks to Dag Wieers for help
testing. Note that Token ring support only works on Linux
currently.
Fix compilation on MacOS X. Thanks to Bernhard Ehlers for
the patch.
Added new "ignore" keyword for
dhcp-host. "dhcp-host=11:22:33:44:55:66,ignore" will
cause the DHCP server to ignore any host with the given
MAC address, leaving it to other servers on the
network. This also works with client-id and hostnames.
Suggestion by Alex Melt.
Fixed parsing of hex client IDs. Problem spotted by Peter
Fichtner.
Allow conf-file options in configuration file, to
provide an include function.
Re-read /etc/ethers on receipt of SIGHUP.
Added back the ability to read ISC dhcpd lease files, by
popular demand. Note that this is deprecated and for
backwards compatibility only. You can get back the 4K of
memory that the code occupies by undefining
"HAVE_ISC_READER" in src/config.h
Added ability to disable "pool" DHCP address allocation
whilst leaving static leases working. The syntax is
"dhcp-range=192.168.0.0,static"
Thanks to Grzegorz Nosek for the suggestion.
Generalized dnsmasq-rh.spec file to work on Mandrake too,
and removed dnsmasq-mdk.spec. Thanks to Doug Keller.
Allow DHCP options which are tied to specific static
leases in the same way as to specific networks.
Generalised the dhcp-option parser a bit to allow hex
strings as parameters. This is now legal:
dhcp-option=128,e4:45:74:68:00:00
Inspired by a patch from Joel Nordell.
Changed the semantics of argument-less dhcp-options for
the default-setting ones, ie 1, 3, 6 and 28. Now, doing
eg, dhcp-option=3 stops dnsmasq from sending a default
router option at all. Thanks to Scott Emmons for pointing
out that this is useful.
Fixed dnsmasq.conf parsing bug which interpreted port
numbers in server= lines as a comment. To start a
comment, a '#' character must now be a the start of a
line or preceded by whitespace. Thanks to Christian
Haggstrom for the bug report.
release 2.7
Allow the dhcp-host specification of id:* which makes
dnsmasq ignore any client-id. This is useful to ensure
that a dual-boot machine sees the same lease when one OS
gives a client-id and the other doesn't. It's also useful
when PXE boot DHCP does not use client IDs but the OS it boots
does. Thanks to Grzegorz Nosek for suggesting this enhancement.
No longer assume that ciaddr is zero in received DHCPDISCOVER
messages, just for security against broken clients.
Set default of siaddr field to the address of the machine running
dnsmasq when not explicitly set using dhcp-boot
option. This is the ISC dhcpd behaviour.
Send T1 and T2 options in DHCPOFFER packets. This is required
by the DHCP client in some JetDirect printers. Thanks
to Paul Mattal for work on this.
Fixed bug with DHCP on OpenBSD reported by Dominique Jacquel.
The code which added loopback interfaces to the list
was confusing the DHCP code, which expected one interface only.
Solved by adding loopback interfaces to address list instead.
Add dhcp-vendorclass option to allow options to be sent only
to certain classes of clients.
Tweaked option search code so that if a netid-qualified
option is used, any unqualified option is ignored.
Changed the method of picking new dynamic IP
addresses. This used to use the next consecutive
address as long it was free, now it uses a hash
from the client hardware address. This reduces the amount
of address movement for clients which let their lease
expire and allows consecutive DHCPOFFERS to the same host
to (almost always) be for the same address, without
storing state before a lease is granted.
Tweaked option handling code to return all possible
options rather than none when DHCP "requested options"
field is missing. This fixes interoperability with
ancient IBM LANMAN DHCP clients. Thanks to Jim Louvau for
help with this.
release 2.8
Pad DHCP packets to a minimum size of 300 bytes. This
fixes interoperability problems with the Linux in-kernel
DHCP/BOOTP client. Thanks to Richard Musil for
diagnosing this and supplying a patch.
Fixed option-parsing bug and potential memory leak. Patch
from Richard Musil.
Improved vendor class configuration and added user class
configuration. Specifically: (1) options are matched on
the netids from dhcp-range, dhcp-host, vendor class and
user class(es). Multiple net-ids are allowed and options
are searched on them all. (2) matches agains vendor class
and user class are now on a substring, if the given
string is a substring of the vendor/user class, then a
match occurs. Thanks again to Richard Musil for prompting
this.
Make "#" match any domain on --address and --server
flags. --address=/#/1.2.3.4 will return 1.2.3.4 for _any_
domain not otherwise matched. Of course
--server=/#/1.2.3.4 is exactly equivalent to
--server=1.2.3.4. Special request from Josh Howlett.
Fixed a nasty bug which would cause dnsmasq to lose track
of leases for hosts which had a --dhcp-host flag without
a name specification. The mechanism for this was that
the hostname could get erroneously set as a zero-length
string and then written to the leases file as a
mal-formed line. Restarting dnsmasq would then lose the lease.
Alex Hermann's work helped chase down this problem.
Add checks against DHCP clients which return zero-length
hostnames. This avoids the potential lease-loss problems
reffered to above. Also, if a client sends a hostname when