lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Mon, 9 Jul 2018 22:27:25 +0200
From:   Florian Westphal <fw@...len.de>
To:     Pablo Neira Ayuso <pablo@...filter.org>
Cc:     Florian Westphal <fw@...len.de>, Arnd Bergmann <arnd@...db.de>,
        Jozsef Kadlecsik <kadlec@...ckhole.kfki.hu>,
        "David S. Miller" <davem@...emloft.net>,
        Máté Eckl <ecklm94@...il.com>,
        Fernando Fernandez Mancera <ffmancera@...eup.net>,
        "Pablo M. Bermudo Garay" <pablombg@...il.com>,
        Felix Fietkau <nbd@....name>, netfilter-devel@...r.kernel.org,
        coreteam@...filter.org, Networking <netdev@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] netfilter: conntrack: add weak IPV6 dependency

Pablo Neira Ayuso <pablo@...filter.org> wrote:
> On Fri, Jul 06, 2018 at 08:35:48PM +0200, Florian Westphal wrote:
> > Florian Westphal <fw@...len.de> wrote:
> > > Arnd Bergmann <arnd@...db.de> wrote:
> > > > and that resulted in a new build failure:
> > > > 
> > > > net/netfilter/nf_conntrack_proto.o:(.rodata+0x788): undefined
> > > > reference to `nf_conntrack_l4proto_icmpv6'
> > > > net/ipv6/netfilter/nf_conntrack_reasm.o: In function `nf_ct_frag6_expire':
> > > > nf_conntrack_reasm.c:(.text+0x2320): undefined reference to
> > > > `ip6_expire_frag_queue'
> > > > net/ipv6/netfilter/nf_conntrack_reasm.o: In function `nf_ct_frag6_init':
> > > > nf_conntrack_reasm.c:(.text+0x2384): undefined reference to `ip6_frag_init'
> > > > nf_conntrack_reasm.c:(.text+0x2394): undefined reference to `ip6_frag_init'
> > > > nf_conntrack_reasm.c:(.text+0x2398): undefined reference to `ip6_rhash_params'
> > > > net/ipv6/netfilter/nf_conntrack_reasm.o: In function `nf_ct_frag6_expire':
> > > > nf_conntrack_reasm.c:(.text+0x10bc): undefined reference to
> > > > `ip6_expire_frag_queue'
> > > > 
> > > > I don't think we can get CONFIG_NF_DEFRAG_IPV6=y to work with IPV6=m.
> > > 
> > > Yes, not with current implementation, but I still don't think this
> > > is unavoidable.
> > > 
> > > In case this is urgent I'm fine with the patch that adds the dependency,
> > > otherwise I'd like to try and disentangle nf_conntrack_reasm and ipv6.
> > 
> > This links fine for me with IPV6=m:
> > 
> > Pablo, do you think this is too ugly?
> 
> Well, yes...
> 
> > It requires some copypastry from ipv6 defrag into nfct ipv6 defrag
> > to avoid the link errors outlined above.
> 
> This is a bit of a regression I think.

nf_defrag_ipv6 has always depended on ipv6.

Previously dependency chain is

nf_conntrack_ipv6 -> ipv6
             +-----> nf_defrag_ipv6 > ipv6
	     +-----> nf_conntrack

new dependency chain is:
nf_conntrack --> nf_defrag_ipv6 --> ipv6

The alternate fix is the one from Arnd to disallow
NF_CONNTRACK=y
IPV6=m

> While I think a bit of demodularization is fine, if things like this
> start to kick in, it's probably good if we go make a step back...

If you want to revert, ok.  It will prevent all l4 unification patches
plus any attempt to get rid of the nf_hook for defrag too however so I
do not like it.

> Let me know, thanks.

Yet another alternative would be to remove the

nf_conntrack -> nf_defrag_ipv6

dependency, e.g. by adding a new rcu-protected function pointer.

nf_conntrack, when ipv6 conntrack is requested, would check if its null,
and, if so, issue request_module() for ipv6 defrag before failing the
request.

However, I find it even more ugly than my patch.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ