From: Pavel Skripkin <paskripkin@gmail.com>
To: Xin Long <lucien.xin@gmail.com>
Cc: syzbot <syzbot+e6741b97d5552f97c24d@syzkaller.appspotmail.com>,
davem <davem@davemloft.net>,
devicetree@vger.kernel.org, frowand.list@gmail.com,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Jon Maloy <jmaloy@redhat.com>, Jakub Kicinski <kuba@kernel.org>,
LKML <linux-kernel@vger.kernel.org>,
network dev <netdev@vger.kernel.org>,
rafael@kernel.org, robh+dt@kernel.org, robh@kernel.org,
syzkaller-bugs <syzkaller-bugs@googlegroups.com>,
tipc-discussion@lists.sourceforge.net,
Ying Xue <ying.xue@windriver.com>
Subject: Re: [syzbot] KASAN: use-after-free Read in tipc_recvmsg
Date: Fri, 23 Jul 2021 19:52:53 +0300 [thread overview]
Message-ID: <20210723195253.56ef4ee3@gmail.com> (raw)
In-Reply-To: <CADvbK_dkv-DDt_VSSn1NQnzrUuxPm0T2Mki46T0jdwfUxENW-Q@mail.gmail.com>
On Fri, 23 Jul 2021 12:41:46 -0400
Xin Long <lucien.xin@gmail.com> wrote:
> a fix already posted in tipc-discussion:
>
> diff --git a/net/tipc/socket.c b/net/tipc/socket.c
> index 9b0b311c7ec1..b0dd183a4dbc 100644
> --- a/net/tipc/socket.c
> +++ b/net/tipc/socket.c
> @@ -1973,10 +1973,12 @@ static int tipc_recvmsg(struct socket *sock,
> struct msghdr *m,
> tipc_node_distr_xmit(sock_net(sk), &xmitq);
> }
>
> - if (!skb_cb->bytes_read)
> - tsk_advance_rx_queue(sk);
> + if (skb_cb->bytes_read)
> + goto exit;
> +
> + tsk_advance_rx_queue(sk);
>
> - if (likely(!connected) || skb_cb->bytes_read)
> + if (likely(!connected))
> goto exit;
>
Ok, thank you for informing
With regards,
Pavel Skripkin
next prev parent reply other threads:[~2021-07-23 16:53 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-18 17:15 [syzbot] KASAN: use-after-free Read in tipc_recvmsg syzbot
2021-07-23 16:36 ` Pavel Skripkin
2021-07-23 16:41 ` Xin Long
2021-07-23 16:52 ` Pavel Skripkin [this message]
2021-07-23 16:49 ` Pavel Skripkin
2021-07-23 23:10 ` syzbot
2021-07-23 22:51 ` syzbot
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=20210723195253.56ef4ee3@gmail.com \
--to=paskripkin@gmail.com \
--cc=davem@davemloft.net \
--cc=devicetree@vger.kernel.org \
--cc=frowand.list@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=jmaloy@redhat.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lucien.xin@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=rafael@kernel.org \
--cc=robh+dt@kernel.org \
--cc=robh@kernel.org \
--cc=syzbot+e6741b97d5552f97c24d@syzkaller.appspotmail.com \
--cc=syzkaller-bugs@googlegroups.com \
--cc=tipc-discussion@lists.sourceforge.net \
--cc=ying.xue@windriver.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.