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-next>] [day] [month] [year] [list]
Message-Id: <20210722142903.213084-1-arnd@kernel.org>
Date:   Thu, 22 Jul 2021 16:28:57 +0200
From:   Arnd Bergmann <arnd@...nel.org>
To:     netdev@...r.kernel.org
Cc:     Arnd Bergmann <arnd@...db.de>, Al Viro <viro@...iv.linux.org.uk>,
        Andrew Lunn <andrew@...n.ch>, Christoph Hellwig <hch@....de>,
        David Ahern <dsahern@...nel.org>,
        "David S. Miller" <davem@...emloft.net>,
        Eric Dumazet <edumazet@...gle.com>,
        Hideaki YOSHIFUJI <yoshfuji@...ux-ipv6.org>,
        Jakub Kicinski <kuba@...nel.org>,
        Kees Cook <keescook@...omium.org>,
        Marco Elver <elver@...gle.com>, linux-kernel@...r.kernel.org,
        linux-arch@...r.kernel.org
Subject: [PATCH net-next v6 0/6] remove compat_alloc_user_space()

From: Arnd Bergmann <arnd@...db.de>

This is the fifth version of my series, now spanning four patches
instead of two, with a new approach for handling struct ifreq
compatibility after I realized that my earlier approach introduces
additional problems.

The idea here is to always push down the compat conversion
deeper into the call stack: rather than pretending to be
native mode with a modified copy of the original data on
the user space stack, have the code that actually works on
the data understand the difference between native and compat
versions.

I have spent a long time looking at all drivers that implement
an ndo_do_ioctl callback to verify that my assumptions are
correct. This has led to a series of ~30 additional patches
that I am not including here but will post separately, fixing
a number of bugs in SIOCDEVPRIVATE ioctls, removing dead
code, and splitting ndo_do_ioctl into multiple new ndo callbacks
for private and ethernet specific commands.

      Arnd

Link: https://lore.kernel.org/netdev/20201124151828.169152-1-arnd@kernel.org/

Changes in v6:
 - Split out and expand linux/compat.h rework
 - Split ifconf change into two patches
 - Rebase on latest net-next/master

Changes in v5:
 - Rebase to v5.14-rc2
 - Fix a few build issues

Changes in v4:
 - build fix without CONFIG_INET
 - build fix without CONFIG_COMPAT
 - style fixes pointed out by hch

Changes in v3:
 - complete rewrite of the series

Arnd Bergmann (6):
  compat: make linux/compat.h available everywhere
  ethtool: improve compat ioctl handling
  net: socket: rework SIOC?IFMAP ioctls
  net: socket: remove register_gifconf
  net: socket: simplify dev_ifconf handling
  net: socket: rework compat_ifreq_ioctl()

 arch/arm64/include/asm/compat.h   |  14 +-
 arch/mips/include/asm/compat.h    |  24 ++-
 arch/parisc/include/asm/compat.h  |  14 +-
 arch/powerpc/include/asm/compat.h |  11 --
 arch/s390/include/asm/compat.h    |  14 +-
 arch/sparc/include/asm/compat.h   |  14 +-
 arch/x86/include/asm/compat.h     |  14 +-
 arch/x86/include/asm/signal.h     |   1 +
 include/asm-generic/compat.h      |  17 ++
 include/linux/compat.h            |  32 ++--
 include/linux/ethtool.h           |   4 -
 include/linux/inetdevice.h        |   9 +
 include/linux/netdevice.h         |  12 +-
 net/appletalk/ddp.c               |   4 +-
 net/core/dev_ioctl.c              | 153 +++++++++-------
 net/ethtool/ioctl.c               | 136 ++++++++++++--
 net/ieee802154/socket.c           |   4 +-
 net/ipv4/af_inet.c                |   6 +-
 net/ipv4/devinet.c                |   4 +-
 net/qrtr/qrtr.c                   |   4 +-
 net/socket.c                      | 292 +++++++-----------------------
 21 files changed, 352 insertions(+), 431 deletions(-)

-- 
2.29.2

Cc: Al Viro <viro@...iv.linux.org.uk> 
Cc: Andrew Lunn <andrew@...n.ch> 
Cc: Christoph Hellwig <hch@....de>
Cc: David Ahern <dsahern@...nel.org> 
Cc: "David S. Miller" <davem@...emloft.net>
Cc: Eric Dumazet <edumazet@...gle.com>
Cc: Hideaki YOSHIFUJI <yoshfuji@...ux-ipv6.org> 
Cc: Jakub Kicinski <kuba@...nel.org> 
Cc: Kees Cook <keescook@...omium.org> 
Cc: Marco Elver <elver@...gle.com> 
Cc: linux-kernel@...r.kernel.org 
Cc: linux-arch@...r.kernel.org 
Cc: netdev@...r.kernel.org 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ