Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp139796ybl; Thu, 9 Jan 2020 18:41:25 -0800 (PST) X-Google-Smtp-Source: APXvYqy/ql/98yI2W833mtzcN0KtJdHp68OduFAqvQO0RjApicU+mBW9NHcU/kW2P5/VSLtidl8U X-Received: by 2002:aca:b608:: with SMTP id g8mr508988oif.142.1578624085547; Thu, 09 Jan 2020 18:41:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1578624085; cv=none; d=google.com; s=arc-20160816; b=auSpp70Y2Nzk0YoFYWo1GJmigtWCkTzTyBmuFcFR1mfoo1bqj0cTOoPrhq9ATxot2F KI4oXI510nCE603Jke23mG3CsIaEwQU8nLSx2xLAgzwqDM0yklRp3MV8IEcsHET9679t 9BOFYa/qQTnk6AbQpRxiQtPCxaVBGjpL4Mre7esU+yQed6lvx3Y7BfsQdwd/dNcTF9O0 K9WLQipSLT5+OXOD8jbfAdIYtXLTUPgIBomYsY1qqTKvMKMd2SQKPQj35HwUtktfhpqL lCHscH4bVtNHoN7R4xGEuqHXzAI+XA5sIUxfHi8QZZdQ35s4TWHIBc1VmsJOlqgTzyB0 TLQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:from:subject:cc:to:message-id:date; bh=72wBLIwvgM15Np4AD1Hgh1Pi9ffCodYFQyvs+fO9G8g=; b=kslcpxDdG/vzSE/PN1n6UrxNjyZ+F1YagW7zSMdv2H1oM1x1qPalF7exP28cK06SsU awVFSFUEwtFDUBcvXffnRIY8zeRzrHOyN8If5jSGgdwxAev2uNjRj5OhwgCGtgfTHe8e CR9YBMy7zV+y//u3FTHznaveLCQrN/3Ba5wfkgO6GHhu5y/2PZw6OLHIrucH2w6L6wfl uEdXA/uMF5juEDPJCmjzfLjoVio3DnPfwrET8amVUqEojKLn/oUaCdIWqsUJR+MZ+JuY wi5yQtpSA3uyBsIWNUOTnIpX/ClbhJOYPPJ7GlSgx2K9SB4gDHTSBn4D3z7ZhoMEK5Zy QQqA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v20si235232oia.159.2020.01.09.18.41.13; Thu, 09 Jan 2020 18:41:25 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730896AbgAJCkK (ORCPT + 99 others); Thu, 9 Jan 2020 21:40:10 -0500 Received: from shards.monkeyblade.net ([23.128.96.9]:60776 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730764AbgAJCkK (ORCPT ); Thu, 9 Jan 2020 21:40:10 -0500 Received: from localhost (unknown [IPv6:2601:601:9f00:1c3::3d5]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: davem-davemloft) by shards.monkeyblade.net (Postfix) with ESMTPSA id A4AC01573F021; Thu, 9 Jan 2020 18:40:08 -0800 (PST) Date: Thu, 09 Jan 2020 18:40:08 -0800 (PST) Message-Id: <20200109.184008.1039668214219996565.davem@davemloft.net> To: ms@dev.tdt.de Cc: arnd@arndb.de, andrew.hendry@gmail.com, edumazet@google.com, gregkh@linuxfoundation.org, tglx@linutronix.de, linux-x25@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com, syzbot+429c200ffc8772bfe070@syzkaller.appspotmail.com, syzbot+eec0c87f31a7c3b66f7b@syzkaller.appspotmail.com Subject: Re: [PATCH] net/x25: fix nonblocking connect From: David Miller In-Reply-To: <20200109063114.23195-1-ms@dev.tdt.de> References: <20200109063114.23195-1-ms@dev.tdt.de> X-Mailer: Mew version 6.8 on Emacs 26.1 Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Thu, 09 Jan 2020 18:40:09 -0800 (PST) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Martin Schiller Date: Thu, 9 Jan 2020 07:31:14 +0100 > This patch fixes 2 issues in x25_connect(): > > 1. It makes absolutely no sense to reset the neighbour and the > connection state after a (successful) nonblocking call of x25_connect. > This prevents any connection from being established, since the response > (call accept) cannot be processed. > > 2. Any further calls to x25_connect() while a call is pending should > simply return, instead of creating new Call Request (on different > logical channels). > > This patch should also fix the "KASAN: null-ptr-deref Write in > x25_connect" and "BUG: unable to handle kernel NULL pointer dereference > in x25_connect" bugs reported by syzbot. > > Signed-off-by: Martin Schiller > Reported-by: syzbot+429c200ffc8772bfe070@syzkaller.appspotmail.com > Reported-by: syzbot+eec0c87f31a7c3b66f7b@syzkaller.appspotmail.com Applied and queued up for -stable, thanks.