CVE-2020-13353: Gitaly Gitaly Insufficient Session Expiration Vulnerability Vulnerability

LOW
Advisory Identifier: GHSA-mmmm-chjf-jmvw
CVSS 3.2
CWE-613
Published
Advisory Summary

CVE-2020-13353 is a LOW (CVSS 3.2) gitaly insufficient session expiration vulnerability vulnerability (CWE-613: Insufficient Session Expiration) affecting Gitaly libraries in the RubyGems ecosystem. The issue involves gitaly insufficient session expiration vulnerability. Remediation is available by upgrading affected packages to version 13.3.9, 13.4.5, 13.5.2.

CVE-2020-13353 at a Glance

CVE Identifier CVE-2020-13353
GHSA Identifier GHSA-mmmm-chjf-jmvw
Severity LOW
CVSS v3.1 Base Score 3.2
CWE Classification CWE-613: Insufficient Session Expiration
Affected Product Gitaly
Package Ecosystem RubyGems
Published Date
Last Updated

Security Impact

CVSS: 3.2

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:C/C:L/I:N/A:N).

Attack Vector Local (AV:L)
Attack Complexity Low (AC:L)
Privileges Required High (PR:H)
User Interaction None (UI:N)
Scope Changed (S:C)
Confidentiality Low (C:L)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2020-13353

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

gitaly fixed: 13.3.9
Upgrade gitaly to 13.3.9
gitaly fixed: 13.4.5
Upgrade gitaly to 13.4.5
gitaly fixed: 13.5.2
Upgrade gitaly to 13.5.2
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 gitaly

How to Check if You Are Affected

To determine whether your application is affected by CVE-2020-13353, inspect your project dependencies for Gitaly:

inspect dependencies for gitaly

Analyze the terminal output to locate any version of Gitaly in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 13.3.9), 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-613: Insufficient Session Expiration, where according to wasc, "insufficient session expiration is when a web site permits an attacker to reuse old session credentials or session ids for authorization.". In Gitaly, 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

When importing repos via URL, one time use git credentials were persisted beyond the expected time window in Gitaly 1.79.0 or above. Affected versions are: >=1.79.0, <13.3.9,>=13.4, <13.4.5,>=13.5, <13.5.2.

CVE-2020-13353 Affected Gitaly Versions

3 component(s)
Fixed Versions:
13.3.913.4.513.5.2
Product / Package Ecosystem Affected Versions Fixed Version
gitaly
RubyGems
≥ 1.79.0
< 13.3.9
13.3.9
gitaly
RubyGems
≥ 13.4
< 13.4.5
13.4.5
gitaly
RubyGems
≥ 13.5
< 13.5.2
13.5.2

References

Frequently Asked Questions

What is CVE-2020-13353?
CVE-2020-13353 is a security vulnerability in Gitaly involving Gitaly Insufficient Session Expiration vulnerability under CWE-613: Insufficient Session Expiration.
Which Gitaly versions are affected?
Affected versions include releases prior to 13.3.9, 13.4.5, 13.5.2 across affected packages: gitaly.
What version fixes CVE-2020-13353?
Upgrading to 13.3.9, 13.4.5, 13.5.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is gitaly affected?
Yes, gitaly is affected in releases prior to 13.3.9, 13.4.5, 13.5.2. Upgrade your dependency to 13.3.9, 13.4.5, 13.5.2 or later.
What is the CVSS score of CVE-2020-13353?
CVE-2020-13353 has a CVSS v3.1 base score of 3.2 (LOW) with vector string CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:C/C:L/I:N/A:N.
What CWE is associated with CVE-2020-13353?
CVE-2020-13353 is classified under CWE-613: Insufficient Session Expiration (According to WASC, "Insufficient Session Expiration is when a web site permits an attacker to reuse old session credentials or session IDs for authorization.").
How can I check RubyGems dependencies for CVE-2020-13353?
Run the dependency tree command: 'inspect dependencies for gitaly'. 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-mmmm-chjf-jmvw",
  "modified" : "2023-01-24T18:35:04Z",
  "published" : "2022-05-24T17:34:24Z",
  "aliases" : [ "CVE-2020-13353" ],
  "summary" : "Gitaly Insufficient Session Expiration vulnerability",
  "details" : "When importing repos via URL, one time use git credentials were persisted beyond the expected time window in Gitaly 1.79.0 or above. Affected versions are: >=1.79.0, <13.3.9,>=13.4, <13.4.5,>=13.5, <13.5.2.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:C/C:L/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "gitaly"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.79.0"
      }, {
        "fixed" : "13.3.9"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "gitaly"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "13.4"
      }, {
        "fixed" : "13.4.5"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "gitaly"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "13.5"
      }, {
        "fixed" : "13.5.2"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-13353"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/gitaly/CVE-2020-13353.yml"
  }, {
    "type" : "WEB",
    "url" : "https://gitlab.com/gitlab-org/cves/-/blob/master/2020/CVE-2020-13353.json"
  }, {
    "type" : "PACKAGE",
    "url" : "https://gitlab.com/gitlab-org/gitaly"
  }, {
    "type" : "WEB",
    "url" : "https://gitlab.com/gitlab-org/gitaly/-/issues/2882"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-613" ],
    "severity" : "LOW",
    "github_reviewed" : true,
    "github_reviewed_at" : "2023-01-24T18:35:04Z",
    "nvd_published_at" : "2020-11-17T01:15:00Z"
  }
}