From patchwork Wed Nov 20 01:06:33 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kees Cook X-Patchwork-Id: 11252943 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id EC2BF1390 for ; Wed, 20 Nov 2019 01:06:57 +0000 (UTC) Received: from mother.openwall.net (mother.openwall.net [195.42.179.200]) by mail.kernel.org (Postfix) with SMTP id EB96220708 for ; Wed, 20 Nov 2019 01:06:56 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="QPNZ3TFY" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EB96220708 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kernel-hardening-return-17403-patchwork-kernel-hardening=patchwork.kernel.org@lists.openwall.com Received: (qmail 25620 invoked by uid 550); 20 Nov 2019 01:06:55 -0000 Mailing-List: contact kernel-hardening-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Delivered-To: mailing list kernel-hardening@lists.openwall.com Received: (qmail 24561 invoked from network); 20 Nov 2019 01:06:54 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id; bh=CUFUdRWnKnM6bQsVtJfdZZf6wE8f8HKbQO0cl/4N/Js=; b=QPNZ3TFYMN2cyDfBdvY07DD5Qf553QuOH2y52Uwcvrqipiupi+07SzCncWmB4ompaa Sp+KugNpDIe0O6L+0QzSoa4zgNsRPXdvojFu1L2G6OGfQek8k6mLkB+UwWM1uFrTy2gS NyC4I93Ch4Jff4rMgtPSiWxg1V0Gf/SF4lmjQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=CUFUdRWnKnM6bQsVtJfdZZf6wE8f8HKbQO0cl/4N/Js=; b=W9NefbWQUy8gYBDVx91fUAVux8e23Eqolm01HDtH5lz2tMo+cgOFrKAszYpXQKJAoi dakuF50WhFo+yikFKS5DY2+yCtquWTLuJJTOUC+a/YGmu8NvjVSdfztKq7w8sGDIeh99 2ox6RQ54mYqFOGkTsmkvH4420jh63guomnlSDDxEeWXocaSucthDZDXlXyq/SvWU2AUn cy7DMr2a6vkh7WncQkUhjxHlyk9b72IjXoYSUkogTN7pGv87nCsZrkeGgtechz8RB0LJ UZo6A4H4EN2p6QZi6Z2zOUBUcS67pEoQ60tpcnQlQ4OEHwn5KkuEaX0xw5ONvyGCNsJY bl1g== X-Gm-Message-State: APjAAAV7C+cO7VySzQEEv3mj9NyrDx3nl+C8YoptOs7DuWWQI1jbOlHa VavvU177fA9m4smHsX08o4z9KQ== X-Google-Smtp-Source: APXvYqwryrV10zt9FpcokSWJA8ITt8y25QMJpvbarPp35S9IPnXIHn2OsUwTFiZFRGn4wDxNWoDbIA== X-Received: by 2002:a62:ae17:: with SMTP id q23mr705132pff.2.1574212002529; Tue, 19 Nov 2019 17:06:42 -0800 (PST) From: Kees Cook To: Andrey Ryabinin Cc: Kees Cook , Elena Petrova , Alexander Potapenko , Dmitry Vyukov , Linus Torvalds , Dan Carpenter , "Gustavo A. R. Silva" , Arnd Bergmann , Ard Biesheuvel , Andrew Morton , kasan-dev@googlegroups.com, linux-kernel@vger.kernel.org, kernel-hardening@lists.openwall.com Subject: [PATCH 0/3] ubsan: Split out bounds checker Date: Tue, 19 Nov 2019 17:06:33 -0800 Message-Id: <20191120010636.27368-1-keescook@chromium.org> X-Mailer: git-send-email 2.17.1 This splits out the bounds checker so it can be individually used. This is expected to be enabled in Android and hopefully for syzbot. Includes LKDTM tests for behavioral corner-cases. -Kees Kees Cook (3): ubsan: Add trap instrumentation option ubsan: Split "bounds" checker from other options lkdtm/bugs: Add arithmetic overflow and array bounds checks drivers/misc/lkdtm/bugs.c | 75 ++++++++++++++++++++++++++++++++++++++ drivers/misc/lkdtm/core.c | 3 ++ drivers/misc/lkdtm/lkdtm.h | 3 ++ lib/Kconfig.ubsan | 34 ++++++++++++++++- lib/Makefile | 2 + scripts/Makefile.ubsan | 16 ++++++-- 6 files changed, 128 insertions(+), 5 deletions(-)