From patchwork Fri Mar 1 03:21:12 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 159453 Delivered-To: patch@linaro.org Received: by 2002:a02:5cc1:0:0:0:0:0 with SMTP id w62csp223801jad; Thu, 28 Feb 2019 19:22:00 -0800 (PST) X-Google-Smtp-Source: APXvYqzrIfUm4Y4ydere3cfYaqoIRYvbCSs+Zw/mOmugcXDXQHJcai/Wl+aRiH7ZF7p7OSY89vOh X-Received: by 2002:a17:902:6684:: with SMTP id e4mr3134667plk.90.1551410520238; Thu, 28 Feb 2019 19:22:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551410520; cv=none; d=google.com; s=arc-20160816; b=N7Geo4JukuU7qvuo88SMXHMSZTXvzI7kqJYoKswO4r3g2nJ5zfcjW10HeucjwqTHbL ewFy6/dDNUaQ7XxIbVOkhaaVFY3OKJr37pPscOmjmB2MsMajCOlrTebL+QQgQj7eAIw+ XtimenIKrwA1JziYTTfvNNsFAEGX8Eirv6V/+OCrJ+O4W3c5ngGYn/MAB1HMkbIv7iTE 2H1A77ojU4H3FVrn572zbnhYqcOnCpGlP//BQ8jpLKf9XGwuqpT8mxujSDAH05jNK2o/ D6vmmxKF6V9RVfvxDEMcvtgR8OtufgPPgb4T9s4NQer26lvBjsj/ew9BcUjemVTwTOlE 88GA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:references:in-reply-to:message-id:date:to:from :dkim-signature:delivered-to; bh=7GC5l2v8eqMsCmYXFMLKLmn7ohXvsqpH8j8Dp53PX70=; b=WUg7pWpL+sK6GdwnoUfdZgJ/yXTwus8JPezrTF9IeE0M6ZYQSYKe7Y/EtXuypOJ5nY vimpKyuE15bzCbBvCLLF99Oh0GmSqLhVvt6+3r5AHYzW0a3LVt5gOQXBedK6C+T+KoCd Q30avhnYQ2hC5Jr9UxgzkzD5a00vR9GnoRG8aBFSmIOsOXEds0xyFana60EVGMxmYXSb ONUrde/kHqReiEntRv7DRCXrWI3rxmaVdSVz5jn71Cf6/02CRtPkfCTcvMGolkwm1kLq clJR7/bOgYjpZ8Xd3N1uD4+O5TAfRNtIOi/4Iuq85oCk4msZAzaxdkLCcUdTE177bVLG 9dkQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=OC06b4gW; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id d73si20614244pfm.210.2019.02.28.19.21.59; Thu, 28 Feb 2019 19:22:00 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=OC06b4gW; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from ec2-34-214-78-129.us-west-2.compute.amazonaws.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 26E227CD55; Fri, 1 Mar 2019 03:21:45 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-pl1-f196.google.com (mail-pl1-f196.google.com [209.85.214.196]) by mail.openembedded.org (Postfix) with ESMTP id EAED17CD45 for ; Fri, 1 Mar 2019 03:21:23 +0000 (UTC) Received: by mail-pl1-f196.google.com with SMTP id m10so10743158plt.10 for ; Thu, 28 Feb 2019 19:21:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=YZUujBytv4bg6vzgI91E1O1iuswu3Hf2Of0soEOI1LQ=; b=OC06b4gWiebHjbYL7QVFDkuacwwYSJHxEy4dGEMnjS/peF5NtOv1F+P3XzFgN8hbtS BsOjtq0IBjgPUM5Av39JvujiIo0bB3Ix//92Jvwmghc644FRmyVqLE+g9RxRTpUqw+L8 frB3kHAtYx5hqPeDkON9h94Ue288tcL6VFA/ZcIA0BqpP8K3TMyCsUTCtCv82rrzEsW8 tusDKvS/VVbEhiXwMxz0ODE+ZhDJzRcV8DgDQ9oyFtL6VaTpW+aJb9N5tgT4zqvyssIQ KtC5jYIzdef1X8o9x1uyysWb1YRNgPV/lkqP39PoGUF5BTvAKBh6nsukAeL5GE4WU58B W7Pg== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=YZUujBytv4bg6vzgI91E1O1iuswu3Hf2Of0soEOI1LQ=; b=ZAVci9I98Jq0hUzFxZj+pKwxMjrmIOAgUcMXAO/slHhrr/tAnjKU+i+1lkIr3QUUUj qG5VB2PZxRm6fLuZafYkDR3N3Pn6yP9s+UsifL35Nxj9M+PIeUxvusyrLRYFrG24AQLy asjBnOIN06jaV++VhxVlEXjcO71/VrjP8wTP5Jc1eJggUJK7PMaO1UEwH5b+fl60/xDJ yAF2jwLfXppvhWt5nNF3fPqakeV7DfI1Lgu6EBZME7uknbsB5bHUTj6AvkpQ3eQSD06+ 2FwCXVdnK2fvnYsgE+fkLri79Vd7FGDvquD/zVJQMwBgymrBHWUTehuVbWRjMq5MWAOL hwYw== X-Gm-Message-State: APjAAAV3R3sMtW8WeFzbZ4NzQF8GsWydMYdvNLy/bV/fB9AF3mqnprG5 zbo7kSgKtkpJ+qbt4Ph/iCBc1K9V X-Received: by 2002:a17:902:7604:: with SMTP id k4mr3136487pll.232.1551410484669; Thu, 28 Feb 2019 19:21:24 -0800 (PST) Received: from apollo.hsd1.ca.comcast.net ([2601:646:8500:6bc6::5fa3]) by smtp.gmail.com with ESMTPSA id z127sm37612096pfb.80.2019.02.28.19.21.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 28 Feb 2019 19:21:24 -0800 (PST) From: Khem Raj To: openembedded-core@lists.openembedded.org Date: Thu, 28 Feb 2019 19:21:12 -0800 Message-Id: <20190301032112.38191-5-raj.khem@gmail.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190301032112.38191-1-raj.khem@gmail.com> References: <20190301032112.38191-1-raj.khem@gmail.com> MIME-Version: 1.0 Subject: [OE-core] [PATCH 5/5] musl: Fix out of bounds data access in dlopen X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org Signed-off-by: Khem Raj --- .../musl/musl/out_of_bounds_read.patch | 20 +++++++++++++++++++ meta/recipes-core/musl/musl_git.bb | 1 + 2 files changed, 21 insertions(+) create mode 100644 meta/recipes-core/musl/musl/out_of_bounds_read.patch -- 2.21.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-core/musl/musl/out_of_bounds_read.patch b/meta/recipes-core/musl/musl/out_of_bounds_read.patch new file mode 100644 index 0000000000..a681cc284e --- /dev/null +++ b/meta/recipes-core/musl/musl/out_of_bounds_read.patch @@ -0,0 +1,20 @@ +Fix out of bounds read + +self->dtv hasn't been extended yet + +Upstream-Status: Pending +Signed-off-by: Khem Raj + +diff --git a/ldso/dynlink.c b/ldso/dynlink.c +index e2c3259f..b23ea0df 100644 +--- a/ldso/dynlink.c ++++ b/ldso/dynlink.c +@@ -1374,7 +1376,7 @@ static void install_new_tls(void) + } + /* Install new dtls into the enlarged, uninstalled dtv copies. */ + for (p=head; ; p=p->next) { +- if (!p->tls_id || self->dtv[p->tls_id]) continue; ++ if (p->tls_id <= old_cnt) continue; + unsigned char *mem = p->new_tls; + for (j=0; j