Change-Id: Ic6826899accee800e1b8810353755de0bed83544
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/3932
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Anish Swaminathan <anishs@vmware.com>
| 4 | 7 |
deleted file mode 100644 |
| ... | ... |
@@ -1,70 +0,0 @@ |
| 1 |
-diff --git a/ext/json/generator/generator.c b/ext/json/generator/generator.c |
|
| 2 |
-index a135e28348..2cdca5685f 100644 |
|
| 3 |
-+++ b/ext/json/generator/generator.c |
|
| 4 |
-@@ -301,7 +301,7 @@ static char *fstrndup(const char *ptr, unsigned long len) {
|
|
| 5 |
- char *result; |
|
| 6 |
- if (len <= 0) return NULL; |
|
| 7 |
- result = ALLOC_N(char, len); |
|
| 8 |
-- memccpy(result, ptr, 0, len); |
|
| 9 |
-+ memcpy(result, ptr, len); |
|
| 10 |
- return result; |
|
| 11 |
- } |
|
| 12 |
- |
|
| 13 |
-@@ -1055,7 +1055,7 @@ static VALUE cState_indent_set(VALUE self, VALUE indent) |
|
| 14 |
- } |
|
| 15 |
- } else {
|
|
| 16 |
- if (state->indent) ruby_xfree(state->indent); |
|
| 17 |
-- state->indent = strdup(RSTRING_PTR(indent)); |
|
| 18 |
-+ state->indent = fstrndup(RSTRING_PTR(indent), len); |
|
| 19 |
- state->indent_len = len; |
|
| 20 |
- } |
|
| 21 |
- return Qnil; |
|
| 22 |
-@@ -1093,7 +1093,7 @@ static VALUE cState_space_set(VALUE self, VALUE space) |
|
| 23 |
- } |
|
| 24 |
- } else {
|
|
| 25 |
- if (state->space) ruby_xfree(state->space); |
|
| 26 |
-- state->space = strdup(RSTRING_PTR(space)); |
|
| 27 |
-+ state->space = fstrndup(RSTRING_PTR(space), len); |
|
| 28 |
- state->space_len = len; |
|
| 29 |
- } |
|
| 30 |
- return Qnil; |
|
| 31 |
-@@ -1129,7 +1129,7 @@ static VALUE cState_space_before_set(VALUE self, VALUE space_before) |
|
| 32 |
- } |
|
| 33 |
- } else {
|
|
| 34 |
- if (state->space_before) ruby_xfree(state->space_before); |
|
| 35 |
-- state->space_before = strdup(RSTRING_PTR(space_before)); |
|
| 36 |
-+ state->space_before = fstrndup(RSTRING_PTR(space_before), len); |
|
| 37 |
- state->space_before_len = len; |
|
| 38 |
- } |
|
| 39 |
- return Qnil; |
|
| 40 |
-@@ -1166,7 +1166,7 @@ static VALUE cState_object_nl_set(VALUE self, VALUE object_nl) |
|
| 41 |
- } |
|
| 42 |
- } else {
|
|
| 43 |
- if (state->object_nl) ruby_xfree(state->object_nl); |
|
| 44 |
-- state->object_nl = strdup(RSTRING_PTR(object_nl)); |
|
| 45 |
-+ state->object_nl = fstrndup(RSTRING_PTR(object_nl), len); |
|
| 46 |
- state->object_nl_len = len; |
|
| 47 |
- } |
|
| 48 |
- return Qnil; |
|
| 49 |
-@@ -1201,7 +1201,7 @@ static VALUE cState_array_nl_set(VALUE self, VALUE array_nl) |
|
| 50 |
- } |
|
| 51 |
- } else {
|
|
| 52 |
- if (state->array_nl) ruby_xfree(state->array_nl); |
|
| 53 |
-- state->array_nl = strdup(RSTRING_PTR(array_nl)); |
|
| 54 |
-+ state->array_nl = fstrndup(RSTRING_PTR(array_nl), len); |
|
| 55 |
- state->array_nl_len = len; |
|
| 56 |
- } |
|
| 57 |
- return Qnil; |
|
| 58 |
-diff --git ext/json/generator/generator.h ext/json/generator/generator.h |
|
| 59 |
-index 298c0a4965..6bbf817b7d 100644 |
|
| 60 |
-+++ b/ext/json/generator/generator.h |
|
| 61 |
-@@ -1,7 +1,6 @@ |
|
| 62 |
- #ifndef _GENERATOR_H_ |
|
| 63 |
- #define _GENERATOR_H_ |
|
| 64 |
- |
|
| 65 |
--#include <string.h> |
|
| 66 |
- #include <math.h> |
|
| 67 |
- #include <ctype.h> |
|
| 68 |
- |
| 69 | 1 |
deleted file mode 100644 |
| ... | ... |
@@ -1,117 +0,0 @@ |
| 1 |
-Index: b/regparse.c |
|
| 2 |
-=================================================================== |
|
| 3 |
-+++ b/regparse.c (revision 57909) |
|
| 4 |
-@@ -4570,11 +4570,11 @@ parse_char_class(Node** np, Node** asc_n https://github.com/ruby/ruby/blob/trunk/ruby_2_4/regparse.c#L4570 |
|
| 5 |
- enum CCVALTYPE val_type, in_type; |
|
| 6 |
- int val_israw, in_israw; |
|
| 7 |
- |
|
| 8 |
-+ *np = *asc_np = NULL_NODE; |
|
| 9 |
- env->parse_depth++; |
|
| 10 |
- if (env->parse_depth > ParseDepthLimit) |
|
| 11 |
- return ONIGERR_PARSE_DEPTH_LIMIT_OVER; |
|
| 12 |
- prev_cc = asc_prev_cc = (CClassNode* )NULL; |
|
| 13 |
-- *np = *asc_np = NULL_NODE; |
|
| 14 |
- r = fetch_token_in_cc(tok, src, end, env); |
|
| 15 |
- if (r == TK_CHAR && tok->u.c == '^' && tok->escaped == 0) {
|
|
| 16 |
- neg = 1; |
|
| 17 |
-Index: b/ext/-test-/regexp/init.c |
|
| 18 |
-=================================================================== |
|
| 19 |
-+++ b/ext/-test-/regexp/init.c (revision 57909) |
|
| 20 |
-@@ -0,0 +1,11 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_4/ext/-test-/regexp/init.c#L1 |
|
| 21 |
-+#include "ruby.h" |
|
| 22 |
-+ |
|
| 23 |
-+#define init(n) {void Init_##n(VALUE klass); Init_##n(klass);}
|
|
| 24 |
-+ |
|
| 25 |
-+void |
|
| 26 |
-+Init_regexp(void) |
|
| 27 |
-+{
|
|
| 28 |
-+ VALUE mBug = rb_define_module("Bug");
|
|
| 29 |
-+ VALUE klass = rb_define_class_under(mBug, "Regexp", rb_cRegexp); |
|
| 30 |
-+ TEST_INIT_FUNCS(init); |
|
| 31 |
-+} |
|
| 32 |
- |
|
| 33 |
-Property changes on: ruby_2_4/ext/-test-/regexp/init.c |
|
| 34 |
-___________________________________________________________________ |
|
| 35 |
-Added: svn:eol-style |
|
| 36 |
- + LF |
|
| 37 |
- |
|
| 38 |
-Index: b/ext/-test-/regexp/extconf.rb |
|
| 39 |
-=================================================================== |
|
| 40 |
-+++ b/ext/-test-/regexp/extconf.rb (revision 57909) |
|
| 41 |
-@@ -0,0 +1,3 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_4/ext/-test-/regexp/extconf.rb#L1 |
|
| 42 |
-+# frozen_string_literal: false |
|
| 43 |
-+require_relative "../auto_ext.rb" |
|
| 44 |
-+auto_ext |
|
| 45 |
- |
|
| 46 |
-Property changes on: ruby_2_4/ext/-test-/regexp/extconf.rb |
|
| 47 |
-___________________________________________________________________ |
|
| 48 |
-Added: svn:eol-style |
|
| 49 |
- + LF |
|
| 50 |
- |
|
| 51 |
-Index: b/ext/-test-/regexp/parse_depth_limit.c |
|
| 52 |
-=================================================================== |
|
| 53 |
-+++ b/ext/-test-/regexp/parse_depth_limit.c (revision 57909) |
|
| 54 |
-@@ -0,0 +1,23 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_4/ext/-test-/regexp/parse_depth_limit.c#L1 |
|
| 55 |
-+#include <ruby.h> |
|
| 56 |
-+#include <ruby/onigmo.h> |
|
| 57 |
-+ |
|
| 58 |
-+static VALUE |
|
| 59 |
-+get_parse_depth_limit(VALUE self) |
|
| 60 |
-+{
|
|
| 61 |
-+ unsigned int depth = onig_get_parse_depth_limit(); |
|
| 62 |
-+ return UINT2NUM(depth); |
|
| 63 |
-+} |
|
| 64 |
-+ |
|
| 65 |
-+static VALUE |
|
| 66 |
-+set_parse_depth_limit(VALUE self, VALUE depth) |
|
| 67 |
-+{
|
|
| 68 |
-+ onig_set_parse_depth_limit(NUM2UINT(depth)); |
|
| 69 |
-+ return depth; |
|
| 70 |
-+} |
|
| 71 |
-+ |
|
| 72 |
-+void |
|
| 73 |
-+Init_parse_depth_limit(VALUE klass) |
|
| 74 |
-+{
|
|
| 75 |
-+ rb_define_singleton_method(klass, "parse_depth_limit", get_parse_depth_limit, 0); |
|
| 76 |
-+ rb_define_singleton_method(klass, "parse_depth_limit=", set_parse_depth_limit, 1); |
|
| 77 |
-+} |
|
| 78 |
- |
|
| 79 |
-Property changes on: ruby_2_4/ext/-test-/regexp/parse_depth_limit.c |
|
| 80 |
-___________________________________________________________________ |
|
| 81 |
-Added: svn:eol-style |
|
| 82 |
- + LF |
|
| 83 |
- |
|
| 84 |
-Index: b/test/ruby/test_regexp.rb |
|
| 85 |
-=================================================================== |
|
| 86 |
-+++ b/test/ruby/test_regexp.rb (revision 57909) |
|
| 87 |
-@@ -1198,6 +1198,25 @@ class TestRegexp < Test::Unit::TestCase https://github.com/ruby/ruby/blob/trunk/ruby_2_4/test/ruby/test_regexp.rb#L1198 |
|
| 88 |
- RUBY |
|
| 89 |
- end |
|
| 90 |
- |
|
| 91 |
-+ def test_invalid_free_at_parse_depth_limit_over |
|
| 92 |
-+ assert_separately([], "#{<<-"begin;"}\n#{<<-"end;"}")
|
|
| 93 |
-+ begin; |
|
| 94 |
-+ begin |
|
| 95 |
-+ require '-test-/regexp' |
|
| 96 |
-+ rescue LoadError |
|
| 97 |
-+ else |
|
| 98 |
-+ bug = '[ruby-core:79624] [Bug #13234]' |
|
| 99 |
-+ Bug::Regexp.parse_depth_limit = 10 |
|
| 100 |
-+ src = "[" * 100 |
|
| 101 |
-+ 3.times do |
|
| 102 |
-+ assert_raise_with_message(RegexpError, /parse depth limit over/, bug) do |
|
| 103 |
-+ Regexp.new(src) |
|
| 104 |
-+ end |
|
| 105 |
-+ end |
|
| 106 |
-+ end |
|
| 107 |
-+ end; |
|
| 108 |
-+ end |
|
| 109 |
-+ |
|
| 110 |
- # This assertion is for porting x2() tests in testpy.py of Onigmo. |
|
| 111 |
- def assert_match_at(re, str, positions, msg = nil) |
|
| 112 |
- re = Regexp.new(re) unless re.is_a?(Regexp) |
| ... | ... |
@@ -1,29 +1,26 @@ |
| 1 |
-Summary: Ruby |
|
| 2 |
-Name: ruby |
|
| 3 |
-Version: 2.4.0 |
|
| 4 |
-Release: 6%{?dist}
|
|
| 5 |
-License: BSDL |
|
| 6 |
-URL: https://www.ruby-lang.org/en/ |
|
| 7 |
-Group: System Environment/Security |
|
| 8 |
-Vendor: VMware, Inc. |
|
| 9 |
-Distribution: Photon |
|
| 10 |
-Source0: http://cache.ruby-lang.org/pub/ruby/%{version}/%{name}-%{version}.tar.gz
|
|
| 11 |
-%define sha1 ruby=d44a3c50a0e742341ed3033d5db79d865151a4f4 |
|
| 12 |
-Patch0: ruby-CVE-2017-9224.patch |
|
| 13 |
-Patch1: ruby-CVE-2017-9226.patch |
|
| 14 |
-Patch2: ruby-CVE-2017-9227.patch |
|
| 15 |
-Patch3: ruby-CVE-2017-9229.patch |
|
| 16 |
-Patch4: ruby-CVE-2017-6181.patch |
|
| 17 |
-Patch5: ruby-CVE-2017-9228.patch |
|
| 18 |
-#https://github.com/flori/json/commit/8f782fd8e181d9cfe9387ded43a5ca9692266b85 |
|
| 19 |
-Patch6: ruby-CVE-2017-14064.patch |
|
| 1 |
+Summary: Ruby |
|
| 2 |
+Name: ruby |
|
| 3 |
+Version: 2.4.2 |
|
| 4 |
+Release: 1%{?dist}
|
|
| 5 |
+License: BSDL |
|
| 6 |
+URL: https://www.ruby-lang.org/en/ |
|
| 7 |
+Group: System Environment/Security |
|
| 8 |
+Vendor: VMware, Inc. |
|
| 9 |
+Distribution: Photon |
|
| 10 |
+Source0: http://cache.ruby-lang.org/pub/ruby/%{name}-%{version}.tar.xz
|
|
| 11 |
+%define sha1 ruby=8373e32c63bba2180799da091b572664aa9faf6f |
|
| 12 |
+Patch0: ruby-CVE-2017-9224.patch |
|
| 13 |
+Patch1: ruby-CVE-2017-9226.patch |
|
| 14 |
+Patch2: ruby-CVE-2017-9227.patch |
|
| 15 |
+Patch3: ruby-CVE-2017-9229.patch |
|
| 16 |
+Patch4: ruby-CVE-2017-9228.patch |
|
| 20 | 17 |
BuildRequires: openssl-devel |
| 21 | 18 |
BuildRequires: ca-certificates |
| 22 | 19 |
BuildRequires: readline-devel |
| 23 | 20 |
BuildRequires: readline |
| 24 |
-Requires: ca-certificates |
|
| 25 |
-Requires: openssl |
|
| 26 |
-Requires: gmp |
|
| 21 |
+Requires: ca-certificates |
|
| 22 |
+Requires: openssl |
|
| 23 |
+Requires: gmp |
|
| 27 | 24 |
%description |
| 28 | 25 |
The Ruby package contains the Ruby development environment. |
| 29 | 26 |
This is useful for object-oriented scripting. |
| ... | ... |
@@ -35,11 +32,9 @@ This is useful for object-oriented scripting. |
| 35 | 35 |
%patch2 -p1 |
| 36 | 36 |
%patch3 -p1 |
| 37 | 37 |
%patch4 -p1 |
| 38 |
-%patch5 -p1 |
|
| 39 |
-%patch6 -p1 |
|
| 40 | 38 |
%build |
| 41 | 39 |
./configure \ |
| 42 |
- --prefix=%{_prefix} \
|
|
| 40 |
+ --prefix=%{_prefix} \
|
|
| 43 | 41 |
--enable-shared \ |
| 44 | 42 |
--docdir=%{_docdir}/%{name}-%{version}
|
| 45 | 43 |
make %{?_smp_mflags}
|
| ... | ... |
@@ -64,6 +59,8 @@ rm -rf %{buildroot}/*
|
| 64 | 64 |
%{_docdir}/%{name}-%{version}
|
| 65 | 65 |
%{_mandir}/man1/*
|
| 66 | 66 |
%changelog |
| 67 |
+* Thu Sep 28 2017 Xiaolin Li <xiaolinl@vmware.com> 2.4.2-1 |
|
| 68 |
+- Update to version 2.4.2 |
|
| 67 | 69 |
* Fri Sep 15 2017 Xiaolin Li <xiaolinl@vmware.com> 2.4.0-6 |
| 68 | 70 |
- [security] CVE-2017-14064 |
| 69 | 71 |
* Tue Aug 08 2017 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 2.4.0-5 |
| ... | ... |
@@ -5,7 +5,7 @@ |
| 5 | 5 |
Summary: Provides Ruby language bindings for the GNOME Libxml2 XML toolkit |
| 6 | 6 |
Name: rubygem-libxml-ruby |
| 7 | 7 |
Version: 3.0.0 |
| 8 |
-Release: 1%{?dist}
|
|
| 8 |
+Release: 2%{?dist}
|
|
| 9 | 9 |
Group: Applications/Programming |
| 10 | 10 |
License: BSD |
| 11 | 11 |
Vendor: VMware, Inc. |
| ... | ... |
@@ -13,9 +13,9 @@ Distribution: Photon |
| 13 | 13 |
URL: https://rubygems.org/gems/%{gem_name}
|
| 14 | 14 |
Source0: https://rubygems.org/downloads/libxml-ruby-%{version}.gem
|
| 15 | 15 |
%define sha1 libxml-ruby=9a4f28d019da0aef73773d676f9ba3ce9294b6bb |
| 16 |
-BuildRequires: ruby = 2.4.0 |
|
| 16 |
+BuildRequires: ruby >= 2.4.0 |
|
| 17 | 17 |
BuildRequires: libxml2-devel |
| 18 |
-Requires: ruby = 2.4.0 |
|
| 18 |
+Requires: ruby >= 2.4.0 |
|
| 19 | 19 |
%description |
| 20 | 20 |
Provides Ruby language bindings for the GNOME Libxml2 XML toolkit |
| 21 | 21 |
%prep |
| ... | ... |
@@ -27,6 +27,8 @@ gem install -V --local --force --install-dir %{buildroot}/%{gemdir} %{SOURCE0}
|
| 27 | 27 |
%defattr(-,root,root,-) |
| 28 | 28 |
%{gemdir}
|
| 29 | 29 |
%changelog |
| 30 |
+* Thu Sep 28 2017 Xiaolin Li <xiaolinl@vmware.com> 3.0.0-2 |
|
| 31 |
+- Build with ruby 2.4.2. |
|
| 30 | 32 |
* Wed Mar 22 2017 Xiaolin Li <xiaolinl@vmware.com> 3.0.0-1 |
| 31 | 33 |
- Updated to version 3.0.0. |
| 32 | 34 |
* Tue Jan 31 2017 Anish Swaminathan <anishs@vmware.com> 2.8.0-4 |
| ... | ... |
@@ -4,7 +4,7 @@ |
| 4 | 4 |
|
| 5 | 5 |
Name: rubygem-nokogiri |
| 6 | 6 |
Version: 1.7.1 |
| 7 |
-Release: 1%{?dist}
|
|
| 7 |
+Release: 2%{?dist}
|
|
| 8 | 8 |
Summary: Nokogiri is an HTML, XML, SAX, and Reader parser. |
| 9 | 9 |
Group: Development/Languages |
| 10 | 10 |
License: MIT |
| ... | ... |
@@ -13,11 +13,11 @@ Distribution: Photon |
| 13 | 13 |
URL: https://rubygems.org/gems/nokogiri/ |
| 14 | 14 |
Source0: https://rubygems.org/downloads/nokogiri-%{version}.gem
|
| 15 | 15 |
%define sha1 nokogiri=5731c2d494381be8440f6ace6e5fcb62e7850581 |
| 16 |
-BuildRequires: ruby = 2.4.0 |
|
| 16 |
+BuildRequires: ruby >= 2.4.0 |
|
| 17 | 17 |
BuildRequires: rubygem-mini_portile2 |
| 18 | 18 |
BuildRequires: libxml2-devel |
| 19 | 19 |
BuildRequires: libxslt-devel |
| 20 |
-Requires: ruby = 2.4.0 |
|
| 20 |
+Requires: ruby >= 2.4.0 |
|
| 21 | 21 |
Requires: rubygem-mini_portile2 |
| 22 | 22 |
Requires: libxml2 |
| 23 | 23 |
Requires: libxslt |
| ... | ... |
@@ -35,6 +35,8 @@ NOKOGIRI_USE_SYSTEM_LIBRARIES=1 gem install -V --local --force --install-dir %{b
|
| 35 | 35 |
%{gemdir}
|
| 36 | 36 |
|
| 37 | 37 |
%changelog |
| 38 |
+* Thu Sep 28 2017 Xiaolin Li <xiaolinl@vmware.com> 1.7.1-2 |
|
| 39 |
+- Build with ruby 2.4.2. |
|
| 38 | 40 |
* Wed Mar 22 2017 Xiaolin Li <xiaolinl@vmware.com> 1.7.1-1 |
| 39 | 41 |
- Updated to version 1.7.1. |
| 40 | 42 |
* Tue Jan 31 2017 Anish Swaminathan <anishs@vmware.com> 1.6.7.2-5 |