Re: [PATCH net-next v2] tun: replace strcpy with strscpy for ifr_name

From: patchwork-bot+netdevbpf
Date: Wed Aug 13 2025 - 20:30:06 EST


Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@xxxxxxxxxx>:

On Tue, 12 Aug 2025 10:22:44 +0200 you wrote:
> Replace the strcpy() calls that copy the device name into ifr->ifr_name
> with strscpy() to avoid potential overflows and guarantee NULL termination.
>
> Destination is ifr->ifr_name (size IFNAMSIZ).
>
> Tested in QEMU (BusyBox rootfs):
> - Created TUN devices via TUNSETIFF helper
> - Set addresses and brought links up
> - Verified long interface names are safely truncated (IFNAMSIZ-1)
>
> [...]

Here is the summary with links:
- [net-next,v2] tun: replace strcpy with strscpy for ifr_name
https://git.kernel.org/netdev/net-next/c/a57384110dc6

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html