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, 11 Nov 2019 23:29:55 +0200
From:   Vladimir Oltean <olteanv@...il.com>
To:     Florian Fainelli <f.fainelli@...il.com>
Cc:     netdev <netdev@...r.kernel.org>, Andrew Lunn <andrew@...n.ch>,
        Vivien Didelot <vivien.didelot@...il.com>,
        "David S. Miller" <davem@...emloft.net>,
        open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH net-next] net: dsa: Prevent usage of NET_DSA_TAG_8021Q as
 tagging protocol

On Mon, 11 Nov 2019 at 21:55, Florian Fainelli <f.fainelli@...il.com> wrote:
>
> On 11/11/19 11:54 AM, Florian Fainelli wrote:
> > It is possible for a switch driver to use NET_DSA_TAG_8021Q as a valid
> > DSA tagging protocol since it registers itself as such, unfortunately
> > since there are not xmit or rcv functions provided, the lack of a xmit()
> > function will lead to a NPD in dsa_slave_xmit() to start with.
> >
> > net/dsa/tag_8021q.c is only comprised of a set of helper functions at
> > the moment, but is not a fully autonomous or functional tagging "driver"
> > (though it could become later on). We do not have any users of
> > NET_DSA_TAG_8021Q so now is a good time to make sure there are not
> > issues being encountered by making this file strictly a place holder for
> > helper functions.
> >
> > Signed-off-by: Florian Fainelli <f.fainelli@...il.com>
> > ---
>
> [snip]
>
> > -static const struct dsa_device_ops dsa_8021q_netdev_ops = {
> > -     .name           = "8021q",
> > -     .proto          = DSA_TAG_PROTO_8021Q,
> > -     .overhead       = VLAN_HLEN,
> > -};
> > -
> > -MODULE_LICENSE("GPL v2");
>
> I probably need to keep that around to avoid complaints about the module
> tainting the kernel, expect a v2 based on that and/or reviewer comments.
> --
> Florian

Actually I wanted to see the tainting in action. But it's worse than
that, due to the use of exported GPL symbols.

insmod tag_8021q.ko
[   68.205843] tag_8021q: module license 'unspecified' taints kernel.
[   68.212183] Disabling lock debugging due to kernel taint
[   68.217876] tag_8021q: Unknown symbol skb_pull_rcsum (err -2)
[   68.223781] tag_8021q: Unknown symbol br_vlan_get_info (err -2)
[   68.229675] tag_8021q: Unknown symbol br_vlan_get_pvid (err -2)
insmod: ERROR: could not insert module tag_8021q.ko: Unknown symbol in module

So you can add on v2:

Reviewed-by: Vladimir Oltean <olteanv@...il.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ