http://bugzilla.spamassassin.org/show_bug.cgi?id=4260
------- Additional Comments From [EMAIL PROTECTED] 2005-04-27 01:57 -------
Subject: Re: rewrite DNS code to use a single socket, event-based model
Sidney:
> The initialization of the DNS ID counter was supposed to spread small
> variations in the pid by shifting the bits up. So much for home brewed
> seat of the pants hash functions :-).
The main issue is that different processes can proceed at different
rates through their IDs and if they're just ~100 apart, it's easy to
collide.
But actually, if we just use a different port for each message by
calling DnsResolver->connect_sock then there is nothing wrong with the
counter that Net::DNS maintains. We could remove all the code that
maintains our own counter and all should work.
Theo:
> I was just noticing -- when the bogus rr warnings pop up, the record
> being returned seems to always be a nameserver, not a DNSBL or
> something more common as I'd expect:
Interesting.
Sidney:
> In Dns.pm in sub rbl_finish I added before the return:
>
> $self->{responder}->connect_sock() if $self-{responder};
One new socket per message? I suppose that's okay. I'd prefer one per
child if we can make it work, but maybe it doesn't and if your fix
works, I say let's go with it! It's still way better than bgsock
originally was.
> I've been thinking about this some more -- why do we care what the
> starting ID is?
Paranoia. At worst, it doesn't hurt to use rand() here. :-)
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.