Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp31807ybi; Fri, 7 Jun 2019 03:34:23 -0700 (PDT) X-Google-Smtp-Source: APXvYqx5oS0k18WnSit02gDvpDvWoUhpGgK+v1oq4sWSTbHJGRPyvLZOYvXBoMBgU4i+GcTWVCXV X-Received: by 2002:a62:1456:: with SMTP id 83mr6428792pfu.228.1559903663321; Fri, 07 Jun 2019 03:34:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559903663; cv=none; d=google.com; s=arc-20160816; b=vN37nWJWS8N98aAvHLsWGKh0Aw2KXMswoRWK/XqYEzN/J5HKOCWFMgsobkzQ++GN9v TOevF4fW1K4oWVUrrzvnqygEdbMtTLR0IsHIIDb4y5iw3AuURXBIwZ2Qe+siFz3kV+IU UPh1E/LbNb2Pp9YhPyBs4WUgrOboPCO+RniQ7C2QkZ1a29mqPyfb2BE/OPGwEoHEHF8E tkh5bngOYDPgKQpHX/Vt7Dwz238pcGn5ygjPFxxqpEPJlwMmGKcKxXBbyM4TD4dXooVA OLvHXG9mlDXEob4JE4+qWzIF9V9wFHDFLOjYuI7KrE4ETpWbNZYo7Abze2dcFoL7XK67 QX2g== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:references:cc:to:from:subject; bh=Fga8PPc/U2bSD9FkVfxqQuL6oYrzMZgTVtrz0AK04Ac=; b=u0Vd9nxAxa3cbbkI0t9vXdk+S0juYEjRHiWH8ntN//3gqy+Z1Z3qh8vxdbEZJQuwMp yBvUfs7LJl0VZbAXjQAcKKg67L39SnhaUmn/PK4x8eYn03uh/1Qw1ivEMX7i1b8FZdnO JKzxoWPvviffmN/Ra9oM9tgW3hAmspjQAdlf/EYmtRpNzzH9WjRkZL8KDlVwDnbmySil chCaqFwoaLzffk2I6/ds+sFCF5mrMCLpGHu+7OkmFVB+/1otNhtAqUvJXUyCSTtfU7nO DQO24gzmEcEPFiI/2y54pryDlICwFhs76hi7EZD2imPlQqcD2d1iAk+bMEN9WvxRg7MD 1VOQ== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h15si1325584pfn.96.2019.06.07.03.34.05; Fri, 07 Jun 2019 03:34:23 -0700 (PDT) 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727672AbfFGKY5 (ORCPT + 99 others); Fri, 7 Jun 2019 06:24:57 -0400 Received: from out30-130.freemail.mail.aliyun.com ([115.124.30.130]:56825 "EHLO out30-130.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727402AbfFGKY4 (ORCPT ); Fri, 7 Jun 2019 06:24:56 -0400 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R391e4;CH=green;DM=||false|;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04400;MF=joseph.qi@linux.alibaba.com;NM=1;PH=DS;RN=8;SR=0;TI=SMTPD_---0TTdaw5M_1559903093; Received: from JosephdeMacBook-Pro.local(mailfrom:joseph.qi@linux.alibaba.com fp:SMTPD_---0TTdaw5M_1559903093) by smtp.aliyun-inc.com(127.0.0.1); Fri, 07 Jun 2019 18:24:53 +0800 Subject: Re: [bug report][stable] kernel tried to execute NX-protected page - exploit attempt? (uid: 0) From: Joseph Qi To: "linux-kernel@vger.kernel.org" , x86@kernel.org, Nadav Amit , "Peter Zijlstra (Intel)" , Ingo Molnar , Greg KH Cc: Caspar Zhang , jiufei Xue References: <5817eaac-29cc-6331-af3b-b9d85a7c1cd7@linux.alibaba.com> Message-ID: Date: Fri, 7 Jun 2019 18:24:53 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: <5817eaac-29cc-6331-af3b-b9d85a7c1cd7@linux.alibaba.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi all, Any idea on this regression? Thanks, Joseph On 19/6/5 18:23, Joseph Qi wrote: > Hi, > > I have encountered a kernel BUG when running ltp ftrace-stress-test > on 4.19.48. > > [ 209.704855] LTP: starting ftrace-stress-test (ftrace_stress_test.sh 90) > [ 209.739412] Scheduler tracepoints stat_sleep, stat_iowait, stat_blocked and stat_runtime require the kernel parameter schedstats=enable or kernel.sched_schedstats=1 > [ 212.054506] kernel tried to execute NX-protected page - exploit attempt? (uid: 0) > [ 212.055595] BUG: unable to handle kernel paging request at ffffffffc0349000 > [ 212.056589] PGD d00c067 P4D d00c067 PUD d00e067 PMD 23673e067 PTE 800000023457f061 > [ 212.057759] Oops: 0011 [#1] SMP PTI > [ 212.058303] CPU: 0 PID: 0 Comm: swapper/0 Kdump: loaded Not tainted 4.19.48 #112 > > After some investigation I have found that it is introduced by commit > 8715ce033eb3 ("x86/modules: Avoid breaking W^X while loading modules"), > and then revert this commit the issue is gone. > > I have also tested the same case on 5.2-rc3 as well as right at > upstream commit f2c65fb3221a ("x86/modules: Avoid breaking W^X while > loading modules"), which has been merged in 5.2-rc1, it doesn't > happen. > > So I don't know why only stable has this issue while upstream doesn't. > > Thanks, > Joseph >