Vulnerabilities in pkg:gem/time
PACKAGECVE-2023-28756 is a HIGH (CVSS 7.5) denial of service vulnerability (CWE-1333: Inefficient Regular Expression Complexity) affecting Time libraries in the RubyGems ecosystem. The issue involves ruby time component redos issue. Remediation is available by upgrading affected packages to version 0.2.2, 0.1.1.
pkg:gem/time
Vulnerability advisories affecting package pkg:gem/time. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-fg7x-g82r-94qc | CVE-2023-28756 | HIGH | Ruby Time component ReDoS issue |
CVE-2023-28756 at a Glance
Security Impact
CVSS: 7.5
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).
How to Fix CVE-2023-28756
To remediate this vulnerability, upgrade all affected Time dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade time to 0.2.2
Upgrade time to 0.1.1
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for time
How to Check if You Are Affected
To determine whether your application is affected by CVE-2023-28756, inspect your project dependencies for Time:
inspect dependencies for time
Analyze the terminal output to locate any version of Time in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.2.2), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-1333: Inefficient Regular Expression Complexity, where the product uses a regular expression with a worst-case computational complexity that is inefficient and possibly exponential. In Time, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2023-28756 Affected Time Versions
2 component(s)References
Frequently Asked Questions
What is CVE-2023-28756?
Which Time versions are affected?
What version fixes CVE-2023-28756?
Is time affected?
What is the CVSS score of CVE-2023-28756?
What CWE is associated with CVE-2023-28756?
How can I check RubyGems dependencies for CVE-2023-28756?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-fg7x-g82r-94qc",
"modified" : "2025-11-04T19:37:42Z",
"published" : "2023-03-31T06:30:15Z",
"aliases" : [ "CVE-2023-28756" ],
"summary" : "Ruby Time component ReDoS issue",
"details" : "A ReDoS issue was discovered in the Time component through 0.2.1 in Ruby through 3.2.1. The Time parser mishandles invalid URLs that have specific characters. It causes an increase in execution time for parsing strings to Time objects. The fixed versions are 0.1.1 and 0.2.2.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "RubyGems",
"name" : "time"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0.2.0"
}, {
"fixed" : "0.2.2"
} ]
} ]
}, {
"package" : {
"ecosystem" : "RubyGems",
"name" : "time"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.1.1"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-28756"
}, {
"type" : "WEB",
"url" : "https://www.ruby-lang.org/en/news/2023/03/30/redos-in-time-cve-2023-28756"
}, {
"type" : "WEB",
"url" : "https://www.ruby-lang.org/en/news/2022/12/25/ruby-3-2-0-released"
}, {
"type" : "WEB",
"url" : "https://www.ruby-lang.org/en/downloads/releases"
}, {
"type" : "WEB",
"url" : "https://security.netapp.com/advisory/ntap-20230526-0004"
}, {
"type" : "WEB",
"url" : "https://security.gentoo.org/glsa/202401-27"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/WMIOPLBAAM3FEQNAXA2L7BDKOGSVUT5Z"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/G76GZG3RAGYF4P75YY7J7TGYAU7Z5E2T"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/FFZANOQA4RYX7XCB42OO3P24DQKWHEKA"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/WMIOPLBAAM3FEQNAXA2L7BDKOGSVUT5Z"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/G76GZG3RAGYF4P75YY7J7TGYAU7Z5E2T"
}, {
"type" : "WEB",
"url" : "https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/FFZANOQA4RYX7XCB42OO3P24DQKWHEKA"
}, {
"type" : "WEB",
"url" : "https://lists.debian.org/debian-lts-announce/2024/09/msg00000.html"
}, {
"type" : "WEB",
"url" : "https://lists.debian.org/debian-lts-announce/2023/04/msg00033.html"
}, {
"type" : "WEB",
"url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/time/CVE-2023-28756.yml"
}, {
"type" : "WEB",
"url" : "https://github.com/ruby/time/releases"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/ruby/time"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-1333" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2023-03-31T22:43:54Z",
"nvd_published_at" : "2023-03-31T04:15:00Z"
}
}