FS#30139 - [bind] Segmentation fault with nsupdate

Attached to Project: Arch Linux
Opened by Stefan J. Betz (encbladexp) - Monday, 04 June 2012, 16:42 GMT
Last edited by Gaetan Bisson (vesath) - Thursday, 07 June 2012, 06:00 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Gaetan Bisson (vesath)
Architecture x86_64
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Hi,

i am using nsupdate from bind 9.9.1-1, and trying to update some remote DNS Records:
nsupdate -y domain.tld.:magickey
> server domain.tld
Segmentation fault

I found this entry in my kernel log:
Jun 04 18:40:55 pc2007 kernel: nsupdate[14189]: segfault at 0 ip 0000000000407aba sp 00007fff6e42e280 error 4 in nsupdate[400000+e000]

Any ideas?
This task depends upon

Closed by  Gaetan Bisson (vesath)
Thursday, 07 June 2012, 06:00 GMT
Reason for closing:  Upstream
Comment by Gaetan Bisson (vesath) - Tuesday, 05 June 2012, 04:00 GMT
Not sure what is wrong here but there's bind-9.9.1.P1 in [testing]: http://mirror.leaseweb.net/archlinux/testing/os/x86_64/bind-9.9.1.P1-1-x86_64.pkg.tar.xz
Could you give this a try?
Comment by Stefan J. Betz (encbladexp) - Tuesday, 05 June 2012, 14:03 GMT
Hi, i tried this: Doesn't work too :(
Comment by Gaetan Bisson (vesath) - Tuesday, 05 June 2012, 14:18 GMT
Does nsupdate segfault without arguments too? Or could you tell me what arguments you use?
So long as I cannot reproduce this, I will not be able to investigate anything, so you will need to work it out on your own...
Comment by Stefan J. Betz (encbladexp) - Tuesday, 05 June 2012, 14:55 GMT
The simplest way to reproduce this issue:
nsupdate
> server localhost
Segfault...

Yes, nsupdate segfaults also without any arguments too.
Comment by Gaetan Bisson (vesath) - Tuesday, 05 June 2012, 16:56 GMT
I identified the problem: after two calls to nsu_strsep in the evaluate_server function of nsupdate.c, word becomes NULL when it should be a pointer to NULL.
To fix this, I came up with the attached patch although I'm not sure if this doesn't break other things...

I've submitted it upstream and will wait to hear back from them before taking any action on our package.
In the meantime, a workaround is to specify all arguments in your requests to nsupdate; here, you were missing the port number, which would give "server localhost 53" or so...
   patch (0.3 KiB)
Comment by Stefan J. Betz (encbladexp) - Tuesday, 05 June 2012, 17:32 GMT
Good Job!
Comment by Gaetan Bisson (vesath) - Thursday, 07 June 2012, 06:00 GMT
The upstream bug reference number is 29550; ISC people are working on fixing it in a future version...

Loading...