mbox series

[net-next,0/4] net: Mark the sk parameter of routing functions as 'const'.

Message ID cover.1689077819.git.gnault@redhat.com (mailing list archive)
Headers show
Series net: Mark the sk parameter of routing functions as 'const'. | expand

Message

Guillaume Nault July 11, 2023, 1:06 p.m. UTC
The sk_getsecid security hook prevents the use of a const sk pointer in
several routing functions. Since this hook should only read sk data,
make its sk argument const (patch 1), then constify the sk parameter of
various routing functions (patches 2-4).

Build-tested with make allmodconfig.

Guillaume Nault (4):
  security: Constify sk in the sk_getsecid hook.
  ipv4: Constify the sk parameter of ip_route_output_*().
  ipv6: Constify the sk parameter of several helper functions.
  pptp: Constify the po parameter of pptp_route_output().

 drivers/net/ppp/pptp.c        |  4 ++--
 include/linux/icmpv6.h        | 10 ++++------
 include/linux/lsm_hook_defs.h |  2 +-
 include/linux/security.h      |  5 +++--
 include/net/route.h           |  6 +++---
 net/ipv6/datagram.c           |  7 ++++---
 net/ipv6/icmp.c               |  6 ++----
 net/ipv6/mcast.c              |  8 +++-----
 security/security.c           |  2 +-
 security/selinux/hooks.c      |  4 ++--
 10 files changed, 25 insertions(+), 29 deletions(-)

Comments

patchwork-bot+netdevbpf@kernel.org July 14, 2023, 7:40 a.m. UTC | #1
Hello:

This series was applied to netdev/net-next.git (main)
by David S. Miller <davem@davemloft.net>:

On Tue, 11 Jul 2023 15:06:00 +0200 you wrote:
> The sk_getsecid security hook prevents the use of a const sk pointer in
> several routing functions. Since this hook should only read sk data,
> make its sk argument const (patch 1), then constify the sk parameter of
> various routing functions (patches 2-4).
> 
> Build-tested with make allmodconfig.
> 
> [...]

Here is the summary with links:
  - [net-next,1/4] security: Constify sk in the sk_getsecid hook.
    https://git.kernel.org/netdev/net-next/c/5b52ad34f948
  - [net-next,2/4] ipv4: Constify the sk parameter of ip_route_output_*().
    https://git.kernel.org/netdev/net-next/c/8d6eba33a272
  - [net-next,3/4] ipv6: Constify the sk parameter of several helper functions.
    https://git.kernel.org/netdev/net-next/c/5bc67a854cb4
  - [net-next,4/4] pptp: Constify the po parameter of pptp_route_output().
    https://git.kernel.org/netdev/net-next/c/dc4c399d215d

You are awesome, thank you!