Vulnerabilities in pkg:gem/activerecord-session_store

PACKAGE
Advisory Identifier: GHSA-cvw2-xj8r-mjf7
Advisory Summary

CVE-2019-25025 is a MODERATE (CVSS 5.3) activerecord-session_store vulnerable to timing attack vulnerability (CWE-208: Observable Timing Discrepancy) affecting Activerecord session store libraries in the RubyGems ecosystem. The issue involves activerecord-session_store vulnerable to timing attack. Remediation is available by upgrading affected packages to version 2.0.0.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:gem/activerecord-session_store

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:gem/activerecord-session_store. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-cvw2-xj8r-mjf7 CVE-2019-25025 MODERATE Activerecord-session_store Vulnerable to Timing Attack

CVE-2019-25025 at a Glance

CVE Identifier CVE-2019-25025
GHSA Identifier GHSA-cvw2-xj8r-mjf7
Severity MODERATE
CVSS v3.1 Base Score 5.3
CWE Classification CWE-208: Observable Timing Discrepancy
Affected Product Activerecord session store
Package Ecosystem RubyGems
Published Date
Last Updated

Security Impact

CVSS: 5.3

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:L/I:N/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality Low (C:L)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2019-25025

To remediate this vulnerability, upgrade all affected Activerecord session store dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

activerecord-session_store fixed: 2.0.0
Upgrade activerecord-session_store to 2.0.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for activerecord-session_store

How to Check if You Are Affected

To determine whether your application is affected by CVE-2019-25025, inspect your project dependencies for Activerecord session store:

inspect dependencies for activerecord-session_store

Analyze the terminal output to locate any version of Activerecord session store in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.0.0), 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-208: Observable Timing Discrepancy, where two separate operations in a product require different amounts of time to complete, in a way that is observable to an actor and reveals security-relevant information about the state of the product, such as whether a particular operation was successful or not. In Activerecord session store, 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

The `activerecord-session_store` (aka Active Record Session Store) component through 1.1.3 for Ruby on Rails does not use a constant-time approach when delivering information about whether a guessed session ID is valid. Consequently, remote attackers can leverage timing discrepancies to achieve a correct guess in a relatively short amount of time. This is a related issue to CVE-2019-16782. ## Recommendation This has been fixed in version 2.0.0. All users are advised to update to this version or later.

CVE-2019-25025 Affected Activerecord session store Versions

1 component(s)
Fixed Versions:
2.0.0
Product / Package Ecosystem Affected Versions Fixed Version
activerecord-session_store
RubyGems
< 2.0.0
2.0.0

References

Frequently Asked Questions

What is CVE-2019-25025?
CVE-2019-25025 is a security vulnerability in Activerecord session store involving Activerecord-session_store Vulnerable to Timing Attack under CWE-208: Observable Timing Discrepancy.
Which Activerecord session store versions are affected?
Affected versions include releases prior to 2.0.0 across affected packages: activerecord-session_store.
What version fixes CVE-2019-25025?
Upgrading to 2.0.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is activerecord-session_store affected?
Yes, activerecord-session_store is affected in releases prior to 2.0.0. Upgrade your dependency to 2.0.0 or later.
What is the CVSS score of CVE-2019-25025?
CVE-2019-25025 has a CVSS v3.1 base score of 5.3 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N.
What CWE is associated with CVE-2019-25025?
CVE-2019-25025 is classified under CWE-208: Observable Timing Discrepancy (Two separate operations in a product require different amounts of time to complete, in a way that is observable to an actor and reveals security-relevant information about the state of the product, such as whether a particular operation was successful or not.).
How can I check RubyGems dependencies for CVE-2019-25025?
Run the dependency tree command: 'inspect dependencies for activerecord-session_store'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-cvw2-xj8r-mjf7",
  "modified" : "2023-09-05T22:00:39Z",
  "published" : "2021-03-09T00:45:31Z",
  "aliases" : [ "CVE-2019-25025" ],
  "summary" : "Activerecord-session_store Vulnerable to Timing Attack",
  "details" : "The `activerecord-session_store` (aka Active Record Session Store) component through 1.1.3 for Ruby on Rails does not use a constant-time approach when delivering information about whether a guessed session ID is valid. Consequently, remote attackers can leverage timing discrepancies to achieve a correct guess in a relatively short amount of time. This is a related issue to CVE-2019-16782. \n\n## Recommendation\n\nThis has been fixed in version 2.0.0.  All users are advised to update to this version or later.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "activerecord-session_store"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.0.0"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 1.1.3"
    }
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2019-25025"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rails/activerecord-session_store/pull/151"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rails/activerecord-session_store/commit/9d4dd113d3010b82daaadf0b0ee6b9fb2afb2160"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/rails/activerecord-session_store"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rails/activerecord-session_store/releases/tag/v2.0.0"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/activerecord-session_store/CVE-2019-25025.yml"
  }, {
    "type" : "WEB",
    "url" : "https://rubygems.org/gems/activerecord-session_store"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-208" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2021-03-09T00:45:19Z",
    "nvd_published_at" : "2021-03-05T06:15:00Z"
  }
}