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: <57ed25b1-e00f-2601-fc76-1f9d19182915@intel.com>
Date: Wed, 23 Aug 2023 14:43:13 -0700
From: Jacob Keller <jacob.e.keller@...el.com>
To: Donald Hunter <donald.hunter@...il.com>
CC: <netdev@...r.kernel.org>, Jakub Kicinski <kuba@...nel.org>, "David S.
 Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, "Paolo
 Abeni" <pabeni@...hat.com>, Jonathan Corbet <corbet@....net>,
	<linux-doc@...r.kernel.org>, Stanislav Fomichev <sdf@...gle.com>, "Arkadiusz
 Kubalewski" <arkadiusz.kubalewski@...el.com>, <donald.hunter@...hat.com>
Subject: Re: [PATCH net-next v4 02/12] doc/netlink: Add a schema for
 netlink-raw families



On 8/23/2023 2:19 PM, Donald Hunter wrote:
> Jacob Keller <jacob.e.keller@...el.com> writes:
>> On 8/23/2023 4:41 AM, Donald Hunter wrote:
>>> +---
>>> +$id: http://kernel.org/schemas/netlink/genetlink-legacy.yaml#
>>> +$schema: https://json-schema.org/draft-07/schema
>>> +
>>> +# Common defines
>>> +$defs:
>>> +  uint:
>>> +    type: integer
>>> +    minimum: 0
>>> +  len-or-define:
>>> +    type: [ string, integer ]
>>> +    pattern: ^[0-9A-Za-z_]+( - 1)?$
>>> +    minimum: 0
>>> +
>>> +# Schema for specs
>>> +title: Protocol
>>> +description: Specification of a genetlink protocol
>>
>> If this is for netlink-raw, shouldn't this not say genetlink? Same
>> elsewhere? or am I misunderstanding something?
> 
> It's a good question. The schema definitions are currently strict
> supersets of genetlink:
> 
> genetlink <= genetlink-c <= genetlink-legacy <= netlink-raw
> 
> As you noted below, there's only 2 additions needed for the netlink raw
> families, protonum and mcast-group value.
> 
> I would be happy to change the description and other references to
> genetlink in this spec, but I'd like to hear Jakub's thoughts about
> minimal modification vs a more thorough rewording. Perhaps a middle
> ground would be to extend the top-level description to say "genetlink or
> raw netlink" and qualify that all mention of genetlink also applies to
> raw netlink.
> 
> Either way, I just noticed that the schema $id does need to be updated.
> 

Ok, ya lets wait for Jakub's opinion. I think the clarification would be
good since at least conceptually genetlink is distinct to me from
netlink raw, so it feels a bit weird.

Either way, they share far more in common than I had originally
realized, so its not a huge deal.

Thanks for the clarification!

>>> +type: object
>>> +required: [ name, doc, attribute-sets, operations ]
>>> +additionalProperties: False
>>> +properties:
>>> +  name:
>>> +    description: Name of the genetlink family.
>>> +    type: string
>>> +  doc:
>>> +    type: string
>>> +  version:
>>> +    description: Generic Netlink family version. Default is 1.
>>> +    type: integer
>>> +    minimum: 1
>>> +  protocol:
>>> +    description: Schema compatibility level. Default is "genetlink".
>>> +    enum: [ genetlink, genetlink-c, genetlink-legacy, netlink-raw ] # Trim
>>> +  # Start netlink-raw
>>
>> I guess the netlink raw part is only below this? Or does netlink raw
>> share more of the generic netlink code than I thought?
> 
> Raw netlink is, so far, the same as genetlink-legacy with the addition
> of hard-coded protocol ids.
> 

Right that makes sense why this shares so much.

Thanks,
Jake

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ