Summary: | dnsmasq-2.21 is un-useable on stable servers with dhcp-host option | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Roy Marples (RETIRED) <uberlord> |
Component: | [OLD] Server | Assignee: | Jon Portnoy (RETIRED) <avenj> |
Status: | RESOLVED FIXED | ||
Severity: | major | CC: | henrik, security |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | All | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 86718 |
Description
Roy Marples (RETIRED)
![]() found the --mx-target= bug, waiting for Uberlord to test my fix. option.c has: if ((daemon->mxtarget || (daemon->options & OPT_LOCALMX)) && !mx) { daemon->mxnames = safe_malloc(sizeof(struct mx_srv_record)); daemon->mxnames->next = daemon->mxnames; daemon->mxnames->issrv = 0; daemon->mxnames->target = NULL; daemon->mxnames->name = safe_string_alloc(buff); } and later: for (mx = daemon->mxnames; mx; mx = mx->next) if (!mx->issrv && !mx->target) mx->target = daemon->mxtarget; This loops forever because mx->next = mx = mx->next as there is no sanity check for loops (in this case, next=self). Not quite sure what was meant to happen here, but it seems maybe it should be: daemon->mxnames->next = NULL; instead of daemon->mxnames->next = daemon->mxnames; We don't have anyone here who can test this functionality easily, so mailing upstream. I can't easily pinpoint the dhcp-host bug because I can't test locally and gdb wasn't playing nice on Uberlord's machine. I'll let Simon know about this bug. author mailed. dnsmasq should probably be masked until resolution I mean 2.21 should be masked (or keywords reset) until resolution as 2.21 is the current stable. uberlord: please test http://www.thekelleys.org.uk/test It should definitely fix the mx-host thing and hopefully the dhcp-host stuff as well. That test version does NOT fix the dhcp-host problem :( If it helps, here is a line that causes the problem dhcp-host=00:09:5b:84:88:7d,uberpc,192.168.2.10 Removing that line makes uberpc get a DHCP address correctly and not cause dnsmasq to eat CPU cycles like it's going out of fashion. Bug is more harmful than potential security problems in <=2.20. I've masked 2.21 for now. The 2.22 test version in comment #7 fixed the mx bug Just the dhcp-host bug to fix now! the dhc-host bug manifests itself at dhcp.c:422 for (; context; context = context->current) loops forever. This is another context == context->current thing, same as last one. Not sure of the fix but I've let the author know. test fix version from simon at: http://thekelleys.org.uk/test/dnsmasq-2.22test7.tar.gz fix confirmed to work :) I've let the author know. 22 released with the fix. 2.22 committed. Thanks Rob! |