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: <m2tt76hnoq.fsf@gmail.com>
Date: Wed, 02 Apr 2025 11:17:57 +0100
From: Donald Hunter <donald.hunter@...il.com>
To: Jakub Kicinski <kuba@...nel.org>
Cc: davem@...emloft.net,  netdev@...r.kernel.org,  edumazet@...gle.com,
  pabeni@...hat.com,  andrew+netdev@...n.ch,  horms@...nel.org,
  yuyanghuang@...gle.com,  jacob.e.keller@...el.com
Subject: Re: [PATCH net v2 3/3] netlink: specs: rt_addr: pull the ifa-
 prefix out of the names

Jakub Kicinski <kuba@...nel.org> writes:

> YAML specs don't normally include the C prefix name in the name
> of the YAML attr. Remove the ifa- prefix from all attributes
> in addr-attrs and specify name-prefix instead.
>
> This is a bit risky, hopefully there aren't many users out there.
>
> Fixes: dfb0f7d9d979 ("doc/netlink: Add spec for rt addr messages")
> Signed-off-by: Jakub Kicinski <kuba@...nel.org>
> ---
>  Documentation/netlink/specs/rt_addr.yaml | 41 ++++++++++++------------
>  tools/testing/selftests/net/rtnetlink.py |  2 +-
>  2 files changed, 22 insertions(+), 21 deletions(-)
>
> diff --git a/Documentation/netlink/specs/rt_addr.yaml b/Documentation/netlink/specs/rt_addr.yaml
> index 1650dc3f091a..d032562d1240 100644
> --- a/Documentation/netlink/specs/rt_addr.yaml
> +++ b/Documentation/netlink/specs/rt_addr.yaml
> @@ -78,45 +78,46 @@ protonum: 0
>  attribute-sets:
>    -
>      name: addr-attrs
> +    name-prefix: ifa-
>      attributes:
>        -
> -        name: ifa-address
> +        name: address
>          type: binary
>          display-hint: ipv4
>        -
> -        name: ifa-local
> +        name: local
>          type: binary
>          display-hint: ipv4
>        -
> -        name: ifa-label
> +        name: label
>          type: string
>        -
> -        name: ifa-broadcast
> +        name: broadcast
>          type: binary
>          display-hint: ipv4
>        -
> -        name: ifa-anycast
> +        name: anycast
>          type: binary
>        -
> -        name: ifa-cacheinfo
> +        name: cacheinfo
>          type: binary
> -        struct: ifa-cacheinfo
> +        struct: cacheinfo

The struct is still called ifa-cacheinfo so this breaks:

Error decoding 'cacheinfo' from 'addr-attrs'
Traceback (most recent call last):
...
  File "/home/donaldh/net-next/tools/net/ynl/pyynl/lib/ynl.py", line 846, in _decode_struct
    members = self.consts[name].members
              ~~~~~~~~~~~^^^^^^
KeyError: 'cacheinfo'

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ