Files
poky/meta/recipes-devtools/perl/perl/CVE-2018-18312.patch
Dan Tran bda26ff31c perl: Fix CVE-2018-18311 to 18314
(From OE-Core rev: cffd085ef77d055e5e837887b0eaf820aa982f00)

Signed-off-by: Dan Tran <dantran@microsoft.com>
[Perl before 5.26.3 and 5.28.x before 5.28.1]
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-10-10 16:52:30 +01:00

53 lines
2.1 KiB
Diff
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

From 497e246e999d14efabd820c47b013d4607dbc344 Mon Sep 17 00:00:00 2001
From: Karl Williamson <khw@cpan.org>
Date: Mon, 24 Sep 2018 11:54:41 -0600
Subject: [PATCH 1/3] PATCH: [perl #133423] for 5.26 maint
CVE: CVE-2018-18312
Upstream-Status: Backport
[https://perl5.git.perl.org/perl.git/commit/5dfd9842f2802803604cf517016d4d0518226006]
Signed-off-by: Dan Tran <dantran@microsoft.com>
---
regcomp.c | 1 -
t/re/reg_mesg.t | 5 +++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/regcomp.c b/regcomp.c
index edfae9cffd..00d26d9290 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -14872,7 +14872,6 @@ redo_curchar:
RExC_parse++;
assert(UCHARAT(RExC_parse) == ')');
- RExC_parse++;
RExC_flags = save_flags;
goto handle_operand;
}
diff --git a/t/re/reg_mesg.t b/t/re/reg_mesg.t
index 08d90c5c40..658397ac27 100644
--- a/t/re/reg_mesg.t
+++ b/t/re/reg_mesg.t
@@ -93,6 +93,8 @@ my $high_mixed_digit = ('A' lt '0') ? '0' : 'A';
my $colon_hex = sprintf "%02X", ord(":");
my $tab_hex = sprintf "%02X", ord("\t");
+my $bug133423 = "(?[(?^:(?[\\\x00]))\\]\x00|2[^^]\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80])R.\\670";
+
##
## Key-value pairs of code/error of code that should have fatal errors.
##
@@ -269,6 +271,9 @@ my @death =
'/(?[()-!])/' => 'Incomplete expression within \'(?[ ])\' {#} m/(?[(){#}-!])/', # [perl #126204]
'/(?[!()])/' => 'Incomplete expression within \'(?[ ])\' {#} m/(?[!(){#}])/', # [perl #126404]
'/(?<=/' => 'Sequence (?... not terminated {#} m/(?<={#}/', # [perl #128170]
+ "/$bug133423/" => "Operand with no preceding operator {#} m/(?[(?^:(?[\\]))\\{#}]|2[^^]\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80\x80])R.\\670/",
+
+
);
# These are messages that are warnings when not strict; death under 'use re
--
2.22.0.vfs.1.1.57.gbaf16c8