netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next v2 0/6] replace deprecated strcpy with strscpy
@ 2024-08-28 12:32 Hongbo Li
  2024-08-28 12:32 ` [PATCH net-next v2 1/6] net: prefer strscpy over strcpy Hongbo Li
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: Hongbo Li @ 2024-08-28 12:32 UTC (permalink / raw)
  To: davem, edumazet, kuba, pabeni, dsahern, ralf, jmaloy, ying.xue,
	dan.carpenter
  Cc: netdev, linux-hams, netfilter-devel, lihongbo22

The deprecated helper strcpy() performs no bounds checking on the
destination buffer. This could result in linear overflows beyond
the end of the buffer, leading to all kinds of misbehaviors.
The safe replacement is strscpy() [1].

Link: https://www.kernel.org/doc/html/latest/process/deprecated.html#strcpy [1]

Hongbo Li (6):
  net: prefer strscpy over strcpy
  net/ipv6: replace deprecated strcpy with strscpy
  net/netrom: prefer strscpy over strcpy
  net/netfilter: replace deprecated strcpy with strscpy
  net/tipc: replace deprecated strcpy with strscpy
  net/ipv4: net: prefer strscpy over strcpy

 net/core/dev.c                  | 2 +-
 net/ipv4/ip_tunnel.c            | 2 +-
 net/ipv4/netfilter/arp_tables.c | 2 +-
 net/ipv4/netfilter/ip_tables.c  | 2 +-
 net/ipv6/ndisc.c                | 2 +-
 net/netfilter/xt_recent.c       | 2 +-
 net/netrom/nr_route.c           | 4 ++--
 net/tipc/bearer.c               | 2 +-
 8 files changed, 9 insertions(+), 9 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-08-29 19:50 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-28 12:32 [PATCH net-next v2 0/6] replace deprecated strcpy with strscpy Hongbo Li
2024-08-28 12:32 ` [PATCH net-next v2 1/6] net: prefer strscpy over strcpy Hongbo Li
2024-08-28 12:32 ` [PATCH net-next v2 2/6] net/ipv6: replace deprecated strcpy with strscpy Hongbo Li
2024-08-28 12:32 ` [PATCH net-next v2 3/6] net/netrom: prefer strscpy over strcpy Hongbo Li
2024-08-28 12:32 ` [PATCH net-next v2 4/6] net/netfilter: replace deprecated strcpy with strscpy Hongbo Li
2024-08-28 12:32 ` [PATCH net-next v2 5/6] net/tipc: " Hongbo Li
2024-08-28 12:32 ` [PATCH net-next v2 6/6] net/ipv4: net: prefer strscpy over strcpy Hongbo Li
2024-08-29 19:36 ` [PATCH net-next v2 0/6] replace deprecated strcpy with strscpy Jakub Kicinski
2024-08-29 19:50 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).