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]
Message-ID: <CADvbK_d+BqJdwDW1ngX4qh_dySQQcLuO5oEZKEFmNzm=P9NPeA@mail.gmail.com>
Date: Sat, 23 Aug 2025 14:38:41 -0400
From: Xin Long <lucien.xin@...il.com>
To: Paolo Abeni <pabeni@...hat.com>
Cc: network dev <netdev@...r.kernel.org>, davem@...emloft.net, kuba@...nel.org, 
	Eric Dumazet <edumazet@...gle.com>, Simon Horman <horms@...nel.org>, 
	Stefan Metzmacher <metze@...ba.org>, Moritz Buhl <mbuhl@...nbsd.org>, Tyler Fanelli <tfanelli@...hat.com>, 
	Pengtao He <hepengtao@...omi.com>, linux-cifs@...r.kernel.org, 
	Steve French <smfrench@...il.com>, Namjae Jeon <linkinjeon@...nel.org>, 
	Paulo Alcantara <pc@...guebit.com>, Tom Talpey <tom@...pey.com>, kernel-tls-handshake@...ts.linux.dev, 
	Chuck Lever <chuck.lever@...cle.com>, Jeff Layton <jlayton@...nel.org>, 
	Benjamin Coddington <bcodding@...hat.com>, Steve Dickson <steved@...hat.com>, Hannes Reinecke <hare@...e.de>, 
	Alexander Aring <aahringo@...hat.com>, David Howells <dhowells@...hat.com>, 
	Cong Wang <xiyou.wangcong@...il.com>, "D . Wythe" <alibuda@...ux.alibaba.com>, 
	Jason Baron <jbaron@...mai.com>, illiliti <illiliti@...tonmail.com>, 
	Sabrina Dubroca <sd@...asysnail.net>, Marcelo Ricardo Leitner <marcelo.leitner@...il.com>, 
	Daniel Stenberg <daniel@...x.se>, Andy Gospodarek <andrew.gospodarek@...adcom.com>
Subject: Re: [PATCH net-next v2 02/15] net: build socket infrastructure for
 QUIC protocol

On Thu, Aug 21, 2025 at 7:17 AM Paolo Abeni <pabeni@...hat.com> wrote:
>
> On 8/18/25 4:04 PM, Xin Long wrote:
> > diff --git a/net/Makefile b/net/Makefile
> > index aac960c41db6..7c6de28e9aa5 100644
> > --- a/net/Makefile
> > +++ b/net/Makefile
> > @@ -42,6 +42,7 @@ obj-$(CONFIG_PHONET)                += phonet/
> >  ifneq ($(CONFIG_VLAN_8021Q),)
> >  obj-y                                += 8021q/
> >  endif
> > +obj-$(CONFIG_IP_QUIC)                += quic/
> >  obj-$(CONFIG_IP_SCTP)                += sctp/
> >  obj-$(CONFIG_RDS)            += rds/
> >  obj-$(CONFIG_WIRELESS)               += wireless/
> > diff --git a/net/quic/Kconfig b/net/quic/Kconfig
> > new file mode 100644
> > index 000000000000..b64fa398750e
> > --- /dev/null
> > +++ b/net/quic/Kconfig
> > @@ -0,0 +1,35 @@
> > +# SPDX-License-Identifier: GPL-2.0-or-later
> > +#
> > +# QUIC configuration
> > +#
> > +
> > +menuconfig IP_QUIC
> > +     tristate "QUIC: A UDP-Based Multiplexed and Secure Transport (Experimental)"
> > +     depends on INET
> > +     depends on IPV6
>
> What if IPV6=m ?
I think 'depends on IPV6' will include IPV6=m.

>
> > +     select CRYPTO
> > +     select CRYPTO_HMAC
> > +     select CRYPTO_HKDF
> > +     select CRYPTO_AES
> > +     select CRYPTO_GCM
> > +     select CRYPTO_CCM
> > +     select CRYPTO_CHACHA20POLY1305
> > +     select NET_UDP_TUNNEL
>
> Possibly:
>         default n
I missed that..

>
> ?
> [...]
> > +static int quic_init_sock(struct sock *sk)
> > +{
> > +     sk->sk_destruct = inet_sock_destruct;
> > +     sk->sk_write_space = quic_write_space;
> > +     sock_set_flag(sk, SOCK_USE_WRITE_QUEUE);
> > +
> > +     WRITE_ONCE(sk->sk_sndbuf, READ_ONCE(sysctl_quic_wmem[1]));
> > +     WRITE_ONCE(sk->sk_rcvbuf, READ_ONCE(sysctl_quic_rmem[1]));
> > +
> > +     local_bh_disable();
>
> Why?
Good catch, there was a quic_put_port() before, and I forgot to
delete local_bh_disable()f while removing quic_put_port().

>
> > +     sk_sockets_allocated_inc(sk);
> > +     sock_prot_inuse_add(sock_net(sk), sk->sk_prot, 1);
> > +     local_bh_enable();
> > +
> > +     return 0;
> > +}
> > +
> > +static void quic_destroy_sock(struct sock *sk)
> > +{
> > +     local_bh_disable();
>
> Same question :)
>
> [...]
> > +static int quic_disconnect(struct sock *sk, int flags)
> > +{
> > +     quic_set_state(sk, QUIC_SS_CLOSED); /* for a listen socket only */
> > +     return 0;
> > +}
>
> disconnect() primary use-case is creating a lot of syzkaller reports.
> Since there should be no legacy/backward compatibility issue, I suggest
> considering a simple implementation always failing.
>
OK. This means shutdown(listensk) won't work.

Thanks Paolo for all the helpful feedback!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ