Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: SpamAssassin: devel

[Bug 6221] DnsResolver.pm attempts to bind ports at random

 

 

SpamAssassin devel RSS feed   Index | Next | Previous | View Threaded


bugzilla-daemon at bugzilla

Oct 15, 2009, 10:18 AM

Post #1 of 2 (235 views)
Permalink
[Bug 6221] DnsResolver.pm attempts to bind ports at random

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6221

Mark Martinec <Mark.Martinec [at] ijs> changed:

What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|Undefined |3.3.0

--- Comment #1 from Mark Martinec <Mark.Martinec [at] ijs> 2009-10-15 10:18:26 UTC ---
> Created an attachment (id=4551)
--> (https://issues.apache.org/SpamAssassin/attachment.cgi?id=4551) [details]
> Patch to always use port 0 instead of trying ports at random
>
> DnsResolver.pm attempts to bind UDP ports at random. This causes numerous
> errors if listening on specific ports is restricted to specific
> applications/users.
>
> The correct way to acquire a UDP socket to listen for responses is to bind to
> port 0 instead. The OS will automatically allocate an appropriate free port
> from the range defined for local allocation (net.ipv4.ip_local_port_range on
> Linux).

While I agree in general, I think there was some underlying reason for the
current hack, but I can't find a reference now. Possibly something to do
with mismatching DNS replies with queries. Moving to 3.3.0 target.

Related to Bug 5264.

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


bugzilla-daemon at bugzilla

Oct 15, 2009, 11:02 AM

Post #2 of 2 (214 views)
Permalink
[Bug 6221] DnsResolver.pm attempts to bind ports at random [In reply to]

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6221

Simon Arlott <spamassassin.bugzilla.apache.simon [at] arlott> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |spamassassin.bugzilla.apach
| |e.simon [at] arlott

--- Comment #2 from Simon Arlott <spamassassin.bugzilla.apache.simon [at] arlott> 2009-10-15 11:02:26 UTC ---
(In reply to comment #1)
> While I agree in general, I think there was some underlying reason for the
> current hack, but I can't find a reference now. Possibly something to do
> with mismatching DNS replies with queries. Moving to 3.3.0 target.

According to the SVN log for revision 161778, it is the Net::DNS code that
mismatched DNS replies. The original bug that introduced this "select a random
port" behaviour is 4260.

--
Configure bugmail: https://issues.apache.org/SpamAssassin/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

SpamAssassin devel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.