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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZebaUyYfghHnwG8C@shredder>
Date: Tue, 5 Mar 2024 10:39:47 +0200
From: Ido Schimmel <idosch@...dia.com>
To: Petr Machata <petrm@...dia.com>
Cc: "David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	netdev@...r.kernel.org, David Ahern <dsahern@...nel.org>,
	Simon Horman <horms@...nel.org>, mlxsw@...dia.com
Subject: Re: [PATCH net-next v3 2/7] net: nexthop: Add NHA_OP_FLAGS

On Mon, Mar 04, 2024 at 09:51:15PM +0100, Petr Machata wrote:
> @@ -2992,6 +2994,11 @@ static int nh_valid_get_del_req(const struct nlmsghdr *nlh,
>  		return -EINVAL;
>  	}
>  
> +	if (tb[NHA_OP_FLAGS])
> +		*op_flags = nla_get_u32(tb[NHA_OP_FLAGS]);
> +	else
> +		*op_flags = 0;
> +
>  	return 0;
>  }

[...]

> @@ -3151,6 +3161,11 @@ static int __nh_valid_dump_req(const struct nlmsghdr *nlh, struct nlattr **tb,
>  		return -EINVAL;
>  	}
>  
> +	if (tb[NHA_OP_FLAGS])
> +		filter->op_flags = nla_get_bitfield32(tb[NHA_OP_FLAGS]).value;

Shouldn't this be:

filter->op_flags = nla_get_u32(tb[NHA_OP_FLAGS]);

?

> +	else
> +		filter->op_flags = 0;
> +
>  	return 0;
>  }

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ