Fruneau / pfixtools

The pfixtools project is a collection of postfix-related tools. The pfixtools are written in C.
Other
26 stars 7 forks source link

Segmentation fault #11

Open caffeinejolt opened 10 years ago

caffeinejolt commented 10 years ago

postlicyd -vvv -f /etc/pfixtools/postlicyd.conf -u [notice] starting postlicyd v0.9... [debug ] starting resource gc: before 0 resources, after 0 [notice] entering processing loop [debug ] running filter check_srs_bounce (match) [debug ] running condition: "EDITED" is empty "(none)" [debug ] no condition matched, not-match_all failed [debug ] filter run, result is fail [debug ] return hook of type fail, value (null) [debug ] request client=EDITED from=EDITED to=EDITED at RCPT: answer fail from filter check_srs_bounce: next filter check_spf [debug ] running filter check_spf (spf) [info ] spf: new SPF lookup of (EDITED) [debug ] spf pool: acquiring 0x94a64c8 - pool length: 0 (created 1) [debug ] spf (depth=0): performing query of type 16 for EDITED [debug ] running dns resolution on EDITED. (type: 16) [error ] Killed (got signal 11)... Segmentation fault

Fruneau commented 10 years ago

Hi,

postlicyd is known to crash during DNS resolutions on some debian version due to a bug in libunbound. What version libunbound are you using?

caffeinejolt commented 10 years ago

I tried two different versions assuming this may be the issue - both had the problem. Here is the current version:

rpm -qa | grep unbound unbound-devel-1.4.21-1.el6.i686 unbound-libs-1.4.21-1.el6.i686

As you can see, I am not running debian - CentOS 6 instead. I also tried the unbound libs from the RPMs here too: http://rpms.famillecollet.com/enterprise/6/remi/i386/ which are:

unbound-libs-1.4.12-3.el6.remi.i686.rpm unbound-devel-1.4.12-3.el6.remi.i686.rpm

But I got the same result. Is there a recommended version of unbound to run? Perhaps I need to compile from source? If so, and lets say I install to /usr/local/unbound to keep it all in one place, how do I tell pfixtools to look there during build time?

Fruneau commented 10 years ago

I'll need a backtrace from the crash in order to be able to identify the actual cause. Can you run the process attached to gdb and print the backtrace?

gdb --args postlicyd -vvv -f /etc/pfixtools/postlicyd.conf -u
% run
<wait for a prompt>
% bt
caffeinejolt commented 10 years ago

I compiled unbound latest from source in /usr/local/unbound and symlinked the relevant headers/.so files etc. and rebuilt pfixtools - it works now - at least in my one test. This seems to confirm your suspicion that it is a problem with libunbound.

caffeinejolt commented 10 years ago

I am unfamiliar with libunbound - does it pass along requests to the servers listed in /etc/resolv.conf ? I read this: http://www.unbound.net/documentation/libunbound.html, to try and determine this, but was still unclear since it says things like "By default the root servers are queried and full resolver mode is used" and " The information from /etc/resolv.conf and /etc/hosts is not utilised by default."