diff options
author | Joe Slater <jslater@windriver.com> | 2017-08-18 10:43:44 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-09-11 22:15:58 +0100 |
commit | c63480c9605a22b3000dc4f0e9198e67365832e9 (patch) | |
tree | 06f61b7391e60f35eba0675e96ce225776e1a242 /meta/recipes-devtools/ruby/ruby/ruby-CVE-2017-9227.patch | |
parent | 62e244d71354f20e8680606e015565690f1bd4f5 (diff) | |
download | poky-c63480c9605a22b3000dc4f0e9198e67365832e9.tar.gz |
ruby: fix CVE-2017-922{6-9}
CVE-2017-9226 : check too big code point value for single byte
CVE-2017-9227 : access to invalid address by reg->dmin value
CVE-2017-9228 : invalid state(CCS_VALUE) in parse_char_class()
CVE-2017-9229 : access to invalid address by reg->dmax value
(From OE-Core rev: f15f01edbaa431829a50053d07ed6d6b333584c7)
(From OE-Core rev: 4077e088b6e750c4143a59c5d89258ab682ed96b)
Signed-off-by: Joe Slater <jslater@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/ruby/ruby/ruby-CVE-2017-9227.patch')
-rw-r--r-- | meta/recipes-devtools/ruby/ruby/ruby-CVE-2017-9227.patch | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/meta/recipes-devtools/ruby/ruby/ruby-CVE-2017-9227.patch b/meta/recipes-devtools/ruby/ruby/ruby-CVE-2017-9227.patch new file mode 100644 index 0000000000..85e7ccb369 --- /dev/null +++ b/meta/recipes-devtools/ruby/ruby/ruby-CVE-2017-9227.patch | |||
@@ -0,0 +1,32 @@ | |||
1 | From 9690d3ab1f9bcd2db8cbe1fe3ee4a5da606b8814 Mon Sep 17 00:00:00 2001 | ||
2 | From: "K.Kosako" <kosako@sofnec.co.jp> | ||
3 | Date: Tue, 23 May 2017 16:15:35 +0900 | ||
4 | Subject: [PATCH] fix #58 : access to invalid address by reg->dmin value | ||
5 | |||
6 | --- | ||
7 | regexec.c | 2 ++ | ||
8 | 1 file changed, 2 insertions(+) | ||
9 | |||
10 | --- end of original header | ||
11 | |||
12 | CVE: CVE-2017-9227 | ||
13 | |||
14 | Upstream-Status: Inappropriate [not author] | ||
15 | Signed-off-by: Joe Slater <joe.slater@windriver.com> | ||
16 | |||
17 | diff --git a/regexec.c b/regexec.c | ||
18 | index d4e577d..2fa0f3d 100644 | ||
19 | --- a/regexec.c | ||
20 | +++ b/regexec.c | ||
21 | @@ -3154,6 +3154,8 @@ forward_search_range(regex_t* reg, const UChar* str, const UChar* end, UChar* s, | ||
22 | } | ||
23 | else { | ||
24 | UChar *q = p + reg->dmin; | ||
25 | + | ||
26 | + if (q >= end) return 0; /* fail */ | ||
27 | while (p < q) p += enclen(reg->enc, p, end); | ||
28 | } | ||
29 | } | ||
30 | -- | ||
31 | 1.7.9.5 | ||
32 | |||