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]
Message-ID: <20220415122601.0b793cb9@hermes.local>
Date:   Fri, 15 Apr 2022 12:26:01 -0700
From:   Stephen Hemminger <stephen@...workplumber.org>
To:     Florent Fourcot <florent.fourcot@...irst.fr>
Cc:     netdev@...r.kernel.org, cong.wang@...edance.com,
        edumazet@...gle.com, Brian Baboch <brian.baboch@...irst.fr>
Subject: Re: [PATCH v5 net-next 4/4] rtnetlink: return EINVAL when request
 cannot succeed

On Fri, 15 Apr 2022 18:53:30 +0200
Florent Fourcot <florent.fourcot@...irst.fr> wrote:

> A request without interface name/interface index/interface group cannot
> work. We should return EINVAL
> 
> Signed-off-by: Florent Fourcot <florent.fourcot@...irst.fr>
> Signed-off-by: Brian Baboch <brian.baboch@...irst.fr>
> ---
>  net/core/rtnetlink.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/net/core/rtnetlink.c b/net/core/rtnetlink.c
> index 73f2cbc440c9..b943336908a7 100644
> --- a/net/core/rtnetlink.c
> +++ b/net/core/rtnetlink.c
> @@ -3457,7 +3457,7 @@ static int __rtnl_newlink(struct sk_buff *skb, struct nlmsghdr *nlh,
>  			return rtnl_group_changelink(skb, net,
>  						nla_get_u32(tb[IFLA_GROUP]),
>  						ifm, extack, tb);
> -		return -ENODEV;
> +		return -EINVAL;

Sometimes changing errno can be viewed as ABI change and break applications.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ