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

--- Comment #1 from Mark Martinec <[email protected]> ---
This can happen when a socket of a protocol family INET6 is bound
to ANY IP address and is allowed to also accept INET connections, in
which case it is *not* possible to create another ANY socket even
if a different protocol family is specified.

There exists a socket option IPV6_V6ONLY, which determined if an
INET6 socket can also accept INET sessions. Its default value is
derived from a global setting (e.g. net.inet6.ip6.v6only), and
defaults to 1 on BSD systems (and Solaris I believe), but defaults
to 0 on Linux systems.

When a socket is created, it is possible to override a global
default for IPV6_V6ONLY for each socket. The perl module
IO::Socket::IP offers this control since version 0.09 and
spamd does turn it off where possible.

Unfortunately the older module IO::Socket::INET6 does not
recognize this option, which leads to the reported problem.

So the situation occurs in a specific situation where all of
the following applies:

- a module IO::Socket::INET6 is installed and the IO::Socket::IP
is not installed or is too old

- the host is a dual-stack host (supports IPv4 and IPv6)

- the global default for IPV6_V6ONLY is off (i.e. Linux, not BSD)

- the spamd option --listen (or -i) is specified without argument,
i.e. spamd is instructed to listen on any interface (not just loopback)


Conversely, the situation does *not* occur if any of the following
is true:

- the OS supports only IPv4 or only IPv6

- the systemwide default setting for IPV6_V6ONLY is true,
typical for a non-linux host

- the module IO::Socket::INET6 is not installed

- the --listen option is left at its default (i.e. bind to a loopback
interface only), or specifies explicitly just one IP address,
e.g. 0.0.0.0 or :: , which tells spamd to only create one listen socket
on one protocol family.

So workarounds are:
- specify 0.0.0.0 or :: explicitly with a --listen (-i) spamd option
- or, install module IO::Socket::IP version 0.09 or later
- or, deinstall IO::Socket::INET6

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to