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] [day] [month] [year] [list]
Date:   Mon, 22 Jun 2020 12:18:52 +0200
From:   Paolo Abeni <pabeni@...hat.com>
To:     David Miller <davem@...emloft.net>
Cc:     eric.dumazet@...il.com, netdev@...r.kernel.org, mptcp@...ts.01.org
Subject: Re: sock diag uAPI and MPTCP

On Sat, 2020-06-20 at 17:44 -0700, David Miller wrote:
> From: Paolo Abeni <pabeni@...hat.com>
> Date: Fri, 19 Jun 2020 12:54:40 +0200
> 
> > IPPROTO_MPTCP value (0x106) can't be represented using the current sock
> > diag uAPI, as the 'sdiag_protocol' field is 8 bits wide.
> > 
> > To implement diag support for MPTCP socket, we will likely need a
> > 'inet_diag_req_v3' with a wider 'sdiag_protocol'
> > field. inet_diag_handler_cmd() could detect the version of
> > the inet_diag_req_v* provided by user-space checking nlmsg_len() and
> > convert _v2 reqs to _v3.
> > 
> > This change will be a bit invasive, as all in kernel diag users will
> > then operate only on 'inet_diag_req_v3' (many functions' signature
> > change required), but the code-related changes will be encapsulated
> > by inet_diag_handler_cmd().
> 
> Another way to extend the size of a field is to add an attribute which
> supercedes the header structure field when present.
> 
> We did this when we needed to make the fib rule table ID number larger,
> see FRA_TABLE.
> 
> You'd only need to specify this when using protocol values larger than
> 8 bits in size.

Thank you very much for the directions! This looks like a better, more
encapsulated solution. I'll try to give it a shot.

Thanks!

Paolo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ