All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alexandra Winter <wintera@linux.ibm.com>
To: hexlabsecurity@proton.me, Eric Dumazet <edumazet@google.com>,
	Paolo Abeni <pabeni@redhat.com>, Jakub Kicinski <kuba@kernel.org>,
	Thorsten Winkler <twinkler@linux.ibm.com>,
	"David S. Miller" <davem@davemloft.net>
Cc: Hidayath Khan <hidayath@linux.ibm.com>,
	Simon Horman <horms@kernel.org>,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
	linux-s390@vger.kernel.org
Subject: Re: [PATCH net v2 1/3] net/iucv: only send the window update on HiperSockets sockets
Date: Fri, 28 Aug 2026 12:05:50 +0200	[thread overview]
Message-ID: <833853f7-6659-4e9a-b8d1-be27d5804930@linux.ibm.com> (raw)
In-Reply-To: <20260821-b4-disp-3a6e8695-v2-1-37597ff723a8@proton.me>



On 21.08.26 13:17, Bryam Vargas via B4 Relay wrote:
> From: Bryam Vargas <hexlabsecurity@proton.me>
> 
> iucv_sock_recvmsg() sends AF_IUCV_FLAG_WIN without testing the transport,
> but that flag exists only on HiperSockets. On a classic z/VM socket
> iucv->hs_dev is NULL and iucv_send_ctrl() sizes the skb from
> LL_RESERVED_SPACE(iucv->hs_dev), so the read goes through NULL. It is one
> recvmsg() away for an unprivileged process on a socket of its own:
> SO_MSGLIMIT accepts 1, so msglimit / 2 is 0 and msg_recv never leaves 0 on
> a classic socket. The read lands in mapped lowcore on a default kernel and
> the socket takes a spurious disconnect; with relocate_lowcore it faults.


Hi Bryam,

FYI, I tried to reproduce the fault with boot parameter relocate_lowcore.
It did not run into a page fault. My AI says: "relocate_lowcore moves the
lowcore mapping from 0x0 to 0x70000. It does not necessarily unmap all of page 0."
So a garbage read still happens.

The bug is very valid and I can reproduce the spurious disconnect, and that
it is fixed with the proposed fix.
But you may want to adapt the commit message.



  parent reply	other threads:[~2026-08-28 10:06 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-21 11:17 [PATCH net v2 0/3] net/iucv: fix the recvmsg window update Bryam Vargas via B4 Relay
2026-08-21 11:17 ` Bryam Vargas
2026-08-21 11:17 ` [PATCH net v2 1/3] net/iucv: only send the window update on HiperSockets sockets Bryam Vargas via B4 Relay
2026-08-21 11:17   ` Bryam Vargas
2026-08-22 11:17   ` sashiko-bot
2026-08-28 10:05   ` Alexandra Winter [this message]
2026-08-21 11:17 ` [PATCH net v2 2/3] net/iucv: claim the receive credit atomically Bryam Vargas via B4 Relay
2026-08-21 11:17   ` Bryam Vargas
2026-08-22 11:17   ` sashiko-bot
2026-08-21 11:17 ` [PATCH net v2 3/3] net/iucv: send the window update outside message_q.lock Bryam Vargas via B4 Relay
2026-08-21 11:17   ` Bryam Vargas
2026-08-22 11:17   ` sashiko-bot
2026-08-24 12:58     ` Alexandra Winter
2026-08-24 13:08 ` [PATCH net v2 0/3] net/iucv: fix the recvmsg window update Alexandra Winter
2026-08-25 13:17 ` Aswin Karuvally

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=833853f7-6659-4e9a-b8d1-be27d5804930@linux.ibm.com \
    --to=wintera@linux.ibm.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=hexlabsecurity@proton.me \
    --cc=hidayath@linux.ibm.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-s390@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=twinkler@linux.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.