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]
Date:   Wed, 22 May 2019 16:16:52 -0700
From:   Stephen Hemminger <stephen@...workplumber.org>
To:     David Ahern <dsahern@...nel.org>
Cc:     netdev@...r.kernel.org, Jason@...c4.com,
        David Ahern <dsahern@...il.com>
Subject: Re: [PATCH iproute2] ip route: Set rtm_dst_len to 32 for all ip
 route get requests

On Fri, 17 May 2019 10:59:13 -0700
David Ahern <dsahern@...nel.org> wrote:

> index 2b3dcc5dbd53..d980b86ffd42 100644
> --- a/ip/iproute.c
> +++ b/ip/iproute.c
> @@ -2035,7 +2035,11 @@ static int iproute_get(int argc, char **argv)
>  			if (addr.bytelen)
>  				addattr_l(&req.n, sizeof(req),
>  					  RTA_DST, &addr.data, addr.bytelen);
> -			req.r.rtm_dst_len = addr.bitlen;
> +			/* kernel ignores prefix length on 'route get'
> +			 * requests; to allow ip to work with strict mode
> +			 * but not break existing users, just set to 32
> +			 */
> +			req.r.rtm_dst_len = 32;
>  			address_found = true;
>  		}
>  		argc--; argv++;

Why not warn user that any prefix length (ie not 32) is ignored,
then do what you propose.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ