Vulnerabilities in pkg:pypi/jupyterhub-systemdspawner

PACKAGE
Advisory Identifier: GHSA-cg54-gpgr-4rm6
Advisory Summary

CVE-2020-26261 is a HIGH (CVSS 7.9) user-readable api tokens vulnerability (CWE-668: Exposure of Resource to Wrong Sphere) affecting Jupyterhub systemdspawner libraries in the PyPI ecosystem. The issue involves user-readable api tokens in systemd units for jupyterhub. Remediation is available by upgrading affected packages to version 0.15.0.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:pypi/jupyterhub-systemdspawner

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:pypi/jupyterhub-systemdspawner. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-cg54-gpgr-4rm6 CVE-2020-26261 HIGH user-readable api tokens in systemd units for JupyterHub

CVE-2020-26261 at a Glance

CVE Identifier CVE-2020-26261
GHSA Identifier GHSA-cg54-gpgr-4rm6
Severity HIGH
CVSS v3.1 Base Score 7.9
CWE Classification CWE-668: Exposure of Resource to Wrong Sphere
Affected Product Jupyterhub systemdspawner
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 7.9

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

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

How to Fix CVE-2020-26261

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

jupyterhub-systemdspawner fixed: 0.15.0
pip install jupyterhub-systemdspawner>=0.15.0
Verify Direct and Transitive Dependencies

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

pip show jupyterhub-systemdspawner

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2020-26261, inspect your installed packages using pip:

pip show jupyterhub-systemdspawner

Analyze the terminal output to locate any version of Jupyterhub systemdspawner in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.15.0), your application is affected.

Note: The pip show jupyterhub-systemdspawner command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-668: Exposure of Resource to Wrong Sphere, where the product exposes a resource to the wrong control sphere, providing unintended actors with inappropriate access to the resource. In Jupyterhub systemdspawner, 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

### Impact user API tokens issued to single-user servers are specified in the environment of systemd units, which are accessible to all users. In particular, the-littlest-jupyterhub is affected, which uses systemdspawner by default. ### Patches Patched in jupyterhub-systemdspawner v0.15 ### Workarounds No workaround other than upgrading systemdspawner to 0.15 ### For more information If you have any questions or comments about this advisory: * Open a thread in [the Jupyter forum](https://discourse.jupyter.org) * Email us at [security@ipython.org](mailto:security@ipython.org)

CVE-2020-26261 Affected Jupyterhub systemdspawner Versions

1 component(s)
Fixed Versions:
0.15.0
Product / Package Ecosystem Affected Versions Fixed Version
jupyterhub-systemdspawner
PyPI
< 0.15.0
0.15.0

References

Frequently Asked Questions

What is CVE-2020-26261?
CVE-2020-26261 is a security vulnerability in Jupyterhub systemdspawner involving user-readable api tokens in systemd units for JupyterHub under CWE-668: Exposure of Resource to Wrong Sphere.
Which Jupyterhub systemdspawner versions are affected?
Affected versions include releases prior to 0.15.0 across affected packages: jupyterhub-systemdspawner.
What version fixes CVE-2020-26261?
Upgrading to 0.15.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is jupyterhub-systemdspawner affected?
Yes, jupyterhub-systemdspawner is affected in releases prior to 0.15.0. Upgrade your dependency to 0.15.0 or later.
What is the CVSS score of CVE-2020-26261?
CVE-2020-26261 has a CVSS v3.1 base score of 7.9 (HIGH) with vector string CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N.
What CWE is associated with CVE-2020-26261?
CVE-2020-26261 is classified under CWE-668: Exposure of Resource to Wrong Sphere (The product exposes a resource to the wrong control sphere, providing unintended actors with inappropriate access to the resource.).
How can I check PyPI dependencies for CVE-2020-26261?
Run the dependency tree command: 'pip show jupyterhub-systemdspawner'. 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-cg54-gpgr-4rm6",
  "modified" : "2024-09-27T15:38:37Z",
  "published" : "2020-12-09T16:27:43Z",
  "aliases" : [ "CVE-2020-26261" ],
  "summary" : "user-readable api tokens in systemd units for JupyterHub",
  "details" : "### Impact\nuser API tokens issued to single-user servers are specified in the environment of systemd units, which are accessible to all users.\n\nIn particular, the-littlest-jupyterhub is affected, which uses systemdspawner by default.\n\n### Patches\nPatched in jupyterhub-systemdspawner v0.15\n\n### Workarounds\nNo workaround other than upgrading systemdspawner to 0.15\n\n### For more information\n\nIf you have any questions or comments about this advisory:\n* Open a thread in [the Jupyter forum](https://discourse.jupyter.org)\n* Email us at [security@ipython.org](mailto:security@ipython.org)",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:N"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N/E:U"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "jupyterhub-systemdspawner"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.15.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/jupyterhub/systemdspawner/security/advisories/GHSA-cg54-gpgr-4rm6"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-26261"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/jupyterhub/systemdspawner/commit/a4d08fd2ade1cfd0ef2c29dc221e649345f23580"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/jupyterhub/systemdspawner"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/jupyterhub/systemdspawner/blob/master/CHANGELOG.md#v015"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/jupyterhub-systemdspawner/PYSEC-2020-52.yaml"
  }, {
    "type" : "WEB",
    "url" : "https://pypi.org/project/jupyterhub-systemdspawner"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-668" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-12-09T16:25:35Z",
    "nvd_published_at" : null
  }
}