jruby/CVE-2023-28756.patch

62 lines
2.1 KiB
Diff
Raw Normal View History

2024-01-26 10:40:54 +08:00
From 957bb7cb81995f26c671afce0ee50a5c660e540e Mon Sep 17 00:00:00 2001
From: Hiroshi SHIBATA <hsbt@ruby-lang.org>
Date: Wed, 29 Mar 2023 13:28:25 +0900
Subject: Merge Time-0.2.2
Origin: https://github.com/ruby/ruby/commit/957bb7cb81995f26c671afce0ee50a5c660e540e
---
lib/ruby/1.8/time.rb | 4 ++--
lib/ruby/1.9/time.rb | 4 ++--
lib/ruby/2.0/time.rb | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/lib/ruby/1.8/time.rb b/lib/ruby/1.8/time.rb
index a37a067..a9ef487 100644
--- a/lib/ruby/1.8/time.rb
+++ b/lib/ruby/1.8/time.rb
@@ -265,8 +265,8 @@ class Time
(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s+
(\d{2,})\s+
(\d{2})\s*
- :\s*(\d{2})\s*
- (?::\s*(\d{2}))?\s+
+ :\s*(\d{2})
+ (?:\s*:\s*(\d\d))?\s+
([+-]\d{4}|
UT|GMT|EST|EDT|CST|CDT|MST|MDT|PST|PDT|[A-IK-Z])/ix =~ date
# Since RFC 2822 permit comments, the regexp has no right anchor.
diff --git a/lib/ruby/1.9/time.rb b/lib/ruby/1.9/time.rb
index 40b28d9..4379be2 100644
--- a/lib/ruby/1.9/time.rb
+++ b/lib/ruby/1.9/time.rb
@@ -320,8 +320,8 @@ class Time
(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s+
(\d{2,})\s+
(\d{2})\s*
- :\s*(\d{2})\s*
- (?::\s*(\d{2}))?\s+
+ :\s*(\d{2})
+ (?:\s*:\s*(\d\d))?\s+
([+-]\d{4}|
UT|GMT|EST|EDT|CST|CDT|MST|MDT|PST|PDT|[A-IK-Z])/ix =~ date
# Since RFC 2822 permit comments, the regexp has no right anchor.
diff --git a/lib/ruby/2.0/time.rb b/lib/ruby/2.0/time.rb
index 12c2b30..3430410 100644
--- a/lib/ruby/2.0/time.rb
+++ b/lib/ruby/2.0/time.rb
@@ -429,8 +429,8 @@ class Time
(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s+
(\d{2,})\s+
(\d{2})\s*
- :\s*(\d{2})\s*
- (?::\s*(\d{2}))?\s+
+ :\s*(\d{2})
+ (?:\s*:\s*(\d\d))?\s+
([+-]\d{4}|
UT|GMT|EST|EDT|CST|CDT|MST|MDT|PST|PDT|[A-IK-Z])/ix =~ date
# Since RFC 2822 permit comments, the regexp has no right anchor.
--
2.33.0