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] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 24 Nov 2021 15:16:29 +0200
From:   Ido Schimmel <idosch@...sch.org>
To:     David Laight <David.Laight@...lab.com>
Cc:     "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "davem@...emloft.net" <davem@...emloft.net>,
        "kuba@...nel.org" <kuba@...nel.org>,
        "nikolay@...dia.com" <nikolay@...dia.com>,
        "roopa@...dia.com" <roopa@...dia.com>,
        "bernard@...o.com" <bernard@...o.com>,
        "mlxsw@...dia.com" <mlxsw@...dia.com>,
        Ido Schimmel <idosch@...dia.com>
Subject: Re: [PATCH net-next] net: bridge: Allow base 16 inputs in sysfs

On Wed, Nov 24, 2021 at 12:55:33PM +0000, David Laight wrote:
> From: Ido Schimmel
> > Sent: 24 November 2021 10:11
> >
> > Cited commit converted simple_strtoul() to kstrtoul() as suggested by
> > the former's documentation. However, it also forced all the inputs to be
> > decimal resulting in user space breakage.
> > 
> > Fix by setting the base to '0' so that the base is automatically
> > detected.
> 
> Do both functions ignore leading whitespace?

With this patch (kstrtoul):

# ip link add name br0 type bridge vlan_filtering 1
# echo "    0x88a8" > /sys/class/net/br0/bridge/vlan_protocol
bash: echo: write error: Invalid argument

With simple_strtoul:

# ip link add name br0 type bridge vlan_filtering 1
# echo "    0x88a8" > /sys/class/net/br0/bridge/vlan_protocol
bash: echo: write error: Invalid argument

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ